/* ============================================
   MacWrench Website - Cyan Modern Theme
   ============================================ */

:root {
    /* Dark macOS palette */
    --bg-primary: #0f0f0f;
    --bg-secondary: #161616;
    --bg-card: #1c1c1c;
    --bg-card-hover: #242424;

    --text-primary: #fafafa;
    --text-secondary: #a3a3a3;
    --text-muted: #737373;

    /* Cyan accent colors */
    --accent-primary: #00C0E8;
    --accent-secondary: #00a0c4;
    --accent-gradient: linear-gradient(135deg, #00C0E8 0%, #0090b0 100%);
    --accent-glow: rgba(0, 192, 232, 0.25);

    --success: #22c55e;
    --warning: #f59e0b;
    --danger: #ef4444;
    
    --border-color: rgba(255, 255, 255, 0.06);
    --border-hover: rgba(255, 255, 255, 0.12);
    
    /* Spacing */
    --section-padding: 100px;
    --container-width: 1100px;
    
    /* Typography */
    --font-family: 'DM Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    
    /* Effects */
    --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.4);
    --shadow-md: 0 8px 24px rgba(0, 0, 0, 0.5);
    --shadow-lg: 0 16px 48px rgba(0, 0, 0, 0.6);
    --transition: all 0.25s ease;

    --navbar-bg: rgba(15, 15, 15, 0.9);
    --navbar-bg-scrolled: rgba(15, 15, 15, 0.98);
}

@media (prefers-color-scheme: light) {
    :root {
        --bg-primary: #ffffff;
        --bg-secondary: #f7f8fa;
        --bg-card: #ffffff;
        --bg-card-hover: #f1f5f9;

        --text-primary: #0f172a;
        --text-secondary: #334155;
        --text-muted: #64748b;

        --accent-primary: #0ea5c4;
        --accent-secondary: #0284a8;
        --accent-gradient: linear-gradient(135deg, #0ea5c4 0%, #0284a8 100%);
        --accent-glow: rgba(14, 165, 196, 0.2);

        --border-color: rgba(15, 23, 42, 0.1);
        --border-hover: rgba(15, 23, 42, 0.2);

        --shadow-sm: 0 2px 8px rgba(15, 23, 42, 0.08);
        --shadow-md: 0 8px 24px rgba(15, 23, 42, 0.12);
        --shadow-lg: 0 16px 48px rgba(15, 23, 42, 0.16);

        --navbar-bg: rgba(255, 255, 255, 0.86);
        --navbar-bg-scrolled: rgba(255, 255, 255, 0.96);
    }

    .btn-primary,
    .pricing-badge,
    .pricing-badge.save,
    .step-number,
    .mockup-tabs .tab.active,
    .cleaner-segmented span.active,
    .subscription-badge.pro {
        color: #ffffff;
    }
}

/* Skip Link (hidden until focused) */
.skip-link {
    position: fixed;
    top: 16px;
    left: 16px;
    z-index: 1200;
    padding: 8px 14px;
    border-radius: 8px;
    background: var(--accent-primary);
    color: #0f0f0f;
    font-size: 0.85rem;
    font-weight: 700;
    text-decoration: none;
    transform: translateY(-180%);
    opacity: 0;
    pointer-events: none;
    transition: transform 0.2s ease, opacity 0.2s ease;
}

.skip-link:focus {
    transform: translateY(0);
    opacity: 1;
    pointer-events: auto;
}

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

@media (prefers-reduced-motion: no-preference) {
    html {
        scroll-behavior: smooth;
    }
}

body {
    font-family: var(--font-family);
    background: var(--bg-primary);
    color: var(--text-primary);
    line-height: 1.65;
    overflow-x: hidden;
    font-size: 16px;
}

.container {
    max-width: var(--container-width);
    margin: 0 auto;
    padding: 0 24px;
}

/* ============================================
   Navigation
   ============================================ */

.navbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    background: var(--navbar-bg);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border-bottom: 1px solid var(--border-color);
}

.nav-container {
    max-width: var(--container-width);
    margin: 0 auto;
    padding: 14px 24px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    display: flex;
    align-items: center;
    gap: 10px;
    text-decoration: none;
    color: var(--text-primary);
    font-weight: 700;
    font-size: 1.2rem;
    letter-spacing: -0.02em;
}

.logo-icon {
    font-size: 1.4rem;
}

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

.nav-links a {
    color: var(--text-secondary);
    text-decoration: none;
    font-size: 0.9rem;
    font-weight: 500;
    transition: var(--transition);
}

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

/* Mobile Nav Toggle */
.nav-toggle {
    display: none;
    flex-direction: column;
    justify-content: center;
    gap: 5px;
    width: 28px;
    height: 28px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 0;
}

.nav-toggle span {
    display: block;
    width: 100%;
    height: 2px;
    background: var(--text-primary);
    border-radius: 2px;
    transition: var(--transition);
}

.nav-toggle[aria-expanded="true"] span:nth-child(1) {
    transform: rotate(45deg) translate(5px, 5px);
}

.nav-toggle[aria-expanded="true"] span:nth-child(2) {
    opacity: 0;
}

.nav-toggle[aria-expanded="true"] span:nth-child(3) {
    transform: rotate(-45deg) translate(5px, -5px);
}

.nav-signin-btn {
    padding: 6px 16px !important;
    font-size: 0.8rem !important;
    border-radius: 8px;
    border: 1px solid var(--accent-primary);
    color: var(--accent-primary) !important;
    transition: var(--transition);
}

.nav-signin-btn:hover {
    background: rgba(0, 192, 232, 0.1);
    color: var(--accent-primary) !important;
}

.nav-overlay {
    position: fixed;
    inset: 0;
    z-index: 900;
    background: rgba(0, 0, 0, 0.45);
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transition: opacity 0.25s ease, visibility 0.25s ease;
}

.nav-overlay.active {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
}

/* ============================================
   Buttons
   ============================================ */

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 12px 24px;
    border-radius: 10px;
    font-size: 0.95rem;
    font-weight: 600;
    text-decoration: none;
    cursor: pointer;
    transition: var(--transition);
    border: none;
    font-family: inherit;
}

