/* CSS Variables for consistent theming */
:root {
    --indigo-light: #6366F1;
    --indigo-dark: #4338CA;
    --primary-gradient: linear-gradient(135deg, var(--indigo-light) 0%, var(--indigo-dark) 100%);
    --primary-solid: #4f46e5;
    --text-dark: #111111;
    --text-main: #333333;
    --text-light: #666666;
    --text-muted: #999999;
    --bg-white: #ffffff;
    --bg-gray: #f8f9fa;
    --border-color: #e5e5e5;
    --font-heading: 'Exo 2', sans-serif;
    --font-body: 'Noto Sans SC', sans-serif;
    --transition-speed: 0.3s;
}

/* Reset & Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    overflow-x: hidden;
    scrollbar-gutter: stable;
}

body {
    overflow-x: hidden;
}

body {
    font-family: var(--font-body);
    color: var(--text-main);
    line-height: 1.6;
    background-color: var(--bg-white);
    max-width: 100vw;
    -webkit-font-smoothing: antialiased;
}

a {
    text-decoration: none;
    color: inherit;
    transition: color var(--transition-speed);
}

ul {
    list-style: none;
}

/* Utility */
.container {
    max-width: 1280px;
    margin: 0 auto;
    padding: 0 40px;
}

.section-title {
    font-family: var(--font-heading);
    font-size: 2.2rem;
    font-weight: 800;
    font-style: italic;
    color: var(--text-dark);
    margin-bottom: 30px;
    display: flex;
    justify-content: space-between;
    align-items: baseline;
}

.view-all {
    font-family: var(--font-body);
    font-size: 0.9rem;
    font-style: normal;
    font-weight: 400;
    color: var(--text-main);
    cursor: pointer;
}

.view-all i {
    margin-left: 5px;
    color: var(--primary-solid);
}

/* ─── Top Navigation ─────────────────────────────────────────── */
nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 72px;
    padding: 0 40px;
    background: var(--bg-white);
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    width: 100%;
    z-index: 1000;
    box-shadow: 0 1px 5px rgba(0, 0, 0, 0.05);
}

.nav-logo {
    font-family: var(--font-heading);
    font-size: 1.8rem;
    font-weight: 800;
    font-style: italic;
    background: var(--primary-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    color: transparent;
    display: flex;
    align-items: center;
    gap: 10px;
}

.nav-logo img {
    width: 40px;
    height: 40px;
    object-fit: contain;
}

.nav-links {
    display: flex;
    gap: 40px;
}

.nav-links a {
    font-weight: 500;
    font-size: 1rem;
    position: relative;
}

.nav-links a:hover {
    color: var(--primary-solid);
}

.nav-links a.active {
    color: var(--primary-solid);
}

.nav-links a.active::after {
    content: '';
    position: absolute;
    bottom: -6px;
    left: 0;
    right: 0;
    height: 2px;
    background: var(--primary-solid);
    border-radius: 2px;
}

.lang-switch {
    font-size: 0.9rem;
    color: var(--text-light);
    cursor: pointer;
    display: flex;
    gap: 6px;
    align-items: center;
}

.lang-switch a {
    color: var(--text-light);
    transition: color var(--transition-speed);
}

.lang-switch a:hover {
    color: var(--text-dark);
}

.lang-switch a.active {
    color: var(--text-dark);
    font-weight: 500;
}

.lang-switch .lang-sep {
    color: var(--border-color);
}

/* Right-side nav group (lang switch + hamburger) */
.nav-right {
    display: flex;
    align-items: center;
    gap: 12px;
}

/* Hamburger button (hidden on desktop) */
.mobile-menu-btn {
    display: none;
    background: none;
    border: none;
    font-size: 1.4rem;
    color: var(--text-main);
    cursor: pointer;
    padding: 4px 8px;
    line-height: 1;
}

/* Language row inside hamburger dropdown (hidden on desktop) */
.mobile-lang-row {
    display: none;
}

/* Mobile nav open state */
@keyframes menuSlideDown {
    from { opacity: 0; transform: translateY(-8px); }
    to   { opacity: 1; transform: translateY(0); }
}

/* ─── Hero Section ───────────────────────────────────────────── */

/* Push page content below fixed nav */
body > .hero,
body > header.hero,
#site-header + .hero,
#site-header ~ .hero {
    margin-top: 72px;
}

.hero {
    position: relative;
    background: linear-gradient(135deg, rgba(243, 244, 251, 0.65) 0%, rgba(224, 231, 255, 0.55) 100%),
                url('https://images.unsplash.com/photo-1486312338219-ce68d2c6f44d?auto=format&fit=crop&w=2000&q=80') center/cover no-repeat;
    padding: 120px 40px;
    overflow: hidden;
}

