/* ===========================
   Charty 2.0 — styles-v2.css
   =========================== */

/* --- CSS Custom Properties --- */
:root {
    /* Brand Colors */
    --color-pink: #F266D2;
    --color-coral: #F66352;
    --color-peach: #F7A784;
    --color-teal: #3EC6A3;
    --color-blue: #1182FD;

    /* Gradients */
    --gradient-brand: linear-gradient(135deg, #F266D2 0%, #F66352 50%, #F7A784 100%);
    --gradient-charts: linear-gradient(135deg, #1182FD, #3EC6A3);
    --gradient-shortcuts: linear-gradient(135deg, #8B5CF6, #C026D3, #F266D2);
    --color-hero-bg: linear-gradient(135deg, #1182FD, #3EC6A3);

    /* Semantic Colors — Light Mode */
    --color-bg-primary: #FFFFFF;
    --color-bg-secondary: #F8F8FA;
    --color-bg-tertiary: #F0F0F5;
    --color-text-primary: #1A1A2E;
    --color-text-secondary: #555568;
    --color-text-tertiary: #8888A0;
    --color-border: #E8E8F0;
    --color-accent: #F266D2;
    --color-accent-hover: #E050C0;

    /* Hero text */
    --color-hero-text: #FFFFFF;
    --color-hero-text-secondary: rgba(255, 255, 255, 0.8);

    /* Navbar */
    --color-nav-bg: rgba(255, 255, 255, 0.8);
    --color-nav-border: rgba(0, 0, 0, 0.06);

    /* Spacing */
    --space-xs: 0.5rem;
    --space-sm: 1rem;
    --space-md: 1.5rem;
    --space-lg: 3rem;
    --space-xl: 5rem;
    --space-2xl: 8rem;

    /* Typography */
    --font-family: 'Lato', 'Helvetica Neue', 'Helvetica', sans-serif;
    --font-size-sm: 0.875rem;
    --font-size-base: 1rem;
    --font-size-lg: 1.125rem;
    --font-size-xl: 1.5rem;
    --font-size-2xl: 2rem;
    --font-size-3xl: 2.75rem;

    /* Layout */
    --container-max: 1120px;
    --radius: 12px;
    --radius-lg: 20px;
    --radius-xg: 25px;
}

@media (prefers-color-scheme: dark) {
    :root {
        --color-bg-primary: #0F0F1A;
        --color-bg-secondary: #1A1A2E;
        --color-bg-tertiary: #252540;
        --color-text-primary: #F0F0F5;
        --color-text-secondary: #B0B0C0;
        --color-text-tertiary: #707088;
        --color-border: #303050;
        --color-accent: #F266D2;
        --color-accent-hover: #FF80E0;
        --color-hero-bg: #0A0A14;
        --color-hero-text: #F5F5F7;
        --color-hero-text-secondary: #8E8E93;
        --color-nav-bg: rgba(15, 15, 26, 0.8);
        --color-nav-border: rgba(255, 255, 255, 0.06);
    }
}

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

html {
    scroll-behavior: smooth;
    -webkit-text-size-adjust: 100%;
}

body {
    font-family: var(--font-family);
    font-size: var(--font-size-base);
    line-height: 1.6;
    color: var(--color-text-primary);
    background: var(--color-bg-primary);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

a {
    color: var(--color-accent);
    text-decoration: none;
    transition: color 0.2s ease;
}

a:hover {
    color: var(--color-accent-hover);
}

h1, h2, h3 {
    line-height: 1.2;
    font-weight: 900;
}

/* --- Container --- */
.container {
    max-width: var(--container-max);
    margin: 0 auto;
    padding: 0 var(--space-md);
}

/* --- Navbar --- */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 100;
    background: transparent;
    transition: background 0.3s ease, border-color 0.3s ease, backdrop-filter 0.3s ease;
    border-bottom: 1px solid transparent;
}

.navbar.scrolled {
    background: var(--color-nav-bg);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-bottom-color: var(--color-nav-border);
}

.navbar-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 64px;
}

.navbar-brand {
    display: flex;
    align-items: center;
    gap: 10px;
    font-weight: 700;
    font-size: var(--font-size-lg);
    color: #F5F5F7;
    text-decoration: none;
    transition: color 0.3s ease;
}

.navbar.scrolled .navbar-brand {
    color: var(--color-text-primary);
}

.navbar-brand img {
    border-radius: 8px;
}

.nav-links {
    display: flex;
    list-style: none;
    gap: var(--space-md);
    align-items: center;
}

.nav-links a {
    color: rgba(245, 245, 247, 0.7);
    text-decoration: none;
    font-size: var(--font-size-sm);
    font-weight: 500;
    transition: color 0.2s ease;
}

.nav-links a:hover {
    color: #F5F5F7;
}

.navbar.scrolled .nav-links a {
    color: var(--color-text-secondary);
}

.navbar.scrolled .nav-links a:hover {
    color: var(--color-text-primary);
}

.nav-toggle {
    display: none;
    flex-direction: column;
    justify-content: center;
    gap: 5px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 4px;
    z-index: 110;
}

.hamburger-line {
    display: block;
    width: 22px;
    height: 2px;
    background: #F5F5F7;
    border-radius: 2px;
    transition: transform 0.3s ease, opacity 0.3s ease, background 0.3s ease;
}

.navbar.scrolled .hamburger-line {
    background: var(--color-text-primary);
}

.navbar-light .navbar-brand {
    color: var(--color-text-primary);
}

.navbar-light .nav-links a {
    color: var(--color-text-secondary);
}

.navbar-light .nav-links a:hover {
    color: var(--color-text-primary);
}

.navbar-light .hamburger-line {
    background: var(--color-text-primary);
}

/* Mobile Nav */
@media (max-width: 768px) {
    .nav-toggle {
        display: flex;
    }

    .nav-links {
        position: fixed;
        top: 0;
        right: 0;
        width: 280px;
        height: 100vh;
        flex-direction: column;
        align-items: flex-start;
        padding: 80px var(--space-md) var(--space-md);
        background: var(--color-bg-primary);
        border-left: 1px solid var(--color-border);
        transform: translateX(100%);
        transition: transform 0.3s ease;
        gap: var(--space-sm);
    }

    .nav-links.nav-open {
        transform: translateX(0);
    }

    .nav-links a {
        color: var(--color-text-primary);
        font-size: var(--font-size-base);
        padding: var(--space-xs) 0;
    }

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

    .navbar.scrolled .nav-links a {
        color: var(--color-text-primary);
    }

    /* Hamburger animation when open */
    .navbar .nav-toggle.active .hamburger-line:nth-child(1) {
        transform: translateY(7px) rotate(45deg);
        background: var(--color-text-primary);
    }

    .navbar .nav-toggle.active .hamburger-line:nth-child(2) {
        opacity: 0;
    }

    .navbar .nav-toggle.active .hamburger-line:nth-child(3) {
        transform: translateY(-7px) rotate(-45deg);
        background: var(--color-text-primary);
    }
}

/* --- Hero --- */
.hero {
    background: var(--color-hero-bg);
    padding: calc(64px + var(--space-xl)) 0 var(--space-xl);
    overflow: hidden;
    position: relative;
}

.hero::before {
    content: '';
    position: absolute;
    inset: 0;
    background: rgba(180, 180, 180, 0.45);
    mix-blend-mode: multiply;
    pointer-events: none;
}

@media (prefers-color-scheme: dark) {
    .hero::before {
        display: none;
    }
}

.hero-centered {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    position: relative;
    z-index: 1;
}

/* Animated chart backdrop */
.hero-bg-chart {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    color: #FFFFFF;
    opacity: 0.16;
    /* keep the backdrop at the edges, away from the hero copy */
    mask-image: linear-gradient(to right, black, transparent 32%, transparent 68%, black);
    -webkit-mask-image: linear-gradient(to right, black, transparent 32%, transparent 68%, black);
}

@media (prefers-color-scheme: dark) {
    .hero-bg-chart {
        opacity: 0.26;
    }

    .hero-bg-line { stroke: var(--color-teal); }
    .hero-bg-bars rect { fill: var(--color-blue); }
    .hero-bg-ring { stroke: var(--color-pink); }
}

.hero-bg-line {
    fill: none;
    stroke: currentColor;
    stroke-width: 3;
    stroke-linecap: round;
    stroke-dasharray: 1700;
    stroke-dashoffset: 1700;
    animation: heroLineDraw 2.4s ease-out 0.5s forwards;
}

.hero-bg-bars rect {
    fill: currentColor;
    transform-box: fill-box;
    transform-origin: center bottom;
    transform: scaleY(0);
    animation: heroBarGrow 0.9s cubic-bezier(0.22, 1, 0.36, 1) forwards;
}

.hero-bg-bars rect:nth-child(1) { animation-delay: 0.6s; }
.hero-bg-bars rect:nth-child(2) { animation-delay: 0.75s; }
.hero-bg-bars rect:nth-child(3) { animation-delay: 0.9s; }
.hero-bg-bars rect:nth-child(4) { animation-delay: 1.05s; }
.hero-bg-bars rect:nth-child(5) { animation-delay: 1.2s; }
.hero-bg-bars rect:nth-child(6) { animation-delay: 1.35s; }

.hero-bg-ring {
    fill: none;
    stroke: currentColor;
    stroke-width: 10;
    stroke-linecap: round;
    stroke-dasharray: 289;
    stroke-dashoffset: 289;
    transform-box: fill-box;
    transform-origin: center;
    transform: rotate(-90deg);
    animation: heroRingFill 1.6s ease-out 1.1s forwards;
}

.hero-bg-ring--small {
    stroke-width: 7;
    stroke-dasharray: 188;
    stroke-dashoffset: 188;
    animation-delay: 1.5s;
}

@keyframes heroLineDraw {
    to { stroke-dashoffset: 0; }
}

@keyframes heroBarGrow {
    to { transform: scaleY(1); }
}

@keyframes heroRingFill {
    to { stroke-dashoffset: 72; }
}

/* Hero badge */
.hero-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 6px 16px;
    border-radius: 999px;
    border: 1px solid rgba(255, 255, 255, 0.35);
    background: rgba(255, 255, 255, 0.12);
    backdrop-filter: blur(6px);
    -webkit-backdrop-filter: blur(6px);
    color: var(--color-hero-text);
    font-size: var(--font-size-sm);
    font-weight: 600;
    letter-spacing: 0.02em;
    margin-bottom: var(--space-md);
    animation: fadeInUp 0.6s ease both;
}

.hero-badge-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--color-teal);
    animation: badgePulse 2s ease-in-out infinite;
}

