/* ==============================================================
   ScorpionTrack — Shared Page Section Styles
   Reusable section patterns for all sub-pages
   Uses design tokens from main.css
   ============================================================== */

/* ============================================================
   PAGE WRAPPER — scoping container for sub-pages
   Each page adds a specific class: .thatcham-page, .fleet-page, etc.
   ============================================================ */

/* ============================================================
   SECTION BASE
   ============================================================ */
.st-section {
    padding: var(--section-padding);
    width: 100%;
}

.st-section .section-inner {
    max-width: var(--max-width);
    margin: 0 auto;
}

/* ============================================================
   HERO SECTION
   ============================================================ */
.st-hero {
    background: linear-gradient(135deg, var(--st-navy) 0%, #162D52 100%);
    color: var(--st-white);
    padding: var(--section-padding-lg);
    text-align: center;
    position: relative;
    overflow: hidden;
}

.st-hero::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -10%;
    width: 500px;
    height: 500px;
    background: rgba(134, 224, 38, 0.05);
    border-radius: 50%;
    pointer-events: none;
}

.st-hero .hero-content {
    position: relative;
    z-index: 1;
    max-width: 900px;
    margin: 0 auto;
}

.st-hero .hero-label {
    font-family: var(--font-body);
    font-size: 0.875rem;
    font-weight: 600;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: var(--st-lime);
    margin-bottom: var(--sp-1);
}

.st-hero h1 {
    color: var(--st-white);
    margin-bottom: var(--sp-3);
}

.st-hero .hero-subtitle {
    font-size: 1.25rem;
    line-height: 1.7;
    color: rgba(255, 255, 255, 0.9);
    max-width: 700px;
    margin: 0 auto;
}

/* ============================================================
   LIGHT SECTIONS
   ============================================================ */
.st-section-light {
    background: #F8FAFC;
}

.st-section-light h2 {
    color: var(--st-navy);
}

.st-section-light .section-description {
    font-size: 1.125rem;
    color: var(--st-body-text);
    max-width: 600px;
    margin-bottom: var(--sp-5);
}

/* ============================================================
   DARK SECTIONS
   ============================================================ */
.st-section-dark {
    background: linear-gradient(135deg, var(--st-navy) 0%, #162D52 100%);
    color: var(--st-white);
}

.st-section-dark h2 {
    color: var(--st-white);
}

.st-section-dark .section-description {
    font-size: 1.125rem;
    color: rgba(255, 255, 255, 0.9);
    max-width: 600px;
    margin-bottom: var(--sp-5);
}

/* ============================================================
   FEATURE CARDS — Light Background
   ============================================================ */
.st-features-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: var(--sp-4);
    margin-top: var(--sp-5);
}

.st-feature-card {
    padding: var(--sp-4);
    border-radius: 12px;
    background: var(--st-white);
    box-shadow: var(--shadow-md);
    transition: transform var(--duration) var(--ease),
                box-shadow var(--duration) var(--ease);
}

.st-feature-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-lg);
}

.st-feature-card h3 {
    color: var(--st-navy);
    text-transform: uppercase;
    font-family: var(--font-heading);
    font-weight: 800;
    margin-bottom: 0.75rem;
}

.st-feature-card p {
    color: var(--st-body-text);
    line-height: 1.6;
}

/* ============================================================
   FEATURE CARDS — Dark Background (Glass Morphic)
   ============================================================ */
.st-section-dark .st-feature-card {
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
}

.st-section-dark .st-feature-card h3 {
    color: var(--st-white);
}

.st-section-dark .st-feature-card p {
    color: rgba(255, 255, 255, 0.9);
}

.st-section-dark .st-feature-card:hover {
    background: rgba(255, 255, 255, 0.12);
    border-color: var(--st-lime);
}

/* ============================================================
   PRODUCT CARDS
   Universal product card component — used on homepage (dark)
   and sub-pages (light).
   Matches homepage card structure:
   .product-image > img + .product-badge
   .product-info > h3 + .product-desc + .product-features + .product-price
   ============================================================ */
