/* ==========================================
   ImgFree Undress — Main Stylesheet
   ========================================== */

/* --- CSS Variables --- */
:root {
    --bg-primary: #0A0A0F;
    --bg-secondary: #12121A;
    --bg-card: #1A1A2E;
    --bg-card-hover: #1F1F35;
    --border-color: #2A2A3E;
    --border-color-light: #3A3A52;
    
    --accent: #9333EA;
    --accent-light: #A855F7;
    --accent-lighter: #C084FC;
    --accent-glow: rgba(147, 51, 234, 0.3);
    --accent-gradient: linear-gradient(135deg, #9333EA, #C084FC);
    
    --text-primary: #F8F8FF;
    --text-secondary: #A0A0B8;
    --text-muted: #6B6B80;
    
    --radius-sm: 8px;
    --radius-md: 12px;
    --radius-lg: 16px;
    --radius-xl: 24px;
    
    --shadow-sm: 0 2px 8px rgba(0,0,0,0.3);
    --shadow-md: 0 4px 20px rgba(0,0,0,0.4);
    --shadow-lg: 0 8px 40px rgba(0,0,0,0.5);
    --shadow-glow: 0 0 30px var(--accent-glow);
    
    --font-main: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    --container-width: 1200px;
    --navbar-height: 72px;
}

/* --- Reset & Base --- */
*, *::before, *::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    scroll-padding-top: var(--navbar-height);
}

body {
    font-family: var(--font-main);
    background-color: var(--bg-primary);
    color: var(--text-primary);
    line-height: 1.6;
    font-size: 16px;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    overflow-x: hidden;
}

a {
    color: var(--accent-lighter);
    text-decoration: none;
    transition: color 0.2s;
}

a:hover {
    color: var(--accent-light);
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

ul {
    list-style: none;
}

.container {
    max-width: var(--container-width);
    margin: 0 auto;
    padding: 0 20px;
}

/* --- Utility Classes --- */
.text-accent {
    color: var(--accent-lighter);
}

.text-gradient {
    background: var(--accent-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.section__title {
    font-size: 2.25rem;
    font-weight: 800;
    text-align: center;
    margin-bottom: 16px;
    line-height: 1.2;
}

.section__subtitle {
    text-align: center;
    color: var(--text-secondary);
    font-size: 1.1rem;
    max-width: 700px;
    margin: 0 auto 48px;
}

/* --- Buttons --- */
.btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 20px;
    border-radius: var(--radius-sm);
    font-size: 0.95rem;
    font-weight: 600;
    cursor: pointer;
    border: none;
    transition: all 0.25s ease;
    text-decoration: none;
    white-space: nowrap;
}

.btn--primary {
    background: var(--accent-gradient);
    color: #fff;
    box-shadow: 0 4px 15px var(--accent-glow);
}

.btn--primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 25px var(--accent-glow);
    color: #fff;
}

/* Spin animation for loading buttons */
@keyframes spin {
    to { transform: rotate(360deg); }
}
.spin {
    animation: spin 0.9s linear infinite;
    display: inline-block;
    flex-shrink: 0;
}

.btn--primary:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    transform: none;
}

.btn--outline {
    background: transparent;
    color: var(--text-primary);
    border: 1px solid var(--border-color-light);
}

.btn--outline:hover {
    border-color: var(--accent);
    color: var(--accent-lighter);
    background: rgba(147, 51, 234, 0.1);
}

.btn--ghost {
    background: transparent;
    color: var(--text-secondary);
    border: 1px solid transparent;
}

.btn--ghost:hover {
    color: var(--text-primary);
    background: rgba(255,255,255,0.05);
}

.btn--lg {
    padding: 14px 28px;
    font-size: 1.05rem;
}

/* ==========================================
   NAVBAR
   ========================================== */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    height: var(--navbar-height);
    background: rgba(10, 10, 15, 0.85);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-bottom: 1px solid var(--border-color);
    z-index: 1000;
    transition: background 0.3s;
}

.navbar__container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 100%;
}

.navbar__logo {
    display: flex;
    align-items: center;
    gap: 10px;
    text-decoration: none;
    color: var(--text-primary);
}

.navbar__logo-text {
    font-size: 1.3rem;
    font-weight: 700;
    letter-spacing: -0.5px;
}

.navbar__nav {
    display: flex;
}

.navbar__list {
    display: flex;
    gap: 32px;
}

.navbar__link {
    color: var(--text-secondary);
    font-size: 0.95rem;
    font-weight: 500;
    transition: color 0.2s;
    position: relative;
}

.navbar__link:hover {
    color: var(--text-primary);
}

.navbar__link::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--accent-gradient);
    transition: width 0.3s;
    border-radius: 2px;
}

.navbar__link:hover::after {
    width: 100%;
}

.navbar__actions {
    display: flex;
    align-items: center;
    gap: 12px;
}