@media (prefers-color-scheme: dark) {
    .hero-badge {
        border-color: rgba(255, 255, 255, 0.18);
        background: rgba(255, 255, 255, 0.06);
    }
}

@keyframes badgePulse {
    0%, 100% { opacity: 1; transform: scale(1); }
    50% { opacity: 0.5; transform: scale(0.8); }
}

.hero-logo {
    width: 80px;
    height: 80px;
    border-radius: 18px;
    margin-bottom: var(--space-md);
    animation: fadeInUp 0.6s ease both;
}

.hero-title {
    font-size: clamp(1.8rem, 7vw, 4.5rem);
    font-weight: 800;
    letter-spacing: -0.03em;
    line-height: 1.1;
    white-space: nowrap;
    color: var(--color-hero-text);
    margin-bottom: var(--space-sm);
    animation: fadeInUp 0.6s ease 0.1s both;
}

.hero-subtitle {
    font-size: clamp(1rem, 2.5vw, 1.3rem);
    color: var(--color-hero-text-secondary);
    max-width: 540px;
    margin-bottom: var(--space-lg);
    line-height: 1.6;
    animation: fadeInUp 0.6s ease 0.2s both;
}

.app-store-btn {
    display: inline-block;
    transition: transform 0.2s ease, opacity 0.2s ease;
    animation: fadeInUp 0.6s ease 0.3s both;
}