.st-product-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: var(--sp-4);
    margin-top: var(--sp-5);
}

.st-product-grid.cols-3 {
    grid-template-columns: repeat(3, 1fr);
}

.st-product-grid.cols-2 {
    grid-template-columns: repeat(2, 1fr);
}

/* --- Card Base --- */
.st-product-card {
    border-radius: 16px;
    overflow: hidden;
    transition: transform var(--duration) var(--ease),
                box-shadow var(--duration) var(--ease);
    display: flex;
    flex-direction: column;
}

.st-product-card:hover {
    transform: translateY(-6px);
}

/* --- Product Image --- */
.st-product-card .product-image {
    position: relative;
    padding: 12px;
    display: flex;
    justify-content: center;
    align-items: center;
    height: 240px;
    overflow: hidden;
}

.st-product-card .product-image img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    border-radius: 8px;
}

.st-product-card .product-badge {
    position: absolute;
    top: 20px;
    left: 20px;
    display: inline-block;
    background: var(--st-lime);
    color: var(--st-navy);
    font-size: 0.7rem;
    font-weight: 700;
    padding: 6px 14px;
    border-radius: 20px;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    z-index: 1;
}

/* --- Product Info (text area below image) --- */
.st-product-card .product-info {
    padding: 20px;
    display: flex;
    flex-direction: column;
    flex: 1;
}

/* Legacy support: .product-header also works as the text area */
.st-product-card .product-header {
    padding: var(--sp-4);
    display: flex;
    flex-direction: column;
    flex: 1;
}

.st-product-card .product-title,
.st-product-card h3 {
    text-transform: uppercase;
    font-family: var(--font-heading);
    font-weight: 800;
    font-size: 1.1rem;
    margin: 0 0 6px 0;
}

.st-product-card .product-desc,
.st-product-card .product-description {
    font-size: 0.9rem;
    line-height: 1.6;
    margin-bottom: 12px;
    flex: 1;
}

/* --- Feature Tags --- */
.st-product-card .product-features {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-bottom: 14px;
}

.st-product-card .feature-tag {
    display: inline-block;
    font-size: 0.7rem;
    font-weight: 600;
    padding: 3px 10px;
    border-radius: 20px;
}

/* --- Price + Button Row --- */
.st-product-card .product-price {
    font-family: var(--font-heading);
    font-weight: 700;
    font-size: 1.2rem;
    margin: 0;
}

.st-product-card .product-price .price-sub {
    font-size: 0.8rem;
    font-weight: 400;
}

.st-product-card .price-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-top: 12px;
    margin-top: auto;
}

.st-product-card .btn-buy {
    background: var(--st-lime);
    color: var(--st-navy);
    border: none;
    border-radius: 4px;
    padding: 8px 18px;
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    cursor: pointer;
    transition: background var(--duration) var(--ease);
    text-decoration: none;
    display: inline-block;
}

.st-product-card .btn-buy:hover {
    background: #9BFF2E;
}

/* --- View link (alternative to button) --- */
.st-product-card .product-link {
    display: inline-block;
    margin-top: var(--sp-1);
    font-weight: 600;
    text-decoration: none;
    transition: color var(--duration) var(--ease);
}

/* ==============================================================
   PRODUCT CARD — DARK VARIANT (homepage style)
   On dark sections: translucent card, white text, lime accents
   ============================================================== */
.st-section-dark .st-product-card {
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.08);
}

.st-section-dark .st-product-card:hover {
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.3);
    border-color: rgba(255, 255, 255, 0.15);
}

.st-section-dark .st-product-card .product-title,
.st-section-dark .st-product-card h3 {
    color: var(--st-white);
}

.st-section-dark .st-product-card .product-desc,
.st-section-dark .st-product-card .product-description {
    color: rgba(255, 255, 255, 0.7);
}

