/* ==========================================================================
   TERMS & POLICIES page — 4FLOW
   Стиль: мінімалізм About-сторінки + читабельний типографічний layout
   ========================================================================== */

/* HERO */
.terms-hero {
    padding: 140px 24px 60px;
    text-align: center;
    background: linear-gradient(180deg, #f9f7f3 0%, #fff 100%);
}

.terms-hero-eyebrow {
    font-family: 'Lora', serif;
    font-style: italic;
    letter-spacing: 6px;
    text-transform: uppercase;
    font-size: 12px;
    color: #999;
    margin: 0 0 18px;
}

.terms-hero-title {
    font-family: 'Ballet', cursive;
    font-weight: 400;
    color: #111;
    font-size: clamp(56px, 9vw, 130px);
    line-height: 1;
    margin: 0;
    letter-spacing: 2px;
}

.terms-hero-tagline {
    max-width: 680px;
    margin: 28px auto 14px;
    font-family: 'Lora', serif;
    font-size: 17px;
    line-height: 1.7;
    color: #555;
}

.terms-hero-updated {
    font-family: 'Montserrat', sans-serif;
    font-size: 12px;
    letter-spacing: 2px;
    text-transform: uppercase;
    color: #888;
    margin: 0;
}

/* SECTION NAVIGATION (sticky on desktop) */
.terms-nav {
    position: sticky;
    top: calc(var(--top-bar-h, 38px) + 60px);
    z-index: 5;
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 8px;
    padding: 18px 16px;
    background: rgba(255, 255, 255, 0.92);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    border-top: 1px solid #f0f0f0;
    border-bottom: 1px solid #f0f0f0;
}

.terms-nav a {
    font-family: 'Montserrat', sans-serif;
    font-size: 12px;
    text-transform: uppercase;
    letter-spacing: 2px;
    color: #555;
    padding: 8px 14px;
    border-radius: 999px;
    transition: background-color 0.25s ease, color 0.25s ease;
    text-decoration: none;
}

.terms-nav a:hover {
    background: #000;
    color: #fff;
}

/* CONTENT */
.terms-content {
    max-width: 1000px;
    margin: 0 auto;
    padding: 0 24px 100px;
    font-family: 'Lora', serif;
    color: #333;
}

/* Each numbered section */
.terms-section {
    padding: 70px 0 30px;
    border-bottom: 1px solid #f0f0f0;
}
.terms-section:last-of-type {
    border-bottom: none;
}

.terms-section-header {
    display: flex;
    align-items: baseline;
    gap: 20px;
    margin-bottom: 28px;
}

.terms-section-number {
    font-family: 'Montserrat', sans-serif;
    font-size: 1.4rem;
    font-weight: 300;
    color: #bbb;
    min-width: 34px;
}

.terms-section-title {
    font-family: 'Montserrat', sans-serif;
    font-size: clamp(28px, 4vw, 40px);
    font-weight: 600;
    color: #111;
    margin: 0;
    position: relative;
    padding-bottom: 12px;
    letter-spacing: -0.5px;
}

.terms-section-title::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 50px;
    height: 2px;
    background: #111;
}

.terms-section-body {
    margin-left: 54px;
}

.terms-section-body p {
    font-family: 'Lora', serif;
    font-size: 16px;
    line-height: 1.8;
    color: #444;
    margin: 0 0 16px;
}

.terms-section-body h3 {
    font-family: 'Montserrat', sans-serif;
    font-size: 18px;
    font-weight: 600;
    color: #111;
    text-transform: uppercase;
    letter-spacing: 2px;
    margin: 36px 0 14px;
}

/* Lists */
.terms-list {
    margin: 0 0 16px;
    padding: 0 0 0 22px;
    list-style: none;
}

.terms-list li {
    position: relative;
    padding-left: 12px;
    margin-bottom: 8px;
    font-size: 16px;
    line-height: 1.7;
    color: #444;
}

.terms-list li::before {
    content: '·';
    position: absolute;
    left: -10px;
    top: -6px;
    font-size: 28px;
    color: #c33;
}

.terms-list-clean li::before {
    content: '';
}

.terms-list-clean li {
    padding-left: 0;
    font-family: 'Montserrat', sans-serif;
    font-size: 14px;
    letter-spacing: 0.5px;
    color: #333;
}