.app-store-btn:hover {
    transform: scale(1.05);
}

.app-store-btn img {
    height: 48px;
    width: auto;
}

.hero-image {
    margin-top: var(--space-lg);
    width: 100%;
    max-width: 900px;
    animation: fadeInUp 0.8s ease 0.4s both, heroFloat 9s ease-in-out 1.4s infinite;
}

@keyframes heroFloat {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-10px); }
}

.hero-img {
    width: 100%;
    height: auto;
}

@media (max-width: 768px) {
    .hero {
        padding: calc(64px + var(--space-lg)) 0 var(--space-xl);
    }

    .hero-title {
        white-space: normal;
    }

    .hero-image {
        max-width: 100%;
        margin-top: var(--space-lg);
    }
}

/* --- Section Common --- */
.section {
    padding: var(--space-xl) 0;
}

.section-title {
    font-size: var(--font-size-2xl);
    font-weight: 700;
    text-align: center;
    margin-bottom: var(--space-xs);
    color: var(--color-text-primary);
}

/* Gradient text for section headings */
.gradient-text {
    display: inline-block;
    background-clip: text !important;
    -webkit-background-clip: text !important;
    -webkit-text-fill-color: transparent !important;
    color: transparent !important;
}

.gradient-text--charts {
    background-image: var(--gradient-charts) !important;
}

