/**
 * Qulbay Child Theme — Terms & Conditions Page Styles
 * Template: page-terms.php
 * RUN_ID: QLB-PUBLIC-PAGES-01
 * Version: 1.0.0
 *
 * UI system: IDENTICAL to about.css — same tokens, same nav,
 * same rainbow strip, same footer, same body scoping pattern.
 * Font: Poppins (loaded in template <head>)
 * No inline CSS anywhere — all rules here.
 */

/* ── Design tokens (mirrors about.css exactly) ─────────────────────────── */
:root {
    --qlb-terms-deep-purple:  #4B0082;
    --qlb-terms-apple-green:  #8DB600;
    --qlb-terms-yellow:       #FFD700;
    --qlb-terms-pink:         #E91E63;
    --qlb-terms-orange:       #FF5722;
    --qlb-terms-blue:         #00BCD4;
    --qlb-terms-off-white:    #F4F7F2;
    --qlb-terms-text:         #1A1A1A;
    --qlb-terms-gradient: linear-gradient(
        90deg,
        #FFD700 0%,    #FFD700 16.6%,
        #E91E63 16.6%, #E91E63 33.3%,
        #FF5722 33.3%, #FF5722 50%,
        #8DB600 50%,   #8DB600 66.6%,
        #00BCD4 66.6%, #00BCD4 83.3%,
        #4B0082 83.3%, #4B0082 100%
    );
}

/* ── Reset (scoped to body class) ─────────────────────────────────────── */
body.qlb-terms *,
body.qlb-terms *::before,
body.qlb-terms *::after {
    box-sizing: border-box;
}

body.qlb-terms {
    background: var(--qlb-terms-off-white);
    font-family: 'Poppins', sans-serif;
    margin: 0;
    padding: 0;
    color: var(--qlb-terms-text);
    -webkit-font-smoothing: antialiased;
}

/* Hide TT25 chrome (same pattern as about.css) */
body.qlb-terms .wp-site-blocks > header,
body.qlb-terms .wp-site-blocks > footer,
body.qlb-terms .wp-block-template-part[data-slug="header"],
body.qlb-terms .wp-block-template-part[data-slug="footer"],
body.qlb-terms .wp-site-blocks {
    padding: 0 !important;
    margin: 0 !important;
}
body.qlb-terms .wp-site-blocks > header,
body.qlb-terms .wp-site-blocks > footer,
body.qlb-terms .site-header,
body.qlb-terms .site-footer,
body.qlb-terms #masthead,
body.qlb-terms #colophon {
    display: none !important;
}

/* ── Truck-art rainbow strip (fixed top) — identical to about ──────────── */
.qlb-terms-truck-border {
    height: 8px;
    background: var(--qlb-terms-gradient);
    width: 100%;
    position: fixed;
    top: 0;
    left: 0;
    z-index: 9999;
}

/* ── NAV — identical to about.css qlb-nav block ───────────────────────── */
.qlb-nav {
    position: sticky;
    top: 8px;
    z-index: 1000;
    background: #0b0b0b;
    height: 64px;
    display: flex;
    align-items: center;
}

.qlb-nav .qlb-nav-inner {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
}

.qlb-logo {
    display: flex;
    align-items: center;
    gap: 10px;
    text-decoration: none;
}