.st-section-dark .st-product-card .feature-tag {
    background: rgba(140, 198, 63, 0.12);
    color: rgb(140, 198, 63);
}

.st-section-dark .st-product-card .product-price {
    color: var(--st-white);
}

.st-section-dark .st-product-card .product-link {
    color: var(--st-blue);
}

.st-section-dark .st-product-card .product-link:hover {
    color: var(--st-lime);
}

/* ==============================================================
   PRODUCT CARD — LIGHT VARIANT (sub-pages)
   On light sections: white card, navy text, subtle shadow
   ============================================================== */
.st-section-light .st-product-card {
    background: var(--st-white);
    border: 1px solid var(--st-border);
    box-shadow: var(--shadow-card);
}

.st-section-light .st-product-card:hover {
    box-shadow: var(--shadow-lg);
    border-color: var(--st-lime);
}

.st-section-light .st-product-card .product-title,
.st-section-light .st-product-card h3 {
    color: var(--st-navy);
}

.st-section-light .st-product-card .product-desc,
.st-section-light .st-product-card .product-description {
    color: var(--st-body-text);
}

.st-section-light .st-product-card .feature-tag {
    background: rgba(134, 224, 38, 0.12);
    color: var(--st-navy);
}

.st-section-light .st-product-card .product-price {
    color: var(--st-lime);
}

.st-section-light .st-product-card .product-link {
    color: var(--st-blue);
}

.st-section-light .st-product-card .product-link:hover {
    color: var(--st-lime);
}

/* ============================================================
   TWO COLUMN LAYOUT
   ============================================================ */
.st-two-col {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: var(--sp-8);
    align-items: center;
    margin-top: var(--sp-5);
}

.st-two-col .two-col-text h3 {
    font-size: 1.75rem;
    text-transform: uppercase;
    font-family: var(--font-heading);
    font-weight: 800;
    margin-bottom: var(--sp-1);
}

.st-two-col .two-col-text p {
    font-size: 1.05rem;
    line-height: 1.7;
    margin-bottom: var(--sp-1);
    color: var(--st-body-text);
}

.st-check-list {
    list-style: none;
    padding: 0;
    margin: var(--sp-2) 0 0;
}

.st-check-list li {
    padding: 0.5rem 0;
    font-size: 1rem;
    color: var(--st-body-text);
    position: relative;
    padding-left: 1.75rem;
}

.st-check-list li::before {
    content: '\2713';
    position: absolute;
    left: 0;
    color: var(--st-lime);
    font-weight: 700;
}