.hero .gradient-text--charts {
    background-image: none !important;
    -webkit-text-fill-color: #FFFFFF !important;
    color: #FFFFFF !important;
}

@media (prefers-color-scheme: dark) {
    .hero .gradient-text--charts {
        background-image: var(--gradient-charts) !important;
        -webkit-text-fill-color: transparent !important;
        color: transparent !important;
    }
}

.gradient-text--shortcuts {
    background-image: var(--gradient-shortcuts) !important;
}

.section-subtitle {
    text-align: center;
    color: var(--color-text-secondary);
    font-size: var(--font-size-lg);
    margin-bottom: var(--space-lg);
}

/* --- Review Carousel --- */
.reviews {
    background: var(--color-bg-secondary);
    padding: var(--space-lg) 0;
    overflow: hidden;
}

.carousel-track-wrapper {
    position: relative;
    width: 100%;
    overflow: hidden;
    mask-image: linear-gradient(to right, transparent, black 5%, black 95%, transparent);
    -webkit-mask-image: linear-gradient(to right, transparent, black 5%, black 95%, transparent);
}

.carousel-track {
    display: flex;
    gap: var(--space-md);
    width: max-content;
    animation: carousel-scroll 40s linear infinite;
}

.carousel-track:hover {
    animation-play-state: paused;
}

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

.review-card {
    flex-shrink: 0;
    width: 320px;
    background: var(--color-bg-primary);
    border: 1px solid var(--color-border);
    border-radius: var(--radius);
    padding: var(--space-md);
    display: flex;
    flex-direction: column;
    gap: var(--space-xs);
}

.review-stars {
    color: #FFB800;
    font-size: var(--font-size-lg);
    letter-spacing: 2px;
}

.review-quote {
    font-size: var(--font-size-sm);
    color: var(--color-text-secondary);
    line-height: 1.6;
    flex: 1;
}

.review-author {
    font-size: var(--font-size-sm);
    font-weight: 600;
    color: var(--color-text-primary);
}

@media (max-width: 768px) {
    .review-card {
        width: 280px;
    }
}

/* --- Feature Rows (Charts / Shortcuts) --- */
.feature-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: var(--space-xl);
    align-items: center;
    margin-bottom: var(--space-2xl);
}

.feature-row:last-child {
    margin-bottom: 0;
}

.feature-row--reverse {
    direction: rtl;
}

.feature-row--reverse > * {
    direction: ltr;
}

.feature-text {
    display: flex;
    flex-direction: column;
    gap: var(--space-sm);
}

.feature-heading {
    font-size: var(--font-size-xl);
    font-weight: 700;
    color: var(--color-text-primary);
}

.feature-description {
    font-size: var(--font-size-base);
    color: var(--color-text-secondary);
    line-height: 1.7;
}

/* Screenshot grids */
.feature-screenshots {
    display: grid;
    gap: var(--space-sm);
}

.grid-2x2 {
    grid-template-columns: 1fr 1fr;
}

.grid-1x2 {
    grid-template-columns: 1fr 1fr;
}

.grid-single {
    grid-template-columns: 1fr;
    max-width: 320px;
    margin: 0 auto;
}

.feature-row--reverse .grid-single {
    margin: 0 auto;
}

.screenshot {
    width: 100%;
    border-radius: var(--radius);
    border: 1px solid var(--color-border);
    background: var(--color-bg-secondary);
}

@media (max-width: 768px) {
    .feature-row {
        grid-template-columns: 1fr;
        gap: var(--space-lg);
        margin-bottom: var(--space-xl);
    }

    .feature-row--reverse {
        direction: ltr;
    }

    .grid-single {
        max-width: 240px;
    }
}

/* --- Charts Section --- */
.charts-section {
    background: var(--color-bg-primary);
    padding: var(--space-2xl) 0;
}

.charts-overview {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: var(--space-xl);
    align-items: center;
}

.charts-overview-images {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: var(--space-sm);
}

.charts-col {
    display: flex;
    flex-direction: column;
    gap: var(--space-sm);
}

.charts-col--offset {
    transform: translateY(2rem);
}

.charts-overview-text .section-title {
    text-align: left;
    margin-bottom: var(--space-lg);
}

.charts-overview-list {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-direction: column;
    gap: var(--space-md);
}

.charts-overview-list li {
    font-size: var(--font-size-base);
    color: var(--color-text-secondary);
    line-height: 1.7;
}

