/* ==========================================================================
   Legal documents — terms & conditions, privacy policy.
   Readable measure, a sticky table of contents, and typography matched to the
   shared .eco-pg-* system.
   ========================================================================== */

.eco-legal {
    --lg-ink: #121212;
    --lg-body: #4f5e71;
    --lg-line: #e8edf1;
    --lg-line-soft: #eff3f6;
    --lg-green: #2d5f3f;
    --lg-teal: #01806c;
    --lg-mint: #e6f7f4;
    --lg-forest: #16302a;
    color: var(--lg-body);
}

/* ---------- masthead ---------- */

.eco-legal-head {
    padding: 52px 0 44px;
    border-bottom: 1px solid var(--lg-line);
    background:
        radial-gradient(90% 130% at 90% 0%, rgba(1, 128, 108, .08), transparent 60%),
        #f7faf9;
}

.eco-legal-head .container,
.eco-legal-body .container {
    max-width: 1290px;
    margin: 0 auto;
    padding: 0 20px;
}

.eco-legal-crumb {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px;
    margin-bottom: 24px;
    color: var(--lg-body);
    font-size: 13.5px;
    font-weight: 600;
}

.eco-legal-crumb a {
    color: var(--lg-body);
    text-decoration: none;
}

.eco-legal-crumb a:hover {
    color: var(--lg-green);
}

.eco-legal-head h1 {
    max-width: 20ch;
    margin: 16px 0 14px !important;
    color: var(--lg-ink) !important;
    font-size: clamp(32px, 4vw, 48px) !important;
    font-weight: 700 !important;
    line-height: 1.1 !important;
    letter-spacing: -0.02em;
}

.eco-legal-head p {
    max-width: 68ch;
    margin: 0;
    color: var(--lg-body);
    font-size: 17px;
    line-height: 1.68;
}

.eco-legal-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 10px 22px;
    margin-top: 26px;
    padding-top: 22px;
    border-top: 1px solid var(--lg-line);
}

.eco-legal-meta span {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    color: var(--lg-body);
    font-size: 14px;
    font-weight: 600;
}

.eco-legal-meta .iconify {
    color: var(--lg-teal);
    font-size: 18px;
}

.eco-legal-meta b {
    color: var(--lg-ink);
}

/* ---------- layout: contents + document ---------- */

.eco-legal-body {
    padding: 56px 0 88px;
    background: #fff;
}

.eco-legal-grid {
    display: grid;
    grid-template-columns: 268px minmax(0, 1fr);
    gap: 56px;
    align-items: start;
}

/* table of contents */

.eco-legal-toc {
    position: sticky;
    top: 92px;
    max-height: calc(100vh - 130px);
    padding: 24px 22px;
    overflow-y: auto;
    border: 1px solid var(--lg-line);
    border-radius: 18px;
    background: #fff;
}

.eco-legal-toc h2 {
    margin: 0 0 16px !important;
    padding-bottom: 14px;
    border-bottom: 1px solid var(--lg-line-soft);
    color: var(--lg-ink) !important;
    font-size: 12px !important;
    font-weight: 700 !important;
    letter-spacing: .13em;
    text-transform: uppercase;
}

.eco-legal-toc ol {
    display: grid;
    gap: 2px;
    margin: 0;
    padding: 0;
    list-style: none;
    counter-reset: toc;
}

.eco-legal-toc a {
    display: block;
    padding: 8px 10px;
    border-radius: 9px;
    border-left: 2px solid transparent;
    color: var(--lg-body);
    font-size: 13.5px;
    font-weight: 600;
    line-height: 1.4;
    text-decoration: none;
    transition: background-color .2s ease, color .2s ease, border-color .2s ease;
}

.eco-legal-toc a:hover {
    background: #f7faf9;
    color: var(--lg-green);
}

.eco-legal-toc a.is-active {
    border-left-color: var(--lg-green);
    background: var(--lg-mint);
    color: var(--lg-green);
}

/* the document itself */