.navbar__burger {
    display: none;
    flex-direction: column;
    justify-content: center;
    gap: 5px;
    width: 32px;
    height: 32px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 4px;
}

.navbar__burger span {
    display: block;
    width: 100%;
    height: 2px;
    background: var(--text-primary);
    border-radius: 2px;
    transition: all 0.3s;
}

/* Активная ссылка в десктопном navbar */
.navbar__link--active {
    color: var(--accent-lighter) !important;
}
.navbar__link--active::after {
    width: 100% !important;
}

/* btn--ghost активное состояние (Блог) */
.btn--ghost--active {
    color: var(--accent-lighter) !important;
    background: rgba(147, 51, 234, 0.1) !important;
}

/* Telegram-кнопка в мобильном меню — скрыта на десктопе */
.navbar__tg-mobile {
    display: none;
}

/* Резервируем высоту под navbar до его инжекции — предотвращает flash layout shift */
#navbar-placeholder {
    display: block;
    height: var(--navbar-height);
}

/* ==========================================
   HERO
   ========================================== */
.hero {
    position: relative;
    padding: calc(var(--navbar-height) + 60px) 0 80px;
    overflow: hidden;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.hero__bg-glow {
    position: absolute;
    top: -200px;
    left: 50%;
    transform: translateX(-50%);
    width: 800px;
    height: 600px;
    background: radial-gradient(ellipse, var(--accent-glow) 0%, transparent 70%);
    pointer-events: none;
    opacity: 0.5;
}

.hero__container {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 60px;
    align-items: center;
}

.hero__badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 16px;
    background: rgba(147, 51, 234, 0.15);
    border: 1px solid rgba(147, 51, 234, 0.3);
    border-radius: 100px;
    font-size: 0.85rem;
    color: var(--accent-lighter);
    margin-bottom: 20px;
}

.hero__title {
    font-size: 3rem;
    font-weight: 800;
    line-height: 1.15;
    margin-bottom: 20px;
    letter-spacing: -1px;
}

.hero__subtitle {
    font-size: 1.1rem;
    color: var(--text-secondary);
    margin-bottom: 28px;
    line-height: 1.7;
}

.hero__subtitle strong {
    color: var(--accent-lighter);
}

.hero__stats {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 0;
    margin-bottom: 28px;
    padding: 20px 0;
    border-top: 1px solid var(--border-color);
    border-bottom: 1px solid var(--border-color);
}

.hero__stat {
    text-align: center;
    position: relative;
    padding: 4px 16px;
}

.hero__stat:not(:last-child)::after {
    content: '';
    position: absolute;
    right: 0;
    top: 50%;
    transform: translateY(-50%);
    height: 60%;
    width: 1px;
    background: var(--border-color);
}

.hero__stat-value {
    display: block;
    font-size: 2rem;
    font-weight: 800;
    background: linear-gradient(135deg, #38BDF8, #A855F7);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    line-height: 1.1;
    margin-bottom: 4px;
}

.hero__stat-label {
    font-size: 0.72rem;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.6px;
    line-height: 1.3;
}

.hero__pills {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px;
    margin-top: 4px;
}

.hero__pill {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 9px 14px;
    background: rgba(147, 51, 234, 0.08);
    border: 1px solid rgba(147, 51, 234, 0.18);
    border-radius: var(--radius-sm);
    font-size: 0.85rem;
    color: var(--text-secondary);
    transition: all 0.25s ease;
}

.hero__pill:hover {
    background: rgba(147, 51, 234, 0.14);
    border-color: rgba(147, 51, 234, 0.35);
    color: var(--text-primary);
}

.hero__pill strong {
    color: var(--text-primary);
    font-weight: 700;
}

.hero__pill-icon {
    font-size: 1rem;
    flex-shrink: 0;
    line-height: 1;
}

/* Upload Area */
.hero__upload-area {
    position: relative;
}

.hero__free-badge {
    position: absolute;
    top: -14px;
    right: 20px;
    background: var(--accent-gradient);
    color: #fff;
    padding: 6px 16px;
    border-radius: 100px;
    font-size: 0.85rem;
    font-weight: 700;
    z-index: 2;
    box-shadow: var(--shadow-glow);
}

.upload-box {
    background: var(--bg-card);
    border: 2px dashed var(--border-color-light);
    border-radius: var(--radius-lg);
    padding: 48px 40px;
    text-align: center;
    cursor: pointer;
    transition: all 0.3s;
    min-height: 400px;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 0 40px rgba(147, 51, 234, 0.08);
}

.upload-box:hover {
    border-color: var(--accent);
    background: var(--bg-card-hover);
}

.upload-box.dragging {
    border-color: var(--accent-light);
    background: rgba(147, 51, 234, 0.1);
}

.upload-box__icon {
    color: var(--accent-lighter);
    margin-bottom: 16px;
}

.upload-box__text {
    font-size: 1.15rem;
    font-weight: 600;
    margin-bottom: 8px;
}

.upload-box__subtext {
    color: var(--text-muted);
    font-size: 0.9rem;
    margin-bottom: 12px;
}

.upload-box__formats {
    color: var(--text-muted);
    font-size: 0.8rem;
    padding: 6px 14px;
    background: rgba(255,255,255,0.05);
    border-radius: 100px;
    display: inline-block;
}

.upload-box__preview {
    width: 100%;
    max-height: 400px;
    overflow: hidden;
    border-radius: var(--radius-md);
}

.upload-box__preview img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    max-height: 380px;
}

