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

:root {
    --telegram-blue: #0088cc;
    --telegram-light-blue: #37aee2;
    --telegram-dark: #1d2733;
    --telegram-darker: #17212b;
    --telegram-light: #ffffff;
    --telegram-gray: #8e99a3;
    --telegram-green: #24b455;
    --vk-blue: #4c75a3;
    --youtube-red: #ff0000;
    --rutube-orange: #f68423;
}

body {
    font-family: 'Segoe UI', system-ui, -apple-system, sans-serif;
    background: var(--telegram-darker);
    color: var(--telegram-light);
    font-size: 16px;
    line-height: 1.6;
    overflow-x: hidden;
    -webkit-text-size-adjust: 100%;
}

.container {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* ============================================================
   Header
   ============================================================ */
header {
    padding: 24px 0;
    position: fixed;
    width: 100%;
    top: 0;
    z-index: 1000;
    background: rgba(23, 33, 43, 0.95);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid rgba(0, 136, 204, 0.2);
    transition: background 0.3s ease, box-shadow 0.3s ease;
}

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

.logo {
    display: flex;
    align-items: center;
    gap: 12px;
    text-decoration: none;
}

.logo-icon {
    background: var(--telegram-blue);
    padding: 8px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.logo-icon i {
    font-size: 24px;
    color: white;
}

.logo-text {
    font-size: 20px;
    font-weight: 700;
    color: white;
}

/* ============================================================
   Desktop Navigation
   ============================================================ */
.nav-desktop {
    display: flex;
    align-items: center;
    gap: 4px;
}

.nav-link {
    color: var(--telegram-gray);
    text-decoration: none;
    font-size: 15px;
    font-weight: 500;
    padding: 8px 14px;
    border-radius: 8px;
    transition: color 0.2s ease, background 0.2s ease;
    white-space: nowrap;
}

.nav-link:hover {
    color: white;
    background: rgba(255, 255, 255, 0.08);
}

.nav-link--active {
    color: white;
    background: rgba(0, 136, 204, 0.15);
}

.nav-ext-icon {
    font-size: 10px;
    vertical-align: middle;
    margin-left: 2px;
    opacity: 0.7;
}

/* ============================================================
   Header actions group
   ============================================================ */
.header-actions {
    display: flex;
    align-items: center;
    gap: 12px;
}

.github-btn {
    display: flex;
    align-items: center;
    gap: 8px;
    background: rgba(255, 255, 255, 0.1);
    color: white;
    padding: 10px 18px;
    border-radius: 8px;
    text-decoration: none;
    font-weight: 500;
    font-size: 15px;
    border: 1px solid rgba(255, 255, 255, 0.2);
    transition: all 0.3s ease;
    white-space: nowrap;
}

.github-btn:hover {
    background: rgba(255, 255, 255, 0.2);
    transform: translateY(-2px);
}

/* ============================================================
   Burger button
   ============================================================ */
.burger-btn {
    display: none;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 5px;
    width: 40px;
    height: 40px;
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.15);
    border-radius: 8px;
    cursor: pointer;
    padding: 8px;
    transition: background 0.2s ease;
    flex-shrink: 0;
}

.burger-btn:hover {
    background: rgba(255, 255, 255, 0.15);
}

.burger-line {
    display: block;
    width: 20px;
    height: 2px;
    background: white;
    border-radius: 2px;
    transition: transform 0.3s ease, opacity 0.3s ease;
    transform-origin: center;
}

/* Burger → X animation */
.burger-btn.is-open .burger-line:nth-child(1) {
    transform: translateY(7px) rotate(45deg);
}
.burger-btn.is-open .burger-line:nth-child(2) {
    opacity: 0;
    transform: scaleX(0);
}
.burger-btn.is-open .burger-line:nth-child(3) {
    transform: translateY(-7px) rotate(-45deg);
}

/* ============================================================
   Mobile menu overlay
   ============================================================ */
.mobile-menu {
    display: none; /* hidden on desktop */
    position: fixed;
    inset: 0;
    z-index: 999;
    background: rgba(23, 33, 43, 0.98);
    backdrop-filter: blur(12px);
    flex-direction: column;
    justify-content: center;
    align-items: center;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease;
}

.mobile-menu.is-open {
    opacity: 1;
    pointer-events: auto;
}

.mobile-menu nav {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    width: 100%;
    max-width: 320px;
    padding: 0 24px;
}

.mobile-nav-link {
    display: block;
    width: 100%;
    text-align: center;
    color: white;
    text-decoration: none;
    font-size: 20px;
    font-weight: 600;
    padding: 16px 24px;
    border-radius: 12px;
    border: 1px solid rgba(255, 255, 255, 0.08);
    transition: background 0.2s ease, border-color 0.2s ease, transform 0.2s ease;
    opacity: 0;
    transform: translateY(16px);
    transition: opacity 0.3s ease, transform 0.3s ease, background 0.2s ease;
}

.mobile-menu.is-open .mobile-nav-link {
    opacity: 1;
    transform: translateY(0);
}

/* stagger children */
.mobile-menu.is-open .mobile-nav-link:nth-child(1) { transition-delay: 0.05s; }
.mobile-menu.is-open .mobile-nav-link:nth-child(2) { transition-delay: 0.10s; }
.mobile-menu.is-open .mobile-nav-link:nth-child(3) { transition-delay: 0.15s; }
.mobile-menu.is-open .mobile-nav-link:nth-child(4) { transition-delay: 0.20s; }
.mobile-menu.is-open .mobile-nav-link:nth-child(5) { transition-delay: 0.25s; }
.mobile-menu.is-open .mobile-nav-link:nth-child(6) { transition-delay: 0.30s; }

.mobile-nav-link:hover {
    background: rgba(255, 255, 255, 0.08);
    border-color: rgba(0, 136, 204, 0.4);
}

.mobile-nav-link--active {
    color: var(--telegram-light-blue);
    border-color: rgba(0, 136, 204, 0.3);
}

.mobile-nav-link--github {
    background: rgba(255, 255, 255, 0.06);
    margin-top: 16px;
    font-size: 17px;
}

/* ============================================================
   Hero Section
   ============================================================ */
.hero {
    padding: 160px 0 80px;
    text-align: center;
    background: var(--telegram-dark);
}

.badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: rgba(0, 136, 204, 0.2);
    color: #37aee2;
    padding: 8px 16px;
    border-radius: 50px;
    font-size: 14px;
    font-weight: 500;
    border: 1px solid rgba(0, 136, 204, 0.3);
    margin-bottom: 24px;
}

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

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