.btn-primary {
    background: var(--accent-gradient);
    color: #0f0f0f;
    box-shadow: 0 4px 16px var(--accent-glow);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 24px var(--accent-glow);
}

.btn-secondary {
    background: var(--bg-card);
    color: var(--text-primary);
    border: 1px solid var(--border-color);
}

.btn-secondary:hover {
    background: var(--bg-card-hover);
    border-color: var(--border-hover);
}

.btn-large {
    padding: 16px 32px;
    font-size: 1rem;
    border-radius: 12px;
}

.btn-full {
    width: 100%;
}

.btn-apple {
    background: #fff;
    color: #000;
    border: 1px solid #fff;
    font-size: 0.95rem;
}

.btn-apple:hover {
    background: #e8e8e8;
    border-color: #e8e8e8;
}

.btn-apple:disabled {
    opacity: 0.7;
    cursor: wait;
}

.btn-spinner {
    display: inline-block;
    width: 16px;
    height: 16px;
    border: 2px solid rgba(0, 0, 0, 0.2);
    border-top-color: #000;
    border-radius: 50%;
    animation: spin 0.6s linear infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* ============================================
   Hero Section
   ============================================ */

.hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    padding: calc(var(--section-padding) + 60px) 24px var(--section-padding);
    background:
        radial-gradient(ellipse at 30% 20%, rgba(0, 192, 232, 0.08) 0%, transparent 50%),
        radial-gradient(ellipse at 70% 80%, rgba(0, 144, 176, 0.06) 0%, transparent 50%),
        var(--bg-primary);
}

.hero-content {
    flex: 1;
    max-width: 540px;
    margin-right: 60px;
}

.hero-badge {
    display: inline-block;
    padding: 8px 16px;
    background: rgba(0, 192, 232, 0.12);
    color: var(--accent-primary);
    text-decoration: none;
    border-radius: 100px;
    font-size: 0.85rem;
    font-weight: 600;
    margin-bottom: 24px;
    border: 1px solid rgba(0, 192, 232, 0.2);
}

.hero h1 {
    font-size: clamp(2.4rem, 5vw, 3.5rem);
    font-weight: 700;
    line-height: 1.15;
    margin-bottom: 20px;
    letter-spacing: -0.03em;
}