.hero__buttons {
    display: flex;
    gap: 10px;
    margin-top: 16px;
}

.hero__buttons .btn {
    flex: 1;
    justify-content: center;
    padding: 12px 16px;
    font-size: 0.9rem;
}

.hero__buttons .btn--outline:disabled {
    opacity: 0.4;
    cursor: not-allowed;
}

.hero__trust-line {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    margin-top: 16px;
    font-size: 0.8rem;
    color: var(--text-muted);
}

.hero__trust-line svg {
    color: var(--accent-lighter);
}

.hero__trust-dot {
    width: 3px;
    height: 3px;
    background: var(--text-muted);
    border-radius: 50%;
}



/* ==========================================
   EXAMPLES
   ========================================== */
.examples {
    padding: 100px 0;
}

.examples__grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 32px;
}

.example-card {
    text-align: center;
}

.example-card__caption {
    color: var(--text-muted);
    font-size: 0.9rem;
    margin-top: 12px;
}

.example-slider {
    position: relative;
    width: 100%;
    aspect-ratio: 1/1;
    border-radius: var(--radius-lg);
    overflow: hidden;
    cursor: default;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    touch-action: pan-y;
}

.example-slider__img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
}

.example-slider__img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.example-slider__img--before {
    z-index: 1;
    clip-path: inset(0 50% 0 0);
}

.example-slider__img--after {
    z-index: 0;
}

.example-slider__placeholder {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    font-weight: 700;
    color: var(--text-muted);
}

.example-slider__placeholder--before {
    background: linear-gradient(135deg, #1a1a2e 0%, #2a2a3e 100%);
}

.example-slider__placeholder--after {
    background: linear-gradient(135deg, #1e0a3e 0%, #2a1a4e 100%);
}

.example-slider__handle {
    position: absolute;
    top: 0;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 40px;
    z-index: 2;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    pointer-events: none;
}

.example-slider__line {
    width: 2px;
    flex: 1;
    background: rgba(255,255,255,0.6);
}

.example-slider__circle {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: var(--accent-gradient);
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    box-shadow: var(--shadow-glow);
    flex-shrink: 0;
    cursor: col-resize;
    pointer-events: auto;
    touch-action: none;
}

/* ==========================================
   SEO BLOCKS
   ========================================== */
.seo-block {
    padding: 100px 0;
}

.seo-block--alt {
    background: var(--bg-secondary);
    border-top: 1px solid var(--border-color);
    border-bottom: 1px solid var(--border-color);
}

.seo-block__grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 48px;
    margin-top: 40px;
}

.seo-block__text p {
    color: var(--text-secondary);
    font-size: 1rem;
    line-height: 1.8;
    margin-bottom: 16px;
}

.seo-block__text strong {
    color: var(--accent-lighter);
}

.seo-block__features {
    display: flex;
    flex-direction: column;
    gap: 24px;
}

.seo-feature {
    display: flex;
    gap: 16px;
    align-items: flex-start;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 20px;
    transition: all 0.3s;
}

.seo-feature:hover {
    border-color: var(--accent);
}

.seo-feature__icon {
    font-size: 1.8rem;
    flex-shrink: 0;
}

.seo-feature h3 {
    font-size: 1rem;
    font-weight: 700;
    margin-bottom: 4px;
}

.seo-feature p {
    color: var(--text-secondary);
    font-size: 0.9rem;
    line-height: 1.5;
}

.seo-block__columns {
    display: grid;
    grid-template-columns: 1fr;
    gap: 48px;
    margin-top: 40px;
}

.seo-block__col h3 {
    font-size: 1.2rem;
    font-weight: 700;
    margin-bottom: 16px;
    color: var(--text-primary);
}

.seo-block__col p {
    color: var(--text-secondary);
    font-size: 1rem;
    line-height: 1.8;
    margin-bottom: 16px;
}

/* ==========================================
   HOW IT WORKS
   ========================================== */
.how-it-works {
    padding: 100px 0;
    background: var(--bg-secondary);
    border-top: 1px solid var(--border-color);
    border-bottom: 1px solid var(--border-color);
}

.steps {
    display: flex;
    align-items: flex-start;
    justify-content: center;
    gap: 16px;
    margin-bottom: 48px;
}

.step {
    text-align: center;
    flex: 1;
    max-width: 280px;
}

.step__number {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: var(--accent-gradient);
    color: #fff;
    font-weight: 800;
    font-size: 1rem;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 16px;
}

.step__icon {
    color: var(--accent-lighter);
    margin-bottom: 16px;
}

.step__title {
    font-size: 1.1rem;
    font-weight: 700;
    margin-bottom: 8px;
}

.step__text {
    color: var(--text-secondary);
    font-size: 0.9rem;
    line-height: 1.6;
}

.step__connector {
    display: flex;
    align-items: center;
    padding-top: 50px;
    color: var(--border-color-light);
}

.how-it-works__cta {
    text-align: center;
}

/* ==========================================
   BLOG PREVIEW
   ========================================== */
.blog-preview {
    padding: 100px 0;
}

.blog-preview__grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 28px;
}