.hero h1 {
    font-size: 3.5rem;
    font-weight: 800;
    margin-bottom: 24px;
    line-height: 1.2;
}

.hero-title-telegram {
    color: var(--telegram-light-blue);
}

.hero p {
    font-size: 1.25rem;
    color: var(--telegram-gray);
    max-width: 700px;
    margin: 0 auto 40px;
    line-height: 1.7;
}

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

/* ============================================================
   Buttons
   ============================================================ */
.btn {
    padding: 16px 32px;
    border-radius: 12px;
    font-weight: 600;
    font-size: 16px;
    text-decoration: none;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.btn-primary {
    background: var(--telegram-blue);
    color: white;
    box-shadow: 0 10px 25px rgba(0, 136, 204, 0.3);
}

.btn-primary:hover {
    background: var(--telegram-light-blue);
    transform: translateY(-3px);
    box-shadow: 0 15px 35px rgba(0, 136, 204, 0.4);
}

.btn-secondary {
    background: rgba(255, 255, 255, 0.1);
    color: white;
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.btn-secondary:hover {
    background: rgba(255, 255, 255, 0.2);
}

.btn-github {
    background: white;
    color: var(--telegram-darker);
}

.btn-github:hover {
    transform: translateY(-3px);
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.2);
}

.btn-issue {
    background: transparent;
    border: 2px solid white;
    color: white;
}

.btn-issue:hover {
    background: rgba(255, 255, 255, 0.1);
}

/* ============================================================
   Stats
   ============================================================ */
.stats {
    display: flex;
    justify-content: center;
    gap: 40px;
    margin-bottom: 60px;
    flex-wrap: wrap;
}

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

.stat-icon {
    font-size: 24px;
    color: var(--telegram-blue);
    margin-bottom: 12px;
}

.stat-value {
    font-size: 2rem;
    font-weight: 700;
    margin-bottom: 4px;
}

.stat-label {
    color: var(--telegram-gray);
    font-size: 0.9rem;
}

/* ============================================================
   Video
   ============================================================ */
.video-section {
    max-width: 800px;
    margin: 0 auto 60px;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
    position: relative;
}

.video-wrapper {
    position: relative;
    padding-bottom: 56.25%; /* 16:9 */
    height: 0;
    overflow: hidden;
}

.video-wrapper iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border: none;
}