.charts-overview-list li strong {
    color: var(--color-text-primary);
}

@media (max-width: 768px) {
    .charts-overview {
        grid-template-columns: 1fr;
        gap: var(--space-lg);
    }

    .charts-overview-text .section-title {
        text-align: center;
    }
}

/* --- Widgets Section --- */
.widgets-section {
    background: var(--color-bg-secondary);
    padding: var(--space-2xl) 0;
}

.widgets-grid {
    display: flex;
    flex-wrap: nowrap;
    gap: var(--space-lg);
    max-width: 1120px;
    margin: 0 auto;
    justify-content: center;
    align-items: flex-start;
}

.widgets-row {
    display: contents;
}

.widget-item {
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
    flex-shrink: 0;
}

.widget-item picture {
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: var(--space-sm);
}

.widget-item .screenshot {
    height: min(150px, 23vw);
    width: auto !important;
    border-radius: var(--radius-xg) !important;
}

.widget-caption {
    font-size: var(--font-size-sm);
    color: var(--color-text-tertiary);
    font-weight: 500;
}

@media (max-width: 768px) {
    .widgets-grid {
        display: flex;
        flex-direction: column;
        align-items: center;
        gap: var(--space-sm);
    }

    .widgets-row {
        display: flex;
        gap: var(--space-sm);
        justify-content: center;
    }

    .widget-item .screenshot {
        height: min(150px, 28vw);
        width: auto !important;
        max-width: none;
        border-radius: var(--radius-xg) !important;
    }
}

/* --- Shortcuts Section --- */
.shortcuts-section {
    background: var(--color-bg-primary);
    padding: var(--space-2xl) 0;
}

/* --- Trust Pillars --- */
.trust-section {
    background: var(--color-bg-secondary);
    padding: var(--space-2xl) 0;
}

.trust-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: var(--space-lg);
}

.trust-card {
    text-align: center;
    padding: var(--space-lg) var(--space-md);
}

.trust-icon {
    width: 56px;
    height: 56px;
    border-radius: 16px;
    background: var(--gradient-charts);
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto var(--space-md);
    color: #fff;
}

.trust-icon svg {
    width: 28px;
    height: 28px;
}

.trust-card h3 {
    font-size: var(--font-size-lg);
    font-weight: 700;
    margin-bottom: var(--space-xs);
    color: var(--color-text-primary);
}

.trust-card p {
    font-size: var(--font-size-sm);
    color: var(--color-text-secondary);
    line-height: 1.6;
    max-width: 300px;
    margin: 0 auto;
}

@media (max-width: 768px) {
    .trust-grid {
        grid-template-columns: 1fr;
        gap: var(--space-md);
    }

    .trust-card {
        padding: var(--space-md);
    }
}

/* --- Pricing --- */
.pricing {
    background: var(--color-bg-primary);
    padding: var(--space-xl) 0;
}

.pricing-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: var(--space-md);
    max-width: 600px;
    margin: 0 auto var(--space-lg);
}

.pricing-card {
    background: var(--color-bg-secondary);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-lg);
    padding: var(--space-lg) var(--space-md);
    text-align: center;
    position: relative;
}

.pricing-card--featured {
    border-color: var(--color-pink);
    border-width: 2px;
}

.pricing-badge {
    font-size: var(--font-size-sm);
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--color-text-tertiary);
    margin-bottom: var(--space-sm);
}

.pricing-card--featured .pricing-badge {
    color: var(--color-pink);
}

.pricing-amount {
    margin-bottom: var(--space-sm);
    display: flex;
    align-items: baseline;
    justify-content: center;
    gap: 2px;
}

.price-currency {
    font-size: var(--font-size-xl);
    font-weight: 600;
    color: var(--color-text-primary);
}

.price-value {
    font-size: 3rem;
    font-weight: 700;
    color: var(--color-text-primary);
    line-height: 1;
}

.price-period {
    font-size: var(--font-size-sm);
    color: var(--color-text-tertiary);
    margin-left: 2px;
}

.pricing-desc {
    font-size: var(--font-size-sm);
    color: var(--color-text-secondary);
    line-height: 1.6;
}

.pricing-save {
    display: inline-block;
    margin-top: var(--space-sm);
    padding: 4px 12px;
    background: var(--color-bg-tertiary);
    border-radius: 20px;
    font-size: var(--font-size-sm);
    font-weight: 600;
    color: var(--color-teal);
}