.blog-card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    overflow: hidden;
    transition: all 0.3s;
}

.blog-card:hover {
    border-color: var(--accent);
    transform: translateY(-4px);
    box-shadow: var(--shadow-md);
}

.blog-card__image {
    position: relative;
    height: 180px;
    background: linear-gradient(135deg, #1a1a2e, #2a1a4e);
    display: flex;
    align-items: center;
    justify-content: center;
}

.blog-card__placeholder {
    font-size: 3rem;
}

.blog-card__tag {
    position: absolute;
    top: 12px;
    left: 12px;
    background: var(--accent-gradient);
    color: #fff;
    padding: 4px 12px;
    border-radius: 100px;
    font-size: 0.75rem;
    font-weight: 700;
}

.blog-card__content {
    padding: 20px;
}

.blog-card__date {
    font-size: 0.8rem;
    color: var(--text-muted);
}

.blog-card__title {
    font-size: 1.05rem;
    font-weight: 700;
    margin: 8px 0 12px;
    line-height: 1.4;
}

.blog-card__title a {
    color: var(--text-primary);
}

.blog-card__title a:hover {
    color: var(--accent-lighter);
}

.blog-card__excerpt {
    color: var(--text-secondary);
    font-size: 0.9rem;
    line-height: 1.5;
    margin-bottom: 16px;
}

.blog-card__link {
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--accent-lighter);
}

.blog-preview__cta {
    text-align: center;
    margin-top: 40px;
}

/* ==========================================
   FAQ
   ========================================== */
.faq {
    padding: 100px 0;
}