/* ============================================================
   About Section
   ============================================================ */
.about {
    padding: 100px 0;
    background: var(--telegram-dark);
}

.about-content {
    max-width: 800px;
    margin: 0 auto;
    text-align: center;
}

.about h2 {
    font-size: 2.5rem;
    font-weight: 800;
    margin-bottom: 30px;
    color: var(--telegram-light-blue);
}

.about p {
    font-size: 1.25rem;
    color: var(--telegram-gray);
    margin-bottom: 25px;
    line-height: 1.8;
}

.vision {
    background: rgba(0, 136, 204, 0.1);
    border-radius: 16px;
    padding: 30px;
    margin: 40px 0;
    border: 1px solid rgba(0, 136, 204, 0.2);
}

.vision p {
    font-style: italic;
    font-size: 1.3rem;
    color: var(--telegram-light);
    margin: 0;
}

/* ============================================================
   Features Section
   ============================================================ */
.section {
    padding: 100px 0;
}

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

.section-title {
    font-size: 2.5rem;
    font-weight: 800;
    margin-bottom: 16px;
}

.section-subtitle {
    font-size: 1.25rem;
    color: var(--telegram-gray);
    max-width: 600px;
    margin: 0 auto;
}

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

.feature-card {
    background: var(--telegram-dark);
    border-radius: 16px;
    padding: 32px 24px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    transition: all 0.3s ease;
    cursor: default;
}

.feature-card:hover {
    border-color: rgba(0, 136, 204, 0.5);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
}

.feature-icon {
    font-size: 32px;
    color: var(--telegram-blue);
    margin-bottom: 20px;
}

.feature-title {
    font-size: 1.5rem;
    font-weight: 700;
    margin-bottom: 12px;
}

.feature-description {
    color: var(--telegram-gray);
    line-height: 1.7;
}

/* ============================================================
   How it Works Section
   ============================================================ */
.how-it-works {
    background: var(--telegram-darker);
}

.steps {
    display: flex;
    flex-direction: column;
    gap: 40px;
    max-width: 800px;
    margin: 0 auto;
}

.step {
    display: flex;
    gap: 30px;
    align-items: flex-start;
    opacity: 0;
    transform: translateX(-20px);
    transition: opacity 0.5s ease, transform 0.5s ease;
}

.step.visible {
    opacity: 1;
    transform: translateX(0);
}

.step-number {
    background: var(--telegram-blue);
    width: 50px;
    height: 50px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    font-weight: 700;
    flex-shrink: 0;
}

.step-content {
    min-width: 0;
    overflow: hidden;
    flex: 1;
}

.step-content h3 {
    font-size: 1.5rem;
    margin-bottom: 12px;
    color: var(--telegram-light-blue);
}

.step-content p {
    color: var(--telegram-gray);
    line-height: 1.7;
}

/* ============================================================
   Installation Section
   ============================================================ */
.installation {
    background: var(--telegram-dark);
}

.docs-link {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    color: var(--telegram-blue);
    text-decoration: none;
    font-weight: 500;
}

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

.video-buttons {
    display: flex;
    gap: 16px;
    justify-content: center;
    flex-wrap: wrap;
    margin-top: 30px;
}

.btn-video {
    padding: 14px 24px;
    border-radius: 12px;
    font-weight: 600;
    font-size: 16px;
    text-decoration: none;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.btn-rutube {
    background: var(--rutube-orange);
    color: white;
}

.btn-youtube {
    background: var(--youtube-red);
    color: white;
}

.btn-vk {
    background: var(--vk-blue);
    color: white;
}

.btn-video:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.3);
}

/* ============================================================
   Community Section
   ============================================================ */
.community {
    background: rgba(0, 136, 204, 0.1);
    border-radius: 24px;
    padding: 80px 40px;
    text-align: center;
    margin: 60px 0;
}

