* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    min-height: 100%;
    color-scheme: dark;
}

body {
    background: #020204 url('../assets/bg-pagina-contato.webp');
    background-repeat: no-repeat;
    background-size: cover;
    min-height: 100dvh;
    position: relative;
    padding: 0 1rem;
    color: #f5f5f5;
    font-family: 'Manrope', sans-serif;
    line-height: 1.4;
}

body::before {
    content: '';
    position: absolute;
    inset: 0;
    background: rgba(2, 2, 4, .9);
    z-index: 2;
    pointer-events: none;
}

body > * {
    position: relative;
    z-index: 3;
}

button,
input,
textarea {
    font: inherit;
}

button {
    border: 0;
}

.quiz-page {
    width: min(100%, 660px);
    margin: 0 auto;
    padding: 28px 0 50px;
}

.logo {
    display: block;
    width: 86px;
    height: auto;
    margin: 0 auto 22px;
}

.quiz-shell {
    width: 100%;
    background: #020204;
    border: 1px solid rgba(255, 255, 255, .08);
    border-radius: 20px;
    padding: 20px;
    overflow: hidden;
    box-shadow: 0 22px 60px rgba(0, 0, 0, .28);
}

.quiz-progress {
    margin-bottom: 30px;
}

.progress-meta {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    color: rgba(245, 245, 245, .58);
    font-size: .78rem;
}

.btn-back {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 0;
    background: transparent;
    color: rgba(245, 245, 245, .78);
    cursor: pointer;
    line-height: 1;
}

.btn-back span:first-child {
    font-family: Arial, sans-serif;
    font-size: 1.25rem;
    transform: translateY(-1px);
}

.btn-back:disabled {
    opacity: .35;
    cursor: default;
}

.progress-track {
    width: 100%;
    height: 3px;
    margin-top: 12px;
    border-radius: 99px;
    background: rgba(255, 255, 255, .12);
    overflow: hidden;
}

.progress-track span {
    display: block;
    height: 100%;
    width: 0;
    border-radius: inherit;
    background: #C76400;
    transition: width .35s ease;
}

.step {
    display: none;
}

.step.active {
    display: block;
    animation: stepIn .38s ease both;
}

.step.leaving {
    animation: stepOut .22s ease both;
}

@keyframes stepIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes stepOut {
    from {
        opacity: 1;
        transform: translateY(0);
    }
    to {
        opacity: 0;
        transform: translateY(-7px);
    }
}

.question {
    margin-bottom: 24px;
}

.eyebrow {
    margin-bottom: 8px;
    color: #C76400;
    font-size: .72rem;
    font-weight: 500;
    letter-spacing: .08em;
    text-transform: uppercase;
}

h1,
h2 {
    color: #fff;
    font-family: 'Gentium Book Plus', serif;
    font-weight: 400;
    line-height: 1.05;
}

h1 {
    font-size: clamp(2rem, 7vw, 3rem);
}

h2 {
    font-size: clamp(1.8rem, 6vw, 2.5rem);
}

.description,
.question > p:not(.eyebrow),
.status-card > p:not(.eyebrow),
.modal > p:not(.eyebrow) {
    margin-top: 10px;
    color: rgba(245, 245, 245, .6);
    font-size: .9rem;
}

.options {
    display: grid;
    gap: 8px;
}

.option-card {
    position: relative;
    display: flex;
    align-items: center;
    gap: 14px;
    min-height: 62px;
    padding: 15px 16px;
    border: 1px solid rgba(255, 255, 255, .13);
    border-radius: 12px;
    background: transparent;
    cursor: pointer;
    transition: border-color .2s ease, background .2s ease, transform .2s ease;
}

.option-card:hover {
    border-color: rgba(199, 100, 0, .7);
    transform: translateY(-1px);
}

.option-card:has(input:checked) {
    border-color: rgba(199, 100, 0, .95);
    background: rgba(199, 100, 0, .08);
}

.option-card input {
    position: absolute;
    opacity: 0;
    pointer-events: none;
}

.option-copy {
    display: grid;
    gap: 3px;
    flex: 1;
    min-width: 0;
}

.option-copy strong {
    color: rgba(255, 255, 255, .92);
    font-size: .9rem;
    font-weight: 400;
}

.option-copy small {
    color: rgba(255, 255, 255, .48);
    font-size: .72rem;
}

.radio-ui,
.check-ui {
    flex: 0 0 auto;
    width: 20px;
    height: 20px;
    border: 1px solid rgba(255, 255, 255, .35);
}

.radio-ui {
    border-radius: 50%;
    position: relative;
    transition: border-color .2s ease;
}

.check-ui {
    border-radius: 5px;
    position: relative;
    transition: border-color .2s ease, background .2s ease;
}

.option-card:has(input:checked) .radio-ui {
    border-color: #C76400;
}

.option-card:has(input:checked) .radio-ui::after {
    content: '';
    position: absolute;
    inset: 4px;
    border-radius: 50%;
    background: #C76400;
    animation: radioPop .2s ease both;
}

.option-card:has(input:checked) .check-ui {
    border-color: #C76400;
    background: #C76400;
}

.option-card:has(input:checked) .check-ui::after {
    content: '';
    position: absolute;
    left: 5px;
    top: 2px;
    width: 6px;
    height: 10px;
    border: solid #020204;
    border-width: 0 2px 2px 0;
    transform: rotate(45deg);
}

@keyframes radioPop {
    from { transform: scale(.4); opacity: .3; }
    to { transform: scale(1); opacity: 1; }
}

.field {
    display: grid;
    gap: 8px;
    margin-top: 16px;
}

.field > span {
    color: rgba(255, 255, 255, .72);
    font-size: .78rem;
}