.faq__list {
    max-width: 800px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.faq__item {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    overflow: hidden;
    transition: border-color 0.3s;
}

.faq__item[open] {
    border-color: var(--accent);
}

.faq__question {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 20px 24px;
    cursor: pointer;
    font-size: 1rem;
    font-weight: 600;
    list-style: none;
    transition: color 0.2s;
}

.faq__question::-webkit-details-marker {
    display: none;
}

.faq__question:hover {
    color: var(--accent-lighter);
}

.faq__arrow {
    flex-shrink: 0;
    transition: transform 0.3s;
    color: var(--text-muted);
}

.faq__item[open] .faq__arrow {
    transform: rotate(180deg);
    color: var(--accent-lighter);
}

.faq__answer {
    padding: 0 24px 20px;
}

.faq__answer p {
    color: var(--text-secondary);
    line-height: 1.7;
    font-size: 0.95rem;
}

/* ==========================================
   FOOTER
   ========================================== */
.footer {
    padding: 60px 0 30px;
    background: var(--bg-secondary);
    border-top: 1px solid var(--border-color);
}

.footer__grid {
    display: grid;
    grid-template-columns: 1.5fr 1fr 1fr 1fr;
    gap: 40px;
    margin-bottom: 40px;
}

.footer__logo {
    display: flex;
    align-items: center;
    gap: 10px;
    color: var(--text-primary);
    font-size: 1.2rem;
    font-weight: 700;
    margin-bottom: 12px;
}

.footer__desc {
    color: var(--text-secondary);
    font-size: 0.9rem;
    line-height: 1.6;
}

.footer__links h4 {
    font-size: 0.95rem;
    font-weight: 700;
    margin-bottom: 16px;
    color: var(--text-primary);
}

.footer__links ul {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.footer__links a {
    color: var(--text-secondary);
    font-size: 0.9rem;
    transition: color 0.2s;
}

.footer__links a:hover {
    color: var(--accent-lighter);
}

.footer__bottom {
    border-top: 1px solid var(--border-color);
    padding-top: 24px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 12px;
}

.footer__bottom p {
    color: var(--text-muted);
    font-size: 0.85rem;
}

.footer__disclaimer {
    font-size: 0.8rem !important;
    color: var(--text-muted);
}

/* ==========================================
   RESPONSIVE
   ========================================== */

/* Tablet */
@media (max-width: 1024px) {
    .hero__container {
        grid-template-columns: 1fr;
        gap: 40px;
    }
    .hero {
        min-height: auto;
        padding: calc(var(--navbar-height) + 40px) 0 60px;
    }
    .hero__title {
        font-size: 2.4rem;
    }
    .examples__grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 24px;
    }
    .seo-block__grid {
        grid-template-columns: 1fr;
    }
    .seo-block__columns {
        grid-template-columns: 1fr;
        gap: 32px;
    }
    .steps {
        flex-wrap: wrap;
        gap: 24px;
    }
    .step__connector {
        display: none;
    }
    .step {
        max-width: 100%;
        flex: 1 1 calc(33% - 24px);
    }
    .blog-preview__grid {
        grid-template-columns: repeat(2, 1fr);
    }
    .footer__grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* Mobile */
@media (max-width: 768px) {
    .section__title {
        font-size: 1.75rem;
    }
    .section__subtitle {
        font-size: 1rem;
        margin-bottom: 32px;
    }

    /* Navbar mobile */
    .navbar__nav {
        display: none;
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        height: calc(100vh - var(--navbar-height));
        background: var(--bg-primary);
        padding: 24px 20px 40px;
        z-index: 9999;
        flex-direction: column;
        gap: 16px;
        overflow-y: auto;
        border-top: 1px solid var(--border-color);
    }
    .navbar__nav.active {
        display: flex;
    }
    .navbar__list {
        flex-direction: column;
        gap: 4px;
    }
    .navbar__link {
        font-size: 1.05rem;
        display: block;
        padding: 13px 16px;
        border-radius: var(--radius-sm);
        transition: all 0.2s;
        color: var(--text-secondary);
    }
    .navbar__link:hover,
    .navbar__link:active {
        background: rgba(147, 51, 234, 0.1);
        color: var(--accent-lighter);
    }
    .navbar__link--active {
        color: var(--accent-lighter) !important;
        background: rgba(147, 51, 234, 0.1);
    }
    .navbar__link::after {
        display: none;
    }
    /* Telegram кнопка внутри мобильного меню */
    .navbar__tg-mobile {
        display: flex;
        align-items: center;
        gap: 10px;
        padding: 14px 16px;
        background: linear-gradient(135deg, #1a73e8 0%, #0d47a1 100%);
        border-radius: var(--radius-sm);
        color: #fff;
        font-size: 1rem;
        font-weight: 700;
        text-decoration: none;
        margin-top: 8px;
    }
    .navbar__tg-mobile:hover {
        color: #fff;
        filter: brightness(1.1);
    }
    /* Скрываем десктопные кнопки блог и TG в navbar__actions на мобилке */
    .navbar__actions .btn--ghost,
    .navbar__actions .btn--primary {
        display: none;
    }
    .navbar__burger {
        display: flex;
    }
    .navbar__burger.active span:nth-child(1) {
        transform: translateY(7px) rotate(45deg);
    }
    .navbar__burger.active span:nth-child(2) {
        opacity: 0;
    }
    .navbar__burger.active span:nth-child(3) {
        transform: translateY(-7px) rotate(-45deg);
    }

    /* Hero mobile */
    .hero__title {
        font-size: 2rem;
    }
    .hero__stats {
        padding: 16px 0;
    }
    .hero__stat-value {
        font-size: 1.5rem;
    }
    .hero__stat-label {
        font-size: 0.65rem;
    }
    .hero__buttons {
        flex-wrap: wrap;
    }
    .upload-box {
        min-height: 250px;
        padding: 24px;
    }

    /* Pills mobile */
    .hero__pills {
        grid-template-columns: 1fr 1fr;
        gap: 6px;
    }
    .hero__pill {
        padding: 8px 10px;
        font-size: 0.8rem;
    }

    /* Examples mobile */
    .examples {
        padding: 60px 0;
    }
    .examples__grid {
        grid-template-columns: 1fr;
        gap: 24px;
    }

    /* Steps mobile */
    .steps {
        flex-direction: column;
        align-items: center;
    }
    .step {
        max-width: 400px;
    }

    /* Blog mobile */
    .blog-preview {
        padding: 60px 0;
    }
    .blog-preview__grid {
        grid-template-columns: 1fr;
    }

    /* SEO mobile */
    .seo-block {
        padding: 60px 0;
    }

    /* FAQ mobile */
    .faq {
        padding: 60px 0;
    }
    .faq__question {
        padding: 16px 18px;
        font-size: 0.95rem;
    }

    /* Footer mobile */
    .footer__grid {
        grid-template-columns: 1fr;
        gap: 28px;
    }
    .footer__bottom {
        flex-direction: column;
        text-align: center;
    }

}

/* ==========================================
   PROCESSING OVERLAY
   ========================================== */

/* upload-box needs relative positioning for overlay */
.upload-box {
    position: relative;
}

.processing-overlay {
    position: absolute;
    top: 20px;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(8, 6, 18, 0.84);
    backdrop-filter: blur(3px);
    -webkit-backdrop-filter: blur(3px);
    border-radius: var(--radius-lg);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 20;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.35s ease;
}

.processing-overlay.is-active {
    opacity: 1;
    pointer-events: all;
}

.processing-overlay__content {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 20px;
    padding: 32px 24px;
    text-align: center;
}

/* ---- Circular progress ring ---- */
/* r=56 → circumference = 2 * π * 56 ≈ 351.86 */
.progress-ring-wrap {
    position: relative;
    width: 128px;
    height: 128px;
    flex-shrink: 0;
}

.progress-ring {
    transform: rotate(-90deg);
    display: block;
}

.progress-ring__bg {
    fill: none;
    stroke: rgba(147, 51, 234, 0.18);
    stroke-width: 7;
}

.progress-ring__fill {
    fill: none;
    stroke: url(#progressGradient);
    stroke-width: 7;
    stroke-linecap: round;
    stroke-dasharray: 351.86;
    stroke-dashoffset: 351.86;
    transition: stroke-dashoffset 0.25s linear;
    filter: drop-shadow(0 0 6px rgba(147, 51, 234, 0.6));
}

.progress-ring__center {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
}

.progress-ring__percent {
    font-size: 26px;
    font-weight: 800;
    color: #f8f8ff;
    letter-spacing: -1px;
    line-height: 1;
    font-variant-numeric: tabular-nums;
}

/* ---- Status text ---- */
.processing-overlay__text {
    font-size: 14px;
    font-weight: 500;
    color: rgba(192, 132, 252, 0.95);
    text-align: center;
    min-height: 22px;
    max-width: 220px;
    line-height: 1.5;
    transition: opacity 0.3s ease;
}

.processing-overlay__text.fading {
    opacity: 0;
}

/* ---- Error overlay ---- */
.processing-overlay--error .processing-overlay__content {
    gap: 12px;
}

.processing-overlay__error-icon {
    color: #fca5a5;
    margin-bottom: 4px;
    filter: drop-shadow(0 0 8px rgba(252, 165, 165, 0.4));
}

.processing-overlay__error-title {
    font-size: 17px;
    font-weight: 700;
    color: #f1f5f9;
    margin: 0;
}

.processing-overlay__error-text {
    font-size: 13px;
    color: #94a3b8;
    line-height: 1.6;
    max-width: 240px;
    margin: 0;
}

.processing-overlay__error-actions {
    display: flex;
    flex-direction: column;
    gap: 8px;
    width: 100%;
    max-width: 220px;
    margin-top: 4px;
}

.processing-overlay__error-actions .btn {
    width: 100%;
    justify-content: center;
    font-size: 13px;
    padding: 9px 16px;
}

/* ==========================================
   TELEGRAM CTA BUTTON (below action buttons)
   ========================================== */
.tg-cta-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    width: 100%;
    padding: 12px 20px;
    margin-top: 10px;
    background: linear-gradient(135deg, #1a73e8 0%, #0d47a1 100%);
    border: 1px solid rgba(29, 155, 240, 0.35);
    border-radius: var(--radius-sm);
    color: #fff;
    font-size: 0.9rem;
    font-weight: 600;
    text-decoration: none;
    transition: all 0.25s ease;
    position: relative;
    overflow: hidden;
}

.tg-cta-btn::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, #1d9bf0 0%, #1a73e8 100%);
    opacity: 0;
    transition: opacity 0.25s;
}

.tg-cta-btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 20px rgba(29, 155, 240, 0.35);
    color: #fff;
}

.tg-cta-btn:hover::before {
    opacity: 1;
}

.tg-cta-btn svg,
.tg-cta-btn span:not(.tg-cta-btn__badge) {
    position: relative;
    z-index: 1;
}

.tg-cta-btn__badge {
    position: relative;
    z-index: 1;
    padding: 2px 8px;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 100px;
    font-size: 0.75rem;
    font-weight: 700;
    letter-spacing: 0.3px;
    margin-left: auto;
}

/* ==========================================
   TELEGRAM UPSELL MODAL
   ========================================== */
.tg-modal-backdrop {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.72);
    backdrop-filter: blur(6px);
    -webkit-backdrop-filter: blur(6px);
    z-index: 2000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 16px;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease;
}

.tg-modal-backdrop.is-open {
    opacity: 1;
    pointer-events: all;
}

.tg-modal {
    background: var(--bg-card);
    border: 1px solid rgba(147, 51, 234, 0.25);
    border-radius: var(--radius-xl);
    padding: 32px 28px 28px;
    width: 100%;
    max-width: 460px;
    max-height: 90vh;
    overflow-y: auto;
    position: relative;
    box-shadow: 0 24px 80px rgba(0, 0, 0, 0.6), 0 0 0 1px rgba(147, 51, 234, 0.1);
    transform: translateY(16px) scale(0.97);
    transition: transform 0.3s ease;
}

.tg-modal-backdrop.is-open .tg-modal {
    transform: translateY(0) scale(1);
}

/* Close button */
.tg-modal__close {
    position: absolute;
    top: 16px;
    right: 16px;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: rgba(255,255,255,0.06);
    border: 1px solid rgba(255,255,255,0.1);
    color: var(--text-muted);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s;
}

.tg-modal__close:hover {
    background: rgba(255,255,255,0.12);
    color: var(--text-primary);
}

/* Header */
.tg-modal__header {
    text-align: center;
    margin-bottom: 24px;
}

.tg-modal__emoji {
    font-size: 2.8rem;
    line-height: 1;
    margin-bottom: 12px;
    display: block;
}

.tg-modal__title {
    font-size: 1.5rem;
    font-weight: 800;
    line-height: 1.25;
    margin-bottom: 10px;
    color: var(--text-primary);
    letter-spacing: -0.5px;
}

.tg-modal__subtitle {
    font-size: 0.9rem;
    color: var(--text-secondary);
    line-height: 1.6;
    max-width: 360px;
    margin: 0 auto;
}

/* Features */
.tg-modal__features {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-bottom: 24px;
}

.tg-modal__feature {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    padding: 12px 14px;
    background: rgba(147, 51, 234, 0.07);
    border: 1px solid rgba(147, 51, 234, 0.14);
    border-radius: var(--radius-md);
    transition: border-color 0.2s;
}

.tg-modal__feature:hover {
    border-color: rgba(147, 51, 234, 0.3);
}

.tg-modal__feature-icon {
    font-size: 1.4rem;
    line-height: 1;
    flex-shrink: 0;
    margin-top: 1px;
}

.tg-modal__feature div {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.tg-modal__feature strong {
    font-size: 0.9rem;
    font-weight: 700;
    color: var(--text-primary);
}

.tg-modal__feature span {
    font-size: 0.8rem;
    color: var(--text-secondary);
    line-height: 1.4;
}

/* Modes (inside feature) */
.tg-modal__modes {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-top: 6px;
}

.tg-modal__mode {
    padding: 3px 10px;
    background: rgba(147, 51, 234, 0.15);
    border: 1px solid rgba(147, 51, 234, 0.25);
    border-radius: 100px;
    font-size: 0.75rem;
    font-weight: 600;
    color: var(--accent-lighter);
}

/* CTA button */
.tg-modal__cta {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    width: 100%;
    padding: 15px 24px;
    background: linear-gradient(135deg, #1d9bf0 0%, #0d47a1 100%);
    color: #fff;
    border-radius: var(--radius-md);
    font-size: 1rem;
    font-weight: 700;
    text-decoration: none;
    transition: all 0.25s ease;
    box-shadow: 0 4px 20px rgba(29, 155, 240, 0.35);
    margin-bottom: 12px;
}

.tg-modal__cta:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 32px rgba(29, 155, 240, 0.5);
    color: #fff;
    filter: brightness(1.05);
}

/* Skip link */
.tg-modal__skip {
    display: block;
    width: 100%;
    text-align: center;
    padding: 8px;
    background: none;
    border: none;
    color: var(--text-muted);
    font-size: 0.82rem;
    cursor: pointer;
    transition: color 0.2s;
    text-decoration: underline;
    text-underline-offset: 2px;
}

.tg-modal__skip:hover {
    color: var(--text-secondary);
}

/* Mobile modal */
@media (max-width: 480px) {
    .tg-modal {
        padding: 24px 20px 20px;
        border-radius: var(--radius-lg);
    }
    .tg-modal__title {
        font-size: 1.3rem;
    }
    .tg-modal__emoji {
        font-size: 2.2rem;
    }
    .tg-modal__cta {
        font-size: 0.95rem;
        padding: 14px 20px;
    }
}

/* ==========================================
   USAGE COUNTER
   ========================================== */
.usage-counter {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 14px;
    margin-top: 12px;
    background: rgba(147, 51, 234, 0.07);
    border: 1px solid rgba(147, 51, 234, 0.18);
    border-radius: var(--radius-sm);
    transition: all 0.3s ease;
}

.usage-counter--exhausted {
    background: rgba(239, 68, 68, 0.08);
    border-color: rgba(239, 68, 68, 0.25);
}

/* 5 dot indicators */
.usage-counter__dots {
    display: flex;
    gap: 5px;
    flex-shrink: 0;
}

.usage-counter__dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--accent);
    transition: all 0.3s ease;
    box-shadow: 0 0 5px rgba(147, 51, 234, 0.5);
}