.qlb-logo-box {
    width: 40px;
    height: 40px;
    border: 2px solid #ffffff;
    border-radius: 6px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.qlb-logo-box span {
    font-family: 'Poppins', sans-serif;
    font-weight: 900;
    font-size: 0.85rem;
    color: #ffffff;
    letter-spacing: 0.05em;
}

.qlb-logo-text {
    font-family: 'Poppins', sans-serif;
    font-weight: 900;
    font-size: 1.2rem;
    color: #ffffff;
    letter-spacing: 0.06em;
}

.qlb-nav-links {
    display: flex;
    align-items: center;
    gap: 4px;
}

.qlb-nav-links a {
    color: rgba(255, 255, 255, 0.75);
    font-size: 0.9rem;
    font-weight: 600;
    padding: 6px 14px;
    border-radius: 999px;
    transition: color 0.15s, background 0.15s;
    text-decoration: none;
}

.qlb-nav-links a:hover,
.qlb-nav-links a.qlb-nav-active {
    color: #FFD700;
    background: rgba(255, 215, 0, 0.08);
}

/* Hamburger — mobile only */
.qlb-hamburger {
    display: none;
    flex-direction: column;
    gap: 5px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 4px;
}

.qlb-hamburger span {
    display: block;
    width: 24px;
    height: 2px;
    background: #ffffff;
    border-radius: 2px;
    transition: opacity 0.2s;
}

/* Mobile menu */
.qlb-mobile-menu {
    display: none;
    position: fixed;
    top: 72px;
    left: 0;
    width: 100%;
    background: #0b0b0b;
    z-index: 999;
    padding: 16px 20px 24px;
    flex-direction: column;
    gap: 4px;
}

.qlb-mobile-menu.open {
    display: flex;
}

.qlb-mobile-menu a {
    color: rgba(255, 255, 255, 0.85);
    font-size: 1rem;
    font-weight: 600;
    padding: 10px 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.07);
    text-decoration: none;
}

.qlb-mobile-menu a:last-child {
    border-bottom: none;
}

@media (max-width: 767px) {
    .qlb-nav-links {
        display: none;
    }
    .qlb-hamburger {
        display: flex;
    }
}

/* ── Page wrapper ───────────────────────────────────────────────────────── */
.qlb-terms-page {
    padding-top: 8px; /* rainbow strip height */
}

/* ── Hero band — same deep purple + pattern as about ──────────────────── */
.qlb-terms-hero {
    background: var(--qlb-terms-deep-purple);
    padding: 28px 5% 56px;
    text-align: center;
    position: relative;
    overflow: hidden;
}

.qlb-terms-hero::before {
    content: '⚖️';
    position: absolute;
    font-size: 280px;
    color: rgba(255, 215, 0, 0.04);
    top: -40px;
    right: -20px;
    pointer-events: none;
    line-height: 1;
}

.qlb-terms-hero-tag {
    display: inline-block;
    background: var(--qlb-terms-yellow);
    color: var(--qlb-terms-deep-purple);
    font-size: 10px;
    font-weight: 800;
    letter-spacing: 3px;
    text-transform: uppercase;
    padding: 5px 16px;
    border-radius: 20px;
    margin-bottom: 20px;
}

.qlb-terms-hero h1 {
    font-family: 'Poppins', sans-serif;
    color: #ffffff;
    font-size: clamp(1.8rem, 4.5vw, 3rem);
    font-weight: 800;
    margin: 0 0 14px;
    line-height: 1.15;
}

.qlb-terms-hero h1 em {
    color: var(--qlb-terms-yellow);
    font-style: normal;
}

.qlb-terms-hero p {
    color: rgba(255, 255, 255, 0.78);
    font-size: 1.05rem;
    max-width: 560px;
    margin: 0 auto 16px;
    line-height: 1.65;
}

.qlb-terms-effective {
    display: inline-block;
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 20px;
    padding: 5px 18px;
    font-size: 0.8rem;
    color: rgba(255, 255, 255, 0.65);
    letter-spacing: 0.03em;
}

/* ── Main section — same overlap card pattern as about ─────────────────── */
.qlb-terms-section {
    max-width: 1100px;
    margin: -32px auto 0;
    padding: 0 5% 72px;
    position: relative;
    z-index: 10;
    display: grid;
    grid-template-columns: 240px 1fr;
    gap: 32px;
    align-items: start;
}

/* ── TOC sidebar — styled as white card matching about cards ───────────── */
.qlb-terms-toc {
    position: sticky;
    top: calc(8px + 64px + 16px); /* rainbow + nav + gap */
    background: #ffffff;
    border-radius: 14px;
    box-shadow: 0 8px 28px rgba(0, 0, 0, 0.09);
    border-bottom: 4px solid var(--qlb-terms-deep-purple);
    padding: 24px 20px;
}