.eco-legal-doc {
    max-width: 74ch;
    color: var(--lg-body);
    font-size: 16.5px;
    line-height: 1.78;
}

.eco-legal-doc > :first-child {
    margin-top: 0 !important;
}

.eco-legal-doc :is(h2, h4.eco-legal-h) {
    scroll-margin-top: 100px;
    margin: 52px 0 16px !important;
    padding-top: 30px;
    border-top: 1px solid var(--lg-line-soft);
    color: var(--lg-ink) !important;
    font-size: clamp(21px, 2.2vw, 26px) !important;
    font-weight: 700 !important;
    line-height: 1.25 !important;
    letter-spacing: -0.01em;
}

.eco-legal-doc :is(h2, h4.eco-legal-h):first-child {
    margin-top: 0 !important;
    padding-top: 0;
    border-top: 0;
}

.eco-legal-doc h3 {
    margin: 30px 0 10px !important;
    color: var(--lg-ink) !important;
    font-size: 17px !important;
    font-weight: 700 !important;
}

.eco-legal-doc p {
    margin: 0 0 18px;
}

.eco-legal-doc p.font-semibold {
    margin-top: 26px;
    margin-bottom: 10px;
    color: var(--lg-ink);
    font-size: 15.5px;
    font-weight: 700 !important;
}

.eco-legal-doc ul,
.eco-legal-doc ol:not(.eco-legal-toc ol) {
    margin: 0 0 20px;
    padding-left: 24px !important;
    list-style: disc;
}

.eco-legal-doc ol {
    list-style: decimal;
}

.eco-legal-doc li {
    margin-bottom: 9px;
    padding-left: 4px;
}

.eco-legal-doc li::marker {
    color: var(--lg-teal);
}

.eco-legal-doc a {
    color: var(--lg-green);
    font-weight: 600;
    text-decoration: underline;
    text-underline-offset: 3px;
}

.eco-legal-doc a:hover {
    color: var(--lg-teal);
}

.eco-legal-doc strong,
.eco-legal-doc b {
    color: var(--lg-ink);
    font-weight: 700;
}

.eco-legal-doc table {
    width: 100%;
    margin: 0 0 24px;
    border-collapse: collapse;
    font-size: 15px;
}

.eco-legal-doc :is(th, td) {
    padding: 12px 14px;
    border: 1px solid var(--lg-line);
    text-align: left;
}

.eco-legal-doc th {
    background: #f7faf9;
    color: var(--lg-ink);
    font-weight: 700;
}

/* callout panel (e.g. the booking-checkbox box on the terms page) */

.eco-legal-doc .bg-green-light,
.eco-legal-callout {
    margin: 34px 0 !important;
    padding: 24px 26px !important;
    border: 1px solid rgba(45, 95, 63, .18) !important;
    border-radius: 16px !important;
    background: var(--lg-mint) !important;
}

.eco-legal-doc .bg-green-light :is(h2, h4) {
    margin: 0 0 12px !important;
    padding-top: 0;
    border-top: 0;
    font-size: 18px !important;
}

.eco-legal-doc .bg-green-light p:last-child {
    margin-bottom: 0;
}

/* the effective-date line */

.eco-legal-doc .text-black.italic {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 30px !important;
    padding: 9px 15px;
    border-radius: 999px;
    background: #f2f5f7;
    color: var(--lg-body) !important;
    font-size: 13.5px;
    font-style: normal !important;
}

.eco-legal-doc .text-black.italic strong {
    color: var(--lg-ink);
}

/* ---------- footer nav between legal docs ---------- */

.eco-legal-nav {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin-top: 56px;
    padding-top: 32px;
    border-top: 1px solid var(--lg-line);
}

.eco-legal-nav a {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    min-height: 46px;
    padding: 11px 20px;
    border: 1px solid var(--lg-line);
    border-radius: 999px;
    color: var(--lg-ink);
    font-size: 14.5px;
    font-weight: 600;
    text-decoration: none;
    transition: all .2s ease;
}