.usage-counter__dot.used {
    background: rgba(100, 100, 120, 0.35);
    box-shadow: none;
}

.usage-counter--exhausted .usage-counter__dot {
    background: rgba(239, 68, 68, 0.4);
    box-shadow: none;
}

.usage-counter__text {
    font-size: 12.5px;
    color: var(--text-secondary);
    margin: 0;
    line-height: 1.4;
    flex: 1;
}

.usage-counter__text a {
    color: var(--accent-lighter);
    font-weight: 600;
}

.usage-counter--exhausted .usage-counter__text {
    color: #fca5a5;
}

/* Small mobile */
@media (max-width: 480px) {
    .hero__title {
        font-size: 1.65rem;
    }
    .hero__stat {
        padding: 4px 8px;
    }
    .hero__stat-value {
        font-size: 1.3rem;
    }
    .hero__stat-label {
        font-size: 0.6rem;
        letter-spacing: 0.3px;
    }
    .hero__trust-line {
        flex-wrap: wrap;
        justify-content: center;
    }

    /* Telegram CTA button — small screens */
    .tg-cta-btn {
        padding: 11px 14px;
        gap: 8px;
        font-size: 0.85rem;
    }
    .tg-cta-btn__badge {
        font-size: 0.7rem;
        padding: 2px 6px;
        flex-shrink: 0;
    }
}