.hero::before {
    content: '';
    position: absolute;
    top: 0; right: 0; bottom: 0; left: 0;
    background-image: radial-gradient(var(--border-color) 1px, transparent 1px);
    background-size: 30px 30px;
    opacity: 0.3;
    z-index: 0;
}

.hero-content {
    position: relative;
    z-index: 1;
    max-width: 800px;
}

.hero h1 {
    font-family: var(--font-heading);
    font-size: 3.5rem;
    font-weight: 800;
    font-style: italic;
    color: var(--text-dark);
    margin-bottom: 20px;
    line-height: 1.2;
}

.hero p {
    font-size: 1.2rem;
    color: var(--text-light);
    margin-bottom: 40px;
    max-width: 600px;
}

.hero-btns {
    display: flex;
    gap: 20px;
}

/* ─── Buttons ────────────────────────────────────────────────── */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 12px 30px;
    font-size: 1rem;
    font-weight: 500;
    border-radius: 4px;
    cursor: pointer;
    transition: all var(--transition-speed);
    border: 1px solid transparent;
}

.btn-primary {
    background: var(--primary-gradient);
    color: white;
    border: none;
}

.btn-primary:hover {
    background: linear-gradient(135deg, #7174fa 0%, #4f42e5 100%);
    box-shadow: 0 6px 20px rgba(67, 56, 202, 0.3);
    transform: translateY(-1px);
}

.btn-outline {
    background-color: transparent;
    color: var(--text-main);
    border-color: var(--border-color);
}

.btn-outline:hover {
    border-color: var(--primary-solid);
    color: var(--primary-solid);
}

.btn i {
    margin-right: 8px;
}

/* ─── Hero Platform Badges ───────────────────────────────────── */
.hero-platforms {
    margin-top: 40px;
    display: flex;
    align-items: center;
    gap: 15px;
    flex-wrap: wrap;
}

.platforms-label {
    font-size: 0.95rem;
    color: var(--text-light);
    font-weight: 500;
}

.platform-badges {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
}

.platform-badge {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 0.85rem;
    font-weight: 500;
    color: var(--text-main);
    background: rgba(255, 255, 255, 0.85);
    border: 1px solid var(--border-color);
    padding: 6px 12px;
    border-radius: 20px;
    transition: all var(--transition-speed);
    cursor: pointer;
    min-width: 0;
    overflow-wrap: break-word;
    text-decoration: none;
}

.platform-badge i {
    color: var(--primary-solid);
    font-size: 1rem;
}

.platform-badge:hover {
    border-color: var(--indigo-light);
    background: white;
    box-shadow: 0 4px 12px rgba(99, 102, 241, 0.15);
    color: var(--primary-solid);
    transform: translateY(-2px);
}

.platform-badge:active {
    transform: translateY(0);
    box-shadow: 0 2px 6px rgba(99, 102, 241, 0.12);
}

/* ─── Sub Navigation ─────────────────────────────────────────── */
.sub-nav {
    border-bottom: 1px solid var(--border-color);
    background: var(--bg-white);
    position: sticky;
    top: 72px;
    z-index: 999;
}

.sub-nav-container {
    display: flex;
    gap: 40px;
    max-width: 1280px;
    margin: 0 auto;
    padding: 0 40px;
}

.sub-nav a {
    padding: 20px 0;
    color: var(--text-light);
    font-size: 0.95rem;
    position: relative;
}

.sub-nav a:hover,
.sub-nav a.active {
    color: var(--primary-solid);
}

.sub-nav a.active::after {
    content: '';
    position: absolute;
    bottom: -1px;
    left: 0;
    width: 100%;
    height: 3px;
    background: var(--primary-gradient);
    border-radius: 3px 3px 0 0;
}

/* ─── Split Section ──────────────────────────────────────────── */
.split-section {
    padding: 80px 0;
    display: flex;
    gap: 60px;
}

.split-column {
    flex: 1;
    min-width: 0;
}

.split-left {
    padding-right: 60px;
    border-right: 1px solid var(--border-color);
}

.data-list {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.data-item {
    display: flex;
    align-items: flex-start;
    padding-bottom: 20px;
    border-bottom: 1px solid #f0f0f0;
    transition: transform 0.2s;
}

.data-item:hover {
    transform: translateX(5px);
}

.item-marker {
    width: 24px;
    height: 24px;
    background: var(--primary-gradient);
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.8rem;
    font-weight: bold;
    border-radius: 2px;
    margin-right: 20px;
    flex-shrink: 0;
    margin-top: 3px;
}

.item-content {
    flex: 1;
    min-width: 0;
}

.item-title {
    font-size: 1.1rem;
    font-weight: 500;
    color: var(--text-main);
    margin-bottom: 8px;
}

.item-desc {
    font-size: 0.9rem;
    color: var(--text-light);
    margin-bottom: 10px;
}

.item-meta {
    display: inline-block;
    font-family: var(--font-heading);
    font-style: italic;
    font-size: 0.85rem;
    color: var(--primary-solid);
    border-bottom: 1px solid var(--primary-solid);
    padding-bottom: 2px;
}

.download-item {
    align-items: center;
}

.platform-icon {
    font-size: 2rem;
    color: var(--text-light);
    margin-right: 20px;
    width: 40px;
    text-align: center;
    flex-shrink: 0;
}

.circle-btn {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    border: 1px solid var(--indigo-light);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    color: var(--primary-solid);
    background: transparent;
    transition: all var(--transition-speed);
    cursor: pointer;
    text-decoration: none;
    flex-shrink: 0;
}

.circle-btn i {
    font-size: 1.2rem;
    margin-bottom: 2px;
}

.circle-btn span {
    font-size: 0.6rem;
    font-weight: bold;
}

.circle-btn:hover {
    background: var(--primary-gradient);
    color: white;
    border-color: transparent;
    box-shadow: 0 4px 12px rgba(67, 56, 202, 0.25);
}

/* ─── Trust Section ──────────────────────────────────────────── */
.trust-section {
    background-color: var(--bg-gray);
    padding: 80px 0;
    text-align: center;
}

.trust-title {
    font-family: var(--font-heading);
    font-size: 2rem;
    font-style: italic;
    font-weight: 800;
    margin-bottom: 40px;
}

.stats-grid {
    display: flex;
    justify-content: center;
    gap: 80px;
}

.stat-box {
    text-align: center;
}

.stat-number {
    font-family: var(--font-heading);
    font-size: 3rem;
    font-weight: 800;
    background: var(--primary-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    color: transparent;
    line-height: 1;
    margin-bottom: 10px;
}

.stat-label {
    font-size: 1rem;
    color: var(--text-light);
}

/* ─── Footer ─────────────────────────────────────────────────── */
.site-footer {
    background-color: var(--bg-white);
    border-top: 1px solid var(--border-color);
    padding: 60px 40px 30px;
}

.footer-top {
    display: flex;
    align-items: center;
    margin-bottom: 40px;
    border-bottom: 1px solid var(--border-color);
    padding-bottom: 30px;
}

.footer-social-title {
    font-size: 1.1rem;
    color: var(--text-light);
    margin-right: 30px;
}

.social-links {
    display: flex;
    gap: 20px;
}

.social-links a {
    color: var(--text-light);
    font-size: 1.5rem;
}

.social-links a:hover {
    color: var(--text-dark);
}

.footer-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 40px;
    margin-bottom: 60px;
}

.footer-col h4 {
    font-size: 1.1rem;
    font-weight: 400;
    color: var(--text-light);
    margin-bottom: 20px;
}

.footer-col ul li {
    margin-bottom: 12px;
}

.footer-col ul a {
    color: var(--text-main);
    font-size: 0.95rem;
}

.footer-col ul a:hover {
    color: var(--primary-solid);
}

.footer-logo-area {
    display: flex;
    justify-content: flex-end;
    align-items: flex-start;
}

.footer-logo-area span {
    font-family: var(--font-heading);
    font-size: 2rem;
    font-weight: 800;
    font-style: italic;
    background: var(--primary-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    color: transparent;
}

.footer-bottom {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-top: 20px;
    border-top: 1px solid var(--border-color);
    font-size: 0.85rem;
    color: var(--text-light);
}

.footer-bottom-links {
    display: flex;
    gap: 20px;
}

/* ─── Floating Tools ─────────────────────────────────────────── */
.floating-tools {
    position: fixed;
    bottom: 40px;
    right: 40px;
    display: flex;
    flex-direction: column;
    gap: 10px;
    z-index: 100;
}

.floating-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--bg-white);
    border: 1px solid var(--border-color);
    color: var(--text-main);
    border-radius: 4px;
    cursor: pointer;
    transition: all 0.3s;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
}

.btn-github-float {
    padding: 10px 20px;
    font-size: 0.9rem;
}

.btn-github-float i {
    margin-right: 8px;
}

.btn-top {
    width: 45px;
    height: 45px;
    border-radius: 50%;
    font-size: 1.2rem;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s, visibility 0.3s, border-color 0.3s, color 0.3s;
}

.floating-btn:hover {
    border-color: var(--primary-solid);
    color: var(--primary-solid);
}

/* ─── Responsive ─────────────────────────────────────────────── */
@media (max-width: 992px) {
    .split-section {
        flex-direction: column;
        gap: 40px;
    }
    .split-left {
        padding-right: 0;
        border-right: none;
        border-bottom: 1px solid var(--border-color);
        padding-bottom: 40px;
    }
    .footer-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    .footer-logo-area {
        justify-content: flex-start;
        margin-top: 20px;
    }
}

@media (max-width: 900px) {
    .nav-links {
        display: none;
        position: absolute;
        top: 72px;
        left: 0;
        width: 100%;
        flex-direction: column;
        gap: 0;
        background: var(--bg-white);
        box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
        padding: 12px 0;
        animation: menuSlideDown 0.2s ease forwards;
    }
    .nav-links a {
        padding: 12px 24px;
        border-bottom: 1px solid var(--border-color);
    }
    .nav-links a:last-child {
        border-bottom: none;
    }
    nav.nav-open .nav-links {
        display: flex;
    }
    .mobile-menu-btn {
        display: block;
    }
    .lang-switch {
        display: none;
    }
    nav.nav-open .lang-switch {
        display: none;
    }
    .mobile-lang-row {
        display: flex;
        align-items: center;
        flex-wrap: wrap;
        gap: 6px;
        padding: 14px 24px;
        border-top: 1px solid var(--border-color);
        font-size: 0.9rem;
    }
    .mobile-lang-row a {
        color: var(--text-light);
        transition: color var(--transition-speed);
    }
    .mobile-lang-row a:hover {
        color: var(--text-dark);
    }
    .mobile-lang-row a.active {
        color: var(--text-dark);
        font-weight: 500;
    }
    .mobile-lang-row .lang-sep {
        color: var(--border-color);
    }
}

@media (max-width: 768px) {
    .hero {
        padding-top: 60px;
    }
    .hero h1 {
        font-size: 2.5rem;
    }
    .hero-btns {
        flex-direction: column;
    }
    .stats-grid {
        flex-direction: column;
        gap: 40px;
    }
    .sub-nav-container {
        gap: 20px;
        overflow-x: auto;
        white-space: nowrap;
    }
    .footer-grid {
        grid-template-columns: 1fr;
    }
    .footer-bottom {
        flex-direction: column;
        align-items: flex-start;
        gap: 15px;
    }
    .floating-tools {
        bottom: 20px;
        right: 20px;
    }
}

/* ─── Protocol Ticker ─────────────────────────────────────────── */
.proto-ticker {
    background: var(--text-dark);
    padding: 14px 0;
    overflow: hidden;
}

.proto-ticker-inner {
    display: flex;
    align-items: center;
}

.proto-label {
    flex-shrink: 0;
    font-size: 0.68rem;
    font-weight: 700;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: rgba(255, 255, 255, 0.3);
    padding: 0 28px;
    border-right: 1px solid rgba(255, 255, 255, 0.08);
    white-space: nowrap;
}

.proto-track-wrap {
    flex: 1;
    overflow: hidden;
    -webkit-mask-image: linear-gradient(90deg, transparent 0, #000 80px, #000 calc(100% - 80px), transparent 100%);
    mask-image: linear-gradient(90deg, transparent 0, #000 80px, #000 calc(100% - 80px), transparent 100%);
}

.proto-track {
    display: inline-flex;
    align-items: center;
    gap: 22px;
    white-space: nowrap;
    animation: proto-scroll 32s linear infinite;
}

.proto-track span {
    font-family: var(--font-heading);
    font-style: italic;
    font-weight: 600;
    font-size: 0.88rem;
    color: rgba(255, 255, 255, 0.6);
    letter-spacing: 0.03em;
}

.proto-track .dot {
    width: 3px;
    height: 3px;
    border-radius: 50%;
    background: rgba(99, 102, 241, 0.55);
    flex-shrink: 0;
    display: inline-block;
}

@keyframes proto-scroll {
    0%   { transform: translateX(0); }
    100% { transform: translateX(-50%); }
}

/* ─── How It Works ───────────────────────────────────────────── */
.how-section {
    background: var(--bg-gray);
    padding: 96px 0;
}

.how-header {
    text-align: center;
    margin-bottom: 64px;
}

.how-header h2 {
    font-family: var(--font-heading);
    font-size: 2.4rem;
    font-weight: 800;
    font-style: italic;
    color: var(--text-dark);
    margin-bottom: 14px;
}

.how-header p {
    font-size: 1rem;
    color: var(--text-light);
    max-width: 520px;
    margin: 0 auto;
    line-height: 1.7;
}

.how-steps {
    display: flex;
    align-items: flex-start;
}

.how-step {
    flex: 1;
    padding: 0 36px;
}

.how-step:first-child { padding-left: 0; }
.how-step:last-child  { padding-right: 0; }

.step-num {
    font-family: var(--font-heading);
    font-size: 5.5rem;
    font-weight: 800;
    font-style: italic;
    line-height: 1;
    background: var(--primary-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    color: transparent;
    opacity: 0.2;
    margin-bottom: -12px;
    user-select: none;
    pointer-events: none;
}

.step-body h3 {
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--text-dark);
    margin-bottom: 12px;
}

.step-body p {
    font-size: 0.88rem;
    color: var(--text-light);
    line-height: 1.75;
    margin-bottom: 16px;
}

.step-link {
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--primary-solid);
    display: inline-flex;
    align-items: center;
    gap: 6px;
    transition: gap var(--transition-speed);
}

.step-link:hover { gap: 10px; }
.step-link i { font-size: 0.8rem; }

.how-connector {
    display: flex;
    align-items: center;
    padding-top: 28px;
    flex-shrink: 0;
    gap: 0;
    color: var(--text-muted);
    opacity: 0.45;
}

.connector-dash {
    display: block;
    width: 28px;
    height: 1px;
    background: var(--border-color);
}

/* ─── Scenarios / Bento Grid ─────────────────────────────────── */
.scenarios-section {
    padding: 96px 0;
    background: var(--bg-white);
}

.section-subtitle {
    font-size: 1rem;
    color: var(--text-light);
    margin-top: -20px;
    margin-bottom: 48px;
    line-height: 1.6;
    font-style: normal;
    font-weight: 400;
}

.bento-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 18px;
}

.bento-item {
    border: 1px solid var(--border-color);
    border-radius: 10px;
    padding: 30px;
    transition: transform 0.25s ease, box-shadow 0.25s ease;
    background: var(--bg-white);
}

.bento-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 16px 48px rgba(0, 0, 0, 0.07);
}

