
:root {

    --primary: #F9AC16;
    --primary-hover: #E69A00;
    --primary-light: #FFF4D6;
    --primary-accent: #FFCD00;

    --secondary: #B9BCBA;

    --text-primary: #484F50;
    --text-secondary: #687070;

    --background: #F5F5F5;
    --surface: #FFFFFF;
    --border: #E2E5E4;

    --success: #16A34A;
    --warning: #EA580C;
    --danger: #DC2626;
    --info: #2563EB;

    --radius: 10px;

    --shadow:
        0 4px 20px rgba(0, 0, 0, 0.05);

}

/* CONFIGURACION GENERAL */

* {
    box-sizing: border-box;
}

[hidden] {
    display: none !important;
}

body {

    margin: 0;

    min-height: 100vh;

    display: flex;
    flex-direction: column;

    background: var(--background);

    color: var(--text-primary);

    font-family:
        "Segoe UI",
        Arial,
        sans-serif;

    font-size: 15px;
    line-height: 1.6;

}

button,
input,
textarea,
select {

    font: inherit;

}

button {

    cursor: pointer;

}

button:disabled {

    opacity: 0.6;
    cursor: not-allowed;

}

/* ENCABEZADO */

.header {

    background: var(--surface);

    border-top: 7px solid var(--primary);
    border-bottom: 1px solid var(--border);

}

.header-container {

    max-width: 1100px;

    margin: auto;
    padding: 18px 28px;

    display: flex;
    align-items: center;

    gap: 25px;

}

.logo {

    width: 125px;
    height: auto;

    display: block;

    object-fit: contain;

}

.header-divider {

    height: 55px;
    width: 1px;

    background: var(--border);

}

.header-title h1 {

    font-size: 24px;

    margin: 0;

    font-weight: 650;

}

.header-title span {

    color: var(--text-secondary);

    font-size: 14px;

}

/* CONTENIDO PRINCIPAL */

.main-container {

    width: 100%;
    max-width: 950px;

    margin: 0 auto;

    padding: 40px 24px 60px;

    flex: 1;

}

.welcome {

    margin-bottom: 28px;

}

.section-label {

    color: #916000;

    font-size: 12px;
    font-weight: 750;

    letter-spacing: 2px;

}

.welcome h2 {

    margin: 8px 0;

    font-size: 32px;
    line-height: 1.3;

    font-weight: 650;

}

.welcome p {

    color: var(--text-secondary);

    margin: 8px 0 0;

}

/* TARJETA PRINCIPAL */

.form-card {

    background: var(--surface);

    border: 1px solid var(--border);
    border-radius: var(--radius);

    box-shadow: var(--shadow);

    overflow: hidden;

}

.card-heading {

    padding: 24px 30px;

    border-bottom: 1px solid var(--border);

    background: #FAFAFA;

}

.card-heading h3 {

    margin: 0 0 4px;

    font-size: 21px;

}

.card-heading p {

    margin: 0;

    font-size: 13px;

    color: var(--text-secondary);

}

#ticketForm {

    padding: 0 30px 30px;

}

/* SECCIONES */

.form-section {

    padding: 28px 0;

    border-bottom: 1px solid var(--border);

}

.form-section h4 {

    display: flex;
    align-items: center;

    gap: 12px;

    margin: 0 0 22px;

    font-size: 17px;

}

.section-number {

    display: inline-flex;

    align-items: center;
    justify-content: center;

    width: 34px;
    height: 34px;

    background: var(--primary-light);

    color: #916000;

    font-size: 13px;
    font-weight: 700;

    border-radius: 7px;

}

.section-description {

    color: var(--text-secondary);

    font-size: 14px;

    margin: -5px 0 20px;

}

/* CAMPOS */

.form-grid {

    display: grid;

    grid-template-columns: 1fr 1fr;

    gap: 20px;

}

.form-group {

    display: flex;
    flex-direction: column;

    margin-bottom: 20px;

    gap: 7px;

    min-width: 0;

}

.form-group:last-child {

    margin-bottom: 0;

}

.form-group label {

    font-size: 14px;
    font-weight: 600;

}

input,
textarea,
select {

    width: 100%;

    padding: 12px 14px;

    border: 1px solid #CDD1D0;
    border-radius: 7px;

    background: var(--surface);

    color: var(--text-primary);

    outline: none;

    transition:
        border-color 0.2s,
        box-shadow 0.2s;

}

input:focus,
textarea:focus,
select:focus {

    border-color: var(--primary-hover);

    box-shadow:
        0 0 0 3px rgba(249, 172, 22, 0.18);

}

input::placeholder,
textarea::placeholder {

    color: #858B8B;

}

textarea {

    resize: vertical;

    min-height: 130px;

}

.form-group small {

    font-size: 12px;

    color: var(--text-secondary);

}

.character-counter {

    text-align: right;

    font-size: 12px;

    color: var(--text-secondary);

}

/* CARGA DE EVIDENCIAS */

.drop-zone {

    display: flex;
    flex-direction: column;

    align-items: center;

    gap: 10px;

    padding: 30px 15px;

    border: 2px dashed var(--primary);

    border-radius: var(--radius);

    background: #FFFCF4;

    text-align: center;

    transition:
        background 0.2s,
        border-color 0.2s;

}

.drop-zone.dragging {

    background: var(--primary-light);

    border-color: var(--primary-hover);

}

