:root {
    --trav-site-body-background:
        radial-gradient(circle at top left, rgba(205, 244, 214, 0.78), transparent 38%),
        radial-gradient(circle at 82% 14%, rgba(255, 232, 208, 0.72), transparent 30%),
        linear-gradient(180deg, #f7fbf5 0%, #eef7f0 48%, #f8f4eb 100%);
}

html,
body,
body[class] {
    background: var(--trav-site-body-background);
}

/* ================================================================
   legal.css — Tra-V Legal Pages + Site Footer + Cookie Banner
   ================================================================ */

/* ── Legal page layout ─────────────────────────────────────────── */

.legal-page {
    font-family: Inika, 'Poppins', sans-serif;
    margin: 0;
    padding: 0;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    background: transparent;
    color: #2C2C54;
}

.legal-main {
    flex: 1;
    max-width: 820px;
    margin: 120px auto 60px;
    padding: 0 24px;
    width: 100%;
}

.legal-content h1 {
    font-family: Inika, serif;
    font-size: 1.8rem;
    color: #1f4d35;
    margin-bottom: 24px;
    padding-bottom: 16px;
    border-bottom: 2px solid rgba(50, 205, 50, 0.2);
}

.legal-content h2 {
    font-size: 1.35rem;
    color: #2a6b45;
    margin: 32px 0 12px;
}

.legal-content h3 {
    font-size: 1.1rem;
    color: #385142;
    margin: 24px 0 8px;
}

.legal-content p,
.legal-content li {
    font-size: 0.95rem;
    line-height: 1.7;
    color: #444;
    margin-bottom: 12px;
}

.legal-content ul, .legal-content ol {
    padding-left: 24px;
    margin-bottom: 16px;
}

.legal-placeholder {
    font-style: italic;
    color: #999;
    padding: 40px 0;
    text-align: center;
    font-size: 1.05rem;
}

/* ── Contact form (legal/contact.html) ─────────────────────────── */

.legal-contact-form {
    display: flex;
    flex-direction: column;
    gap: 18px;
    margin-top: 24px;
}

.legal-form-group {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.legal-form-group label {
    font-size: 0.9rem;
    font-weight: 600;
    color: #385142;
}

.legal-form-group input,
.legal-form-group textarea,
.legal-form-group select {
    width: 100%;
    box-sizing: border-box;
    padding: 12px 16px;
    border: 1.5px solid rgba(45, 138, 87, 0.22);
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.7);
    font-family: inherit;
    font-size: 0.92rem;
    color: #2c3e35;
    transition: border-color 0.25s, box-shadow 0.25s;
}

.legal-form-group input:focus,
.legal-form-group textarea:focus,
.legal-form-group select:focus {
    border-color: #38a169;
    outline: none;
    box-shadow: 0 0 0 3px rgba(45, 138, 87, 0.12);
}

.legal-form-group textarea {
    resize: vertical;
    min-height: 120px;
}

.legal-upload-zone {
    display: grid;
    gap: 12px;
    padding: 18px 18px 16px;
    border-radius: 18px;
    border: 1.5px dashed rgba(45, 138, 87, 0.3);
    background:
        radial-gradient(circle at top right, rgba(202, 244, 215, 0.35), transparent 45%),
        linear-gradient(180deg, rgba(255, 255, 255, 0.84), rgba(244, 250, 246, 0.78));
    cursor: pointer;
    transition: border-color 0.22s ease, transform 0.22s ease, box-shadow 0.22s ease;
}

.legal-upload-zone:hover,
.legal-upload-zone:focus-visible,
.legal-upload-zone.is-dragover {
    border-color: rgba(56, 161, 105, 0.72);
    box-shadow: 0 16px 32px rgba(55, 132, 88, 0.12);
    transform: translateY(-1px);
    outline: none;
}

.legal-upload-zone-copy {
    display: grid;
    gap: 4px;
}

.legal-upload-zone-copy strong {
    font-size: 0.98rem;
    color: #1f4d35;
}

.legal-upload-zone-copy span,
.legal-upload-zone-meta {
    font-size: 0.84rem;
    line-height: 1.5;
    color: #5d7668;
}

.legal-upload-zone-meta {
    display: inline-flex;
    align-items: center;
    justify-self: start;
    min-height: 32px;
    padding: 0 12px;
    border-radius: 999px;
    background: rgba(221, 244, 228, 0.74);
    border: 1px solid rgba(90, 180, 124, 0.18);
    color: #2d8053;
}

.legal-upload-error {
    min-height: 18px;
    font-size: 0.83rem;
    color: #cb5b5b;
}

.legal-upload-error.is-visible {
    margin-top: 2px;
}

.legal-upload-previews {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
    gap: 12px;
}

.legal-upload-preview-card {
    display: grid;
    gap: 10px;
    padding: 10px;
    border-radius: 16px;
    border: 1px solid rgba(45, 138, 87, 0.16);
    background: rgba(255, 255, 255, 0.86);
    box-shadow: 0 12px 26px rgba(48, 109, 73, 0.08);
}

.legal-upload-preview-image {
    width: 100%;
    height: 118px;
    object-fit: cover;
    border-radius: 12px;
    background: linear-gradient(180deg, #eef4ee, #e3ece5);
}

.legal-upload-preview-body {
    display: grid;
    gap: 3px;
}

.legal-upload-preview-body strong {
    font-size: 0.86rem;
    color: #244833;
    line-height: 1.4;
    word-break: break-word;
}

.legal-upload-preview-body span {
    font-size: 0.78rem;
    color: #6a7f74;
}

.legal-upload-remove {
    justify-self: start;
    min-height: 34px;
    padding: 0 12px;
    border-radius: 999px;
    border: 1px solid rgba(202, 108, 108, 0.25);
    background: rgba(255, 245, 245, 0.96);
    color: #b44d4d;
    font-family: inherit;
    font-size: 0.8rem;
    font-weight: 700;
    cursor: pointer;
    transition: background 0.18s ease, transform 0.18s ease, box-shadow 0.18s ease;
}

.legal-upload-remove:hover {
    background: rgba(255, 237, 237, 0.98);
    transform: translateY(-1px);
    box-shadow: 0 10px 18px rgba(180, 77, 77, 0.1);
}

.legal-contact-btn {
    align-self: center;
    padding: 12px 40px;
    background: linear-gradient(140deg, #2a7a4e, #4dbf72);
    color: #fff;
    border: none;
    border-radius: 999px;
    font-family: inherit;
    font-weight: 700;
    font-size: 0.95rem;
    cursor: pointer;
    box-shadow: 0 8px 24px rgba(42, 120, 78, 0.2);
    transition: transform 0.18s, box-shadow 0.18s;
}

.legal-contact-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 14px 32px rgba(42, 120, 78, 0.3);
}

.contact-success-msg {
    text-align: center;
    color: #2a7d48;
    font-weight: 600;
    margin-top: 8px;
}

@media (max-width: 600px) {
    .legal-main {
        margin-top: 90px;
        padding: 0 16px;
    }
    .legal-content h1 {
        font-size: 1.5rem;
    }
}

/* ── Site Footer (shared across all pages) ─────────────────────── */

.site-footer {
    background: linear-gradient(180deg, rgba(245, 250, 247, 0.95), rgba(235, 245, 238, 0.98));
    border-top: 1px solid rgba(50, 205, 50, 0.12);
    padding: 32px 24px 24px;
    text-align: center;
}

.footer-links {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 8px 24px;
    margin-bottom: 16px;
}

.footer-links a {
    font-family: Inika, sans-serif;
    font-size: 0.82rem;
    color: #3a7d53;
    text-decoration: none;
    transition: color 0.2s;
    white-space: nowrap;
}

.footer-links a:hover {
    color: #1f4d35;
    text-decoration: underline;
}

.footer-copy {
    font-size: 0.82rem;
    color: #8a9b90;
    margin: 0;
}

@media (max-width: 600px) {
    .footer-links {
        flex-direction: column;
        gap: 10px;
    }
    .site-footer {
        padding: 24px 16px 20px;
    }
}

/* ── Cookie Consent Banner ─────────────────────────────────────── */

.cookie-banner {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    z-index: 99999;
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.97), rgba(247, 251, 248, 0.98));
    border-top: 1px solid rgba(50, 205, 50, 0.18);
    box-shadow: 0 -8px 32px rgba(0, 0, 0, 0.1);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    padding: 20px 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 20px;
    flex-wrap: wrap;
    animation: cookieSlideUp 0.4s ease;
}