/* ==========================================
   AGE VERIFICATION GATE (18+)
   ========================================== */
.age-gate {
    position: fixed;
    inset: 0;
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    background: rgba(5, 5, 10, 0.93);
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
    animation: ageGateFadeIn 0.3s ease both;
}

.age-gate--closing {
    animation: ageGateFadeOut 0.4s ease both;
}

@keyframes ageGateFadeIn {
    from { opacity: 0; }
    to   { opacity: 1; }
}

@keyframes ageGateFadeOut {
    from { opacity: 1; }
    to   { opacity: 0; }
}

.age-gate__card {
    background: linear-gradient(145deg, #13131f, #0e0e1a);
    border: 1px solid rgba(147, 51, 234, 0.28);
    border-radius: 20px;
    padding: 44px 36px 36px;
    max-width: 440px;
    width: 100%;
    text-align: center;
    box-shadow:
        0 0 0 1px rgba(147, 51, 234, 0.1),
        0 24px 60px rgba(0, 0, 0, 0.65),
        0 0 80px rgba(147, 51, 234, 0.07);
    animation: ageGateSlideUp 0.35s cubic-bezier(0.34, 1.56, 0.64, 1) both;
}

@keyframes ageGateSlideUp {
    from { transform: translateY(28px) scale(0.95); opacity: 0; }
    to   { transform: translateY(0) scale(1); opacity: 1; }
}

.age-gate--closing .age-gate__card {
    animation: ageGateSlideDown 0.35s ease both;
}

@keyframes ageGateSlideDown {
    from { transform: translateY(0) scale(1); opacity: 1; }
    to   { transform: translateY(16px) scale(0.96); opacity: 0; }
}

.age-gate__badge {
    width: 72px;
    height: 72px;
    border-radius: 50%;
    background: var(--accent-gradient);
    color: #fff;
    font-size: 1.35rem;
    font-weight: 800;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 24px;
    box-shadow: 0 0 32px rgba(147, 51, 234, 0.5);
    letter-spacing: 0.5px;
}

.age-gate__title {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 14px;
    line-height: 1.3;
}

.age-gate__desc {
    color: var(--text-secondary);
    font-size: 0.95rem;
    line-height: 1.65;
    margin-bottom: 28px;
}

.age-gate__actions {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin-bottom: 16px;
}

.age-gate__btn {
    display: block;
    width: 100%;
    padding: 15px 24px;
    border-radius: var(--radius-md);
    font-size: 1rem;
    font-weight: 700;
    cursor: pointer;
    border: none;
    transition: transform 0.15s ease, box-shadow 0.15s ease, opacity 0.15s ease, background 0.2s ease;
    letter-spacing: 0.2px;
    font-family: var(--font-main);
}

.age-gate__btn:active {
    transform: scale(0.98);
}

.age-gate__btn--yes {
    background: var(--accent-gradient);
    color: #fff;
    box-shadow: 0 4px 20px rgba(147, 51, 234, 0.4);
}

.age-gate__btn--yes:hover {
    opacity: 0.9;
    box-shadow: 0 6px 28px rgba(147, 51, 234, 0.58);
    transform: translateY(-1px);
}

.age-gate__btn--no {
    background: rgba(255, 255, 255, 0.06);
    color: var(--text-secondary);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.age-gate__btn--no:hover {
    background: rgba(255, 255, 255, 0.1);
    color: var(--text-primary);
}

.age-gate__note {
    font-size: 0.78rem;
    color: var(--text-muted);
    line-height: 1.5;
}

@media (max-width: 480px) {
    .age-gate__card {
        padding: 36px 22px 28px;
        border-radius: 16px;
    }
    .age-gate__badge {
        width: 60px;
        height: 60px;
        font-size: 1.15rem;
        margin-bottom: 18px;
    }
    .age-gate__title {
        font-size: 1.25rem;
    }
    .age-gate__desc {
        font-size: 0.88rem;
    }
    .age-gate__btn {
        padding: 14px 20px;
        font-size: 0.95rem;
    }
}

