:root {
    --primary-color: #2E1F61;
    --secondary-color: #2E1F61;
    --tertiary-color: #B49FFB;
    --fourth-color: rgba(180, 159, 251, 0.15);
    --fifth-color: rgba(250, 159, 201, 0.49);
    --accent-color: #E52E8D;
    --text-color: #FA9FC9;
    --light-text: #FFFFFF;
    --spacing: 2rem;
    --light-gray: #DFE1E4;
    --rose: #FA9FC9;
    --dark-blue: #102036;
    --dusty-rose: #E52E8D;
    --gray-blue: #A5B2BA;
    --white: #FFFFFF;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    color: var(--primary-color);
}

@font-face {
    font-family: 'NexaExtraLight';
    src: url('https://codigoenblanco.com/assets/fonts/nexa/Nexa-ExtraLight.woff2') format('woff2'),
        url('https://codigoenblanco.com/assets/fonts/nexa/Nexa-ExtraLight.woff') format('woff');
    font-weight: normal;
    font-style: normal;
    font-display: swap;
}

@font-face {
    font-family: 'NexaHeavy';
    src: url('https://codigoenblanco.com/assets/fonts/nexa/Nexa-Heavy.woff2') format('woff2'),
        url('https://codigoenblanco.com/assets/fonts/nexa/Nexa-Heavy.woff') format('woff');
    font-weight: normal;
    font-style: normal;
    font-display: swap;
}

body {
    font-family: 'NexaExtraLight';
    line-height: 1.6;
    color: var(--light-text);
    height: 100%;
    background-color: var(--primary-color);
    position: relative;
}

h1,
h2,
h3,
h4,
h5,
h6 {
    font-family: 'NexaHeavy';
}

b {
    font-family: 'NexaHeavy';
    font-weight: normal;
}

.text-white {
    color: var(--white);
}

.container {
    max-width: 1200px;
    margin: 5vh auto 0vh auto;
    background: var(--white);
    border-radius: 10px;
    padding: 20px;
    box-shadow: 0 8px 30px rgba(16, 32, 54, 0.08);
    display: grid;
    grid-template-columns: 1fr 420px;
    gap: 20px;
    min-height: 80vh;
    align-items: center;
}

@media (max-width:980px) {
    .container {
        grid-template-columns: 1fr;
    }
}

header.card {
    display: flex;
    gap: 16px;
    align-items: center;
    border-bottom: 1px solid #e6e9ee;
    padding-bottom: 12px;
    margin-bottom: 12px;
}

header.card img {
    width: 96px;
    height: 96px;
    object-fit: cover;
    border-radius: 8px;
    background: #eee;
}

.meta {
    display: flex;
    flex-direction: column;
}

h1 {
    margin: 0;
    font-size: 1.25rem;
}

.position {
    color: #4b5563;
    margin-top: 6px;
}

section {
    margin-bottom: 12px;
}

.kv {
    font-weight: 700;
    margin-right: 6px;
}

.form-panel {
    background: #fbfbff;
    padding: 12px;
    border-radius: 8px;
    border: 1px solid #eef2ff;
    max-height: 80vh;
    overflow: auto;
}

label {
    display: block;
    font-size: .9rem;
    margin-top: 8px;
    color: #374151;
}

input[type="text"],
input[type="url"],
input,
textarea {
    width: 100%;
    padding: 8px;
    border: 1px solid #e6e9ee;
    border-radius: 6px;
    margin-top: 6px;
    box-sizing: border-box;
}

input[type="checkbox"] {
    width: 13px;
}

textarea {
    min-height: 72px;
    resize: vertical;
}

.grid-2 {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px;
}

.btn {
    background: #2563eb;
    color: white;
    padding: 8px 12px;
    border-radius: 6px;
    border: none;
    cursor: pointer;
    margin-top: 12px;
}

.note {
    font-size: .85rem;
    color: #6b7280;
    margin-top: 8px;
}

.preview {
    padding: 12px;
    border-radius: 8px;
    border: 1px solid #e6e9ee;
}

.input-clear-wrap {
    position: relative;
    display: flex;
    align-items: center;
}

.input-clear-btn {
    position: absolute;
    right: 10px;
    top: 60%;
    transform: translateY(-50%);
    background: none;
    border: none;
    color: #888;
    font-size: 1.1em;
    cursor: pointer;
    padding: 0 4px;
    line-height: 1;
    z-index: 2;
}

.input-clear-wrap input:not(:disabled):not([readonly]):not(:placeholder-shown):not([type="hidden"]):not([type="submit"]):not([type="button"]):not([type="checkbox"]):not([type="radio"]),
.input-clear-wrap textarea:not(:disabled):not([readonly]):not(:placeholder-shown) {
    padding-right: 2em;
}

.input-clear-wrap.has-value .input-clear-btn {
    display: block;
}

.text-gray {
    color: var(--light-gray);
}

.text-rose {
    color: var(--rose);
}

#fullPreview {
    word-break: break-word;
    overflow-wrap: anywhere;
}

#fullPreview a {
    word-break: break-all;
    overflow-wrap: anywhere;
    text-decoration: underline;
    color: #2d3a4a;
}