.bento-wide {
    grid-column: span 2;
    display: flex;
    align-items: flex-start;
    gap: 24px;
}

.bento-accent {
    background: linear-gradient(135deg, #f2f2ff 0%, #e9ebff 100%);
    border-color: rgba(99, 102, 241, 0.2);
}

.bento-icon {
    font-size: 1.25rem;
    color: var(--primary-solid);
    flex-shrink: 0;
    width: 48px;
    height: 48px;
    background: rgba(99, 102, 241, 0.1);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.bento-item:not(.bento-wide) .bento-icon {
    margin-bottom: 18px;
}

.bento-item h3 {
    font-size: 1.05rem;
    font-weight: 700;
    color: var(--text-dark);
    margin-bottom: 10px;
}

.bento-text { flex: 1; }
.bento-text h3 { margin-top: 0; }

.bento-item p {
    font-size: 0.875rem;
    color: var(--text-light);
    line-height: 1.75;
}

/* ─── FAQ Section ────────────────────────────────────────────── */
.faq-section {
    padding: 96px 0;
    background: var(--bg-gray);
}

.faq-layout {
    display: grid;
    grid-template-columns: 260px 1fr;
    gap: 80px;
    align-items: start;
}

.faq-left h2 {
    font-family: var(--font-heading);
    font-size: 2.2rem;
    font-weight: 800;
    font-style: italic;
    color: var(--text-dark);
    margin-bottom: 16px;
    line-height: 1.2;
}

.faq-left p {
    font-size: 0.9rem;
    color: var(--text-light);
    line-height: 1.75;
}

.faq-right {
    display: flex;
    flex-direction: column;
}

.faq-item { border-bottom: 1px solid var(--border-color); }
.faq-item:first-child { border-top: 1px solid var(--border-color); }

.faq-q {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
    padding: 22px 0;
    background: none;
    border: none;
    cursor: pointer;
    text-align: left;
    gap: 16px;
}

.faq-q span {
    font-size: 0.97rem;
    font-weight: 600;
    color: var(--text-dark);
    line-height: 1.45;
}

.faq-icon {
    font-size: 0.85rem;
    color: var(--text-muted);
    flex-shrink: 0;
    transition: transform 0.3s ease, color 0.3s ease;
}

.faq-item.open .faq-icon {
    transform: rotate(45deg);
    color: var(--primary-solid);
}

.faq-item.open .faq-q span {
    color: var(--primary-solid);
}

.faq-a {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.38s cubic-bezier(0.4, 0, 0.2, 1);
}

.faq-a p {
    font-size: 0.88rem;
    color: var(--text-light);
    line-height: 1.8;
    padding-bottom: 24px;
}

.faq-a code {
    font-family: 'Courier New', monospace;
    font-size: 0.82rem;
    background: rgba(0, 0, 0, 0.05);
    padding: 1px 5px;
    border-radius: 3px;
}

.faq-item.open .faq-a { max-height: 600px; }

/* ─── New Sections Responsive ────────────────────────────────── */
@media (max-width: 992px) {
    .faq-layout {
        grid-template-columns: 1fr;
        gap: 40px;
    }
    .bento-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    .bento-wide {
        grid-column: span 2;
    }
}

@media (max-width: 768px) {
    .how-steps {
        flex-direction: column;
        gap: 40px;
    }
    .how-connector { display: none; }
    .how-step { padding: 0; }
    .step-num { font-size: 4rem; }
    .how-header h2 { font-size: 1.9rem; }
    .bento-grid { grid-template-columns: 1fr; }
    .bento-wide {
        grid-column: span 1;
        flex-direction: column;
    }
    .proto-label { display: none; }
    .faq-left h2 { font-size: 1.8rem; }
    .faq-layout { gap: 32px; }
}

/* ─── Compare Section ────────────────────────────────────────── */
.compare-section {
    padding: 96px 0;
    background: var(--bg-gray);
}

.compare-layout {
    display: grid;
    grid-template-columns: 280px 1fr;
    gap: 80px;
    align-items: start;
}

.compare-intro h2 {
    font-family: var(--font-heading);
    font-size: 2.2rem;
    font-weight: 800;
    font-style: italic;
    color: var(--text-dark);
    margin-bottom: 16px;
    line-height: 1.2;
}

.compare-intro p {
    font-size: 0.9rem;
    color: var(--text-light);
    line-height: 1.75;
}

.compare-table {
    display: grid;
    grid-template-columns: 1fr auto 1fr;
    gap: 0;
    align-items: start;
}

.compare-col-head {
    font-family: var(--font-heading);
    font-style: italic;
    font-weight: 700;
    font-size: 1rem;
    margin-bottom: 22px;
    padding-bottom: 14px;
    border-bottom: 2px solid;
}

.compare-old .compare-col-head {
    color: var(--text-muted);
    border-color: var(--border-color);
}

.compare-new .compare-col-head {
    color: var(--primary-solid);
    border-color: var(--primary-solid);
}

.compare-col ul {
    display: flex;
    flex-direction: column;
    gap: 16px;
    list-style: none;
}

.compare-col ul li {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    font-size: 0.875rem;
    line-height: 1.55;
}

.compare-col ul li i {
    flex-shrink: 0;
    margin-top: 2px;
}

.compare-old ul li {
    color: var(--text-muted);
}

.compare-old ul li i {
    color: #d1d5db;
}

.compare-new ul li {
    color: var(--text-main);
    font-weight: 500;
}

.compare-new ul li i {
    color: #22c55e;
}

.compare-divider {
    font-family: var(--font-heading);
    font-style: italic;
    font-weight: 800;
    font-size: 1.2rem;
    color: var(--border-color);
    padding: 0 22px;
    padding-top: 48px;
    text-align: center;
}

/* ─── Platform Detail Tabs ───────────────────────────────────── */
.platform-detail-section {
    padding: 96px 0;
    background: var(--bg-white);
}

.pds-title {
    font-family: var(--font-heading);
    font-size: 2.2rem;
    font-weight: 800;
    font-style: italic;
    color: var(--text-dark);
    margin-bottom: 10px;
}

.pds-sub {
    font-size: 1rem;
    color: var(--text-light);
    margin-bottom: 40px;
    line-height: 1.6;
}

.ptab-nav {
    display: flex;
    gap: 0;
    border-bottom: 1px solid var(--border-color);
    margin-bottom: 48px;
    overflow-x: auto;
    -ms-overflow-style: none;
    scrollbar-width: none;
}

.ptab-nav::-webkit-scrollbar { display: none; }

.ptab-btn {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 16px 26px;
    background: none;
    border: none;
    border-bottom: 3px solid transparent;
    cursor: pointer;
    font-size: 0.9rem;
    font-weight: 500;
    color: var(--text-light);
    white-space: nowrap;
    margin-bottom: -1px;
    transition: color 0.25s ease, border-color 0.25s ease;
    font-family: var(--font-body);
}

.ptab-btn:hover { color: var(--text-dark); }

.ptab-btn.active {
    color: var(--primary-solid);
    border-bottom-color: var(--primary-solid);
}

.ptab-panel { display: none; }
.ptab-panel.active { display: block; }

.ptab-body {
    display: grid;
    grid-template-columns: 1fr 300px;
    gap: 60px;
    align-items: start;
}

.ptab-info h3 {
    font-family: var(--font-heading);
    font-size: 1.8rem;
    font-weight: 800;
    font-style: italic;
    color: var(--text-dark);
    margin-bottom: 6px;
}

.ptab-sub-text {
    font-size: 0.9rem;
    color: var(--primary-solid);
    margin-bottom: 18px;
    font-weight: 500;
}

.ptab-info > p {
    font-size: 0.9rem;
    color: var(--text-light);
    line-height: 1.75;
    margin-bottom: 22px;
}

.ptab-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 30px;
}

.ptab-tags span {
    font-size: 0.76rem;
    font-weight: 600;
    color: var(--primary-solid);
    background: rgba(99, 102, 241, 0.07);
    border: 1px solid rgba(99, 102, 241, 0.18);
    padding: 4px 12px;
    border-radius: 20px;
}

.ptab-actions {
    display: flex;
    gap: 14px;
    flex-wrap: wrap;
}

.ptab-spec {
    background: var(--bg-gray);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    padding: 6px 0;
}

.spec-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 13px 22px;
    border-bottom: 1px solid var(--border-color);
    font-size: 0.84rem;
    gap: 12px;
}

