/* Octtane — Termos de Garantia (home + formulário) */

/* ========== HOME — seção destaque ========== */
.warranty-section {
    position: relative;
    padding: 88px 0 96px;
    background: linear-gradient(165deg, #0a0a0a 0%, #141414 40%, #1a0808 100%);
    overflow: hidden;
}

.warranty-section__glow {
    position: absolute;
    border-radius: 50%;
    filter: blur(80px);
    pointer-events: none;
    opacity: 0.45;
}

.warranty-section__glow--left {
    width: 420px;
    height: 420px;
    background: #e40f0f;
    top: -120px;
    left: -100px;
}

.warranty-section__glow--right {
    width: 320px;
    height: 320px;
    background: #ff4444;
    bottom: -80px;
    right: -60px;
    opacity: 0.25;
}

.warranty-header {
    position: relative;
    z-index: 1;
    text-align: center;
    max-width: 720px;
    margin: 0 auto 56px;
}

.warranty-header__badge {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 8px 18px;
    background: rgba(228, 15, 15, 0.15);
    border: 1px solid rgba(228, 15, 15, 0.4);
    border-radius: 100px;
    color: #ff6b6b;
    font-size: 12px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    margin-bottom: 20px;
}

.warranty-header__badge-dot {
    width: 8px;
    height: 8px;
    background: #e40f0f;
    border-radius: 50%;
    animation: warranty-pulse 2s ease infinite;
}

@keyframes warranty-pulse {
    0%, 100% { opacity: 1; transform: scale(1); }
    50% { opacity: 0.5; transform: scale(1.2); }
}

.warranty-header__title {
    font-family: 'Muli', sans-serif;
    font-size: clamp(32px, 5vw, 44px);
    font-weight: 800;
    color: #fff;
    line-height: 1.15;
    margin-bottom: 16px;
}

.warranty-header__title span {
    color: #e40f0f;
}

.warranty-header__lead {
    font-size: 17px;
    color: rgba(255, 255, 255, 0.65);
    line-height: 1.7;
    margin: 0;
}

/* Bento grid */
.warranty-bento {
    position: relative;
    z-index: 1;
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
}

.w-card {
    background: rgba(255, 255, 255, 0.97);
    border-radius: 16px;
    padding: 28px 28px 26px;
    border: 1px solid rgba(255, 255, 255, 0.08);
    box-shadow: 0 4px 24px rgba(0, 0, 0, 0.25), 0 0 0 1px rgba(255, 255, 255, 0.05) inset;
    transition: transform 0.35s ease, box-shadow 0.35s ease;
}

.w-card:hover {
    transform: translateY(-6px);
    box-shadow: 0 20px 48px rgba(0, 0, 0, 0.35), 0 0 0 1px rgba(228, 15, 15, 0.15);
}

.w-card--deadline {
    grid-column: 1 / -1;
    background: linear-gradient(135deg, #e40f0f 0%, #b80c0c 50%, #1a1a1a 100%);
    border: none;
    padding: 0;
    overflow: hidden;
}

.w-card--deadline:hover {
    transform: translateY(-4px);
    box-shadow: 0 24px 56px rgba(228, 15, 15, 0.35);
}

.w-card__deadline-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 32px;
    padding: 32px 40px;
    flex-wrap: wrap;
}

.w-card__deadline-left {
    display: flex;
    align-items: center;
    gap: 20px;
}

.w-card__deadline-right {
    text-align: right;
}

.w-card__deadline-number {
    font-family: 'Muli', sans-serif;
    font-size: 64px;
    font-weight: 800;
    color: #fff;
    line-height: 1;
    display: block;
}

.w-card__deadline-unit {
    font-size: 22px;
    font-weight: 700;
    color: rgba(255, 255, 255, 0.9);
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.w-card__deadline-note {
    font-size: 13px;
    color: rgba(255, 255, 255, 0.7);
    margin: 8px 0 0;
}

.w-card__top {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    margin-bottom: 18px;
}

.w-card__icon {
    width: 52px;
    height: 52px;
    border-radius: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.w-card__icon--red {
    background: linear-gradient(135deg, #ffe5e5, #ffcccc);
    color: #e40f0f;
}

.w-card__icon--amber {
    background: linear-gradient(135deg, #fff8e6, #ffecd0);
    color: #d97706;
}

.w-card__icon--green {
    background: linear-gradient(135deg, #e6faf3, #c8f0de);
    color: #059669;
}

.w-card__icon--white {
    background: rgba(255, 255, 255, 0.2);
    color: #fff;
    border: 1px solid rgba(255, 255, 255, 0.3);
}

.w-card__tag {
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    padding: 6px 12px;
    border-radius: 6px;
    background: #f4f4f4;
    color: #555;
}

.w-card__tag--amber {
    background: #fef3c7;
    color: #b45309;
}

.w-card__tag--green {
    background: #d1fae5;
    color: #047857;
}

.w-card__tag--light {
    background: rgba(255, 255, 255, 0.2);
    color: #fff;
}

.w-card__title {
    font-family: 'Muli', sans-serif;
    font-size: 22px;
    font-weight: 800;
    color: #111;
    margin: 0 0 12px;
    line-height: 1.25;
}

.w-card__title--light {
    color: #fff;
    margin-bottom: 0;
}

.w-card__text {
    font-size: 15px;
    color: #555;
    line-height: 1.65;
    margin: 0;
}

.w-card__text strong {
    color: #222;
}

.w-card__list {
    list-style: none;
    margin: 20px 0 0;
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.w-card__list li {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 14px 16px;
    background: #fafafa;
    border-radius: 10px;
    border: 1px solid #eee;
}

.w-card__price {
    font-family: 'Muli', sans-serif;
    font-size: 22px;
    font-weight: 800;
    color: #e40f0f;
    white-space: nowrap;
}

.w-card__list-label {
    font-size: 14px;
    color: #444;
}

.w-card__list-icon {
    font-size: 20px;
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #fff;
    border-radius: 8px;
    border: 1px solid #ddd;
    flex-shrink: 0;
}

.w-card__checks {
    list-style: none;
    margin: 16px 0 0;
    padding: 0;
}

.w-card__checks li {
    position: relative;
    padding: 10px 0 10px 32px;
    font-size: 15px;
    color: #333;
    border-bottom: 1px solid #f0f0f0;
}

.w-card__checks li:last-child {
    border-bottom: none;
}

.w-card__checks li::before {
    content: '✓';
    position: absolute;
    left: 0;
    top: 50%;
    transform: translateY(-50%);
    width: 22px;
    height: 22px;
    background: #059669;
    color: #fff;
    font-size: 12px;
    font-weight: 700;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    line-height: 22px;
    text-align: center;
}

/* ========== FORMULÁRIO ========== */
.termos-form-box {
    margin: 28px 0;
    padding: 0;
    border-radius: 16px;
    overflow: hidden;
    border: 2px solid #e40f0f;
    box-shadow: 0 8px 32px rgba(228, 15, 15, 0.12);
}

.termos-form-box__header {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 18px 24px;
    background: linear-gradient(90deg, #1a1a1a, #2d0a0a);
    color: #fff;
}

.termos-form-box__icon {
    width: 44px;
    height: 44px;
    background: rgba(228, 15, 15, 0.25);
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #ff6b6b;
}

.termos-form-box__title {
    font-family: 'Muli', sans-serif;
    font-size: 18px;
    font-weight: 800;
    margin: 0;
}

.termos-form-cards {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 0;
    background: #fff;
}

.termos-mini {
    padding: 18px 20px;
    border-bottom: 1px solid #f0f0f0;
    border-right: 1px solid #f0f0f0;
}

.termos-mini:nth-child(2n) {
    border-right: none;
}

.termos-mini:nth-last-child(-n+2) {
    border-bottom: none;
}

.termos-mini__label {
    display: block;
    font-size: 10px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    margin-bottom: 6px;
    color: #888;
}

.termos-mini p {
    margin: 0;
    font-size: 13px;
    color: #444;
    line-height: 1.5;
}

.termos-mini--warn {
    background: #fff9f9;
}

.termos-mini--warn .termos-mini__label {
    color: #e40f0f;
}

.termos-mini--ok {
    background: #f6fdf9;
}

.termos-mini--ok .termos-mini__label {
    color: #059669;
}

.termos-accept {
    display: flex;
    align-items: flex-start;
    gap: 14px;
    cursor: pointer;
    padding: 20px 24px;
    background: #111;
    margin: 0;
}

.termos-accept input {
    position: absolute;
    opacity: 0;
    width: 0;
    height: 0;
}

.termos-accept__box {
    width: 22px;
    height: 22px;
    flex-shrink: 0;
    margin-top: 2px;
    border: 2px solid #555;
    border-radius: 6px;
    background: #222;
    transition: all 0.2s ease;
    position: relative;
}

.termos-accept input:checked + .termos-accept__box {
    background: #e40f0f;
    border-color: #e40f0f;
}

.termos-accept input:checked + .termos-accept__box::after {
    content: '';
    position: absolute;
    left: 6px;
    top: 2px;
    width: 6px;
    height: 11px;
    border: solid #fff;
    border-width: 0 2px 2px 0;
    transform: rotate(45deg);
}

.termos-accept__text {
    font-size: 14px;
    color: rgba(255, 255, 255, 0.85);
    line-height: 1.55;
}

.termos-accept__text strong {
    color: #ff6b6b;
}

#btnGerarProtocolo:disabled,
#btnGerarProtocoloAdmin:disabled {
    opacity: 0.45;
    cursor: not-allowed;
    transform: none !important;
}

@media (max-width: 768px) {
    .warranty-section {
        padding: 56px 0 64px;
    }

    .warranty-bento {
        grid-template-columns: 1fr;
    }

    .w-card--deadline {
        grid-column: 1;
    }

    .w-card__deadline-inner {
        flex-direction: column;
        align-items: flex-start;
        padding: 24px;
    }

    .w-card__deadline-right {
        text-align: left;
    }

    .w-card__deadline-number {
        font-size: 48px;
    }

    .termos-form-cards {
        grid-template-columns: 1fr;
    }

    .termos-mini {
        border-right: none !important;
    }

    .termos-mini:nth-last-child(1) {
        border-bottom: none;
    }
}

/* ========== Modais pré-envio (novo envio cliente) ========== */
.pre-envio-overlay {
    position: fixed;
    inset: 0;
    z-index: 10000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    box-sizing: border-box;
}
.pre-envio-overlay.is-hidden {
    display: none !important;
    pointer-events: none;
}

html.pre-envio-lock #novo-envio-conteudo {
    display: none;
}

.pre-envio-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(8, 8, 8, 0.82);
    backdrop-filter: blur(6px);
}

.pre-envio-dialog {
    position: relative;
    z-index: 1;
    width: 100%;
    max-width: 480px;
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 24px 64px rgba(0, 0, 0, 0.45);
    padding: 28px 28px 24px;
    animation: pre-envio-in 0.35s ease;
}

@keyframes pre-envio-in {
    from { opacity: 0; transform: translateY(16px) scale(0.98); }
    to { opacity: 1; transform: translateY(0) scale(1); }
}

.pre-envio-dialog__head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 20px;
    padding-bottom: 14px;
    border-bottom: 1px solid #eee;
}
.pre-envio-dialog__step {
    font-size: 12px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: #888;
}
.pre-envio-dialog__dots {
    display: flex;
    gap: 6px;
}
.pre-envio-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #ddd;
    transition: background 0.25s, transform 0.25s;
}
.pre-envio-dot.is-active {
    background: #e40f0f;
    transform: scale(1.15);
}

.pre-envio-panel { display: none; }
.pre-envio-panel.is-active { display: block; }

.pre-envio-panel__icon {
    width: 56px;
    height: 56px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 16px;
}
.pre-envio-panel__icon--red {
    background: rgba(228, 15, 15, 0.12);
    color: #e40f0f;
}
.pre-envio-panel__icon--amber {
    background: rgba(220, 143, 56, 0.15);
    color: #b45309;
}
.pre-envio-panel__icon--green {
    background: rgba(75, 185, 140, 0.15);
    color: #2e7d32;
}

.pre-envio-panel__badge {
    display: inline-block;
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: #2e7d32;
    background: #e8f5e9;
    border: 1px solid #c8e6c9;
    padding: 4px 10px;
    border-radius: 4px;
    margin-bottom: 10px;
}

.pre-envio-panel__title {
    font-family: 'Muli', sans-serif;
    font-size: 22px;
    font-weight: 800;
    color: #1a1a1a;
    margin-bottom: 12px;
    line-height: 1.2;
}

.pre-envio-panel__text {
    font-size: 15px;
    line-height: 1.55;
    color: #444;
    margin-bottom: 16px;
}

.pre-envio-list {
    list-style: none;
    margin: 0 0 8px;
    padding: 14px 16px;
    background: #f8f8f8;
    border-radius: 8px;
    border: 1px solid #e8e8e8;
}
.pre-envio-list li {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 0;
    font-size: 14px;
    color: #333;
}
.pre-envio-list li + li {
    border-top: 1px solid #e5e5e5;
}
.pre-envio-price {
    font-size: 20px;
    font-weight: 800;
    color: #e40f0f;
    min-width: 100px;
}
.pre-envio-list__icon {
    font-size: 18px;
    font-weight: bold;
    color: #e40f0f;
}
.pre-envio-list--checks li::before {
    content: '✓';
    color: #2e7d32;
    font-weight: bold;
    margin-right: 4px;
}

.pre-envio-btn-next {
    margin-top: 20px;
}

.novo-envio-page {
    position: relative;
}

.pre-envio-skip-wrap {
    margin: 12px 0 0;
    text-align: center;
}
.pre-envio-skip {
    font-size: 13px;
    color: #888;
    text-decoration: underline;
}
.pre-envio-skip:hover {
    color: var(--accent, #e40f0f);
}

body.pre-envio-open {
    overflow: hidden;
}

@media (max-width: 480px) {
    .pre-envio-dialog {
        padding: 20px 16px 16px;
        max-height: calc(100vh - 32px);
        overflow-y: auto;
    }
}