.eco-legal-nav a:hover {
    border-color: var(--lg-green);
    background: var(--lg-mint);
    color: var(--lg-green);
}

/* back-to-top */

.eco-legal-top {
    position: fixed;
    right: 22px;
    bottom: 22px;
    z-index: 60;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 46px;
    height: 46px;
    border: 1px solid var(--lg-line);
    border-radius: 50%;
    background: #fff;
    color: var(--lg-green);
    box-shadow: 0 14px 30px -16px rgba(18, 38, 30, .5);
    cursor: pointer;
    opacity: 0;
    visibility: hidden;
    transition: opacity .25s ease, visibility .25s ease, transform .25s ease;
}

.eco-legal-top.is-visible {
    opacity: 1;
    visibility: visible;
}

.eco-legal-top:hover {
    transform: translateY(-3px);
}

/* ---------- responsive ---------- */

@media (max-width: 1024px) {
    .eco-legal-grid {
        grid-template-columns: minmax(0, 1fr);
        gap: 32px;
    }

    .eco-legal-toc {
        position: static;
        max-height: none;
    }

    .eco-legal-toc ol {
        display: grid;
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 2px 12px;
    }

    .eco-legal-doc {
        max-width: none;
    }
}

@media (max-width: 640px) {
    .eco-legal-head {
        padding: 34px 0 32px;
    }

    .eco-legal-body {
        padding: 38px 0 62px;
    }

    .eco-legal-toc ol {
        grid-template-columns: minmax(0, 1fr);
    }

    .eco-legal-doc {
        font-size: 16px;
    }
}

@media print {
    .eco-legal-toc,
    .eco-legal-top,
    .eco-legal-nav,
    header,
    footer {
        display: none !important;
    }

    .eco-legal-grid {
        grid-template-columns: minmax(0, 1fr);
    }
}

/* ==========================================================================
   Multi-step application wizard (.eco-wiz-*)
   Used by the travel & visa and accommodation application forms.
   ========================================================================== */

.eco-wiz {
    --wiz-ink: #121212;
    --wiz-body: #4f5e71;
    --wiz-line: #e8edf1;
    --wiz-line-soft: #eff3f6;
    --wiz-green: #2d5f3f;
    --wiz-teal: #01806c;
    --wiz-mint: #e6f7f4;
    --wiz-amber: #f4a259;
}

/* progress rail */

.eco-wiz-progress {
    display: grid;
    grid-auto-flow: column;
    grid-auto-columns: 1fr;
    gap: 8px;
    margin-bottom: 34px;
    padding: 0;
    list-style: none;
    counter-reset: wiz;
}

.eco-wiz-progress li {
    position: relative;
    display: flex;
    flex-direction: column;
    gap: 9px;
    padding-top: 16px;
    color: var(--wiz-body);
    font-size: 13.5px;
    font-weight: 600;
    line-height: 1.35;
}

.eco-wiz-progress li::before {
    content: "";
    display: block;
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    border-radius: 999px;
    background: var(--wiz-line);
    transition: background-color .3s ease;
}

.eco-wiz-progress li.is-done::before,
.eco-wiz-progress li.is-current::before {
    background: var(--wiz-green);
}

.eco-wiz-progress li.is-current {
    color: var(--wiz-green);
}

.eco-wiz-progress .step-n {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    font-size: 12px;
    letter-spacing: .08em;
    text-transform: uppercase;
    opacity: .8;
}

.eco-wiz-progress li.is-done .step-n::after {
    content: "✓";
    color: var(--wiz-green);
    font-weight: 800;
}

.eco-wiz-progress .step-label {
    color: inherit;
    font-size: 14.5px;
    font-weight: 700;
}

/* steps */

.eco-wiz-step {
    display: none;
}

.eco-wiz-step.is-active {
    display: block;
    animation: eco-wiz-in .25s ease both;
}