.qlb-terms-toc h3 {
    font-size: 10px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 3px;
    color: var(--qlb-terms-deep-purple);
    margin: 0 0 16px;
}

.qlb-terms-toc ol {
    list-style: none;
    counter-reset: toc;
    padding: 0;
    margin: 0;
}

.qlb-terms-toc li {
    counter-increment: toc;
    margin-bottom: 8px;
    display: flex;
    align-items: baseline;
    gap: 6px;
}

.qlb-terms-toc li::before {
    content: counter(toc) '.';
    color: var(--qlb-terms-deep-purple);
    font-weight: 800;
    font-size: 0.72rem;
    flex-shrink: 0;
    min-width: 18px;
}

.qlb-terms-toc li a {
    color: var(--qlb-terms-text);
    text-decoration: none;
    font-size: 0.78rem;
    font-weight: 500;
    line-height: 1.4;
    transition: color 0.15s;
}

.qlb-terms-toc li a:hover {
    color: var(--qlb-terms-deep-purple);
}

/* ── Content column ─────────────────────────────────────────────────────── */
.qlb-terms-content {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

/* ── Each section card — white card identical to about card style ─────── */
.qlb-terms-card {
    background: #ffffff;
    border-radius: 14px;
    padding: 28px 32px;
    box-shadow: 0 8px 28px rgba(0, 0, 0, 0.09);
    border-bottom: 4px solid var(--qlb-terms-apple-green);
    scroll-margin-top: calc(8px + 64px + 16px);
    transition: transform 0.22s ease, box-shadow 0.22s ease;
}

.qlb-terms-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 16px 40px rgba(0, 0, 0, 0.12);
}

/* Colour-coded bottom border per section — mirrors card colour variants */
.qlb-terms-card--purple { border-bottom-color: var(--qlb-terms-deep-purple); }
.qlb-terms-card--pink   { border-bottom-color: var(--qlb-terms-pink); }
.qlb-terms-card--orange { border-bottom-color: var(--qlb-terms-orange); }
.qlb-terms-card--blue   { border-bottom-color: var(--qlb-terms-blue); }
.qlb-terms-card--green  { border-bottom-color: var(--qlb-terms-apple-green); }

/* Card header row: number circle + title */
.qlb-terms-card-head {
    display: flex;
    align-items: center;
    gap: 14px;
    margin-bottom: 16px;
    padding-bottom: 14px;
    border-bottom: 1px solid #f0e6ff;
}

.qlb-terms-num {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: var(--qlb-terms-deep-purple);
    color: #ffffff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: 'Poppins', sans-serif;
    font-weight: 800;
    font-size: 0.9rem;
    flex-shrink: 0;
}

.qlb-terms-card h2 {
    font-family: 'Poppins', sans-serif;
    font-size: 1.05rem;
    font-weight: 700;
    color: var(--qlb-terms-deep-purple);
    margin: 0;
    line-height: 1.3;
}

.qlb-terms-card p {
    font-size: 13.5px;
    color: #444;
    margin: 0 0 10px;
    line-height: 1.75;
}

.qlb-terms-card p:last-child { margin-bottom: 0; }

.qlb-terms-card ul,
.qlb-terms-card ol {
    padding-left: 20px;
    margin: 0 0 10px;
}

.qlb-terms-card li {
    font-size: 13.5px;
    color: #444;
    margin-bottom: 5px;
    line-height: 1.7;
}

.qlb-terms-card strong { color: var(--qlb-terms-text); font-weight: 700; }
.qlb-terms-card a { color: var(--qlb-terms-deep-purple); }
.qlb-terms-card a:hover { text-decoration: underline; }