.community h2 {
    font-size: 2.5rem;
    font-weight: 800;
    margin-bottom: 20px;
}

.community p {
    font-size: 1.25rem;
    color: var(--telegram-gray);
    max-width: 600px;
    margin: 0 auto 40px;
}

.btn-community {
    background: var(--telegram-blue);
    color: white;
    padding: 16px 32px;
    border-radius: 12px;
    font-weight: 600;
    font-size: 16px;
    text-decoration: none;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.btn-community:hover {
    background: var(--telegram-light-blue);
    transform: translateY(-3px);
    box-shadow: 0 15px 35px rgba(0, 136, 204, 0.4);
}

/* ============================================================
   CTA Section
   ============================================================ */
.cta {
    background: rgba(0, 136, 204, 0.1);
    border-radius: 24px;
    padding: 80px 40px;
    text-align: center;
    margin: 60px 0;
}

.cta h2 {
    font-size: 2.5rem;
    font-weight: 800;
    margin-bottom: 20px;
}

.cta p {
    font-size: 1.25rem;
    color: var(--telegram-gray);
    max-width: 600px;
    margin: 0 auto 40px;
}

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

/* ============================================================
   Footer
   ============================================================ */
footer {
    padding: 60px 0 40px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    background: var(--telegram-darker);
}

.footer-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 30px;
    margin-bottom: 40px;
}

.footer-logo {
    display: flex;
    align-items: center;
    gap: 12px;
    text-decoration: none;
}

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

.footer-link {
    color: var(--telegram-gray);
    font-size: 24px;
    transition: color 0.3s ease;
}

.footer-link:hover {
    color: white;
}