.spec-item:last-child { border-bottom: none; }
.spec-k { color: var(--text-muted); flex-shrink: 0; }
.spec-v { color: var(--text-main); font-weight: 500; text-align: right; }

/* ─── Blog Preview ───────────────────────────────────────────── */
.blog-preview-section {
    padding: 96px 0;
    background: var(--bg-gray);
}

.bp-header {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    margin-bottom: 40px;
}

.bp-header h2 {
    font-family: var(--font-heading);
    font-size: 2.2rem;
    font-weight: 800;
    font-style: italic;
    color: var(--text-dark);
}

.bp-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 22px;
    align-items: stretch;
}

.bp-featured {
    display: block;
    border-radius: 10px;
    overflow: hidden;
    position: relative;
    min-height: 380px;
    background: linear-gradient(145deg, #1e1b4b 0%, #3730a3 55%, #4f46e5 100%);
    text-decoration: none;
    transition: transform 0.28s ease, box-shadow 0.28s ease;
}

.bp-featured-deco {
    position: absolute;
    top: -60px;
    right: -60px;
    width: 260px;
    height: 260px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(255,255,255,0.06) 0%, transparent 70%);
    pointer-events: none;
}

.bp-featured:hover {
    transform: translateY(-5px);
    box-shadow: 0 24px 64px rgba(67, 56, 202, 0.28);
}