@keyframes cookieSlideUp {
    from { transform: translateY(100%); opacity: 0; }
    to   { transform: translateY(0); opacity: 1; }
}

.cookie-banner.hidden {
    display: none;
}

.cookie-banner-text {
    flex: 1;
    min-width: 240px;
    max-width: 600px;
    font-family: Inika, sans-serif;
    font-size: 0.88rem;
    color: #2c3e35;
    line-height: 1.5;
}

.cookie-banner-text a {
    color: #2a7d48;
    text-decoration: underline;
}

.cookie-banner-actions {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
    align-items: center;
}

.cookie-btn {
    font-family: Inika, sans-serif;
    font-size: 0.84rem;
    font-weight: 600;
    padding: 10px 20px;
    border-radius: 10px;
    cursor: pointer;
    transition: transform 0.2s, box-shadow 0.2s, background 0.2s;
    border: none;
    white-space: nowrap;
}

.cookie-btn:hover {
    transform: translateY(-1px);
}

.cookie-btn-accept {
    background: linear-gradient(135deg, #2f8b58, #38a169);
    color: #fff;
    box-shadow: 0 4px 14px rgba(47, 139, 88, 0.3);
}

.cookie-btn-accept:hover {
    box-shadow: 0 6px 20px rgba(47, 139, 88, 0.4);
}

.cookie-btn-refuse {
    background: rgba(0, 0, 0, 0.06);
    color: #385142;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06);
}

.cookie-btn-refuse:hover {
    background: rgba(0, 0, 0, 0.1);
}

.cookie-btn-customize {
    background: transparent;
    color: #3a7d53;
    text-decoration: underline;
    padding: 10px 12px;
    font-weight: 500;
}

.cookie-btn-customize:hover {
    color: #1f4d35;
}

/* ── Cookie Preferences Modal ──────────────────────────────────── */

.cookie-prefs-overlay {
    position: fixed;
    inset: 0;
    z-index: 100000;
    background: rgba(0, 0, 0, 0.4);
    backdrop-filter: blur(4px);
    display: flex;
    align-items: center;
    justify-content: center;
    animation: cookieFadeIn 0.25s ease;
}

.cookie-prefs-overlay.hidden {
    display: none;
}

@keyframes cookieFadeIn {
    from { opacity: 0; }
    to   { opacity: 1; }
}

.cookie-prefs-box {
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.98), rgba(247, 251, 248, 0.96));
    border: 1px solid rgba(182, 214, 195, 0.5);
    border-radius: 20px;
    padding: 32px 28px 24px;
    max-width: 480px;
    width: 90vw;
    max-height: 80vh;
    overflow-y: auto;
    box-shadow: 0 24px 64px rgba(83, 129, 102, 0.2);
}

.cookie-prefs-box h2 {
    font-family: Inika, serif;
    font-size: 1.3rem;
    color: #1f4d35;
    margin: 0 0 16px;
}

.cookie-prefs-box p {
    font-size: 0.88rem;
    color: #555;
    line-height: 1.6;
    margin-bottom: 18px;
}

.cookie-pref-item {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 12px;
    padding: 14px 0;
    border-top: 1px solid rgba(0, 0, 0, 0.06);
}

.cookie-pref-item label {
    flex: 1;
}

.cookie-pref-item label strong {
    display: block;
    font-size: 0.9rem;
    color: #2c3e35;
    margin-bottom: 2px;
}

.cookie-pref-item label span {
    font-size: 0.8rem;
    color: #777;
}

.cookie-pref-item input[type="checkbox"] {
    margin-top: 4px;
    width: 18px;
    height: 18px;
    accent-color: #38a169;
    flex-shrink: 0;
}

.cookie-prefs-actions {
    display: flex;
    gap: 10px;
    justify-content: flex-end;
    margin-top: 20px;
    padding-top: 16px;
    border-top: 1px solid rgba(0, 0, 0, 0.06);
}