/* App mockup placeholder */
.st-app-mockup {
    background: linear-gradient(135deg, var(--st-navy) 0%, #162D52 100%);
    border-radius: 16px;
    padding: var(--sp-5);
    text-align: center;
    color: var(--st-white);
    min-height: 300px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
}

.st-app-mockup .app-icon {
    font-size: 4rem;
    margin-bottom: var(--sp-2);
}

.st-app-mockup h3 {
    color: var(--st-white);
    text-transform: uppercase;
    font-family: var(--font-heading);
    font-weight: 800;
}

.st-app-mockup p {
    color: rgba(255, 255, 255, 0.8);
}

/* ============================================================
   CTA SECTION
   ============================================================ */
.st-cta {
    text-align: center;
}

.st-cta h2 {
    color: var(--st-white);
    margin-bottom: var(--sp-1);
}

.st-cta p {
    color: rgba(255, 255, 255, 0.9);
    font-size: 1.125rem;
    max-width: 600px;
    margin: 0 auto var(--sp-5);
}

.st-form-wrapper {
    max-width: 700px;
    margin: 0 auto;
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    padding: var(--sp-5) var(--sp-4);
    backdrop-filter: blur(10px);
}

/* ============================================================
   FAQ / ACCORDION
   ============================================================ */
.st-faq-list {
    max-width: 800px;
    margin: var(--sp-5) auto 0;
}

.st-faq-item {
    border-bottom: 1px solid var(--st-border);
    padding: var(--sp-3) 0;
}

.st-faq-item summary {
    font-family: var(--font-heading);
    font-weight: 700;
    font-size: 1.1rem;
    color: var(--st-navy);
    cursor: pointer;
    text-transform: uppercase;
    list-style: none;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.st-faq-item summary::after {
    content: '+';
    font-size: 1.5rem;
    font-weight: 300;
    color: var(--st-blue);
    transition: transform var(--duration) var(--ease);
}

.st-faq-item[open] summary::after {
    content: '\2212';
}

.st-faq-item p {
    padding-top: var(--sp-2);
    color: var(--st-body-text);
    line-height: 1.7;
}

/* ============================================================
   CONTACT / INFO CARDS (3-col)
   ============================================================ */
.st-info-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: var(--sp-4);
    margin-top: var(--sp-5);
}

.st-info-card {
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    padding: var(--sp-4);
    backdrop-filter: blur(10px);
    text-align: center;
}

.st-info-card h3 {
    color: var(--st-white);
    text-transform: uppercase;
    font-family: var(--font-heading);
    font-weight: 800;
    margin-bottom: 0.75rem;
}

.st-info-card p,
.st-info-card a {
    color: rgba(255, 255, 255, 0.9);
}

.st-info-card a:hover {
    color: var(--st-lime);
}

/* ============================================================
   CALLOUT / HIGHLIGHT BOX
   ============================================================ */
.st-callout {
    background: var(--st-navy);
    color: var(--st-white);
    border-radius: 12px;
    padding: var(--sp-5);
    text-align: center;
    max-width: 800px;
    margin: var(--sp-5) auto 0;
}

.st-callout h3 {
    color: var(--st-white);
    text-transform: uppercase;
    font-family: var(--font-heading);
    font-weight: 800;
    margin-bottom: var(--sp-1);
}

.st-callout p {
    color: rgba(255, 255, 255, 0.9);
    font-size: 1.05rem;
}

/* ============================================================
   NEWS / ARTICLE CARDS
   ============================================================ */
.st-article-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: var(--sp-4);
    margin-top: var(--sp-5);
}

.st-article-card {
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    overflow: hidden;
    transition: transform var(--duration) var(--ease),
                border-color var(--duration) var(--ease);
}

.st-article-card:hover {
    transform: translateY(-4px);
    border-color: var(--st-lime);
}

.st-article-card .article-body {
    padding: var(--sp-3);
}

.st-article-card .article-meta {
    font-size: 0.8rem;
    color: rgba(255, 255, 255, 0.6);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: 0.5rem;
}

.st-article-card h3 {
    color: var(--st-white);
    font-size: 1.15rem;
    text-transform: uppercase;
    font-family: var(--font-heading);
    font-weight: 700;
    margin-bottom: 0.75rem;
}

.st-article-card p {
    color: rgba(255, 255, 255, 0.8);
    font-size: 0.95rem;
    line-height: 1.6;
}

/* Light variant */
.st-section-light .st-article-card {
    background: var(--st-white);
    border: 1px solid var(--st-border);
    box-shadow: var(--shadow-card);
}

.st-section-light .st-article-card h3 {
    color: var(--st-navy);
}

.st-section-light .st-article-card p {
    color: var(--st-body-text);
}

.st-section-light .st-article-card .article-meta {
    color: var(--st-body-text);
}

/* ============================================================
   TOPIC / CATEGORY CARDS
   ============================================================ */
.st-topic-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: var(--sp-3);
    margin-top: var(--sp-5);
}

.st-topic-card {
    background: var(--st-white);
    border: 1px solid var(--st-border);
    border-radius: 12px;
    padding: var(--sp-4);
    text-align: center;
    transition: transform var(--duration) var(--ease),
                border-color var(--duration) var(--ease);
}

.st-topic-card:hover {
    transform: translateY(-4px);
    border-color: var(--st-lime);
}

