/* ============================================
   GHOST REGEX — Landing
   ============================================ */

:root {
    /* Цвета в стиле VS Code dark */
    --bg: #0d1117;
    --bg-elevated: #161b22;
    --bg-card: #1c2128;
    --border: #30363d;
    --border-hover: #484f58;

    --text: #e6edf3;
    --text-muted: #8b949e;
    --text-dim: #6e7681;

    --accent: #58a6ff;
    --accent-hover: #79c0ff;
    --green: #7ee787;
    --purple: #d2a8ff;
    --orange: #ffa657;
    --red: #ff7b72;

    --font-sans: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    --font-mono: 'JetBrains Mono', 'SF Mono', Consolas, monospace;

    --radius: 12px;
    --radius-sm: 8px;
    --shadow: 0 8px 24px rgba(0, 0, 0, 0.4);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: var(--font-sans);
    background: var(--bg);
    color: var(--text);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
    overflow-x: hidden;
}

a {
    color: inherit;
    text-decoration: none;
}

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

code {
    font-family: var(--font-mono);
    background: var(--bg-card);
    padding: 2px 6px;
    border-radius: 4px;
    font-size: 0.9em;
    color: var(--orange);
}

/* ============================================
   CONTAINER
   ============================================ */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 24px;
}

.container-narrow {
    max-width: 800px;
}

/* ============================================
   NAVBAR
   ============================================ */
.nav {
    position: sticky;
    top: 0;
    z-index: 100;
    background: rgba(13, 17, 23, 0.85);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-bottom: 1px solid var(--border);
}

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

.logo {
    display: flex;
    align-items: center;
    gap: 10px;
    font-weight: 700;
    font-size: 16px;
}

.logo-mark {
    font-family: var(--font-mono);
    font-weight: 700;
    font-size: 14px;
    background: linear-gradient(135deg, var(--accent), var(--purple));
    color: #0d1117;
    padding: 6px 10px;
    border-radius: 8px;
    letter-spacing: 1px;
}

.logo-text {
    color: var(--text);
}

.nav-links {
    display: flex;
    align-items: center;
    gap: 24px;
    font-size: 14px;
}

.nav-links a {
    color: var(--text-muted);
    transition: color 0.15s;
}

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

/* ============================================
   BUTTONS
   ============================================ */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 10px 20px;
    border-radius: var(--radius-sm);
    font-weight: 600;
    font-size: 14px;
    cursor: pointer;
    border: 1px solid transparent;
    transition: all 0.15s ease;
    white-space: nowrap;
    font-family: inherit;
}

.btn-primary {
    background: var(--accent);
    color: #0d1117;
}

.btn-primary:hover {
    background: var(--accent-hover);
    transform: translateY(-1px);
}

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

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

.btn-sm {
    padding: 6px 14px;
    font-size: 13px;
}

.btn-lg {
    padding: 14px 28px;
    font-size: 16px;
}

.btn-block {
    width: 100%;
    margin-top: 8px;
}

/* ============================================
   HERO
   ============================================ */
.hero {
    padding: 80px 0 60px;
    text-align: center;
    position: relative;
    overflow: hidden;
}

.hero::before {
    content: '';
    position: absolute;
    top: -200px;
    left: 50%;
    transform: translateX(-50%);
    width: 800px;
    height: 800px;
    background: radial-gradient(circle, rgba(88, 166, 255, 0.12) 0%, transparent 60%);
    pointer-events: none;
    z-index: 0;
}

.hero .container {
    position: relative;
    z-index: 1;
}

.hero-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 6px 14px;
    background: var(--bg-elevated);
    border: 1px solid var(--border);
    border-radius: 999px;
    font-size: 13px;
    color: var(--text-muted);
    margin-bottom: 24px;
}

.hero-badge .dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: var(--green);
    box-shadow: 0 0 8px var(--green);
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.4; }
}

.hero-title {
    font-size: clamp(32px, 5vw, 56px);
    font-weight: 800;
    line-height: 1.15;
    letter-spacing: -0.02em;
    margin-bottom: 24px;
}