/* Sub-heading inside a card */
.qlb-terms-sub {
    font-size: 11px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 2px;
    color: var(--qlb-terms-deep-purple);
    margin: 16px 0 8px;
    display: block;
}

/* Alert box — yellow (important notice) */
.qlb-terms-alert {
    background: #fffbeb;
    border: 1px solid #fcd34d;
    border-left: 4px solid var(--qlb-terms-yellow);
    border-radius: 8px;
    padding: 12px 16px;
    margin: 12px 0;
    font-size: 13px;
    line-height: 1.65;
    color: #78350f;
}

.qlb-terms-alert strong { color: #92400e; }

/* Not-liable box — pink/purple */
.qlb-terms-notliable {
    background: #fdf4ff;
    border: 1px solid #e9d5ff;
    border-left: 4px solid var(--qlb-terms-deep-purple);
    border-radius: 8px;
    padding: 12px 16px;
    margin: 12px 0;
    font-size: 13px;
    line-height: 1.65;
    color: #5b21b6;
}

.qlb-terms-notliable strong { color: #4B0082; }

/* ── Acceptance banner — mirrors about mission strip ──────────────────── */
.qlb-terms-accept {
    background: var(--qlb-terms-deep-purple);
    border-radius: 16px;
    padding: 48px 40px;
    text-align: center;
    position: relative;
    overflow: hidden;
}

.qlb-terms-accept::before {
    content: '';
    position: absolute;
    inset: 0;
    background: var(--qlb-terms-gradient);
    opacity: 0.08;
    pointer-events: none;
}

.qlb-terms-accept-tag {
    display: inline-block;
    background: var(--qlb-terms-yellow);
    color: var(--qlb-terms-deep-purple);
    font-size: 10px;
    font-weight: 800;
    letter-spacing: 3px;
    text-transform: uppercase;
    padding: 5px 16px;
    border-radius: 20px;
    margin-bottom: 20px;
}

.qlb-terms-accept h2 {
    font-family: 'Poppins', sans-serif;
    color: #ffffff;
    font-size: clamp(1.4rem, 3vw, 2rem);
    font-weight: 800;
    margin: 0 0 14px;
}

.qlb-terms-accept p {
    color: rgba(255, 255, 255, 0.82);
    font-size: 1rem;
    max-width: 600px;
    margin: 0 auto 24px;
    line-height: 1.65;
}

/* CTA button — identical to .qlb-about-btn */
.qlb-terms-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: var(--qlb-terms-yellow);
    color: var(--qlb-terms-deep-purple);
    font-family: 'Poppins', sans-serif;
    font-weight: 800;
    font-size: 0.95rem;
    padding: 13px 28px;
    border-radius: 999px;
    text-decoration: none;
    transition: background 0.18s ease, transform 0.18s ease;
}

.qlb-terms-btn:hover {
    background: #e6c200;
    transform: translateY(-2px);
    text-decoration: none;
    color: var(--qlb-terms-deep-purple);
}

/* ── Footer — identical to about footer ─────────────────────────────────── */
.qlb-terms-footer {
    background: #0b0b0b;
    color: rgba(255, 255, 255, 0.5);
    text-align: center;
    font-size: 12.5px;
    padding: 24px 20px;
}

.qlb-terms-footer a {
    color: rgba(255, 255, 255, 0.65);
    text-decoration: none;
    transition: color 0.15s;
}

.qlb-terms-footer a:hover {
    color: var(--qlb-terms-yellow);
}

/* ── Responsive ─────────────────────────────────────────────────────────── */
@media (max-width: 860px) {
    .qlb-terms-section {
        grid-template-columns: 1fr;
    }
    .qlb-terms-toc {
        position: static;
    }
}

@media (max-width: 600px) {
    .qlb-terms-hero {
        padding: 28px 5% 36px;
    }
    .qlb-terms-section {
        padding: 0 5% 48px;
    }
    .qlb-terms-card {
        padding: 20px 18px;
    }
    .qlb-terms-accept {
        padding: 36px 24px;
    }
}