.gradient-text {
    background: var(--accent-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.hero-description {
    font-size: 1.15rem;
    color: var(--text-secondary);
    margin-bottom: 28px;
    line-height: 1.7;
}

.hero-buttons {
    display: flex;
    gap: 14px;
    margin-bottom: 14px;
}

.hero-note {
    font-size: 0.85rem;
    color: var(--text-muted);
}

.hero-visual {
    flex: 1;
    display: flex;
    justify-content: center;
}

/* Window Mockup */
.window-mockup {
    width: 100%;
    max-width: 540px;
    background: var(--bg-card);
    border-radius: 14px;
    border: 1px solid var(--border-color);
    box-shadow: var(--shadow-lg);
    overflow: hidden;
}

/* Screenshot variant — wider, with brand glow */
.window-mockup--screenshot {
    max-width: 720px;
    box-shadow:
        0 24px 60px rgba(0, 0, 0, 0.55),
        0 0 0 1px rgba(0, 192, 232, 0.15),
        0 0 80px -20px rgba(0, 192, 232, 0.35);
}

.window-screenshot {
    display: block;
    width: 100%;
    height: auto;
    background: var(--bg-secondary);
}

.window-titlebar {
    display: flex;
    align-items: center;
    padding: 12px 16px;
    background: var(--bg-secondary);
    border-bottom: 1px solid var(--border-color);
}

.window-buttons {
    display: flex;
    gap: 8px;
}

.window-buttons span {
    width: 12px;
    height: 12px;
    border-radius: 50%;
}

.btn-close { background: #ff5f57; }
.btn-minimize { background: #febc2e; }
.btn-maximize { background: #28c840; }

.window-title {
    flex: 1;
    text-align: center;
    font-size: 0.8rem;
    color: var(--text-muted);
    font-weight: 500;
}

.window-content {
    display: flex;
    min-height: 280px;
}

.mockup-sidebar {
    width: 160px;
    background: var(--bg-secondary);
    padding: 14px;
    border-right: 1px solid var(--border-color);
}

.mockup-tabs {
    display: flex;
    gap: 6px;
    margin-bottom: 16px;
}

.mockup-tabs .tab {
    padding: 5px 8px;
    border-radius: 6px;
    font-size: 0.7rem;
    color: var(--text-muted);
    cursor: pointer;
    transition: var(--transition);
}

.mockup-tabs .tab.active {
    background: var(--accent-primary);
    color: #0f0f0f;
    font-weight: 600;
}

.mockup-tabs .tab:focus-visible {
    outline: 2px solid var(--accent-primary);
    outline-offset: 2px;
}

.mockup-list {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.mockup-item {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 7px 10px;
    border-radius: 6px;
    font-size: 0.75rem;
    color: var(--text-secondary);
    background: var(--bg-card);
}

.mockup-item .dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: var(--warning);
}

.mockup-item .dot.green {
    background: var(--success);
}

.mockup-item.update {
    background: rgba(0, 192, 232, 0.08);
    border: 1px solid rgba(0, 192, 232, 0.15);
}

.mockup-detail {
    flex: 1;
    display: flex;
    flex-direction: column;
}

.mockup-app-header {
    display: flex;
    align-items: center;
    gap: 14px;
}

.app-icon {
    width: 56px;
    height: 56px;
    background: var(--bg-secondary);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.8rem;
}

.app-info h3 {
    font-size: 1rem;
    margin-bottom: 3px;
    font-weight: 600;
}

.app-info p {
    font-size: 0.8rem;
    color: var(--warning);
}

.mockup-btn {
    padding: 9px 28px;
    background: var(--accent-gradient);
    color: #0f0f0f;
    border: none;
    border-radius: 7px;
    font-weight: 600;
    font-size: 0.85rem;
    cursor: pointer;
}

/* Tab Panels (mockup content switching) */
.tab-panel {
    display: none;
    flex-direction: column;
    align-items: stretch;
    justify-content: flex-start;
    padding: 12px 16px;
    gap: 8px;
    overflow: hidden;
    flex: 1;
}

.tab-panel.tab-panel-active {
    display: flex;
}

/* Cleaner tab styles */
.cleaner-segmented {
    display: flex;
    gap: 2px;
    background: var(--bg-secondary);
    border-radius: 6px;
    padding: 2px;
}

.cleaner-segmented span {
    flex: 1;
    text-align: center;
    padding: 3px 6px;
    font-size: 0.6rem;
    border-radius: 4px;
    color: var(--text-muted);
    cursor: pointer;
    font-weight: 500;
}

.cleaner-segmented span.active {
    background: var(--accent-primary);
    color: #0f0f0f;
    font-weight: 600;
}

.cleaner-disk-bar {
    height: 6px;
    background: var(--bg-secondary);
    border-radius: 3px;
    overflow: hidden;
}

.cleaner-disk-bar-fill {
    height: 100%;
    border-radius: 3px;
    background: var(--accent-gradient);
}

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

.cleaner-card {
    background: var(--bg-card);
    border-radius: 5px;
    padding: 5px 6px;
    font-size: 0.55rem;
    text-align: center;
    border: 1px solid var(--border-color);
}

.cleaner-card .card-size {
    font-weight: 600;
    color: var(--text-primary);
    font-size: 0.6rem;
}

.cleaner-card .card-name {
    color: var(--text-muted);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.cleaner-card .safety-bar {
    height: 2px;
    border-radius: 1px;
    margin-top: 3px;
}

/* ============================================
   Section Headers
   ============================================ */

.section-header {
    text-align: center;
    margin-bottom: 56px;
}

.section-header h2 {
    font-size: clamp(1.8rem, 4vw, 2.5rem);
    font-weight: 700;
    margin-bottom: 12px;
    letter-spacing: -0.02em;
}

.section-header p {
    font-size: 1.05rem;
    color: var(--text-secondary);
    max-width: 500px;
    margin: 0 auto;
}

/* ============================================
   What's New Section (1.2 release showcase)
   ============================================ */

.whats-new {
    padding: var(--section-padding) 24px;
    background:
        radial-gradient(ellipse at top, rgba(0, 192, 232, 0.06), transparent 60%),
        var(--bg-primary);
}

.section-eyebrow {
    display: inline-block;
    margin-bottom: 12px;
    padding: 6px 14px;
    border-radius: 999px;
    background: rgba(0, 192, 232, 0.10);
    border: 1px solid rgba(0, 192, 232, 0.28);
    color: var(--accent-primary);
    font-size: 0.75rem;
    font-weight: 600;
    letter-spacing: 0.04em;
    text-transform: uppercase;
}

.whats-new-grid {
    display: grid;
    grid-template-columns: 2fr 1fr;
    grid-template-rows: auto auto;
    gap: 24px;
    align-items: stretch;
}

.whats-new-card {
    position: relative;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 20px;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    transition: transform 0.25s ease, border-color 0.25s ease, box-shadow 0.25s ease;
}

.whats-new-card:hover {
    transform: translateY(-3px);
    border-color: var(--border-hover);
    box-shadow: var(--shadow-md);
}

.whats-new-card--feature {
    grid-row: span 2;
}

.whats-new-shot {
    margin: 0;
    padding: 20px 20px 0;
    background:
        linear-gradient(180deg, rgba(0, 192, 232, 0.08), transparent 70%),
        var(--bg-secondary);
    display: flex;
    align-items: flex-end;
    justify-content: center;
}

.whats-new-shot img {
    width: 100%;
    height: auto;
    display: block;
    border-radius: 12px 12px 0 0;
    box-shadow: 0 18px 40px rgba(0, 0, 0, 0.45), 0 0 0 1px rgba(0, 192, 232, 0.15);
}

.whats-new-shot--menu {
    padding: 28px 20px;
    background:
        radial-gradient(circle at center, rgba(0, 192, 232, 0.10), transparent 70%),
        var(--bg-secondary);
    align-items: center;
}

.whats-new-shot--menu img {
    width: auto;
    max-width: 100%;
    max-height: 220px;
    border-radius: 14px;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.55), 0 0 0 1px rgba(255, 255, 255, 0.05);
}

.whats-new-content {
    padding: 24px 28px 28px;
    display: flex;
    flex-direction: column;
    gap: 8px;
    flex: 1;
}

.whats-new-tag {
    align-self: flex-start;
    padding: 4px 10px;
    border-radius: 999px;
    background: rgba(0, 192, 232, 0.12);
    color: var(--accent-primary);
    font-size: 0.7rem;
    font-weight: 600;
    letter-spacing: 0.03em;
    text-transform: uppercase;
}

.whats-new-content h3 {
    font-size: 1.4rem;
    font-weight: 600;
    margin: 0;
}

.whats-new-content p {
    color: var(--text-secondary);
    font-size: 0.95rem;
    line-height: 1.55;
    margin: 0;
}

.whats-new-card--text {
    padding: 28px;
    gap: 12px;
}

.whats-new-card--text .whats-new-content {
    padding: 0;
}

.whats-new-icon {
    font-size: 2.4rem;
    line-height: 1;
}

.whats-new-footnote {
    margin: 32px auto 0;
    text-align: center;
    color: var(--text-muted);
    font-size: 0.95rem;
    max-width: 680px;
}

.whats-new-footnote a {
    color: var(--accent-primary);
    font-weight: 500;
    text-decoration: none;
    border-bottom: 1px solid rgba(0, 192, 232, 0.4);
    transition: border-color 0.2s ease;
}

.whats-new-footnote a:hover {
    border-bottom-color: var(--accent-primary);
}

/* ============================================
   Features Section
   ============================================ */

.features {
    padding: var(--section-padding) 24px;
    background: var(--bg-secondary);
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 24px;
}

.feature-card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 16px;
    padding: 28px;
    transition: transform 0.25s ease, border-color 0.25s ease, box-shadow 0.25s ease;
    position: relative;
    overflow: hidden;
}

.feature-card:hover {
    transform: translateY(-3px);
    border-color: var(--border-hover);
    box-shadow: var(--shadow-md);
}

.feature-card::after {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: inherit;
    border: 1px solid transparent;
    background: linear-gradient(135deg, rgba(0, 192, 232, 0.3), rgba(0, 160, 196, 0.1)) border-box;
    -webkit-mask: linear-gradient(#fff 0 0) padding-box, linear-gradient(#fff 0 0);
    -webkit-mask-composite: xor;
    mask-composite: exclude;
    opacity: 0;
    transition: opacity 0.25s ease;
    pointer-events: none;
}

.feature-card:hover::after {
    opacity: 1;
}

.feature-icon {
    font-size: 2.5rem;
    margin-bottom: 16px;
    transition: transform 0.25s ease, filter 0.25s ease;
}

.feature-card:hover .feature-icon {
    transform: translateY(-2px) scale(1.06);
    filter: drop-shadow(0 4px 12px rgba(0, 192, 232, 0.28));
}

.feature-card h3 {
    font-size: 1.3rem;
    margin-bottom: 10px;
    font-weight: 600;
}

.feature-card > p {
    color: var(--text-secondary);
    margin-bottom: 16px;
    font-size: 0.95rem;
}

.feature-list {
    list-style: none;
}

.feature-list li {
    padding: 6px 0;
    padding-left: 22px;
    position: relative;
    color: var(--text-secondary);
    font-size: 0.9rem;
}

.feature-list li::before {
    content: "→";
    position: absolute;
    left: 0;
    color: var(--accent-primary);
    font-weight: 600;
}

/* ============================================
   How It Works Section
   ============================================ */

.how-it-works {
    padding: var(--section-padding) 24px;
}

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

.workflow-step {
    text-align: center;
    padding: 24px;
}

.step-number {
    width: 52px;
    height: 52px;
    background: var(--accent-gradient);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.3rem;
    font-weight: 700;
    color: #0f0f0f;
    margin: 0 auto 16px;
}

.workflow-step h3 {
    font-size: 1.15rem;
    margin-bottom: 8px;
    font-weight: 600;
}

.workflow-step p {
    color: var(--text-secondary);
    font-size: 0.9rem;
}

/* ============================================
   Pricing Section
   ============================================ */

.pricing {
    padding: var(--section-padding) 24px;
    background: var(--bg-secondary);
}

.pricing-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
    max-width: 900px;
    margin: 0 auto;
}

.pricing-card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 16px;
    padding: 28px;
    position: relative;
    transition: var(--transition);
    display: flex;
    flex-direction: column;
}

.pricing-card:hover {
    border-color: var(--border-hover);
}

.pricing-card.featured {
    border-color: var(--accent-primary);
    transform: scale(1.03);
}

.pricing-badge {
    position: absolute;
    top: -12px;
    left: 50%;
    transform: translateX(-50%);
    padding: 6px 14px;
    background: var(--accent-gradient);
    color: #0f0f0f;
    border-radius: 100px;
    font-size: 0.75rem;
    font-weight: 700;
    white-space: nowrap;
}

.pricing-badge.save {
    background: linear-gradient(135deg, #22c55e 0%, #16a34a 100%);
}

.pricing-header {
    text-align: center;
    padding-bottom: 20px;
    margin-bottom: 20px;
    border-bottom: 1px solid var(--border-color);
}

.pricing-header h3 {
    font-size: 1.1rem;
    margin-bottom: 8px;
    font-weight: 600;
}

.price {
    font-size: 2.2rem;
    font-weight: 700;
    letter-spacing: -0.02em;
}

.price span {
    font-size: 0.9rem;
    color: var(--text-muted);
    font-weight: 500;
}

.pricing-header > p {
    font-size: 0.85rem;
    color: var(--text-muted);
    margin-top: 4px;
}

.pricing-features {
    list-style: none;
    margin-bottom: 24px;
    flex: 1;
}

.pricing-features li {
    padding: 8px 0;
    font-size: 0.9rem;
    color: var(--text-secondary);
}

.pricing-features li.disabled {
    color: var(--text-muted);
    opacity: 0.6;
}

.pricing-note {
    text-align: center;
    margin-top: 32px;
    font-size: 0.85rem;
    color: var(--text-muted);
}

/* ============================================
   Comparison
   ============================================ */

.comparison {
    padding: var(--section-padding) 24px;
    background: var(--bg-secondary);
}

.comparison-table-wrapper {
    border: 1px solid var(--border-color);
    border-radius: 16px;
    overflow: hidden;
    background: var(--bg-card);
}

.comparison-table {
    width: 100%;
    border-collapse: collapse;
}

.comparison-table th,
.comparison-table td {
    padding: 14px 16px;
    border-bottom: 1px solid var(--border-color);
    text-align: left;
}

.comparison-table th[scope="col"] {
    background: var(--bg-secondary);
    color: var(--text-primary);
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

.comparison-table td {
    color: var(--text-secondary);
}

.comparison-table tbody tr:last-child th,
.comparison-table tbody tr:last-child td {
    border-bottom: none;
}

/* ============================================
   FAQ
   ============================================ */

.faq {
    padding: var(--section-padding) 24px;
}

.faq-list {
    max-width: 820px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.faq-item {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    overflow: hidden;
}

.faq-question {
    width: 100%;
    border: none;
    background: transparent;
    color: var(--text-primary);
    text-align: left;
    font-family: inherit;
    font-size: 1rem;
    font-weight: 600;
    padding: 18px 20px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    cursor: pointer;
}

.faq-icon {
    color: var(--accent-primary);
    font-weight: 700;
    font-size: 1.2rem;
    transition: transform 0.2s ease;
}

.faq-question[aria-expanded="true"] .faq-icon {
    transform: rotate(45deg);
}

.faq-answer {
    padding: 0 20px 18px;
    color: var(--text-secondary);
}

/* ============================================
   Download Section
   ============================================ */

.download {
    padding: var(--section-padding) 24px;
}

.download-card {
    max-width: 500px;
    margin: 0 auto;
    text-align: center;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 20px;
    padding: 48px 32px;
}

.download-icon {
    font-size: 4rem;
    margin-bottom: 20px;
}

.download-card h2 {
    font-size: 1.8rem;
    margin-bottom: 10px;
    font-weight: 700;
}

.download-card > p {
    color: var(--text-secondary);
    margin-bottom: 24px;
}

.download-version {
    font-size: 0.85rem;
    color: var(--text-muted);
    margin-top: 14px !important;
}

.download-notes {
    margin-top: 28px;
    padding-top: 24px;
    border-top: 1px solid var(--border-color);
    text-align: left;
}

.download-notes h4 {
    font-size: 0.9rem;
    margin-bottom: 12px;
    color: var(--text-secondary);
}

.download-notes ul {
    list-style: none;
}

.download-notes li {
    padding: 5px 0;
    padding-left: 20px;
    position: relative;
    font-size: 0.85rem;
    color: var(--text-muted);
}

.download-notes li::before {
    content: "✓";
    position: absolute;
    left: 0;
    color: var(--success);
}

/* ============================================
   Modal
   ============================================ */

.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(8px);
    z-index: 2000;
    align-items: center;
    justify-content: center;
}

.modal.active {
    display: flex;
}

.modal-content {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 20px;
    padding: 40px;
    max-width: 400px;
    width: 90%;
    text-align: center;
    position: relative;
}

.modal-close {
    position: absolute;
    top: 16px;
    right: 16px;
    background: none;
    border: none;
    color: var(--text-muted);
    font-size: 1.5rem;
    cursor: pointer;
    transition: var(--transition);
}

.modal-close:hover {
    color: var(--text-primary);
}

.modal-content h2 {
    font-size: 1.4rem;
    margin-bottom: 10px;
}

.modal-content > p {
    color: var(--text-secondary);
    margin-bottom: 28px;
    font-size: 0.95rem;
}

#apple-signin-btn {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 16px;
    margin-bottom: 20px;
}

.auth-apple-wrapper {
    cursor: pointer;
}

.auth-divider {
    display: flex;
    align-items: center;
    gap: 12px;
    width: 100%;
    color: var(--text-muted);
    font-size: 0.8rem;
}

.auth-divider::before,
.auth-divider::after {
    content: '';
    flex: 1;
    height: 1px;
    background: var(--border-color);
}

.auth-email-form {
    display: flex;
    flex-direction: column;
    gap: 10px;
    width: 100%;
}

.auth-email-form input[type="email"] {
    width: 100%;
    padding: 12px 16px;
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: 10px;
    color: var(--text-primary);
    font-size: 0.95rem;
    font-family: inherit;
    outline: none;
    transition: var(--transition);
}

.auth-email-form input[type="email"]:focus {
    border-color: var(--accent-primary);
    box-shadow: 0 0 0 2px var(--accent-glow);
}

.auth-email-form input[type="email"]::placeholder {
    color: var(--text-muted);
}

.auth-note {
    font-size: 0.8rem;
    color: var(--accent-primary);
    margin-bottom: 4px;
}

.auth-error {
    font-size: 0.8rem;
    color: var(--danger);
    margin-top: 8px;
}

.auth-otp-step {
    display: flex;
    flex-direction: column;
    gap: 12px;
    width: 100%;
}

.auth-otp-info {
    font-size: 0.85rem;
    color: var(--text-secondary);
    text-align: center;
    margin: 0;
}

.auth-email-form input[type="text"] {
    width: 100%;
    padding: 12px 16px;
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: 10px;
    color: var(--text-primary);
    font-size: 0.95rem;
    font-family: inherit;
    outline: none;
    transition: var(--transition);
}

.auth-email-form input[type="text"]:focus {
    border-color: var(--accent-primary);
    box-shadow: 0 0 0 2px var(--accent-glow);
}

.auth-email-form input[type="text"]::placeholder {
    color: var(--text-muted);
}

.auth-otp-resend {
    display: flex;
    justify-content: space-between;
    width: 100%;
}

.btn-link {
    background: none;
    border: none;
    color: var(--accent-primary);
    font-size: 0.8rem;
    cursor: pointer;
    padding: 0;
    font-family: inherit;
}

.btn-link:hover {
    text-decoration: underline;
}

.btn-link:disabled {
    color: var(--text-muted);
    cursor: default;
    text-decoration: none;
}

.modal-note {
    font-size: 0.8rem;
    color: var(--text-muted);
}

/* ============================================
   Success Page
   ============================================ */

.success-page {
    min-height: 100vh;
    display: flex;
    align-items: center;
    padding: calc(var(--section-padding) + 60px) 24px var(--section-padding);
    background:
        radial-gradient(ellipse at 50% 30%, rgba(0, 192, 232, 0.06) 0%, transparent 50%),
        var(--bg-primary);
}

.success-card {
    max-width: 540px;
    margin: 0 auto;
    text-align: center;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 20px;
    padding: 48px 32px;
}

.success-icon {
    margin-bottom: 24px;
}

.success-card h1 {
    font-size: 1.6rem;
    font-weight: 700;
    margin-bottom: 8px;
    letter-spacing: -0.02em;
}

.success-subtitle {
    color: var(--text-secondary);
    font-size: 1rem;
    margin-bottom: 32px;
}

.download-status {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 16px;
    margin-bottom: 24px;
}

.download-spinner {
    width: 40px;
    height: 40px;
    position: relative;
}

.spinner-ring {
    width: 100%;
    height: 100%;
    border: 3px solid var(--border-color);
    border-top-color: var(--accent-primary);
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

.download-status-text {
    color: var(--text-muted);
    font-size: 0.9rem;
}

.success-error {
    color: var(--danger);
    font-size: 0.9rem;
    margin-bottom: 20px;
    padding: 12px 16px;
    background: rgba(239, 68, 68, 0.08);
    border: 1px solid rgba(239, 68, 68, 0.15);
    border-radius: 10px;
}

.success-next-steps {
    margin: 32px 0;
    padding: 24px;
    background: var(--bg-secondary);
    border-radius: 12px;
    text-align: left;
}

.success-next-steps h3 {
    font-size: 0.95rem;
    font-weight: 600;
    margin-bottom: 12px;
}

.success-next-steps ol {
    list-style: none;
    counter-reset: steps;
}

.success-next-steps li {
    counter-increment: steps;
    padding: 6px 0;
    padding-left: 28px;
    position: relative;
    color: var(--text-secondary);
    font-size: 0.9rem;
}

.success-next-steps li::before {
    content: counter(steps);
    position: absolute;
    left: 0;
    width: 20px;
    height: 20px;
    background: var(--accent-gradient);
    color: #0f0f0f;
    border-radius: 50%;
    font-size: 0.7rem;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
    top: 7px;
}

/* ============================================
   Profile Page
   ============================================ */

.profile-page {
    min-height: 100vh;
    display: flex;
    align-items: center;
    padding: calc(var(--section-padding) + 60px) 24px var(--section-padding);
    background:
        radial-gradient(ellipse at 50% 30%, rgba(0, 192, 232, 0.06) 0%, transparent 50%),
        var(--bg-primary);
}

.profile-card {
    max-width: 480px;
    margin: 0 auto;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 20px;
    padding: 40px 32px;
}

.profile-header {
    text-align: center;
    margin-bottom: 32px;
}

.profile-avatar {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    background: var(--accent-gradient);
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 16px;
    font-size: 1.8rem;
    font-weight: 700;
    color: #0f0f0f;
}

.profile-header h1 {
    font-size: 1.5rem;
    font-weight: 700;
    margin-bottom: 4px;
    letter-spacing: -0.02em;
}

.profile-email {
    color: var(--text-muted);
    font-size: 0.9rem;
}

.profile-section {
    margin-bottom: 24px;
    padding-bottom: 24px;
    border-bottom: 1px solid var(--border-color);
}

.profile-section h3 {
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: 16px;
}

.profile-loading {
    display: flex;
    align-items: center;
    gap: 12px;
    color: var(--text-muted);
    font-size: 0.9rem;
}

.spinner-sm {
    width: 20px;
    height: 20px;
    border-width: 2px;
    flex-shrink: 0;
}

.subscription-badge {
    display: inline-block;
    padding: 6px 16px;
    border-radius: 100px;
    font-size: 0.85rem;
    font-weight: 600;
    margin-bottom: 16px;
}

.subscription-badge.pro {
    background: var(--accent-gradient);
    color: #0f0f0f;
}

.subscription-badge.free {
    background: var(--bg-secondary);
    color: var(--text-secondary);
    border: 1px solid var(--border-color);
}

.subscription-details {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.detail-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.detail-label {
    font-size: 0.9rem;
    color: var(--text-muted);
}

.detail-value {
    font-size: 0.9rem;
    color: var(--text-primary);
    font-weight: 500;
}

.profile-actions {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.btn-danger-outline {
    background: transparent;
    color: var(--danger);
    border: 1px solid rgba(239, 68, 68, 0.3);
}

.btn-danger-outline:hover {
    background: rgba(239, 68, 68, 0.08);
    border-color: rgba(239, 68, 68, 0.5);
}

/* ============================================
   Changelog & Blog Pages
   ============================================ */

.content-page {
    min-height: 100vh;
    padding: calc(var(--section-padding) + 60px) 24px var(--section-padding);
    background:
        radial-gradient(ellipse at 50% 20%, rgba(0, 192, 232, 0.07) 0%, transparent 55%),
        var(--bg-primary);
}

.content-card {
    max-width: 860px;
    margin: 0 auto;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 20px;
    padding: 36px 30px;
}

.content-meta {
    color: var(--text-muted);
    font-size: 0.88rem;
    margin-bottom: 10px;
}

.content-title {
    font-size: clamp(1.8rem, 4vw, 2.4rem);
    margin-bottom: 10px;
    letter-spacing: -0.02em;
}

.content-description {
    color: var(--text-secondary);
    margin-bottom: 26px;
}

/* Breadcrumb navigation */
.breadcrumb {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 18px;
    font-size: 0.85rem;
}

.breadcrumb a {
    color: var(--accent-primary);
    text-decoration: none;
    transition: var(--transition);
}

.breadcrumb a:hover {
    color: var(--accent-secondary);
    text-decoration: underline;
}

.breadcrumb .separator {
    color: var(--text-muted);
    user-select: none;
}

.breadcrumb .current {
    color: var(--text-muted);
}

/* Blog article prose — for long-form content that uses p tags instead of ul */
.blog-prose {
    display: flex;
    flex-direction: column;
    gap: 16px;
    margin-top: 24px;
}

.blog-prose p {
    color: var(--text-secondary);
    line-height: 1.75;
    font-size: 0.95rem;
}

.blog-prose h3 {
    font-size: 1.15rem;
    margin-top: 12px;
    color: var(--text-primary);
}

.blog-prose ul {
    margin-left: 20px;
    color: var(--text-secondary);
    display: grid;
    gap: 6px;
    line-height: 1.6;
}

/* Inline screenshot figures inside blog posts */
.blog-figure {
    margin: 12px 0 8px;
    padding: 0;
    border-radius: 14px;
    overflow: hidden;
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    box-shadow:
        0 18px 40px rgba(0, 0, 0, 0.45),
        0 0 0 1px rgba(0, 192, 232, 0.10);
}

.blog-figure img {
    display: block;
    width: 100%;
    height: auto;
}

.blog-figure--narrow {
    max-width: 460px;
    margin-left: auto;
    margin-right: auto;
}

/* Back link at bottom of articles */
.back-link {
    margin-top: 28px;
    padding-top: 20px;
    border-top: 1px solid var(--border-color);
}

.changelog-list {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.changelog-item {
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 18px;
    background: var(--bg-secondary);
}

.changelog-item h3 {
    font-size: 1.05rem;
    margin-bottom: 8px;
}

.changelog-item ul {
    margin-left: 18px;
    color: var(--text-secondary);
    display: grid;
    gap: 5px;
}

.blog-list {
    display: grid;
    gap: 14px;
}

.blog-item {
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 18px;
    background: var(--bg-secondary);
}

.blog-item h3 {
    margin-bottom: 6px;
}

.blog-item p {
    color: var(--text-secondary);
}

/* ============================================
   Logo Image
   ============================================ */

.logo-img {
    border-radius: 6px;
}

/* ============================================
   Footer
   ============================================ */

.footer {
    padding: 56px 24px 28px;
    background: var(--bg-primary);
    border-top: 1px solid var(--border-color);
}

.footer-content {
    text-align: center;
    margin-bottom: 28px;
}

.footer-brand {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    font-size: 1.15rem;
    font-weight: 700;
    margin-bottom: 10px;
}

.footer-content > p {
    color: var(--text-muted);
    margin-bottom: 18px;
    font-size: 0.9rem;
}

.footer-links {
    display: flex;
    justify-content: center;
    gap: 28px;
    flex-wrap: wrap;
}

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

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

.footer-bottom {
    text-align: center;
    padding-top: 24px;
    border-top: 1px solid var(--border-color);
}

.footer-bottom p {
    color: var(--text-muted);
    font-size: 0.8rem;
}

/* ============================================
   Mockup Inline Style Replacements
   ============================================ */

.mockup-trial-banner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 6px 16px;
    background: rgba(0, 192, 232, 0.08);
    border-bottom: 1px solid var(--border-color);
    font-size: 0.7rem;
}

.mockup-trial-text {
    color: var(--accent-primary);
}

.mockup-trial-btn {
    padding: 3px 10px;
    background: var(--accent-gradient);
    color: #0f0f0f;
    border-radius: 4px;
    font-weight: 600;
    font-size: 0.65rem;
    cursor: pointer;
}

.mockup-tab-icon {
    display: flex;
    align-items: center;
    gap: 6px;
}

.mockup-beta-badge {
    font-size: 0.55rem;
    padding: 1px 4px;
    background: rgba(0, 192, 232, 0.15);
    color: var(--accent-primary);
    border-radius: 3px;
    font-weight: 600;
}

.mockup-section-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.mockup-section-title {
    font-size: 0.75rem;
    font-weight: 600;
    color: var(--text-primary);
}

.mockup-action-btn {
    font-size: 0.6rem;
    padding: 3px 8px;
    background: var(--accent-gradient);
    color: #0f0f0f;
    border-radius: 4px;
    font-weight: 600;
    cursor: pointer;
}

.mockup-update-row {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 6px 8px;
    background: rgba(245, 158, 11, 0.08);
    border: 1px solid rgba(245, 158, 11, 0.12);
    border-radius: 6px;
    font-size: 0.7rem;
}

.mockup-status-dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    flex-shrink: 0;
}

.mockup-status-dot.warning { background: var(--warning); }
.mockup-status-dot.success { background: var(--success); }

.mockup-app-name {
    flex: 1;
    color: var(--text-secondary);
}

.mockup-version-info {
    color: var(--text-muted);
    font-size: 0.6rem;
}

.mockup-source-badge {
    font-size: 0.55rem;
    padding: 1px 5px;
    background: rgba(0, 192, 232, 0.12);
    color: var(--accent-primary);
    border-radius: 3px;
    font-weight: 600;
}

.mockup-update-btn {
    font-size: 0.6rem;
    padding: 2px 8px;
    background: var(--accent-gradient);
    color: #0f0f0f;
    border-radius: 4px;
    font-weight: 600;
    cursor: pointer;
}

.mockup-app-row {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 4px 8px;
    border-radius: 5px;
    font-size: 0.68rem;
    color: var(--text-secondary);
    background: var(--bg-card);
}

.mockup-app-row .mockup-version-info {
    margin-left: auto;
}

.mockup-section-spacer {
    margin-top: 4px;
}

.mockup-formula-row {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 6px 8px;
    background: rgba(245, 158, 11, 0.08);
    border: 1px solid rgba(245, 158, 11, 0.12);
    border-radius: 6px;
    font-size: 0.68rem;
}

.mockup-formula-row .mockup-version-info {
    font-size: 0.58rem;
}

.mockup-disk-info {
    display: flex;
    align-items: center;
    justify-content: space-between;
    font-size: 0.65rem;
}

.mockup-disk-used {
    color: var(--text-muted);
}

.mockup-disk-percent {
    color: var(--accent-primary);
    font-weight: 600;
}

.mockup-clean-btn {
    text-align: center;
}

.mockup-clean-btn span {
    font-size: 0.6rem;
    padding: 4px 12px;
    background: var(--accent-gradient);
    color: #0f0f0f;
    border-radius: 5px;
    font-weight: 600;
    cursor: pointer;
}

.mockup-bottom-bar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 8px 16px;
    background: var(--bg-secondary);
    border-top: 1px solid var(--border-color);
    font-size: 0.65rem;
    color: var(--text-muted);
}

.mockup-settings-icon {
    cursor: pointer;
}

.mockup-tabs-vertical {
    flex-direction: column;
    gap: 4px;
}

.mockup-app-list {
    display: flex;
    flex-direction: column;
    gap: 3px;
}

/* ============================================
   Focus States & Accessibility
   ============================================ */

*:focus-visible {
    outline: 2px solid var(--accent-primary);
    outline-offset: 2px;
}

.btn:focus-visible {
    outline: 2px solid var(--accent-primary);
    outline-offset: 2px;
    box-shadow: 0 0 0 4px var(--accent-glow);
}

.nav-links a:focus-visible {
    outline: 2px solid var(--accent-primary);
    outline-offset: 4px;
    border-radius: 4px;
}

.faq-item summary:focus-visible {
    outline: 2px solid var(--accent-primary);
    outline-offset: -2px;
}

/* ============================================
   Button Active/Press States
   ============================================ */

.btn:active {
    transform: translateY(0) scale(0.98);
    transition-duration: 0.1s;
}

.btn-primary:active {
    box-shadow: 0 2px 8px var(--accent-glow);
}

.btn-secondary:active {
    background: var(--bg-secondary);
}

/* ============================================
   FAQ Accordion Animations
   ============================================ */

.faq-item summary {
    cursor: pointer;
    padding: 18px 20px;
    font-weight: 600;
    list-style: none;
    display: flex;
    justify-content: space-between;
    align-items: center;
    transition: background 0.2s ease;
}

.faq-item summary::-webkit-details-marker {
    display: none;
}

.faq-item summary::after {
    content: "+";
    font-size: 1.2rem;
    font-weight: 700;
    color: var(--accent-primary);
    transition: transform 0.2s ease;
}

.faq-item[open] summary::after {
    transform: rotate(45deg);
}

.faq-item summary:hover {
    background: var(--bg-secondary);
}

.faq-item p {
    padding: 0 20px 18px;
    color: var(--text-secondary);
    animation: faqSlideIn 0.2s ease;
}

@keyframes faqSlideIn {
    from {
        opacity: 0;
        transform: translateY(-8px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* ============================================
   Mobile Touch Targets
   ============================================ */

@media (pointer: coarse) {
    .nav-links a {
        min-height: 44px;
        display: flex;
        align-items: center;
    }

    .btn {
        min-height: 44px;
    }

    .faq-item summary {
        min-height: 48px;
    }

    .footer-links a {
        min-height: 44px;
        display: inline-flex;
        align-items: center;
    }

    .back-to-top {
        width: 48px;
        height: 48px;
    }
}

/* ============================================
   Reduced Motion Support
   ============================================ */

@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
        scroll-behavior: auto !important;
    }

    .skeleton {
        animation: none;
        background: rgba(0, 192, 232, 0.12);
    }

    .btn-primary:hover,
    .feature-card:hover,
    .pricing-card.featured {
        transform: none;
    }

    .feature-card:hover .feature-icon {
        transform: none;
        filter: none;
    }
}

/* ============================================
   Utility Interactions
   ============================================ */

@keyframes shimmer {
    0% { background-position: -200% 0; }
    100% { background-position: 200% 0; }
}

.skeleton {
    border-radius: 6px;
    padding: 2px 4px;
    background: linear-gradient(
        90deg,
        rgba(0, 192, 232, 0.08) 0%,
        rgba(0, 192, 232, 0.18) 50%,
        rgba(0, 192, 232, 0.08) 100%
    );
    background-size: 200% 100%;
    animation: shimmer 1.8s linear infinite;
}

.back-to-top {
    position: fixed;
    right: 22px;
    bottom: 22px;
    width: 44px;
    height: 44px;
    border-radius: 999px;
    border: 1px solid var(--border-color);
    background: var(--bg-card);
    color: var(--accent-primary);
    box-shadow: var(--shadow-md);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    z-index: 1100;
    opacity: 0;
    transform: translateY(10px);
    pointer-events: none;
    transition: opacity 0.25s ease, transform 0.25s ease;
}

.back-to-top.visible {
    opacity: 1;
    transform: translateY(0);
    pointer-events: auto;
}

.back-to-top:hover {
    border-color: var(--border-hover);
    color: var(--text-primary);
}

@keyframes shake {
    0%, 100% { transform: translateX(0); }
    20% { transform: translateX(-4px); }
    40% { transform: translateX(4px); }
    60% { transform: translateX(-3px); }
    80% { transform: translateX(3px); }
}

.auth-error.shake {
    animation: shake 0.36s ease;
}

@keyframes successPulse {
    0% { box-shadow: 0 0 0 0 rgba(34, 197, 94, 0.45); }
    100% { box-shadow: 0 0 0 14px rgba(34, 197, 94, 0); }
}

.modal-content.success-pulse {
    animation: successPulse 0.7s ease;
}

/* Scroll animations */
.feature-card,
.workflow-step,
.pricing-card,
.download-card,
.comparison-table-wrapper,
.faq-item,
.whats-new-card {
    opacity: 0;
    transform: translateY(16px);
    transition: opacity 0.5s ease, transform 0.5s ease;
}

.animate-in {
    opacity: 1;
    transform: translateY(0);
}

@media (prefers-reduced-motion: reduce) {
    .feature-card,
    .workflow-step,
    .pricing-card,
    .download-card,
    .comparison-table-wrapper,
    .faq-item,
    .whats-new-card {
        opacity: 1;
        transform: none;
        transition: none;
    }

    html {
        scroll-behavior: auto;
    }
}

/* ============================================
   Responsive
   ============================================ */

@media (max-width: 968px) {
    .hero {
        flex-direction: column;
        text-align: center;
        padding-top: 120px;
    }
    
    .hero-content {
        margin-right: 0;
        margin-bottom: 48px;
    }
    
    .hero-buttons {
        justify-content: center;
    }
    
    .pricing-grid {
        grid-template-columns: 1fr;
        max-width: 400px;
    }
    
    .pricing-card.featured {
        transform: none;
    }
    
    .workflow-grid {
        grid-template-columns: 1fr;
        max-width: 300px;
        margin: 0 auto;
    }

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

    .whats-new-grid {
        grid-template-columns: 1fr;
        grid-template-rows: auto;
    }

    .whats-new-card--feature {
        grid-row: auto;
    }

    .comparison-table th,
    .comparison-table td {
        padding: 12px;
    }
}

@media (max-width: 640px) {
    :root {
        --section-padding: 70px;
    }
    
    .hero h1 {
        font-size: 2rem;
    }
    
    .hero-buttons {
        flex-direction: column;
    }
    
    .btn {
        width: 100%;
    }
    
    .window-mockup {
        max-width: 100%;
    }
    
    .window-content {
        flex-direction: column;
    }
    
    .mockup-sidebar {
        width: 100%;
        border-right: none;
        border-bottom: 1px solid var(--border-color);
    }
    
    .features-grid {
        grid-template-columns: 1fr;
    }
    
    .nav-toggle {
        display: flex;
    }
    
    .nav-links {
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        background: var(--navbar-bg-scrolled);
        backdrop-filter: blur(16px);
        -webkit-backdrop-filter: blur(16px);
        flex-direction: column;
        padding: 16px 24px;
        gap: 0;
        border-bottom: 1px solid var(--border-color);
        opacity: 0;
        transform: translateY(-8px);
        visibility: hidden;
        pointer-events: none;
        transition: opacity 0.2s ease, transform 0.2s ease, visibility 0.2s ease;
    }
    
    .nav-links.active {
        opacity: 1;
        transform: translateY(0);
        visibility: visible;
        pointer-events: auto;
    }
    
    .nav-links a {
        padding: 12px 0;
        border-bottom: 1px solid var(--border-color);
    }
    
    .nav-links a:last-child {
        border-bottom: none;
    }

    .comparison-table {
        font-size: 0.88rem;
    }

    .faq-question {
        font-size: 0.95rem;
    }

    .back-to-top {
        right: 16px;
        bottom: 16px;
        width: 40px;
        height: 40px;
    }
}