.gradient-text {
    background: linear-gradient(135deg, var(--accent) 0%, var(--purple) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.hero-sub {
    font-size: 18px;
    color: var(--text-muted);
    max-width: 640px;
    margin: 0 auto 32px;
    line-height: 1.6;
}

.hero-buttons {
    display: flex;
    gap: 12px;
    justify-content: center;
    flex-wrap: wrap;
    margin-bottom: 20px;
}

.hero-meta {
    font-size: 13px;
    color: var(--text-dim);
    margin-bottom: 60px;
}

/* Screenshot в hero */
.hero-screenshot {
    max-width: 1000px;
    margin: 0 auto;
}

.screenshot-frame {
    border-radius: var(--radius);
    border: 1px solid var(--border);
    background: var(--bg-elevated);
    overflow: hidden;
    box-shadow: var(--shadow);
}

.screenshot-bar {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 12px 16px;
    background: var(--bg-card);
    border-bottom: 1px solid var(--border);
}

.dot-red, .dot-yellow, .dot-green {
    width: 10px;
    height: 10px;
    border-radius: 50%;
}

.dot-red { background: #ff5f57; }
.dot-yellow { background: #febc2e; }
.dot-green { background: #28c840; }

.screenshot-title {
    margin-left: 12px;
    font-size: 12px;
    color: var(--text-dim);
    font-family: var(--font-mono);
}

.screenshot-frame img {
    width: 100%;
    display: block;
}

/* ============================================
   SECTIONS
   ============================================ */
section {
    padding: 80px 0;
}

.section-title {
    font-size: clamp(28px, 4vw, 40px);
    font-weight: 800;
    letter-spacing: -0.02em;
    text-align: center;
    margin-bottom: 16px;
}

.section-sub {
    text-align: center;
    color: var(--text-muted);
    font-size: 17px;
    margin-bottom: 48px;
}

/* ============================================
   PAIN
   ============================================ */
.pain {
    background: var(--bg-elevated);
    border-top: 1px solid var(--border);
    border-bottom: 1px solid var(--border);
}

.pain-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 16px;
    margin-top: 40px;
}

.pain-card {
    background: var(--bg);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 24px;
    display: flex;
    gap: 14px;
    align-items: flex-start;
}

.pain-icon {
    font-size: 20px;
    flex-shrink: 0;
}

.pain-card p {
    color: var(--text-muted);
    font-size: 15px;
    line-height: 1.5;
}

.pain-footer {
    text-align: center;
    margin-top: 40px;
    font-size: 18px;
    font-weight: 600;
    color: var(--text);
}

/* ============================================
   FEATURES
   ============================================ */
.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 20px;
    margin-top: 40px;
}

.feature-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 28px;
    transition: all 0.2s ease;
}

.feature-card:hover {
    border-color: var(--border-hover);
    transform: translateY(-2px);
}

.feature-card-warn:hover {
    border-color: var(--red);
    box-shadow: 0 0 0 1px rgba(255, 123, 114, 0.2);
}

.feature-icon {
    font-size: 28px;
    margin-bottom: 14px;
    display: block;
}

.feature-card h3 {
    font-size: 17px;
    font-weight: 700;
    margin-bottom: 10px;
}

.feature-card p {
    font-size: 14.5px;
    color: var(--text-muted);
    line-height: 1.6;
}

/* ============================================
   REDOS / SNIPPETS SHOWCASE
   ============================================ */
.redos-showcase,
.snippets-showcase {
    padding: 100px 0;
}

.redos-showcase {
    background: var(--bg-elevated);
    border-top: 1px solid var(--border);
    border-bottom: 1px solid var(--border);
}

.redos-grid,
.snippets-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 60px;
    align-items: center;
}

.redos-image img,
.snippets-image img {
    border-radius: var(--radius);
    border: 1px solid var(--border);
    box-shadow: var(--shadow);
}

.redos-badge,
.snippets-badge {
    display: inline-block;
    padding: 5px 12px;
    border-radius: 999px;
    font-size: 12px;
    font-weight: 600;
    margin-bottom: 16px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.redos-badge {
    background: rgba(255, 123, 114, 0.15);
    color: var(--red);
    border: 1px solid rgba(255, 123, 114, 0.3);
}

.snippets-badge {
    background: rgba(126, 231, 135, 0.15);
    color: var(--green);
    border: 1px solid rgba(126, 231, 135, 0.3);
}

.redos-text h2,
.snippets-text h2 {
    font-size: clamp(24px, 3vw, 34px);
    font-weight: 800;
    letter-spacing: -0.02em;
    margin-bottom: 20px;
    line-height: 1.2;
}

.redos-text p,
.snippets-text p {
    color: var(--text-muted);
    font-size: 16px;
    line-height: 1.7;
    margin-bottom: 20px;
}

.redos-list {
    list-style: none;
    margin-top: 24px;
}

.redos-list li {
    padding: 10px 0;
    padding-left: 28px;
    position: relative;
    color: var(--text);
    font-size: 15px;
}

.redos-list li::before {
    content: '→';
    position: absolute;
    left: 0;
    color: var(--red);
    font-weight: bold;
}

.snippets-note {
    font-size: 14px !important;
    color: var(--text-dim) !important;
    padding: 12px 16px;
    background: var(--bg-card);
    border-left: 3px solid var(--green);
    border-radius: 4px;
}

/* ============================================
   PRICING
   ============================================ */
.pricing {
    background: var(--bg);
}

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

.price-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 36px 32px;
    position: relative;
    transition: all 0.2s;
}

.price-card-pro {
    border-color: var(--accent);
    background: linear-gradient(180deg, rgba(88, 166, 255, 0.05) 0%, var(--bg-card) 60%);
    box-shadow: 0 0 40px rgba(88, 166, 255, 0.15);
}

.price-badge {
    position: absolute;
    top: -12px;
    left: 50%;
    transform: translateX(-50%);
    background: var(--accent);
    color: #0d1117;
    padding: 4px 14px;
    border-radius: 999px;
    font-size: 12px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

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

.price-header h3 {
    font-size: 20px;
    font-weight: 700;
    margin-bottom: 12px;
}

.price-value {
    font-size: 48px;
    font-weight: 800;
    letter-spacing: -0.02em;
    line-height: 1;
}

.price-unit {
    font-size: 20px;
    font-weight: 500;
    color: var(--text-muted);
    margin-left: 4px;
}

.price-period {
    color: var(--text-dim);
    font-size: 14px;
    margin-top: 8px;
}

.price-features {
    list-style: none;
    margin-bottom: 24px;
}

.price-features li {
    padding: 8px 0;
    font-size: 15px;
    color: var(--text-muted);
    padding-left: 28px;
    position: relative;
}

.price-features li.included::before {
    content: '✓';
    position: absolute;
    left: 0;
    color: var(--green);
    font-weight: bold;
}

.price-features li.highlight {
    color: var(--text);
    font-weight: 500;
}

/* ============================================
   WHY
   ============================================ */
.why {
    background: var(--bg-elevated);
    border-top: 1px solid var(--border);
    border-bottom: 1px solid var(--border);
}

.why-quote {
    text-align: center;
    font-size: 18px;
    line-height: 1.7;
}

.why-quote p {
    color: var(--text-muted);
    margin-bottom: 24px;
}

.why-highlight {
    color: var(--text) !important;
    font-size: 22px;
    font-weight: 700;
    padding: 24px;
    border-left: 3px solid var(--accent);
    background: var(--bg-card);
    border-radius: 4px;
    text-align: left;
}

/* ============================================
   FAQ
   ============================================ */
.faq-item {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    margin-bottom: 12px;
    overflow: hidden;
    transition: border-color 0.15s;
}

.faq-item:hover {
    border-color: var(--border-hover);
}

.faq-item summary {
    padding: 20px 24px;
    cursor: pointer;
    font-weight: 600;
    font-size: 16px;
    list-style: none;
    display: flex;
    align-items: center;
    justify-content: space-between;
    user-select: none;
}

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

.faq-item summary::after {
    content: '+';
    font-size: 22px;
    color: var(--text-muted);
    font-weight: 300;
    transition: transform 0.2s;
}

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

.faq-item p {
    padding: 0 24px 20px;
    color: var(--text-muted);
    font-size: 15px;
    line-height: 1.7;
}

/* ============================================
   CTA
   ============================================ */
.cta {
    text-align: center;
    padding: 100px 0;
    background: radial-gradient(circle at 50% 50%, rgba(88, 166, 255, 0.1) 0%, transparent 60%);
}

.cta h2 {
    font-size: clamp(28px, 4vw, 40px);
    font-weight: 800;
    letter-spacing: -0.02em;
    margin-bottom: 12px;
}

.cta p {
    color: var(--text-muted);
    font-size: 17px;
    margin-bottom: 32px;
}

.cta-buttons {
    display: flex;
    gap: 12px;
    justify-content: center;
    flex-wrap: wrap;
}

/* ============================================
   FOOTER
   ============================================ */
.footer {
    border-top: 1px solid var(--border);
    padding: 32px 0;
    background: var(--bg);
}

.footer-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 20px;
}

.footer-brand {
    display: flex;
    align-items: center;
    gap: 10px;
    font-weight: 600;
}

.footer-links {
    display: flex;
    gap: 24px;
    font-size: 14px;
}

.footer-links a {
    color: var(--text-muted);
    transition: color 0.15s;
}

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

.footer-copy {
    color: var(--text-dim);
    font-size: 13px;
}

/* ============================================
   RESPONSIVE
   ============================================ */
@media (max-width: 768px) {
    .nav-links a:not(.btn) {
        display: none;
    }

    .hero {
        padding: 60px 0 40px;
    }

    .hero-buttons {
        flex-direction: column;
        align-items: stretch;
    }

    .hero-buttons .btn {
        width: 100%;
    }

    .redos-grid,
    .snippets-grid {
        grid-template-columns: 1fr;
        gap: 32px;
    }

    .snippets-image {
        order: -1;
    }

    section {
        padding: 60px 0;
    }

    .footer-inner {
        flex-direction: column;
        text-align: center;
    }

    .pain-card {
        padding: 20px;
    }

    .price-card {
        padding: 28px 24px;
    }
}

@media (max-width: 480px) {
    .container {
        padding: 0 16px;
    }

    .hero-title {
        font-size: 28px;
    }

    .hero-sub {
        font-size: 16px;
    }

    .btn-lg {
        padding: 12px 20px;
        font-size: 15px;
    }
}
/* ============================================
   REPORT FORM
   ============================================ */
.report {
    background: var(--bg-elevated);
    border-top: 1px solid var(--border);
    border-bottom: 1px solid var(--border);
}

.report-form {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 36px;
    margin-top: 24px;
}

.form-row {
    margin-bottom: 22px;
}

.form-row label {
    display: block;
    font-size: 14px;
    font-weight: 600;
    margin-bottom: 8px;
    color: var(--text);
}

.form-row input[type="text"],
.form-row input[type="email"],
.form-row select,
.form-row textarea {
    width: 100%;
    padding: 12px 14px;
    background: var(--bg);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    color: var(--text);
    font-family: var(--font-sans);
    font-size: 15px;
    transition: border-color 0.15s, box-shadow 0.15s;
    box-sizing: border-box;
}

.form-row input[type="text"]:focus,
.form-row input[type="email"]:focus,
.form-row select:focus,
.form-row textarea:focus {
    outline: none;
    border-color: var(--accent);
    box-shadow: 0 0 0 3px rgba(88, 166, 255, 0.15);
}

.form-row textarea {
    resize: vertical;
    min-height: 100px;
    line-height: 1.6;
}

.form-row input[type="file"] {
    width: 100%;
    padding: 12px 14px;
    background: var(--bg);
    border: 1px dashed var(--border);
    border-radius: var(--radius-sm);
    color: var(--text-muted);
    font-size: 14px;
    cursor: pointer;
    box-sizing: border-box;
}

.form-row input[type="file"]:hover {
    border-color: var(--border-hover);
}

.form-row input[type="file"]::file-selector-button {
    background: var(--bg-elevated);
    border: 1px solid var(--border);
    color: var(--text);
    padding: 6px 14px;
    border-radius: 6px;
    margin-right: 12px;
    cursor: pointer;
    font-family: inherit;
    font-size: 13px;
    transition: all 0.15s;
}

.form-row input[type="file"]::file-selector-button:hover {
    background: var(--bg-card);
    border-color: var(--border-hover);
}

.form-hint {
    font-size: 12.5px;
    color: var(--text-dim);
    margin-top: 6px;
}

.form-note {
    text-align: center;
    font-size: 14px;
    color: var(--text-muted);
    margin-top: 20px;
}

.form-note a {
    color: var(--accent);
}

.form-note a:hover {
    text-decoration: underline;
}

@media (max-width: 600px) {
    .report-form {
        padding: 24px 20px;
    }
}
/* ============================================
   JS-DRIVEN: ANIMATIONS & MOBILE
   ============================================ */

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

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

/* Каскад для карточек внутри grid */
.features-grid .feature-card:nth-child(2) { transition-delay: 0.06s; }
.features-grid .feature-card:nth-child(3) { transition-delay: 0.12s; }
.features-grid .feature-card:nth-child(4) { transition-delay: 0.18s; }
.features-grid .feature-card:nth-child(5) { transition-delay: 0.06s; }
.features-grid .feature-card:nth-child(6) { transition-delay: 0.12s; }
.features-grid .feature-card:nth-child(7) { transition-delay: 0.18s; }
.features-grid .feature-card:nth-child(8) { transition-delay: 0.24s; }

.pain-grid .pain-card:nth-child(2) { transition-delay: 0.08s; }
.pain-grid .pain-card:nth-child(3) { transition-delay: 0.16s; }
.pain-grid .pain-card:nth-child(4) { transition-delay: 0.24s; }

/* --- Navbar при скролле --- */
.nav {
    transition: background 0.25s ease, border-color 0.25s ease, box-shadow 0.25s ease;
}

.nav-scrolled {
    background: rgba(13, 17, 23, 0.96);
    box-shadow: 0 4px 24px rgba(0, 0, 0, 0.4);
}

/* --- Активная ссылка в navbar --- */
.nav-links a.nav-link-active {
    color: var(--accent);
}

/* --- Бургер --- */
.nav-burger {
    display: none;
    flex-direction: column;
    justify-content: center;
    gap: 5px;
    width: 36px;
    height: 36px;
    padding: 6px;
    background: transparent;
    border: 1px solid var(--border);
    border-radius: 8px;
    cursor: pointer;
    transition: border-color 0.15s;
}

.nav-burger:hover {
    border-color: var(--border-hover);
}

.nav-burger span {
    display: block;
    height: 2px;
    width: 100%;
    background: var(--text);
    border-radius: 2px;
    transition: transform 0.25s ease, opacity 0.2s ease;
}

.nav-burger-open span:nth-child(1) {
    transform: translateY(7px) rotate(45deg);
}

.nav-burger-open span:nth-child(2) {
    opacity: 0;
}

.nav-burger-open span:nth-child(3) {
    transform: translateY(-7px) rotate(-45deg);
}

/* --- Мобильная версия navbar --- */
@media (max-width: 768px) {
    .nav-burger {
        display: flex;
    }

    .nav-links {
        position: fixed;
        top: 64px;
        left: 0;
        right: 0;
        flex-direction: column;
        align-items: stretch;
        gap: 0;
        background: rgba(13, 17, 23, 0.98);
        backdrop-filter: blur(16px);
        -webkit-backdrop-filter: blur(16px);
        border-bottom: 1px solid var(--border);
        padding: 16px 24px 24px;
        transform: translateY(-12px);
        opacity: 0;
        pointer-events: none;
        transition: opacity 0.2s ease, transform 0.25s ease;
    }

    .nav-links.nav-open {
        opacity: 1;
        transform: translateY(0);
        pointer-events: auto;
    }

    .nav-links a:not(.btn) {
        display: block;
        padding: 14px 0;
        font-size: 16px;
        border-bottom: 1px solid var(--border);
    }

    .nav-links .btn {
        margin-top: 16px;
        width: 100%;
    }
}

/* --- Плавность prefers-reduced-motion --- */
@media (prefers-reduced-motion: reduce) {
    .reveal,
    .reveal-active {
        transition: none;
        opacity: 1;
        transform: none;
    }

    html {
        scroll-behavior: auto;
    }
}