.pricing-legacy {
    max-width: 540px;
    margin: 0 auto;
    text-align: center;
    padding: var(--space-md);
    background: var(--color-bg-tertiary);
    border-radius: var(--radius);
    font-size: var(--font-size-sm);
    color: var(--color-text-secondary);
    line-height: 1.7;
}

.pricing-legacy strong {
    color: var(--color-text-primary);
    display: block;
    margin-bottom: 4px;
}

/* --- CTA --- */
.cta {
    background: var(--color-bg-primary);
    padding: var(--space-2xl) 0;
    text-align: center;
}

@media (prefers-color-scheme: dark) {
    .cta {
        background: #0A0A14;
    }
}

.cta-title {
    font-size: var(--font-size-2xl);
    font-weight: 700;
    color: var(--color-text-primary);
    margin-bottom: var(--space-xs);
}

.cta-subtitle {
    color: var(--color-text-secondary);
    font-size: var(--font-size-lg);
    margin-bottom: var(--space-lg);
}

/* --- Footer --- */
.footer {
    background: var(--color-bg-secondary);
    border-top: 1px solid var(--color-border);
    padding: var(--space-lg) 0;
}

.footer-inner {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: var(--space-md);
}

.footer-brand {
    display: flex;
    align-items: center;
    gap: 8px;
    font-weight: 700;
    font-size: var(--font-size-base);
    color: var(--color-text-primary);
}

.footer-brand img {
    border-radius: 8px;
}

.footer-links {
    display: flex;
    gap: var(--space-md);
    flex-wrap: wrap;
    justify-content: center;
}

.footer-links a {
    color: var(--color-text-secondary);
    font-size: var(--font-size-sm);
    text-decoration: none;
}

.footer-links a:hover {
    color: var(--color-accent);
}

.footer-social {
    display: flex;
    gap: var(--space-sm);
}

.footer-social a {
    color: var(--color-text-tertiary);
    transition: color 0.2s ease;
}

.footer-social a:hover {
    color: var(--color-accent);
}

.footer-social svg {
    width: 20px;
    height: 20px;
    fill: currentColor;
}

.footer-credit {
    font-size: var(--font-size-sm);
    color: var(--color-text-tertiary);
}

.footer-credit a {
    color: var(--color-text-secondary);
}

/* --- Scroll Reveal --- */
.reveal {
    opacity: 0;
    transform: translateY(24px);
    transition: opacity 0.6s ease, transform 0.6s ease;
}

.reveal.revealed {
    opacity: 1;
    transform: translateY(0);
}

.trust-grid .reveal:nth-child(2) { transition-delay: 0.08s; }
.trust-grid .reveal:nth-child(3) { transition-delay: 0.16s; }

.widgets-row:nth-child(1) .widget-item:nth-child(2) { transition-delay: 0.08s; }
.widgets-row:nth-child(2) .widget-item:nth-child(1) { transition-delay: 0.16s; }
.widgets-row:nth-child(2) .widget-item:nth-child(2) { transition-delay: 0.24s; }

.pricing-grid .reveal:nth-child(2) { transition-delay: 0.08s; }