.st-topic-card .topic-icon {
    font-size: 2.5rem;
    margin-bottom: var(--sp-2);
}

.st-topic-card h3 {
    color: var(--st-navy);
    font-size: 1.1rem;
    text-transform: uppercase;
    font-family: var(--font-heading);
    font-weight: 700;
    margin-bottom: 0.5rem;
}

.st-topic-card p {
    color: var(--st-body-text);
    font-size: 0.9rem;
}

/* ============================================================
   FEATURED ARTICLE (full-width highlight)
   ============================================================ */
.st-featured-article {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: var(--sp-6);
    align-items: center;
    margin-top: var(--sp-5);
}

.st-featured-article .featured-image {
    background: var(--st-navy);
    border-radius: 12px;
    min-height: 280px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: rgba(255, 255, 255, 0.3);
    font-size: 3rem;
}

.st-featured-article .featured-meta {
    font-size: 0.8rem;
    color: var(--st-blue);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: 0.75rem;
}

.st-featured-article h3 {
    color: var(--st-navy);
    font-size: 1.75rem;
    text-transform: uppercase;
    font-family: var(--font-heading);
    font-weight: 800;
    margin-bottom: var(--sp-1);
}

.st-featured-article p {
    color: var(--st-body-text);
    font-size: 1.05rem;
    line-height: 1.7;
}

.st-featured-article .read-more {
    display: inline-block;
    margin-top: var(--sp-2);
    color: var(--st-blue);
    font-weight: 600;
    transition: color var(--duration) var(--ease);
}

.st-featured-article .read-more:hover {
    color: var(--st-lime);
}

/* ============================================================
   RESPONSIVE — 900px (Tablet)
   ============================================================ */
@media (max-width: 900px) {
    .st-hero {
        padding: var(--sp-10) var(--sp-3);
    }

    .st-section {
        padding: var(--sp-8) var(--sp-2);
    }

    .st-features-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: var(--sp-3);
    }

    .st-product-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: var(--sp-3);
    }

    .st-two-col {
        grid-template-columns: 1fr;
        gap: var(--sp-4);
    }

    .st-article-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .st-topic-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .st-info-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .st-featured-article {
        grid-template-columns: 1fr;
    }
}

/* ============================================================
   RESPONSIVE — 600px (Mobile)
   ============================================================ */
@media (max-width: 600px) {
    .st-hero {
        padding: var(--sp-8) var(--sp-2);
    }

    .st-hero .hero-subtitle {
        font-size: 1rem;
    }

    .st-section {
        padding: var(--sp-6) var(--sp-2);
    }

    .st-features-grid,
    .st-product-grid,
    .st-article-grid,
    .st-topic-grid,
    .st-info-grid {
        grid-template-columns: 1fr;
        gap: var(--sp-2);
    }

    .st-feature-card {
        padding: var(--sp-3);
    }

    .st-product-card .product-image {
        height: 180px;
    }

    .st-product-card .product-info {
        padding: 16px;
    }

    .st-form-wrapper {
        padding: var(--sp-4) var(--sp-2);
    }
}

/* ------------------------------------------------------------------
   Default page template (page.php) — legal / utility pages.
   Moved here from inline styles in page.php (theme v1.1.8).
   .page-title aligned to the 56px site H1 standard.
------------------------------------------------------------------ */
.container.page-narrow { max-width: 900px; margin: 0 auto; padding: 0 var(--sp-3); }
.page-featured-image { margin-bottom: var(--sp-6); }
.page-featured-image__img { width: 100%; height: auto; border-radius: 8px; }
.page-title { color: #0F2140; margin-bottom: var(--sp-4); font-family: 'Exo 2', sans-serif; font-size: clamp(2.2rem, 5vw, 3.5rem); }
.page-content { font-size: 1.05rem; line-height: 1.8; color: #4A5568; margin-bottom: var(--sp-6); }
.page-content .page-links { margin-top: var(--sp-4); }