.bp-featured-content {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    padding: 36px 32px;
    background: linear-gradient(to top, rgba(0, 0, 0, 0.65) 0%, transparent 100%);
}

.bp-cat {
    display: inline-block;
    font-size: 0.7rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    border-radius: 20px;
    padding: 4px 10px;
    margin-bottom: 12px;
}

.bp-featured-content .bp-cat {
    color: rgba(255, 255, 255, 0.8);
    background: rgba(255, 255, 255, 0.12);
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.bp-featured-content h3 {
    font-size: 1.25rem;
    font-weight: 700;
    color: #fff;
    margin-bottom: 10px;
    line-height: 1.45;
}

.bp-featured-content p {
    font-size: 0.84rem;
    color: rgba(255, 255, 255, 0.7);
    line-height: 1.65;
}

.bp-list {
    display: flex;
    flex-direction: column;
    gap: 22px;
}

.bp-card {
    display: block;
    background: var(--bg-white);
    border: 1px solid var(--border-color);
    border-radius: 10px;
    padding: 28px;
    flex: 1;
    text-decoration: none;
    transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.bp-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 32px rgba(0, 0, 0, 0.07);
}

.bp-card-meta {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 14px;
}

.bp-card .bp-cat {
    color: var(--primary-solid);
    background: rgba(99, 102, 241, 0.07);
    border: 1px solid rgba(99, 102, 241, 0.15);
}

.bp-date {
    font-size: 0.78rem;
    color: var(--text-muted);
    font-family: var(--font-heading);
    font-style: italic;
}

.bp-card h3 {
    font-size: 1rem;
    font-weight: 700;
    color: var(--text-dark);
    margin-bottom: 9px;
    line-height: 1.45;
}

.bp-card p {
    font-size: 0.84rem;
    color: var(--text-light);
    line-height: 1.68;
}

/* ─── Additional New Sections Responsive ────────────────────── */
@media (max-width: 992px) {
    .compare-layout { grid-template-columns: 1fr; gap: 40px; }
    .ptab-body { grid-template-columns: 1fr; gap: 36px; }
    .bp-grid { grid-template-columns: 1fr; }
    .bp-featured { min-height: 300px; }
}

@media (max-width: 768px) {
    .compare-table {
        grid-template-columns: 1fr;
        gap: 32px;
    }
    .compare-divider { display: none; }
    .compare-intro h2 { font-size: 1.8rem; }
    .pds-title { font-size: 1.8rem; }
    .bp-header h2 { font-size: 1.8rem; }
    .section-title { font-size: 1.8rem; }
    .ptab-btn { padding: 14px 16px; font-size: 0.82rem; }
    .ptab-actions { flex-direction: column; }
    .ptab-info h3 { font-size: 1.4rem; }
}

@media (max-width: 480px) {
    .section-title {
        font-size: 1.4rem;
    }
    .bp-header h2 {
        font-size: 1.4rem;
    }
}

/* ─── Home (index.html): extracted inline styles → main.css ───────────────── */

.downloads-rule-hint {
    margin-top: 16px;
    font-size: 0.82rem;
    color: var(--text-muted, #888);
}

.downloads-rule-hint-link {
    color: inherit;
}

.section-title.section-title--compact {
    margin-bottom: 10px;
}

.faq-intro-cta {
    margin-top: 28px;
}

.compare-all-features-link {
    margin-top: 20px;
    display: inline-flex;
}

/* Rule engine flow diagram (homepage) */
.rule-flow-diagram-scroll {
    margin: 36px 0 44px;
    overflow-x: auto;
}

.rule-flow-diagram-track {
    display: flex;
    align-items: center;
    gap: 0;
    min-width: 560px;
}

.rule-flow-step {
    flex: 1;
    border: 1px solid #35355a;
    border-top: 3px solid #7c6af7;
    border-radius: 10px;
    padding: 20px 18px;
}

.rule-flow-step-head {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 10px;
}

.rule-flow-step-num {
    background: #7c6af7;
    color: #fff;
    font-size: 0.68rem;
    font-weight: 700;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    line-height: 1;
}

.rule-flow-step-icon {
    color: #7c6af7;
    font-size: 0.95rem;
}

.rule-flow-step-title {
    font-size: 0.88rem;
    font-weight: 700;
    margin-bottom: 4px;
}

.rule-flow-step-desc {
    font-size: 0.76rem;
    color: #888;
    line-height: 1.4;
}

.rule-flow-connector {
    display: flex;
    align-items: center;
    padding: 0 6px;
    flex-shrink: 0;
    color: #454565;
}

.rule-flow-connector-line {
    width: 22px;
    height: 1px;
    background: currentColor;
}

.rule-flow-connector-caret {
    margin-left: -1px;
    font-size: 0.8rem;
}

.rule-flow-outcomes {
    flex: 1;
    border: 1px solid #35355a;
    border-radius: 10px;
    padding: 16px 18px;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.rule-flow-outcomes-label {
    font-size: 0.7rem;
    font-weight: 600;
    color: #666;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    margin-bottom: 2px;
}

.rule-flow-pill {
    display: flex;
    align-items: center;
    gap: 7px;
    border-radius: 6px;
    padding: 7px 11px;
}

.rule-flow-pill--direct {
    background: #0d1f0d;
    border: 1px solid #1e3c1e;
}

.rule-flow-pill--proxy {
    background: #0d0d22;
    border: 1px solid #2a2a55;
}

.rule-flow-pill--reject {
    background: #1f0d0d;
    border: 1px solid #3c1e1e;
}

.rule-flow-pill--direct .rule-flow-pill-icon {
    color: #4caf50;
}

.rule-flow-pill--direct .rule-flow-pill-name {
    font-size: 0.8rem;
    font-weight: 600;
    color: #4caf50;
}

.rule-flow-pill--direct .rule-flow-pill-note {
    font-size: 0.75rem;
    color: #5a7a5a;
    margin-left: auto;
}

.rule-flow-pill--proxy .rule-flow-pill-icon {
    color: #7c6af7;
}

.rule-flow-pill--proxy .rule-flow-pill-name {
    font-size: 0.8rem;
    font-weight: 600;
    color: #7c6af7;
}

.rule-flow-pill--proxy .rule-flow-pill-note {
    font-size: 0.75rem;
    color: #555580;
    margin-left: auto;
}

.rule-flow-pill--reject .rule-flow-pill-icon {
    color: #e53935;
}

.rule-flow-pill--reject .rule-flow-pill-name {
    font-size: 0.8rem;
    font-weight: 600;
    color: #e53935;
}

.rule-flow-pill--reject .rule-flow-pill-note {
    font-size: 0.75rem;
    color: #7a3a3a;
    margin-left: auto;
}

.rule-flow-pill-icon {
    font-size: 0.75rem;
    width: 14px;
    text-align: center;
}

.rule-engine-docs-cta {
    text-align: center;
    margin-top: 36px;
}

.trust-github-cta {
    margin-top: 50px;
}

.btn-github {
    background: #24292e;
}

.btn-github:hover {
    background: #2f363d;
}