/* --- Animations --- */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(24px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* --- Reduced Motion --- */
@media (prefers-reduced-motion: reduce) {
    html {
        scroll-behavior: auto;
    }

    .hero-badge,
    .hero-logo,
    .hero-title,
    .hero-subtitle,
    .app-store-btn,
    .hero-image,
    .hero-badge-dot {
        animation: none;
    }

    .hero-bg-line {
        animation: none;
        stroke-dashoffset: 0;
    }

    .hero-bg-bars rect {
        animation: none;
        transform: scaleY(1);
    }

    .hero-bg-ring {
        animation: none;
        stroke-dashoffset: 72;
    }

    .carousel-track {
        animation: none;
        flex-wrap: wrap;
        width: auto;
        justify-content: center;
    }

    .reveal {
        opacity: 1;
        transform: none;
        transition: none;
    }
}

/* --- Blog --- */
.blog-date {
    font-size: var(--font-size-sm);
    color: var(--color-text-tertiary);
}

/* --- Blog Post Pages --- */
.post-notice {
    background: var(--color-bg-tertiary);
    border-left: 3px solid var(--color-accent);
    border-radius: var(--radius);
    padding: var(--space-md);
    margin-bottom: var(--space-xl);
    font-size: var(--font-size-sm);
    color: var(--color-text-secondary);
    line-height: 1.7;
}

.post-notice strong {
    color: var(--color-text-primary);
}

.post-body p,
.post-body li {
    color: var(--color-text-secondary);
    line-height: 1.7;
}

.post-body p {
    margin-bottom: var(--space-sm);
}

.post-body ul,
.post-body ol {
    padding-left: var(--space-md);
    margin-bottom: var(--space-sm);
}

.post-body li {
    margin-bottom: 4px;
}

.post-body strong {
    color: var(--color-text-primary);
}

.post-body h2 {
    font-size: var(--font-size-xl);
    font-weight: 700;
    color: var(--color-text-primary);
    text-align: center;
    margin: var(--space-xl) 0 var(--space-md);
}

.post-body h3 {
    font-size: var(--font-size-lg);
    font-weight: 700;
    color: var(--color-text-primary);
    margin: var(--space-md) 0 var(--space-xs);
}

.post-figure {
    margin: var(--space-md) auto;
    text-align: center;
}

.post-figure img,
.post-figure video {
    border-radius: var(--radius);
    border: 1px solid var(--color-border);
    background: var(--color-bg-secondary);
    max-width: 100%;
    height: auto;
    margin: 0 auto;
}

.post-figure figcaption {
    font-size: var(--font-size-sm);
    color: var(--color-text-tertiary);
    margin-top: var(--space-xs);
}

.post-figure--narrow {
    max-width: 360px;
}

.post-split {
    display: grid;
    grid-template-columns: 320px 1fr;
    gap: var(--space-lg);
    align-items: start;
    margin: var(--space-md) 0;
}

.post-split .post-figure {
    margin: 0;
}

.post-split--reverse {
    grid-template-columns: 1fr 320px;
}

.post-split--reverse .post-figure {
    order: 2;
}

.post-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: var(--space-sm);
    margin: var(--space-md) 0;
}

.post-grid--2 {
    grid-template-columns: repeat(2, 1fr);
    max-width: 560px;
    margin-left: auto;
    margin-right: auto;
}

.post-grid .post-figure {
    margin: 0;
}

.post-code {
    display: block;
    font-family: 'SF Mono', 'Menlo', 'Consolas', monospace;
    font-size: var(--font-size-sm);
    background: var(--color-bg-tertiary);
    border-radius: var(--radius);
    padding: var(--space-sm) var(--space-md);
    margin-bottom: var(--space-sm);
    color: var(--color-text-primary);
    word-break: break-all;
    line-height: 1.7;
}

@media (max-width: 768px) {
    .post-split,
    .post-split--reverse {
        grid-template-columns: 1fr;
        gap: var(--space-md);
    }

    .post-split .post-figure {
        margin: 0 auto;
        max-width: 320px;
        order: 0;
    }

    .post-grid--2 {
        max-width: 320px;
    }

    .post-grid {
        grid-template-columns: 1fr;
        max-width: 320px;
        margin-left: auto;
        margin-right: auto;
    }
}

.faq-item h3 a {
    color: var(--color-text-primary);
    text-decoration: none;
}

.faq-item h3 a:hover {
    color: var(--color-accent);
}

/* --- FAQ Page --- */
.faq-header {
    background: var(--color-bg-primary);
    padding: calc(64px + var(--space-xl)) 0 var(--space-lg);
    text-align: center;
}

.faq-header-title {
    font-size: clamp(2rem, 5vw, 3rem);
    font-weight: 800;
    letter-spacing: -0.03em;
    line-height: 1.1;
    color: var(--color-text-primary);
    margin-bottom: var(--space-sm);
}

.faq-header-subtitle {
    font-size: clamp(1rem, 2.5vw, 1.2rem);
    color: var(--color-text-secondary);
    max-width: 540px;
    margin: 0 auto;
    line-height: 1.6;
}

.faq-header-subtitle a {
    color: var(--color-text-primary);
    text-decoration: underline;
    text-underline-offset: 2px;
}

.faq-content {
    padding: 0 0 var(--space-2xl);
}

.faq-container {
    max-width: 780px;
}

/* FAQ Index */
.faq-index {
    background: var(--color-bg-secondary);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-lg);
    padding: var(--space-lg);
    margin-bottom: var(--space-xl);
}

.faq-index h2 {
    font-size: var(--font-size-xl);
    font-weight: 700;
    margin-bottom: var(--space-md);
    color: var(--color-text-primary);
}

.faq-index > ul {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-direction: column;
    gap: var(--space-sm);
}