.upload-icon {

    width: 42px;
    height: 42px;

    color: #B87800;

    margin-bottom: 4px;

}

.drop-zone span,
.drop-zone small {

    color: var(--text-secondary);

}

.drop-zone span {

    font-size: 13px;

}

.drop-zone small {

    font-size: 12px;

}

.image-preview {

    display: grid;

    grid-template-columns:
        repeat(auto-fill, minmax(140px, 1fr));

    gap: 14px;

    margin-top: 20px;

}

.preview-card {

    position: relative;

    border: 1px solid var(--border);
    border-radius: 8px;

    overflow: hidden;

    background: var(--surface);

}

.preview-card img {

    display: block;

    width: 100%;
    height: 115px;

    object-fit: contain;

    background: #F3F3F3;

}

.preview-info {

    padding: 10px;

}

.preview-name {

    display: block;

    overflow: hidden;

    text-overflow: ellipsis;
    white-space: nowrap;

    font-size: 12px;

    font-weight: 600;

}

.preview-size {

    font-size: 11px;

    color: var(--text-secondary);

}

.remove-image {

    position: absolute;

    top: 7px;
    right: 7px;

    width: 28px;
    height: 28px;

    border: none;
    border-radius: 50%;

    background: var(--danger);

    color: white;

    font-size: 18px;

    line-height: 1;

}

.attachment-summary {

    margin-top: 14px;

    font-size: 12px;

    color: var(--text-secondary);

}

/* BOTONES */

.button-primary {

    display: inline-flex;

    align-items: center;
    justify-content: center;

    width: 100%;

    padding: 14px 22px;

    border: 1px solid transparent;
    border-radius: 7px;

    background: var(--primary);

    color: #332600;

    font-size: 15px;
    font-weight: 700;

    transition: background 0.2s;

}

.button-primary:hover:not(:disabled) {

    background: var(--primary-hover);

}

.button-secondary {

    padding: 9px 18px;

    border: 1px solid #D7DAD9;
    border-radius: 6px;

    background: var(--surface);

    color: var(--text-primary);

    font-size: 13px;
    font-weight: 600;

}

.button-secondary:hover:not(:disabled) {

    border-color: var(--primary-hover);

    background: var(--primary-light);

}

button:focus-visible {

    outline: 3px solid var(--text-primary);
    outline-offset: 3px;

}

.form-actions {

    padding-top: 28px;

}

.form-actions p {

    margin: 12px 0 0;

    font-size: 12px;

    text-align: center;

    color: var(--text-secondary);

}

/* MENSAJES */

.form-message,
.file-message {

    padding: 12px 15px;

    margin-top: 15px;

    border-radius: 7px;

    font-size: 13px;

    white-space: pre-line;

}

.message-error {

    background: #FEF2F2;

    border: 1px solid #FECACA;

    color: #B91C1C;

}

.message-info {

    background: #EFF6FF;

    border: 1px solid #BFDBFE;

    color: #1D4ED8;

}

/* CONFIRMACION */

.success-card {

    padding: 45px 30px;

    text-align: center;

}

.success-icon {

    display: flex;

    align-items: center;
    justify-content: center;

    width: 75px;
    height: 75px;

    margin: 0 auto 20px;

    background: #DCFCE7;

    border-radius: 50%;

    color: var(--success);

    font-size: 38px;

}

.success-card h2 {

    margin: 10px 0;

}

.success-card p {

    color: var(--text-secondary);

}

.folio-container {

    display: flex;
    flex-direction: column;

    align-items: center;

    gap: 12px;

    padding: 25px;

    margin: 28px 0;

    background: var(--primary-light);

    border: 1px solid var(--primary);

    border-radius: var(--radius);

}

.folio-container span {

    font-size: 12px;

    letter-spacing: 2px;

    font-weight: 700;

}

.folio-container strong {

    font-size: clamp(20px, 5vw, 32px);

    color: var(--text-primary);

    overflow-wrap: anywhere;

}

/* PIE DE PAGINA */

.footer {

    display: flex;
    flex-direction: column;

    align-items: center;

    gap: 6px;

    padding: 28px 20px;

    background: var(--text-primary);

    border-bottom: 5px solid var(--primary);

    color: white;

    text-align: center;

}

.footer span {

    font-size: 13px;

    color: #E0E2E2;

}

.footer a {

    color: var(--primary-accent);

    font-size: 13px;

    text-decoration: none;

}

.footer a:hover {

    text-decoration: underline;

}

.footer small {

    margin-top: 10px;

    font-size: 11px;

    color: #E0E2E2;

}

/* DISPOSITIVOS MOVILES */

@media (max-width: 600px) {

    .header-container {

        padding: 15px;

        gap: 15px;

    }

    .logo {

        width: 90px;

    }

    .header-title h1 {

        font-size: 19px;

    }

    .header-title span {

        font-size: 12px;

    }

    .header-divider {

        height: 45px;

    }

    .main-container {

        padding: 25px 14px 35px;

    }

    .welcome h2 {

        font-size: 25px;

    }

    .form-grid {

        grid-template-columns: 1fr;

        gap: 16px;

    }

    .card-heading {

        padding: 20px;

    }

    #ticketForm {

        padding: 0 20px 20px;

    }

    .form-section h4 {

        font-size: 15px;

    }

    .image-preview {

        grid-template-columns: repeat(2, minmax(0, 1fr));

    }

    .success-card {

        padding: 30px 20px;

    }

}