@keyframes eco-wiz-in {
    from { opacity: 0; transform: translateY(6px); }
    to   { opacity: 1; transform: none; }
}

.eco-wiz-step-head {
    margin-bottom: 26px;
}

.eco-wiz-step-head h2 {
    margin: 0 0 6px;
    color: var(--wiz-ink);
    font-size: clamp(22px, 2.4vw, 28px);
    font-weight: 700;
    line-height: 1.2;
}

.eco-wiz-step-head p {
    margin: 0;
    color: var(--wiz-body);
    font-size: 15.5px;
    line-height: 1.6;
}

/* nav buttons */

.eco-wiz-nav {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
    margin-top: 30px;
    padding-top: 26px;
    border-top: 1px solid var(--wiz-line-soft);
}

.eco-wiz-nav-right {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin-left: auto;
}

/* document rows */

.document-item {
    padding: 18px !important;
    margin-bottom: 14px !important;
    border: 1px solid var(--wiz-line) !important;
    border-radius: 14px !important;
    background: #fbfcfc;
}

.eco-wiz-doc-add {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    min-height: 46px;
    padding: 11px 20px;
    border: 1px dashed #c7d3da;
    border-radius: 999px;
    background: #fff;
    color: var(--wiz-green);
    font-size: 14.5px;
    font-weight: 700;
    cursor: pointer;
    transition: all .2s ease;
}

.eco-wiz-doc-add:hover {
    border-color: var(--wiz-green);
    background: var(--wiz-mint);
}

/* review step */

.eco-wiz-review {
    display: grid;
    gap: 16px;
}

.eco-wiz-review-group {
    padding: 22px 24px;
    border: 1px solid var(--wiz-line);
    border-radius: 16px;
    background: #fbfcfc;
}

.eco-wiz-review-group h3 {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
    margin: 0 0 16px;
    padding-bottom: 12px;
    border-bottom: 1px solid var(--wiz-line);
    color: var(--wiz-ink);
    font-size: 12px;
    font-weight: 700;
    letter-spacing: .1em;
    text-transform: uppercase;
}

.eco-wiz-review-group h3 button {
    border: 0;
    background: none;
    color: var(--wiz-green);
    font-size: 12.5px;
    font-weight: 700;
    letter-spacing: 0;
    text-transform: none;
    cursor: pointer;
}

.eco-wiz-review-group h3 button:hover {
    text-decoration: underline;
}

.eco-wiz-review-group dl {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px 24px;
    margin: 0;
}

.eco-wiz-review-group dt {
    color: var(--wiz-body);
    font-size: 13px;
    font-weight: 600;
}

.eco-wiz-review-group dd {
    margin: 3px 0 0;
    color: var(--wiz-ink);
    font-size: 15px;
    font-weight: 600;
    overflow-wrap: anywhere;
}

.eco-wiz-review-group dd.is-empty {
    color: #97a3ad;
    font-weight: 500;
    font-style: italic;
}

/* aside panel */

.eco-wiz-aside {
    position: sticky;
    top: 96px;
    display: grid;
    gap: 18px;
}

.eco-wiz-layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 316px;
    gap: 44px;
    align-items: start;
}

@media (max-width: 1100px) {
    .eco-wiz-layout {
        grid-template-columns: minmax(0, 1fr);
        gap: 32px;
    }

    .eco-wiz-aside {
        position: static;
    }
}

@media (max-width: 760px) {
    .eco-wiz-progress {
        grid-auto-flow: row;
        grid-auto-columns: auto;
        gap: 6px;
    }

    .eco-wiz-progress li {
        display: none;
    }

    .eco-wiz-progress li.is-current {
        display: flex;
    }

    .eco-wiz-review-group dl {
        grid-template-columns: minmax(0, 1fr);
    }

    .eco-wiz-nav,
    .eco-wiz-nav-right {
        width: 100%;
    }

    .eco-wiz-nav .form-submit-btn,
    .eco-wiz-nav .form-secondary-btn {
        width: 100%;
    }
}