.faq-index > ul > li > a {
    font-weight: 700;
    font-size: var(--font-size-base);
    color: var(--color-text-primary);
}

.faq-index ul ul {
    list-style: none;
    padding-left: var(--space-md);
    margin-top: var(--space-xs);
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.faq-index ul ul a {
    font-size: var(--font-size-sm);
    color: var(--color-text-secondary);
}

.faq-index ul ul a:hover {
    color: var(--color-accent);
}

/* FAQ Sections */
.faq-section {
    margin-bottom: var(--space-xl);
}

.faq-section-title {
    font-size: var(--font-size-xl);
    font-weight: 700;
    color: var(--color-text-primary);
    padding-bottom: var(--space-sm);
    border-bottom: 2px solid var(--color-border);
    margin-bottom: var(--space-lg);
}

/* FAQ Items */
.faq-item {
    margin-bottom: var(--space-lg);
    scroll-margin-top: 80px;
}

.faq-item h3 {
    font-size: var(--font-size-lg);
    font-weight: 700;
    color: var(--color-text-primary);
    margin-bottom: var(--space-sm);
}

.faq-item p {
    color: var(--color-text-secondary);
    line-height: 1.7;
    margin-bottom: var(--space-sm);
}

.faq-item p:last-child {
    margin-bottom: 0;
}

.faq-item ul, .faq-item ol {
    color: var(--color-text-secondary);
    line-height: 1.7;
    padding-left: var(--space-md);
    margin-bottom: var(--space-sm);
}

.faq-item li {
    margin-bottom: 4px;
}

.faq-item strong {
    color: var(--color-text-primary);
}

.faq-image {
    margin-top: var(--space-md);
    max-width: 400px;
}

.faq-image-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: var(--space-sm);
    margin-top: var(--space-md);
}

.faq-image-grid .screenshot {
    width: 100%;
    height: auto;
    border-radius: var(--radius);
    border: none;
    background: none;
    mix-blend-mode: multiply;
}

.faq-blend {
    mix-blend-mode: multiply;
}

@media (prefers-color-scheme: dark) {
    .faq-image-grid .screenshot,
    .faq-blend {
        mix-blend-mode: screen;
    }
}

.faq-image-pair {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: var(--space-sm);
    margin-top: var(--space-md);
    align-items: start;
}

.faq-image-pair .screenshot {
    width: 100%;
    height: auto;
    border-radius: var(--radius);
    border: none;
    background: none;
}

.faq-image-clipped {
    position: relative;
    aspect-ratio: 1350 / 1656;
    overflow: hidden;
    border-radius: var(--radius);
}

.faq-image-clipped .screenshot {
    border-radius: var(--radius) var(--radius) 0 0;
    border: none;
    background: none;
}

.faq-image-clipped::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 80px;
    background: linear-gradient(to bottom, transparent, var(--color-bg-primary));
    pointer-events: none;
}

@media (max-width: 600px) {
    .faq-image-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .faq-image-pair {
        grid-template-columns: 1fr;
        max-width: 300px;
    }
}

/* FAQ Table */
.faq-table-wrapper {
    overflow-x: auto;
    margin-top: var(--space-sm);
    border: 1px solid var(--color-border);
    border-radius: var(--radius);
}

.faq-table {
    width: 100%;
    border-collapse: collapse;
    font-size: var(--font-size-sm);
}

.faq-table thead {
    background: var(--color-bg-secondary);
}

.faq-table th {
    text-align: left;
    padding: var(--space-sm) var(--space-md);
    font-weight: 700;
    color: var(--color-text-primary);
    border-bottom: 1px solid var(--color-border);
    white-space: nowrap;
}

.faq-table td {
    padding: var(--space-sm) var(--space-md);
    color: var(--color-text-secondary);
    border-bottom: 1px solid var(--color-border);
}

.faq-table tr:last-child td {
    border-bottom: none;
}

.faq-table td:first-child {
    font-weight: 600;
    color: var(--color-text-primary);
    white-space: nowrap;
}

.badge-free {
    display: inline-block;
    padding: 2px 10px;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 600;
    background: rgba(62, 198, 163, 0.15);
    color: var(--color-teal);
}

.badge-premium {
    display: inline-block;
    padding: 2px 10px;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 600;
    background: rgba(242, 102, 210, 0.15);
    color: var(--color-pink);
}

@media (max-width: 768px) {
    .faq-index {
        padding: var(--space-md);
    }

    .faq-table td:first-child {
        white-space: normal;
    }
}