.copyright {
    text-align: center;
    color: var(--telegram-gray);
    padding-top: 40px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

/* ============================================================
   Scroll-to-top button
   ============================================================ */
.scroll-top {
    position: fixed;
    bottom: 32px;
    right: 32px;
    width: 44px;
    height: 44px;
    background: var(--telegram-blue);
    color: white;
    border: none;
    border-radius: 50%;
    font-size: 18px;
    cursor: pointer;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease, transform 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 999;
}

.scroll-top.visible {
    opacity: 1;
    pointer-events: auto;
}

.scroll-top:hover {
    transform: translateY(-3px);
    background: var(--telegram-light-blue);
}

/* ============================================================
   Responsive
   ============================================================ */
@media (max-width: 768px) {
    /* Hide desktop nav, show burger */
    .nav-desktop {
        display: none;
    }

    .burger-btn {
        display: flex;
    }

    .mobile-menu {
        display: flex;
    }

    /* body lock when menu is open */
    body.menu-open {
        overflow: hidden;
    }

    .hero h1 {
        font-size: 2rem;
    }

    .hero p {
        font-size: 1rem;
    }

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

    .stats {
        gap: 20px;
    }

    .stat-value {
        font-size: 1.25rem;
    }

    .section-title {
        font-size: 1.75rem;
    }

    .section-subtitle {
        font-size: 1rem;
    }

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

    .step .code-block {
        text-align: left;
    }

    .step .step-note {
        text-align: left;
    }

    .faq-item {
        text-align: left;
    }

    .step-number {
        margin: auto;
    }

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

    .footer-links {
        justify-content: center;
    }

    /* Hide GitHub button on mobile — it's in the burger menu */
    .github-btn {
        display: none;
    }

    .feature-card {
        display: flex;
        flex-direction: column;
        align-items: center;
        text-align: center;
    }

    .video-buttons {
        flex-direction: column;
    }

    a.btn-video {
        display: block;
        text-align: center;
    }

    .cta-buttons {
        flex-direction: column;
    }

    a.btn {
        display: block;
        text-align: center;
    }
}

/* ============================================================
   Page Hero (inner pages — features, install, about)
   ============================================================ */
.page-hero {
    padding: 160px 0 80px;
    text-align: center;
    background: var(--telegram-dark);
}

.page-hero h1 {
    font-size: 3rem;
    font-weight: 800;
    margin-bottom: 24px;
    line-height: 1.2;
}

.page-hero p {
    font-size: 1.25rem;
    color: var(--telegram-gray);
    max-width: 700px;
    margin: 0 auto 40px;
    line-height: 1.7;
}

.page-hero .badge {
    margin-bottom: 24px;
}

.page-hero .hero-buttons {
    margin-bottom: 0;
}

/* ============================================================
   Feature Detail Sections (features.html)
   ============================================================ */
.feature-detail-section {
    background: var(--telegram-darker);
}

.feature-detail-section--alt {
    background: var(--telegram-dark);
}

.feature-detail {
    display: grid;
    grid-template-columns: 120px 1fr;
    gap: 60px;
    align-items: start;
    max-width: 900px;
    margin: 0 auto;
}

.feature-detail--reverse {
    grid-template-columns: 1fr 120px;
}

.feature-detail--reverse .feature-detail-icon {
    order: 2;
}

.feature-detail--reverse .feature-detail-content {
    order: 1;
}

.feature-detail-icon {
    width: 100px;
    height: 100px;
    background: rgba(0, 136, 204, 0.15);
    border: 2px solid rgba(0, 136, 204, 0.3);
    border-radius: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 42px;
    color: var(--telegram-blue);
    flex-shrink: 0;
    margin-top: 8px;
}

.feature-detail-icon--vk {
    background: rgba(76, 117, 163, 0.15);
    border-color: rgba(76, 117, 163, 0.3);
    color: var(--vk-blue);
}

.feature-detail-icon--green {
    background: rgba(36, 180, 85, 0.15);
    border-color: rgba(36, 180, 85, 0.3);
    color: var(--telegram-green);
}

.feature-detail-icon--orange {
    background: rgba(246, 132, 35, 0.15);
    border-color: rgba(246, 132, 35, 0.3);
    color: var(--rutube-orange);
}

.feature-detail-icon--red {
    background: rgba(255, 0, 0, 0.1);
    border-color: rgba(255, 0, 0, 0.2);
    color: #e05555;
}

.feature-detail-content h2 {
    font-size: 2rem;
    font-weight: 800;
    margin-bottom: 16px;
    color: var(--telegram-light);
}

.feature-detail-lead {
    font-size: 1.1rem;
    color: var(--telegram-gray);
    line-height: 1.7;
    margin-bottom: 24px;
}

.feature-list {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.feature-list li {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    color: var(--telegram-gray);
    line-height: 1.6;
    font-size: 0.95rem;
}

.feature-list li i {
    color: var(--telegram-green);
    font-size: 14px;
    margin-top: 4px;
    flex-shrink: 0;
}

/* ============================================================
   Prerequisites (install.html)
   ============================================================ */
.prereq-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 24px;
}

.prereq-card {
    background: var(--telegram-dark);
    border-radius: 16px;
    padding: 28px 24px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    transition: border-color 0.3s ease, box-shadow 0.3s ease;
}

.prereq-card:hover {
    border-color: rgba(0, 136, 204, 0.4);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
}

.prereq-icon {
    font-size: 32px;
    color: var(--telegram-blue);
    margin-bottom: 16px;
}

.prereq-card h3 {
    font-size: 1.15rem;
    font-weight: 700;
    margin-bottom: 10px;
    color: var(--telegram-light);
}

.prereq-card p {
    color: var(--telegram-gray);
    font-size: 0.95rem;
    line-height: 1.6;
}

/* ============================================================
   Install Steps (install.html)
   ============================================================ */
.install-steps {
    display: flex;
    flex-direction: column;
    gap: 40px;
    max-width: 820px;
    margin: 0 auto;
    overflow: hidden;
}

.install-step {
    /* Inherits .step styles for the scroll animation */
}

.step-note {
    margin-top: 12px;
    font-size: 0.9rem;
    color: var(--telegram-gray);
    background: rgba(255, 255, 255, 0.04);
    border-radius: 8px;
    padding: 10px 14px;
    border-left: 3px solid rgba(0, 136, 204, 0.4);
}

.step-note i {
    color: var(--telegram-blue);
    margin-right: 6px;
}

.step-note--success {
    border-left-color: var(--telegram-green);
    color: var(--telegram-light);
}

.step-note--success i {
    color: var(--telegram-green);
}

/* ============================================================
   Code blocks (install.html)
   ============================================================ */
.code-block {
    background: #0d1117;
    border-radius: 10px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    overflow: hidden;
    margin: 16px 0;
    font-family: 'Fira Code', 'Cascadia Code', 'Consolas', monospace;
    width: 100%;
    min-width: 0;
}

.code-block-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px 14px;
    background: rgba(255, 255, 255, 0.05);
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.code-lang {
    font-size: 12px;
    color: var(--telegram-gray);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    font-family: inherit;
}

.code-copy-btn {
    background: none;
    border: none;
    color: var(--telegram-gray);
    cursor: pointer;
    font-size: 14px;
    padding: 4px 8px;
    border-radius: 6px;
    transition: color 0.2s ease, background 0.2s ease;
}

.code-copy-btn:hover {
    color: white;
    background: rgba(255, 255, 255, 0.1);
}

.code-copy-btn.copied {
    color: var(--telegram-green);
}

.code-block pre {
    margin: 0;
    padding: 16px 18px;
    overflow-x: auto;
    max-width: 100%;
}

.code-block code {
    font-size: 0.88rem;
    line-height: 1.7;
    color: #e6edf3;
    white-space: pre;
    word-break: break-all;
    overflow-wrap: break-word;
}

/* ============================================================
   Config table (install.html)
   ============================================================ */
.config-table-wrapper {
    overflow-x: auto;
    border-radius: 12px;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.config-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.95rem;
}

.config-table thead {
    background: rgba(0, 136, 204, 0.12);
}

.config-table th {
    padding: 14px 18px;
    text-align: left;
    font-weight: 600;
    color: var(--telegram-light-blue);
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 0.4px;
}

.config-table td {
    padding: 14px 18px;
    border-top: 1px solid rgba(255, 255, 255, 0.06);
    color: var(--telegram-gray);
    vertical-align: middle;
}

.config-table tr:hover td {
    background: rgba(255, 255, 255, 0.03);
}

.config-table code {
    font-family: 'Fira Code', 'Consolas', monospace;
    font-size: 0.85rem;
    background: rgba(0, 136, 204, 0.12);
    color: var(--telegram-light-blue);
    padding: 2px 7px;
    border-radius: 5px;
}

.badge-required {
    display: inline-block;
    background: rgba(255, 0, 0, 0.15);
    color: #e05555;
    padding: 3px 10px;
    border-radius: 50px;
    font-size: 0.8rem;
    font-weight: 600;
}

.badge-optional {
    display: inline-block;
    background: rgba(142, 153, 163, 0.15);
    color: var(--telegram-gray);
    padding: 3px 10px;
    border-radius: 50px;
    font-size: 0.8rem;
    font-weight: 600;
}

/* ============================================================
   FAQ (install.html)
   ============================================================ */
.faq-list {
    display: flex;
    flex-direction: column;
    gap: 24px;
    max-width: 820px;
    margin: 0 auto;
    overflow: hidden;
}

.faq-item {
    /* Inherits .step animation */
    flex-direction: column;
    gap: 12px;
    min-width: 0;
}

.faq-q {
    display: flex;
    align-items: flex-start;
    gap: 14px;
}

.faq-q i {
    font-size: 20px;
    color: var(--telegram-blue);
    margin-top: 3px;
    flex-shrink: 0;
}

.faq-q h3 {
    font-size: 1.15rem;
    font-weight: 700;
    color: var(--telegram-light-blue);
    margin: 0;
}

.faq-item > p {
    color: var(--telegram-gray);
    line-height: 1.7;
    padding-left: 34px;
    font-size: 0.95rem;
    overflow-wrap: break-word;
    word-break: break-word;
}

.faq-item > p code {
    font-family: 'Fira Code', 'Consolas', monospace;
    font-size: 0.85rem;
    background: rgba(0, 136, 204, 0.12);
    word-break: break-all;
    color: var(--telegram-light-blue);
    padding: 2px 7px;
    border-radius: 5px;
}

/* ============================================================
   Inline links (used in install.html content)
   ============================================================ */
.inline-link {
    color: var(--telegram-blue);
    text-decoration: none;
    border-bottom: 1px solid rgba(0, 136, 204, 0.3);
    transition: color 0.2s ease, border-color 0.2s ease;
}

.inline-link:hover {
    color: var(--telegram-light-blue);
    border-bottom-color: var(--telegram-light-blue);
}

/* ============================================================
   About: stats row
   ============================================================ */
.stats--about {
    margin-bottom: 0;
    padding: 40px 0;
    border-top: 1px solid rgba(255, 255, 255, 0.07);
    border-bottom: 1px solid rgba(255, 255, 255, 0.07);
}

/* ============================================================
   Author card (about.html)
   ============================================================ */
.author-card {
    display: flex;
    gap: 40px;
    align-items: flex-start;
    max-width: 720px;
    margin: 0 auto;
    background: var(--telegram-dark);
    border-radius: 20px;
    padding: 40px;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.author-avatar {
    font-size: 80px;
    color: var(--telegram-blue);
    flex-shrink: 0;
    line-height: 1;
}

.author-name {
    font-size: 1.6rem;
    font-weight: 800;
    margin-bottom: 4px;
    color: var(--telegram-light);
}

.author-handle {
    color: var(--telegram-blue);
    font-size: 1rem;
    font-weight: 600;
    margin-bottom: 16px;
}

.author-bio {
    color: var(--telegram-gray);
    line-height: 1.7;
    margin-bottom: 24px;
    font-size: 0.95rem;
}

.author-links {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
}

.author-link {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: rgba(255, 255, 255, 0.08);
    color: white;
    padding: 10px 18px;
    border-radius: 8px;
    text-decoration: none;
    font-weight: 500;
    font-size: 14px;
    border: 1px solid rgba(255, 255, 255, 0.15);
    transition: all 0.2s ease;
}

.author-link:hover {
    background: rgba(0, 136, 204, 0.2);
    border-color: rgba(0, 136, 204, 0.4);
}

/* ============================================================
   Community button secondary variant (about.html)
   ============================================================ */
.btn-community--secondary {
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.btn-community--secondary:hover {
    background: rgba(255, 255, 255, 0.2);
    transform: translateY(-3px);
    box-shadow: none;
}

/* ============================================================
   Responsive — inner pages
   ============================================================ */
@media (max-width: 768px) {
    .page-hero h1 {
        font-size: 1.75rem;
    }

    .page-hero p {
        font-size: 1rem;
    }

    .feature-detail,
    .feature-detail--reverse {
        grid-template-columns: 1fr;
        gap: 30px;
    }

    .feature-detail--reverse .feature-detail-icon,
    .feature-detail--reverse .feature-detail-content {
        order: unset;
    }

    .feature-detail-icon {
        width: 72px;
        height: 72px;
        font-size: 30px;
        margin: 0 auto;
    }

    .feature-detail-content h2 {
        font-size: 1.375rem;
        text-align: center;
    }

    .feature-detail-lead {
        font-size: 1rem;
        text-align: center;
    }

    .feature-list li {
        font-size: 0.9375rem;
    }

    .author-card {
        flex-direction: column;
        align-items: center;
        text-align: center;
        padding: 28px 20px;
    }

    .author-name {
        font-size: 1.375rem;
    }

    .author-links {
        justify-content: center;
    }

    .config-table th,
    .config-table td {
        padding: 10px 12px;
        font-size: 0.875rem;
    }

    .faq-item > p {
        padding-left: 0;
    }

    .code-block code {
        font-size: 0.8rem;
        white-space: pre-wrap;
        word-break: break-all;
    }

    .step-note {
        font-size: 0.85rem;
    }

    .cta h2,
    .community h2 {
        font-size: 1.75rem;
    }

    .cta p,
    .community p {
        font-size: 1rem;
    }
}

@media (max-width: 480px) {
    .page-hero {
        padding: 140px 0 60px;
    }

    .page-hero h1 {
        font-size: 1.5rem;
    }

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

    .hero h1 {
        font-size: 1.75rem;
    }

    .section {
        padding: 60px 0;
    }

    .section-title {
        font-size: 1.5rem;
    }

    .about {
        padding: 60px 0;
    }

    .community,
    .cta {
        padding: 60px 20px;
    }

    .community h2,
    .cta h2 {
        font-size: 1.5rem;
    }

    .feature-detail-content h2 {
        font-size: 1.25rem;
    }

    .nav-link {
        font-size: 14px;
    }

    .logo-text {
        font-size: 18px;
    }

    .scroll-top {
        bottom: 20px;
        right: 20px;
    }
}