/* Payment icons row */
.terms-payment-icons {
    display: flex;
    gap: 18px;
    flex-wrap: wrap;
    margin: 26px 0 0;
    font-size: 38px;
    color: #333;
}

/* mailto link */
.terms-mailto {
    margin: 0 0 16px !important;
}
.terms-mailto a {
    font-family: 'Montserrat', sans-serif;
    font-weight: 600;
    color: #000;
    text-decoration: underline;
    text-underline-offset: 4px;
}

/* Merchant grid */
.terms-merchant-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 28px;
    margin-top: 18px;
}

.terms-merchant-card {
    background: #fafafa;
    border: 1px solid #eee;
    border-radius: 12px;
    padding: 24px;
}

.terms-merchant-card h4 {
    font-family: 'Montserrat', sans-serif;
    font-size: 13px;
    font-weight: 700;
    letter-spacing: 2px;
    text-transform: uppercase;
    color: #999;
    margin: 0 0 14px;
}

.terms-merchant-card p {
    font-family: 'Lora', serif;
    font-size: 15px;
    color: #333;
    margin: 0 0 10px;
    line-height: 1.6;
}

.terms-merchant-card p i {
    margin-right: 8px;
    color: #666;
    width: 16px;
    text-align: center;
}

.terms-merchant-card a {
    color: #111;
    text-decoration: none;
    border-bottom: 1px solid transparent;
    transition: border-color 0.25s ease;
}
.terms-merchant-card a:hover {
    border-bottom-color: #111;
}

/* TODO placeholders — щоб власник побачив і заповнив */
.terms-todo {
    display: inline-block;
    background: #fff3cd;
    color: #856404;
    padding: 2px 8px;
    border-radius: 4px;
    font-style: italic;
    font-size: 0.95em;
    border: 1px dashed #ffb347;
}

p.terms-todo {
    display: block;
    margin: 0 0 12px;
}

/* Follow line at bottom of section 06 */
.terms-followline {
    display: flex;
    align-items: center;
    gap: 14px;
    flex-wrap: wrap;
    margin-top: 36px;
    padding-top: 28px;
    border-top: 1px solid #eee;
}

.terms-followline > span {
    font-family: 'Montserrat', sans-serif;
    text-transform: uppercase;
    letter-spacing: 3px;
    font-size: 12px;
    color: #666;
    margin-right: 8px;
}

/* Footnote / CTA */
.terms-footnote {
    text-align: center;
    padding: 70px 0 30px;
    border-top: 1px solid #f0f0f0;
}

.terms-footnote p {
    font-family: 'Lora', serif;
    font-style: italic;
    font-size: 18px;
    color: #555;
    margin: 0 0 24px;
}

.terms-cta {
    display: inline-block;
    padding: 14px 44px;
    background: #000;
    color: #fff !important;
    border: 1.5px solid #000;
    font-family: 'Montserrat', sans-serif;
    font-weight: 600;
    letter-spacing: 3px;
    font-size: 13px;
    text-transform: uppercase;
    text-decoration: none;
    transition: background-color 0.3s ease, color 0.3s ease;
}

.terms-cta:hover {
    background: transparent;
    color: #000 !important;
}

/* Smooth anchor scroll */
html {
    scroll-behavior: smooth;
}

/* MOBILE */
@media (max-width: 768px) {
    .terms-hero {
        padding: 110px 18px 40px;
    }
    .terms-nav {
        top: calc(var(--top-bar-h, 32px) + 56px);
        gap: 4px;
        padding: 12px 8px;
        overflow-x: auto;
        flex-wrap: nowrap;
        justify-content: flex-start;
        -webkit-overflow-scrolling: touch;
    }
    .terms-nav a {
        white-space: nowrap;
        font-size: 11px;
        padding: 6px 11px;
    }
    .terms-section {
        padding: 50px 0 20px;
    }
    .terms-section-header {
        gap: 12px;
        margin-bottom: 20px;
    }
    .terms-section-body {
        margin-left: 0;
    }
    .terms-section-body p,
    .terms-list li {
        font-size: 15px;
    }
    .terms-payment-icons {
        font-size: 30px;
        gap: 14px;
    }
    .terms-merchant-grid {
        gap: 18px;
    }
}

@media (max-width: 480px) {
    .terms-hero-title {
        letter-spacing: 1px;
    }
    .terms-hero-tagline {
        font-size: 15px;
    }
    .terms-section-title {
        padding-bottom: 8px;
    }
}