.field em {
    color: rgba(255, 255, 255, .4);
    font-style: normal;
}

.field input,
.field textarea {
    width: 100%;
    border: 1px solid rgba(255, 255, 255, .23);
    border-radius: 10px;
    background: transparent;
    color: #fff;
    outline: none;
    transition: border-color .2s ease, box-shadow .2s ease;
}

.field input {
    min-height: 52px;
    padding: 14px 15px;
}

.field textarea {
    min-height: 140px;
    padding: 14px 15px;
    resize: vertical;
}

.field input::placeholder,
.field textarea::placeholder {
    color: rgba(255, 255, 255, .33);
}

.field input:focus,
.field textarea:focus {
    border-color: #C76400;
    box-shadow: 0 0 0 3px rgba(199, 100, 0, .1);
}

.field.invalid input,
.field.invalid textarea {
    border-color: #c43d3d;
}

.btn-next,
.btn-submit,
.btn-primary,
.btn-secondary {
    width: 100%;
    min-height: 52px;
    margin-top: 22px;
    border-radius: 10px;
    cursor: pointer;
    font-weight: 500;
    transition: transform .2s ease, opacity .2s ease, background .2s ease;
}

.btn-next,
.btn-submit,
.btn-primary {
    background: #C76400;
    color: #fff;
}

.btn-next:hover,
.btn-submit:hover,
.btn-primary:hover {
    transform: translateY(-1px);
    background: #dd7200;
}

.btn-secondary {
    border: 1px solid rgba(255, 255, 255, .16);
    background: transparent;
    color: rgba(255, 255, 255, .8);
}

.btn-secondary:hover {
    background: rgba(255, 255, 255, .05);
}

.overlay,
.status-screen {
    position: fixed !important;
    inset: 0;
    display: grid;
    place-items: center;
    padding: 20px;
    background: rgba(2, 2, 4, .78);
    backdrop-filter: blur(8px);
}

.overlay {
    z-index: 20;
}

.status-screen {
    z-index: 25;
}

.hidden {
    display: none !important;
}

.modal,
.status-card {
    width: min(100%, 440px);
    padding: 28px;
    border: 1px solid rgba(255, 255, 255, .1);
    border-radius: 18px;
    background: #020204;
    box-shadow: 0 28px 80px rgba(0, 0, 0, .45);
}

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

.modal-actions button {
    margin-top: 20px;
}

.status-card {
    text-align: center;
}

.status-card .btn-primary {
    margin-top: 24px;
}

.toast {
    position: fixed;
    left: 50%;
    bottom: 22px;
    z-index: 40;
    width: min(calc(100% - 32px), 420px);
    padding: 12px 14px;
    border: 1px solid rgba(255, 255, 255, .1);
    border-radius: 10px;
    background: #111116;
    color: rgba(255, 255, 255, .9);
    font-size: .78rem;
    text-align: center;
    opacity: 0;
    pointer-events: none;
    transform: translate(-50%, 12px);
    transition: opacity .2s ease, transform .2s ease;
}

.toast.show {
    opacity: 1;
    transform: translate(-50%, 0);
}

@media (max-width: 520px) {
    body {
        padding: 0 .7rem;
    }

    .quiz-page {
        padding-top: 18px;
    }

    .logo {
        width: 74px;
        margin-bottom: 16px;
    }

    .quiz-shell {
        padding: 18px 15px 16px;
        border-radius: 18px;
    }

    .question {
        margin-bottom: 20px;
    }

    .option-card {
        min-height: 58px;
        padding: 14px;
    }

    .option-copy strong {
        font-size: .84rem;
    }

    .modal-actions {
        grid-template-columns: 1fr;
    }

    .modal-actions button {
        margin-top: 10px;
    }

    .modal {
        padding: 24px 20px;
    }
}

@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: .01ms !important;
        animation-iteration-count: 1 !important;
        scroll-behavior: auto !important;
        transition-duration: .01ms !important;
    }
}

/* Tela final de envio */
.success-screen {
    position: fixed !important;
    inset: 0;
    z-index: 25;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 28px;
    padding: 24px 16px;
    text-align: center;
}

.success-logo {
    width: 82px;
    height: auto;
}

.success-card {
    width: min(100%, 560px);
    padding: 42px 34px 46px;
    border: 1px solid rgba(255, 255, 255, .09);
    border-radius: 20px;
    background: #020204;
    box-shadow: 0 28px 90px rgba(0, 0, 0, .38);
    animation: successIn .5s ease both;
}

.success-icon {
    display: grid;
    place-items: center;
    width: 58px;
    height: 58px;
    margin: 0 auto 26px;
    border: 1px solid rgba(199, 100, 0, .8);
    border-radius: 50%;
    color: #C76400;
}

.success-icon svg {
    width: 28px;
    height: 28px;
}

.success-card .eyebrow {
    margin-bottom: 10px;
}

.success-card h2 {
    font-size: clamp(2.1rem, 6vw, 3.4rem);
}

.success-card > p:last-child {
    width: min(100%, 430px);
    margin: 16px auto 0;
    color: rgba(245, 245, 245, .58);
    font-size: .95rem;
}

@keyframes successIn {
    from {
        opacity: 0;
        transform: translateY(14px) scale(.985);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

@media (max-width: 520px) {
    .success-screen {
        gap: 22px;
    }

    .success-logo {
        width: 72px;
    }

    .success-card {
        padding: 34px 22px 38px;
        border-radius: 18px;
    }

    .success-icon {
        width: 52px;
        height: 52px;
        margin-bottom: 22px;
    }

    .success-card h2 {
        font-size: 2.25rem;
    }
}
