/* Core Variables & Design System */
:root {
    --bg-dark: #0f1115;
    --bg-darker: #0a0b0e;
    --primary-purple: #9d4edd;
    --primary-blue: #3a86ff;
    --accent-teal: #38b000;
    --text-light: #f8f9fa;
    --text-muted: #adb5bd;
    
    --glass-bg: rgba(255, 255, 255, 0.03);
    --glass-border: rgba(255, 255, 255, 0.08);
    --glass-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.37);
    
    --font-main: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    --transition-smooth: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
    
    /* Platform Colors */
    --twitch-color: #9146FF;
    --youtube-color: #FF0000;
    --kick-color: #53FC18;
    --tiktok-color: #00f2fe;
}

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

html {
    scroll-behavior: smooth;
    scroll-padding-top: 88px;
}

body {
    font-family: var(--font-main);
    background-color: var(--bg-dark);
    color: var(--text-light);
    line-height: 1.6;
    overflow-x: hidden;
}

a {
    text-decoration: none;
    color: inherit;
    transition: var(--transition-smooth);
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
}

/* Typography */
h1, h2, h3, h4 {
    font-weight: 700;
    line-height: 1.2;
}

.headline {
    font-size: 4.5rem;
    letter-spacing: -0.03em;
    margin-bottom: 1.5rem;
}

.gradient-text {
    background: linear-gradient(135deg, var(--primary-purple), var(--primary-blue));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.subtitle {
    font-size: 1.25rem;
    color: var(--text-muted);
    max-width: 600px;
    margin-bottom: 2.5rem;
}

.section-header {
    text-align: center;
    margin-bottom: 4rem;
}

.section-header h2 {
    font-size: 2.5rem;
    margin-bottom: 1rem;
}

.section-header p {
    color: var(--text-muted);
    font-size: 1.1rem;
    max-width: 600px;
    margin: 0 auto;
}

/* Reusable Components */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.6rem;
    padding: 0.75rem 1.5rem;
    border-radius: 8px;
    font-weight: 600;
    cursor: pointer;
    border: none;
    transition: var(--transition-smooth);
}

.os-icon {
    width: 1em;
    height: 1em;
    flex-shrink: 0;
}

.btn-large {
    padding: 1rem 2rem;
    font-size: 1.1rem;
}

.btn-primary {
    background: linear-gradient(135deg, var(--primary-purple), #7b2cbf);
    color: white;
    box-shadow: 0 4px 15px rgba(157, 78, 221, 0.3);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(157, 78, 221, 0.4);
}

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

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

.btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    transform: none;
    box-shadow: none;
}

/* .btn:disabled above only applies to real <button>/<input> elements — the
   Store link is an <a>, which has no native disabled state, so JS toggles
   this class instead (see setStoreLink/markUnavailable in js/main.js). */
.btn.is-unavailable {
    opacity: 0.5;
    cursor: not-allowed;
    pointer-events: none;
}

.btn.is-unavailable:hover {
    transform: none;
    box-shadow: none;
}

.glass-panel {
    background: var(--glass-bg);
    /* 8px, not 12px — backdrop-filter blur is a well-documented scroll
       performance cost (confirmed against Mozilla's own bug tracker:
       "backdrop-filter blur is laggy when many elements are rendered",
       and this page uses .glass-panel 15 times). A smaller blur radius
       is meaningfully cheaper to recompute per frame while still reading
       as "frosted glass" — most of the visual effect comes from the
       semi-transparent background + border, not the exact blur amount.
       transform: translateZ(0) below promotes each panel to its own
       GPU compositing layer, which is the standard mitigation for this. */
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    transform: translateZ(0);
    border: 1px solid var(--glass-border);
    border-radius: 16px;
    box-shadow: var(--glass-shadow);
}

/* Navigation */
nav {
    position: fixed;
    top: var(--lang-banner-offset, 0px);
    width: 100%;
    z-index: 1000;
    padding: 0.95rem 0;
    min-height: 72px;
    box-sizing: border-box;
    transition: background-color 180ms ease, border-color 180ms ease, box-shadow 180ms ease, top 200ms ease;
}

nav.scrolled {
    background: rgba(10, 11, 14, 0.94);
    border-bottom: 1px solid var(--glass-border);
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.16);
}

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

.logo {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    font-size: 1.5rem;
    font-weight: 700;
    letter-spacing: -0.02em;
}

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

.nav-links {
    display: flex;
    gap: 2rem;
}

.nav-links a {
    color: var(--text-muted);
    font-weight: 500;
}

.nav-support-link {
    color: #ff8fc7 !important;
}

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

.mobile-menu-btn {
    display: none;
    background: none;
    border: none;
    cursor: pointer;
    flex-direction: column;
    gap: 5px;
}

.mobile-menu-btn span {
    width: 24px;
    height: 2px;
    background: var(--text-light);
    border-radius: 2px;
}

.mobile-menu {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100vh;
    background: var(--bg-darker);
    z-index: 999;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 2rem;
}

.mobile-menu.active {
    display: flex;
}

.mobile-link {
    font-size: 1.5rem;
    font-weight: 600;
}

/* Hero Section */
.hero {
    position: relative;
    padding-top: 12rem;
    padding-bottom: 6rem;
    min-height: 100vh;
    display: flex;
    align-items: center;
    overflow: hidden;
}

.hero-bg-glow {
    position: absolute;
    top: -20%;
    left: -10%;
    width: 600px;
    height: 600px;
    background: radial-gradient(circle, rgba(157, 78, 221, 0.15) 0%, rgba(15, 17, 21, 0) 70%);
    border-radius: 50%;
    z-index: -1;
}

.hero-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
}

.hero-buttons {
    display: flex;
    gap: 1rem;
}

.hero-image-wrapper {
    padding: 0.5rem;
    transform: perspective(1000px) rotateY(-5deg) rotateX(5deg);
    transition: transform 0.5s ease;
}

.hero-image-wrapper:hover {
    transform: perspective(1000px) rotateY(0deg) rotateX(0deg);
}

.hero-image {
    width: 100%;
    height: auto;
    border-radius: 12px;
    display: block;
}

/* Hero platform user stats */
.hero-visual {
    min-width: 0;
}

.hero-platform-stats {
    margin: 0.75rem 0 0;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.75rem;
    min-height: 30px;
    color: var(--text-muted);
}

.hero-platform-stats-title {
    flex: 0 0 auto;
    color: var(--text-muted);
    font-size: 0.74rem;
    font-weight: 650;
    letter-spacing: 0.01em;
    white-space: nowrap;
}

.hero-platform-stats-row {
    display: flex;
    align-items: center;
    gap: 0.85rem;
    min-width: 0;
}

.hero-platform-stat {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    min-width: 0;
    padding: 0.3rem 0.48rem;
    border: 1px solid rgba(255,255,255,.07);
    border-radius: 8px;
    background: rgba(255,255,255,.025);
}

.hero-platform-stat-icon {
    width: 15px;
    height: 15px;
    display: block;
}

.hero-platform-stat-count {
    color: rgba(255,255,255,.62);
    font-size: 0.73rem;
    font-weight: 650;
    line-height: 1;
    font-variant-numeric: tabular-nums;
}

.hero-platform-stat-count[hidden] {
    display: none;
}

/* Platforms Section */
.platforms {
    padding: 6rem 0;
    background: var(--bg-darker);
}

.platforms-card {
    padding: 3rem;
}

.platforms-logos {
    display: flex;
    justify-content: center;
    align-items: center;
    flex-wrap: wrap;
    gap: 2.75rem;
    padding-bottom: 2.5rem;
    margin-bottom: 2.5rem;
    border-bottom: 1px solid var(--glass-border);
}

.platform-logo-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.75rem;
    transition: var(--transition-smooth);
}

.platform-logo-item:hover {
    transform: translateY(-3px);
}

.platform-logo-icon {
    width: 40px;
    height: 40px;
}

.platform-logo-item > span:not(.platform-user-count) {
    font-weight: 600;
    font-size: 0.95rem;
    color: var(--text-light);
}


.platforms-highlights {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 2rem;
}

.platform-highlight {
    display: flex;
    align-items: flex-start;
    gap: 1rem;
}

.platform-highlight-icon {
    width: 44px;
    height: 44px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    background: linear-gradient(135deg, rgba(157, 78, 221, 0.16), rgba(58, 134, 255, 0.16));
    border: 1px solid var(--glass-border);
    color: var(--primary-purple);
}

.platform-highlight h4 {
    font-size: 1.05rem;
    margin-bottom: 0.35rem;
}

.platform-highlight p {
    color: var(--text-muted);
    font-size: 0.92rem;
}

/* Features Section */
.features {
    padding: 8rem 0;
}

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

.feature-card {
    padding: 2rem;
    background: var(--bg-darker);
    border-radius: 16px;
    border: 1px solid rgba(255,255,255,0.02);
}

.feature-icon {
    width: 44px;
    height: 44px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    margin-bottom: 1.5rem;
    background: linear-gradient(135deg, rgba(157, 78, 221, 0.16), rgba(58, 134, 255, 0.16));
    border: 1px solid var(--glass-border);
    color: var(--primary-purple);
}

.feature-card h3 {
    margin-bottom: 1rem;
}

.feature-card p {
    color: var(--text-muted);
}

/* Screenshots Section */
.screenshots {
    padding: 8rem 0;
    background: var(--bg-darker);
}

.screenshot-showcase {
    display: flex;
    flex-direction: column;
    gap: 8rem;
}

.screenshot-item {
    display: grid;
    grid-template-columns: 1fr 1.2fr;
    gap: 4rem;
    align-items: center;
}

.screenshot-item.reverse {
    grid-template-columns: 1.2fr 1fr;
}

.screenshot-item.reverse .screenshot-text {
    order: 2;
}

.screenshot-item.reverse .screenshot-img {
    order: 1;
}

.screenshot-text h3 {
    font-size: 2rem;
    margin-bottom: 1.5rem;
}

.screenshot-text p {
    color: var(--text-muted);
    font-size: 1.1rem;
}

.screenshot-img {
    padding: 0.5rem;
    border-radius: 16px;
}

.screenshot-img img {
    width: 100%;
    height: auto;
    border-radius: 12px;
    display: block;
}

/* Anchor positioning */
#platforms, #features, #about, #faq, #contact, #download { scroll-margin-top: 88px; }

/* Download Section */
.download {
    padding: 5.5rem 0;
    scroll-margin-top: 88px;
}

.download-box {
    padding: 2.75rem 3rem 2.5rem;
    text-align: center;
    position: relative;
    overflow: hidden;
}

.download-box::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(58, 134, 255, 0.1) 0%, transparent 50%);
    z-index: -1;
}

.download-box h2 {
    font-size: 2.5rem;
    margin-bottom: 1rem;
}

.download-box p {
    color: var(--text-muted);
    max-width: 600px;
    margin: 0 auto 1.5rem auto;
}

.download-cta {
    display: flex;
    justify-content: center;
    margin-bottom: 1.25rem;
}

.platform-support-row {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 0.6rem;
    margin-bottom: 2.5rem;
}

.download-reassure {
    font-size: 1.02rem;
    font-weight: 600;
    margin: 1.75rem 0 1rem;
    padding-top: 1.75rem;
    border-top: 1px solid var(--glass-border);
}

.reassure-badges {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 0.6rem;
    margin-bottom: 1.5rem;
}

.reassure-badges .os-badge {
    background: rgba(56, 176, 0, 0.08);
    border-color: rgba(56, 176, 0, 0.25);
}

/* FAQ Section */
.faq {
    padding: 6rem 0;
    background: var(--bg-darker);
}

.faq-accordion {
    max-width: 800px;
    margin: 0 auto;
}

.faq-item {
    border-top: 1px solid var(--glass-border);
    break-inside: avoid;
    -webkit-column-break-inside: avoid;
}

.faq-item:last-child {
    border-bottom: 1px solid var(--glass-border);
}

.faq-question {
    width: 100%;
    background: none;
    border: none;
    color: var(--text-light);
    font-size: 1.2rem;
    font-weight: 600;
    text-align: left;
    padding: 1.5rem 0;
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.faq-icon {
    font-size: 1.5rem;
    font-weight: 400;
    color: var(--primary-purple);
    transition: var(--transition-smooth);
}

.faq-item.active .faq-icon {
    transform: rotate(45deg);
}

.faq-answer {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease;
}

.faq-answer p {
    padding-bottom: 1.5rem;
    color: var(--text-muted);
}

/* Two-column FAQ on wider screens — halves the scroll length of a 12-item
   list. Uses CSS multi-column (not grid) so each item keeps its own height
   and the columns fill top-to-bottom independently, which handles the
   accordion's variable open/closed heights cleanly. */
@media screen and (min-width: 900px) {
    .faq-accordion {
        max-width: 1100px;
        column-count: 2;
        column-gap: 3rem;
    }
}

/* Download Section — platform cards, version badge */
.download-version {
    color: var(--text-muted);
    font-size: 0.95rem;
    margin: -0.35rem 0 1.5rem;
    min-height: 1.3em;
}

.download-version a {
    color: var(--text-light);
    text-decoration: underline;
    text-decoration-color: var(--glass-border);
    text-underline-offset: 3px;
}

.platform-cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 1.5rem;
    margin-bottom: 2.5rem;
    text-align: left;
}

.platform-card {
    padding: 1.35rem;
    scroll-margin-top: 88px;
    transition: var(--transition-smooth);
}

.platform-card.is-recommended {
    border-color: var(--primary-purple);
    box-shadow: 0 0 0 1px var(--primary-purple), var(--glass-shadow);
}

.platform-card-head {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    margin-bottom: 1.25rem;
    flex-wrap: wrap;
}

.platform-card-head .os-icon {
    width: 1.4em;
    height: 1.4em;
}

.platform-card-head h3 {
    font-size: 1.2rem;
    margin: 0;
}

.platform-recommended-badge {
    background: rgba(157, 78, 221, 0.15);
    border: 1px solid rgba(157, 78, 221, 0.4);
    color: var(--primary-purple);
    font-size: 0.72rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.03em;
    padding: 0.25rem 0.6rem;
    border-radius: 999px;
}

.platform-btn {
    width: 100%;
    margin-bottom: 0.6rem;
}

.platform-card-note {
    color: var(--text-muted);
    font-size: 0.88rem;
    line-height: 1.5;
    margin-bottom: 1rem;
}

.platform-card-note a {
    color: var(--text-light);
}

.platform-card-altlink {
    display: block;
    text-align: center;
    font-size: 0.85rem;
    color: var(--text-muted);
    margin: -0.6rem 0 1rem;
}

.platform-card-divider {
    display: flex;
    align-items: center;
    text-align: center;
    color: var(--text-muted);
    font-size: 0.8rem;
    margin: 1.25rem 0;
}

.platform-card-divider::before,
.platform-card-divider::after {
    content: '';
    flex: 1;
    border-bottom: 1px solid var(--glass-border);
}

.platform-card-divider span {
    padding: 0 0.75rem;
}

.platform-btn-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0.6rem;
    margin-bottom: 1rem;
}

.platform-btn-sm {
    padding: 0.6rem 0.5rem;
    font-size: 0.85rem;
}

/* Note: the .security-explainer / .security-steps rule set that used to
   live here has been removed — the download section was rebuilt with a
   tab + collapsible-help-panel layout (.help-images etc., see below),
   which no longer uses any of those classes. Leaving unused CSS around
   for markup that no longer exists just invites confusion later. */

.security-note {
    text-align: center;
    color: var(--text-muted);
    font-size: 0.9rem;
    max-width: 700px;
    margin: 3rem auto 0;
    padding-top: 2rem;
    border-top: 1px solid var(--glass-border);
}

/* Contact Section */
.contact {
    padding: 8rem 0;
}

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

.contact-card {
    padding: 2.5rem;
    text-align: center;
}

.contact-card-icon {
    width: 44px;
    height: 44px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1.25rem;
    background: linear-gradient(135deg, rgba(157, 78, 221, 0.16), rgba(58, 134, 255, 0.16));
    border: 1px solid var(--glass-border);
    color: var(--primary-purple);
}

.contact-card-icon-img {
    width: 22px;
    height: 22px;
}

.contact-card h3 {
    margin-bottom: 1rem;
}

.contact-card p {
    color: var(--text-muted);
    margin-bottom: 1.5rem;
}

.contact-link {
    color: var(--primary-blue);
    font-weight: 600;
}

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

/* Follow PixieOnTV socials */
.contact-social-box {
    margin-top: 2rem;
    padding: 2.5rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 2rem;
    flex-wrap: wrap;
}

.contact-social-text h3 {
    margin-bottom: 0.5rem;
}

.contact-social-text p {
    color: var(--text-muted);
    max-width: 420px;
}

.contact-social-links {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
}

.social-icon-link {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 46px;
    height: 46px;
    border-radius: 50%;
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    transition: var(--transition-smooth);
}

.social-icon-link img {
    width: 20px;
    height: 20px;
}

.social-icon-link:hover {
    background: rgba(255, 255, 255, 0.08);
    border-color: var(--primary-purple);
    transform: translateY(-3px);
}

/* Guides strip - low-key SEO internal links, sits right above the footer */
.footer-guides {
    background: #050608;
    padding: 1.4rem 0;
    border-top: 1px solid var(--glass-border);
}

.footer-guides-inner {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.5rem 1.1rem;
}

.footer-guides-label {
    color: var(--text-muted);
    font-size: 0.78rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.03em;
    opacity: 0.6;
}

.footer-guides-inner a {
    color: var(--text-muted);
    font-size: 0.82rem;
    opacity: 0.75;
}

.footer-guides-inner a:hover {
    color: var(--primary-purple);
    opacity: 1;
}

/* Footer */
footer {
    background: #050608;
    padding: 4rem 0 2rem 0;
    border-top: 1px solid var(--glass-border);
}

.footer-content {
    display: grid;
    grid-template-columns: 2fr 3fr;
    gap: 4rem;
    margin-bottom: 4rem;
}

.footer-brand .footer-logo {
    width: 32px;
    height: 32px;
    vertical-align: middle;
    margin-right: 0.5rem;
}

.brand-name {
    font-size: 1.5rem;
    font-weight: 700;
    vertical-align: middle;
}

.footer-brand p {
    margin-top: 1rem;
    color: var(--text-muted);
    max-width: 300px;
}

.footer-links {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
}

.link-column h4 {
    margin-bottom: 1.5rem;
    color: var(--text-light);
}

.link-column a {
    display: block;
    color: var(--text-muted);
    margin-bottom: 0.75rem;
}

.link-column a:hover {
    color: var(--primary-purple);
}

.footer-bottom {
    text-align: center;
    color: var(--text-muted);
    font-size: 0.9rem;
    padding-top: 2rem;
    border-top: 1px solid rgba(255,255,255,0.05);
}

.footer-bottom a {
    color: var(--text-muted);
    text-decoration: none;
}

.footer-bottom a:hover {
    color: var(--primary-purple);
}

/* Legal Pages (Privacy/Terms) */
.legal-page {
    background: var(--bg-dark);
}

.legal-content {
    padding-top: 10rem;
    padding-bottom: 6rem;
}

.text-document {
    padding: 4rem;
}

.text-document h1 {
    font-size: 3rem;
    margin-bottom: 0.5rem;
}

.text-document > p:first-of-type {
    color: var(--text-muted);
    margin-bottom: 3rem;
    border-bottom: 1px solid var(--glass-border);
    padding-bottom: 1rem;
}

.text-document section {
    margin-bottom: 2.5rem;
}

.text-document h2 {
    font-size: 1.5rem;
    margin-bottom: 1rem;
    color: var(--primary-blue);
}

.text-document p {
    margin-bottom: 1rem;
    color: #d1d5db;
}

.text-document ul {
    margin-left: 1.5rem;
    margin-bottom: 1.5rem;
    color: #d1d5db;
}

.text-document li {
    margin-bottom: 0.5rem;
}

.text-document a {
    color: var(--primary-purple);
    text-decoration: underline;
}
/* ==========================================================================
   New sections for v2: About, Comparison, Donate, Credits, Stats highlight
   ========================================================================== */

/* Stats highlight strip */
.stats-highlight {
    padding: 2rem 0;
}
.stats-box {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 2rem;
    padding: 2.5rem;
    flex-wrap: wrap;
}
.stats-box-text h3 {
    font-size: 1.4rem;
    margin-bottom: 0.5rem;
}
.stats-box-text p {
    color: var(--text-muted);
    max-width: 480px;
}
.stats-pills {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
}
.stats-pill {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    border-radius: 14px;
    padding: 1rem 1.5rem;
    min-width: 110px;
}
.stats-pill strong {
    font-size: 1.1rem;
    background: linear-gradient(135deg, var(--primary-purple), var(--primary-blue));
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}
.stats-pill span {
    font-size: 0.78rem;
    color: var(--text-muted);
    margin-top: 0.25rem;
    text-align: center;
}

/* Donate section */
.donate {
    padding: 4rem 0;
}
.donate-box {
    text-align: center;
    padding: 3rem 2rem;
}
.donate-eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    color: var(--primary-purple);
    font-weight: 600;
    font-size: 0.85rem;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    margin-bottom: 1rem;
}
.donate-box h2 {
    font-size: 1.8rem;
    margin-bottom: 0.75rem;
}
.donate-box p {
    color: var(--text-muted);
    max-width: 560px;
    margin: 0 auto 2rem;
}
.donate-actions {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 1rem;
}
.btn-donate {
    background: linear-gradient(135deg, #ff5f9e, var(--primary-purple));
    color: white;
}
.btn-donate:hover {
    filter: brightness(1.1);
    transform: translateY(-2px);
}

/* Comparison section */
.comparison {
    padding: 6rem 0;
}
.comparison-intro {
    max-width: 720px;
    margin: 0 auto 3rem;
    text-align: center;
    color: var(--text-muted);
}
.comparison-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 1.5rem;
    margin-bottom: 2rem;
}
.comparison-card {
    padding: 1.75rem;
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}
.comparison-card.is-pixelychat {
    border: 1px solid rgba(157, 78, 221, 0.5);
    background: rgba(157, 78, 221, 0.06);
}
.comparison-card h3 {
    font-size: 1.15rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}
.comparison-card .tag {
    display: inline-block;
    font-size: 0.7rem;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    color: var(--primary-purple);
    background: rgba(157, 78, 221, 0.12);
    border: 1px solid rgba(157, 78, 221, 0.3);
    padding: 0.2rem 0.6rem;
    border-radius: 999px;
    width: fit-content;
}
.comparison-card p {
    color: var(--text-muted);
    font-size: 0.92rem;
    flex-grow: 1;
}
.comparison-card a {
    font-size: 0.85rem;
    color: var(--primary-blue);
}

.comparison-table-wrap {
    overflow-x: auto;
    margin-bottom: 2rem;
    border-radius: 16px;
    border: 1px solid var(--glass-border);
}
.comparison-table {
    width: 100%;
    border-collapse: collapse;
    background: var(--glass-bg);
    min-width: 640px;
}
.comparison-table th,
.comparison-table td {
    padding: 0.9rem 1.1rem;
    text-align: left;
    border-bottom: 1px solid var(--glass-border);
    font-size: 0.88rem;
}
.comparison-table th {
    color: var(--text-light);
    font-weight: 600;
    background: rgba(255, 255, 255, 0.02);
    white-space: nowrap;
}
.comparison-table td:first-child,
.comparison-table th:first-child {
    color: var(--text-muted);
    font-weight: 500;
    white-space: nowrap;
}
.comparison-table tr:last-child td {
    border-bottom: none;
}
.comparison-table .col-pixelychat {
    background: rgba(157, 78, 221, 0.07);
}
.comparison-table .yes {
    color: #6fdc4f;
}
.comparison-table .neutral {
    color: var(--text-muted);
}

.comparison-note {
    text-align: center;
    color: var(--text-muted);
    font-size: 0.85rem;
    max-width: 640px;
    margin: 0 auto;
}

/* Mobile "See full comparison table" toggle — hidden on desktop, where the
   table is short enough (and useful enough) to just show outright. */
.comparison-toggle {
    display: none;
    width: 100%;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    margin: 0 auto 1.25rem;
    padding: 0.85rem 1.5rem;
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    border-radius: 999px;
    color: var(--text-light);
    font-weight: 600;
    font-size: 0.9rem;
    cursor: pointer;
    transition: var(--transition-smooth);
}

.comparison-toggle:hover {
    border-color: var(--primary-purple);
}

.comparison-toggle-icon {
    transition: transform 0.25s ease;
}

.comparison-toggle[aria-expanded="true"] .comparison-toggle-icon {
    transform: rotate(180deg);
}

/* About page */
.about-hero {
    padding: 7rem 0 4rem;
    position: relative;
}
.about-hero-grid {
    display: grid;
    grid-template-columns: 1fr 340px;
    gap: 3rem;
    align-items: center;
}
.about-hero-photo {
    border-radius: 24px;
    overflow: hidden;
    border: 1px solid var(--glass-border);
    box-shadow: var(--glass-shadow);
}
.about-hero-photo img {
    width: 100%;
    height: auto;
    display: block;
}
.about-eyebrow {
    color: var(--primary-purple);
    font-weight: 600;
    font-size: 0.9rem;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    margin-bottom: 0.75rem;
    display: block;
}
.about-content {
    padding: 1rem 0 5rem;
}
.about-content .text-document {
    max-width: 780px;
    margin: 0 auto;
}
.about-content .text-document p {
    font-size: 1.05rem;
    line-height: 1.75;
}
.about-content .text-document h2 {
    color: var(--text-light);
    font-size: 1.6rem;
    margin-top: 2.5rem;
}
.about-cta {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
    margin-top: 2rem;
}
.about-quote {
    border-left: 3px solid var(--primary-purple);
    padding-left: 1.25rem;
    margin: 2rem 0;
    font-style: italic;
    color: var(--text-light);
    font-size: 1.15rem;
}

/* About teaser card on homepage */
.about-teaser {
    padding: 5rem 0;
}
.about-teaser-box {
    display: grid;
    grid-template-columns: 220px 1fr;
    gap: 2.5rem;
    align-items: center;
    padding: 2.5rem;
}
.about-teaser-photo {
    border-radius: 18px;
    overflow: hidden;
    border: 1px solid var(--glass-border);
}
.about-teaser-photo img {
    width: 100%;
    height: auto;
    display: block;
}
.about-teaser-text h2 {
    font-size: 1.6rem;
    margin-bottom: 0.75rem;
}
.about-teaser-text p {
    color: var(--text-muted);
    margin-bottom: 1.25rem;
}

/* Credits / props section */
.credits {
    padding: 5rem 0;
}
.credits-box {
    padding: 2.5rem;
    text-align: center;
}
.credits-box h2 {
    font-size: 1.5rem;
    margin-bottom: 0.75rem;
}
.credits-box > p {
    color: var(--text-muted);
    max-width: 620px;
    margin: 0 auto 2rem;
}
.credits-links {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 0.75rem;
}
.credits-links a {
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    padding: 0.6rem 1.2rem;
    border-radius: 999px;
    font-size: 0.9rem;
    font-weight: 500;
}
.credits-links a:hover {
    border-color: var(--primary-purple);
    color: var(--primary-purple);
}

/* OS badges in hero */
.os-badges {
    display: flex;
    gap: 0.6rem;
    margin-top: 1.5rem;
    flex-wrap: wrap;
}
.os-badge {
    display: flex;
    align-items: center;
    gap: 0.4rem;
    font-size: 0.8rem;
    color: var(--text-muted);
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    padding: 0.4rem 0.85rem;
    border-radius: 999px;
}

.hero-free-note { margin-top: 0.9rem; color: var(--text-light); font-size: 0.8rem; font-weight: 650; letter-spacing: 0.01em; }

/* Free-forever ribbon on hero */
.free-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    background: rgba(56, 176, 0, 0.1);
    border: 1px solid rgba(56, 176, 0, 0.35);
    color: #6fdc4f;
    padding: 0.4rem 0.9rem;
    border-radius: 999px;
    font-size: 0.82rem;
    font-weight: 600;
    margin-bottom: 1.25rem;
}

/* How It Works — 3-step visual */
.how-it-works {
    padding: 5rem 0 2rem;
}
.steps-grid {
    display: grid;
    grid-template-columns: 1fr 40px 1fr 40px 1fr;
    gap: 0.5rem;
    align-items: center;
    position: relative;
}
.step-card {
    padding: 2rem 1.75rem;
    text-align: center;
    position: relative;
}
.step-number {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    margin: 0 auto 1.25rem;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--primary-purple), var(--primary-blue));
    color: white;
    font-weight: 700;
    font-size: 1.1rem;
}
.step-card h3 {
    font-size: 1.15rem;
    margin-bottom: 0.6rem;
}
.step-card p {
    color: var(--text-muted);
    font-size: 0.92rem;
}
.step-arrow {
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--primary-purple);
    font-size: 1.5rem;
    opacity: 0.6;
}

/* ==========================================================================\n   PixelyChat 2026 polish + simplified download experience\n   ========================================================================== */
:root {
    --container-width: 1180px;
    --section-space: 7rem;
    --panel-radius: 18px;
}

.container,
.nav-container { max-width: var(--container-width); }

section { scroll-margin-top: 88px; }

/* Navigation: quieter, cleaner, more product-like. */
nav {
    will-change: background-color;
    contain: layout paint;
    padding: .95rem 0;
    min-height: 72px;
    box-sizing: border-box;
}
nav.scrolled {
    padding: .95rem 0;
    min-height: 72px;
    background: rgba(10, 11, 14, .96);
    backdrop-filter: none;
    -webkit-backdrop-filter: none;
}
.nav-container { gap: 2rem; }
.nav-links { gap: 1.65rem; margin-left: auto; }
.nav-links a { font-size: .94rem; }
.nav-actions { margin-left: 1.2rem; }
.nav-btn { padding: .65rem 1.15rem; }

/* Hero: less copy, stronger hierarchy. */
.hero { padding-top: 10.5rem; padding-bottom: 7rem; }
.free-badge { font-size: .85rem; letter-spacing: .01em; }
.subtitle { max-width: 620px; line-height: 1.7; }
.hero-buttons { gap: .8rem; }
.hero-image-wrapper { border-radius: 18px; }

/* Reduce the amount of visual boxing across the site. */
.platforms-card,
.about-teaser-box,
.donate-box { border-radius: var(--panel-radius); }

.section-header { margin-bottom: 3.2rem; }
.section-header h2 { letter-spacing: -.025em; }

/* Download redesign */
.download { padding: 5rem 0; scroll-margin-top: 88px; }
.download-box { padding: 2.75rem 3rem 2.25rem; max-width: 1040px; margin: 0 auto; }
.download-box::before { opacity: .65; }
.download-heading { text-align: center; }
.download-eyebrow { display: inline-block; color: var(--primary-purple); font-size: .78rem; font-weight: 800; letter-spacing: .1em; text-transform: uppercase; margin-bottom: .7rem; }
.download-box h2 { font-size: 2.7rem; margin-bottom: .55rem; letter-spacing: -.03em; }
.download-heading p { margin-bottom: 1.25rem; }
.download-primary { text-align: center; margin-bottom: .8rem; }
.download-primary .btn { min-width: 260px; }
.download-primary-meta { font-size: .82rem !important; margin: .7rem auto 0 !important; }
.download-version { margin: .5rem 0 2rem; min-height: 1.3em; }

.download-tabs { display: flex; justify-content: center; gap: .25rem; margin: 1rem auto 1rem; padding: .3rem; width: fit-content; max-width: 100%; background: rgba(255,255,255,.035); border: 1px solid var(--glass-border); border-radius: 12px; }
.download-tab { appearance: none; border: 0; background: transparent; color: var(--text-muted); padding: .7rem 1.35rem; border-radius: 8px; font: inherit; font-size: .92rem; font-weight: 650; cursor: pointer; transition: var(--transition-smooth); }
.download-tab:hover { color: var(--text-light); background: rgba(255,255,255,.04); }
.download-tab[aria-selected="true"] { color: var(--text-light); background: rgba(157,78,221,.16); box-shadow: inset 0 0 0 1px rgba(157,78,221,.32); }
.download-tab:focus-visible { outline: 2px solid var(--primary-purple); outline-offset: 2px; }

.download-panels { max-width: 780px; margin: 0 auto; }
.platform-panel { padding: 1.35rem; border: 1px solid var(--glass-border); border-radius: 16px; background: rgba(255,255,255,.018); text-align: left; animation: downloadPanelIn .22s ease both; }
.platform-panel[hidden] { display: none; }
.platform-panel-head { display: flex; justify-content: space-between; gap: 1rem; margin-bottom: .9rem; }
.platform-title { display: flex; align-items: center; gap: .65rem; }
.platform-title .os-icon { width: 1.45rem; height: 1.45rem; }
.platform-title h3 { font-size: 1.35rem; }
.platform-panel-head p { color: var(--text-muted); font-size: .9rem; margin-top: .35rem; }
.platform-recommended-badge { display: inline-flex; align-items: center; margin-left: .25rem; background: rgba(157,78,221,.12); border: 1px solid rgba(157,78,221,.3); color: #c792f1; font-size: .68rem; font-weight: 750; text-transform: uppercase; letter-spacing: .05em; padding: .2rem .48rem; border-radius: 999px; }
.platform-panel:not(#platform-windows) .platform-recommended-badge { display: none; }

.download-option { display: flex; align-items: center; justify-content: space-between; gap: 1.2rem; padding: 1rem 1.05rem; border: 1px solid var(--glass-border); border-radius: 12px; margin-top: .7rem; background: rgba(255,255,255,.018); }
.download-option.primary-option { border-color: rgba(157,78,221,.32); background: rgba(157,78,221,.055); }
.download-option-copy { display: flex; flex-direction: column; gap: .18rem; }
.download-option-copy strong { font-size: .98rem; }
.download-option-copy span { color: var(--text-muted); font-size: .82rem; line-height: 1.4; }
.download-option .btn { flex: 0 0 auto; white-space: nowrap; }

.help-toggle { width: 100%; margin-top: .9rem; padding: .75rem .2rem .1rem; border: 0; border-top: 1px solid var(--glass-border); background: transparent; color: var(--text-muted); display: flex; align-items: center; justify-content: space-between; gap: 1rem; text-align: left; font: inherit; font-size: .82rem; cursor: pointer; }
.help-toggle:hover { color: var(--text-light); }
.help-toggle-icon { color: var(--primary-purple); font-size: 1.15rem; line-height: 1; transition: transform .2s ease; }
.help-toggle[aria-expanded="true"] .help-toggle-icon { transform: rotate(45deg); }
.download-help { max-height: 0; overflow: hidden; opacity: 0; transition: max-height .28s ease, opacity .2s ease, margin-top .28s ease; }
.download-help.open { max-height: 1400px; opacity: 1; margin-top: .9rem; }
.download-help > p { color: var(--text-muted); font-size: .82rem; line-height: 1.6; margin: 0 0 1rem; }
.help-steps { display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: .65rem; }
.help-steps > div { display: flex; gap: .6rem; padding: .75rem; border-radius: 10px; background: rgba(255,255,255,.025); }
.help-steps > div > span { display: inline-flex; flex: 0 0 1.5rem; width: 1.5rem; height: 1.5rem; align-items: center; justify-content: center; border-radius: 50%; background: rgba(157,78,221,.15); color: #c792f1; font-size: .72rem; font-weight: 800; }
.help-steps p { color: var(--text-muted); font-size: .78rem; line-height: 1.45; }
.help-images { display: grid; grid-template-columns: repeat(2, 1fr); gap: .75rem; margin-top: .85rem; }
.help-images-three { grid-template-columns: repeat(3, 1fr); }
.help-images img { width: 100%; display: block; border-radius: 9px; border: 1px solid var(--glass-border); }

.linux-download-grid { display: grid; grid-template-columns: 1fr 1fr; gap: .75rem; }
.linux-option { margin-top: 0; color: inherit; transition: var(--transition-smooth); }
.linux-option:hover { border-color: rgba(157,78,221,.38); background: rgba(157,78,221,.055); transform: translateY(-1px); }
.linux-option-copy strong { font-size: 1rem; }
.linux-option-copy span { max-width: 230px; }
.download-arrow { color: var(--primary-purple); font-size: 1.1rem; }
.linux-other { margin-top: .9rem; border-top: 1px solid var(--glass-border); padding-top: .75rem; }
.linux-other summary { cursor: pointer; color: var(--text-muted); font-size: .8rem; }
.linux-other summary:hover { color: var(--text-light); }
.linux-other-links { display: flex; gap: 1rem; flex-wrap: wrap; margin-top: .7rem; }
.linux-other-links a { color: var(--text-muted); font-size: .78rem; text-decoration: underline; text-underline-offset: 3px; }
.download-footer-note { font-size: .8rem !important; margin: .9rem auto 0 !important; }
.download-footer-note a { color: var(--text-light); text-decoration: underline; text-underline-offset: 3px; }

@keyframes downloadPanelIn { from { opacity: .4; transform: translateY(3px); } to { opacity: 1; transform: translateY(0); } }

/* Feature section: slightly more breathing room without adding containers. */
.features { padding-top: var(--section-space); padding-bottom: var(--section-space); }
.screenshot-showcase { gap: 7rem; }
.feature-card { transition: transform .25s ease, border-color .25s ease, background .25s ease; }
.feature-card:hover { transform: translateY(-3px); }

/* Comparison: keep it useful but visually secondary. */
.comparison { padding-top: 5.5rem; }
.comparison .section-header { margin-bottom: 2rem; }
.comparison-table-wrap { border-radius: 14px; }

/* Footer / donate are secondary destinations now, not primary navigation. */
.donate { padding-top: 5rem; }

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

/* Anchor destinations land on the actual content heading, not the padded section edge. */
#features, #platforms, #download { scroll-margin-top: 0; }

/* SEO-focused internal linking section */
.seo-explore {
    padding: 5.5rem 0;
    background: var(--bg-darker);
}
.seo-explore-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0,1fr));
    gap: 1rem;
}
.seo-explore-card {
    display: block;
    padding: 1.35rem 1.25rem;
    border: 1px solid var(--glass-border);
    border-radius: 14px;
    background: var(--glass-bg);
}
.seo-explore-card:hover {
    transform: translateY(-2px);
    border-color: rgba(157,78,221,.35);
    background: rgba(255,255,255,.045);
}
.seo-explore-card strong {
    display: block;
    margin-bottom: .35rem;
}
.seo-explore-card span {
    display: block;
    color: var(--text-muted);
    font-size: .86rem;
    line-height: 1.5;
}
.seo-explore-more-header {
    max-width: 720px;
    margin: 3rem auto 1.25rem;
    text-align: center;
}
.seo-explore-more-header h3 {
    font-size: 1.25rem;
    margin-bottom: .35rem;
}
.seo-explore-more-header p {
    margin: 0;
    color: var(--text-muted);
    font-size: .92rem;
}
.seo-explore-more-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0,1fr));
    gap: 1rem;
}
.seo-explore-more-card {
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: .9rem;
    min-height: 50px;
    padding: 1.75rem 2.25rem;
    text-align: center;
}
.seo-explore-more-card > .seo-explore-icon {
    align-self: center;
    margin-inline: auto;
}
.seo-explore-more-card > div {
    min-width: 0;
    max-width: 430px;
}
.seo-explore-arrow {
    position: absolute;
    top: 1.15rem;
    right: 1.25rem;
    color: var(--text-muted);
    font-size: 1.15rem;
    transition: transform .25s ease, color .25s ease;
}
.seo-explore-more-card:hover .seo-explore-arrow {
    transform: translateX(3px);
    color: var(--text-light);
}

@media (max-width: 900px) {
    .seo-explore-grid,
    .seo-explore-more-grid { grid-template-columns: repeat(2, minmax(0,1fr)); }
}
@media (max-width: 560px) {
    .seo-explore-grid,
    .seo-explore-more-grid { grid-template-columns: 1fr; }
}

@media screen and (min-width: 1100px) { .footer-links { grid-template-columns: repeat(4, 1fr); } }

/* Larger, purpose-built icons for the "More to explore" cards. */
.seo-explore-icon {
    width: 56px;
    height: 56px;
    flex: 0 0 56px;
    padding: 0;
    border-radius: 15px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, rgba(157,78,221,.22), rgba(58,134,255,.16));
    border: 1px solid rgba(157,78,221,.26);
    box-shadow: inset 0 1px 0 rgba(255,255,255,.06), 0 8px 24px rgba(0,0,0,.14);
    color: var(--text-light);
    transition: transform .25s ease, border-color .25s ease, background .25s ease;
}
.seo-explore-icon svg {
    width: 29px;
    height: 29px;
    display: block;
    fill: none;
    stroke: currentColor;
    stroke-width: 1.7;
    stroke-linecap: round;
    stroke-linejoin: round;
}
.seo-icon--guides svg rect {
    fill: rgba(255,255,255,.08);
}
.seo-explore-more-card:hover .seo-explore-icon {
    transform: translateY(-1px) scale(1.035);
    border-color: rgba(157,78,221,.48);
    background: linear-gradient(135deg, rgba(157,78,221,.30), rgba(58,134,255,.22));
}
@media (max-width: 560px) {
    .seo-explore-icon {
        width: 52px;
        height: 52px;
        flex-basis: 52px;
    }
    .seo-explore-icon svg {
        width: 27px;
        height: 27px;
    }
}

/* Final alignment fix for the "More to explore" cards.
   Keep each icon centered in the full card regardless of text width or arrow placement. */
.seo-explore-more-card {
    display: grid !important;
    grid-template-columns: 1fr !important;
    grid-template-rows: auto auto !important;
    justify-items: center !important;
    align-items: start !important;
    justify-content: stretch !important;
    text-align: center !important;
}
.seo-explore-more-card .seo-explore-icon {
    grid-column: 1;
    grid-row: 1;
    justify-self: center !important;
    align-self: start !important;
    margin: 0 auto .9rem !important;
}
.seo-explore-more-card > div {
    grid-column: 1;
    grid-row: 2;
    width: 100%;
    max-width: 430px;
    text-align: center !important;
}
.seo-explore-more-card > div strong,
.seo-explore-more-card > div span {
    text-align: center !important;
}

/* ==========================================================================
   Language switcher + language-suggestion banner
   Appended for the multi-language rollout — uses existing design tokens.

   The trigger button lives inline in the real nav layout (wraps/aligns
   exactly like Download at any width). Its dropdown is a native popover
   (popover="auto" + popovertarget) instead of a <details> disclosure —
   popovers render in the browser's top layer, which is the one thing
   that's actually immune to nav's `contain: layout paint` (the confirmed
   cause of every earlier clipping issue). Bonus: popover="auto" gives us
   free light-dismiss (closes on outside click / Escape) that <details>
   never had. js/main.js positions each popover against its trigger's
   on-screen position when it opens.
   ========================================================================== */
.lang-switch {
    position: relative;
    display: inline-block;
    margin-inline-start: 0.75rem;
}
.lang-switch-trigger {
    all: unset;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 0.35rem;
    padding: 0.5rem 0.75rem;
    border-radius: 8px;
    border: 1px solid var(--glass-border);
    background: var(--glass-bg);
    color: var(--text-muted);
    font-size: 0.85rem;
    font-weight: 600;
    letter-spacing: 0.01em;
    white-space: nowrap;
    box-sizing: border-box;
}
.lang-switch-trigger:hover,
.lang-switch-trigger:focus-visible { color: #fff; border-color: var(--primary-purple); }
.lang-switch-trigger:focus-visible { outline: 2px solid var(--primary-purple); outline-offset: 2px; }
.lang-switch-globe { color: var(--primary-purple); flex-shrink: 0; }
.lang-switch-code { color: inherit; }
.lang-switch-caret { font-size: 0.65rem; opacity: 0.7; }

.lang-switch-menu {
    /* [popover] already gets `position: fixed` from the UA stylesheet;
       margin/inset are reset here since main.js sets top/left explicitly
       right before it opens. */
    margin: 0;
    inset: auto;
    min-width: 220px;
    max-height: 70vh;
    overflow-y: auto;
    background: var(--bg-darker);
    border: 1px solid var(--glass-border);
    border-radius: 12px;
    box-shadow: var(--glass-shadow);
    padding: 0.4rem;
    z-index: 2000;
}
.lang-switch-menu a {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.5rem;
    padding: 0.55rem 0.75rem;
    border-radius: 8px;
    color: var(--text-muted);
    font-size: 0.9rem;
    text-decoration: none;
}
.lang-switch-menu a:hover { background: var(--glass-bg); color: #fff; }
.lang-switch-menu a[aria-current="true"] {
    color: var(--primary-purple);
    font-weight: 600;
}
.mobile-menu .lang-switch { width: auto; margin-inline-start: 0; }

/* Manual page: switcher sits inline with the "Website / Releases" links */
.top-actions .lang-switch-trigger {
    padding: 0.4rem 0.7rem;
    font-size: 0.85rem;
}

/* Dismissible "we noticed your browser prefers X" suggestion banner.
   Hidden by default; js/main.js reveals it only when useful. Fixed at the
   very top, above the navbar, so it's never covered by it — main.js sets
   --lang-banner-offset on <html> to the banner's height so the navbar
   (and the manual page's sticky topbar) shift down to make room instead
   of being overlapped. */
.lang-suggest-banner {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1300;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center;
    gap: 0.75rem;
    padding: 0.7rem 1rem;
    background: var(--bg-darker);
    border-bottom: 1px solid var(--glass-border);
    color: var(--text-muted);
    font-size: 0.9rem;
    text-align: center;
}
.lang-suggest-banner[hidden] { display: none; }
.lang-suggest-banner a.lang-suggest-switch {
    color: #fff;
    background: linear-gradient(135deg, var(--primary-purple), #7b2cbf);
    padding: 0.35rem 0.9rem;
    border-radius: 6px;
    text-decoration: none;
    font-weight: 600;
}
.lang-suggest-banner button.lang-suggest-dismiss {
    background: none;
    border: 1px solid var(--glass-border);
    color: var(--text-muted);
    border-radius: 6px;
    padding: 0.35rem 0.7rem;
    cursor: pointer;
    font-size: 0.85rem;
}

/* ==========================================================================
   Minimal RTL support (used only by the /ar/ copy of this stylesheet)
   ========================================================================== */
html[dir="rtl"] body { text-align: right; }
html[dir="rtl"] .nav-container { flex-direction: row-reverse; }
html[dir="rtl"] .nav-links { flex-direction: row-reverse; }
html[dir="rtl"] .nav-actions { flex-direction: row-reverse; }
/* RTL menu alignment is handled in JS (positions itself against the
   trigger's left edge instead of right edge), since placement is computed
   dynamically rather than pinned via CSS now. */
html[dir="rtl"] .mobile-menu { text-align: right; }
html[dir="rtl"] .hero-content { direction: rtl; }
html[dir="rtl"] .hero-buttons { flex-direction: row-reverse; justify-content: center; }
html[dir="rtl"] .os-badges { flex-direction: row-reverse; }
html[dir="rtl"] .footer-links,
html[dir="rtl"] .footer-bottom,
html[dir="rtl"] .comparison-table,
html[dir="rtl"] .lang-suggest-banner { direction: rtl; }
html[dir="rtl"] ul, html[dir="rtl"] ol { padding-right: 1.25em; padding-left: 0; }

/* ==========================================================================
   Hero "Watch the intro" video trigger + click-to-load video modal.
   The YouTube iframe is only created when the visitor actually clicks —
   nothing from youtube-nocookie.com loads on page visit, so this costs
   nothing for people who don't watch it.
   ========================================================================== */
.hero-video-trigger {
    display: inline-flex;
    align-items: center;
    gap: 0.6rem;
    margin-top: 1.1rem;
    background: none;
    border: none;
    padding: 0;
    color: var(--text-muted);
    font-size: 0.95rem;
    font-weight: 600;
    cursor: pointer;
    font-family: inherit;
}
.hero-video-trigger:hover,
.hero-video-trigger:focus-visible { color: #fff; }
.hero-video-trigger:focus-visible { outline: 2px solid var(--primary-purple); outline-offset: 4px; border-radius: 4px; }
.hero-video-play-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 30px;
    height: 30px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--primary-purple), #7b2cbf);
    box-shadow: 0 4px 15px rgba(157, 78, 221, 0.35);
    color: #fff;
    font-size: 0.7rem;
    flex-shrink: 0;
    transition: var(--transition-smooth);
}
.hero-video-trigger:hover .hero-video-play-icon { transform: scale(1.08); }

.video-modal {
    position: fixed;
    inset: 0;
    z-index: 3000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1.5rem;
}
.video-modal[hidden] { display: none; }
.video-modal-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(5, 6, 9, 0.86);
    backdrop-filter: blur(4px);
}
.video-modal-dialog {
    position: relative;
    width: 100%;
    max-width: 960px;
    background: var(--bg-darker);
    border: 1px solid var(--glass-border);
    border-radius: 16px;
    box-shadow: var(--glass-shadow);
    padding: 0.75rem;
}
.video-modal-close {
    position: absolute;
    top: -3rem;
    right: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 38px;
    height: 38px;
    border-radius: 50%;
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    color: #fff;
    font-size: 1.3rem;
    line-height: 1;
    cursor: pointer;
}
.video-modal-close:hover,
.video-modal-close:focus-visible { border-color: var(--primary-purple); }
.video-modal-frame {
    position: relative;
    width: 100%;
    aspect-ratio: 16 / 9;
    border-radius: 10px;
    overflow: hidden;
    background: #000;
}
.video-modal-frame iframe {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    border: 0;
}
@media (max-width: 640px) {
    .video-modal { padding: 1rem; }
    .video-modal-close { top: -3.2rem; right: 0; width: 34px; height: 34px; }
}
html[dir="rtl"] .video-modal-close { right: auto; left: 0; }

/* Replaces the old 3-icon .os-badges row in the hero with one compact
   line — same "works on all three OSes" signal, far less visual weight.
   The Download section further down still shows full OS-specific badges. */
.hero-os-note {
    margin-top: 0.9rem;
    color: var(--text-muted);
    font-size: 0.85rem;
    opacity: 0.85;
}

/* Watch Intro now sits as a caption under the hero screenshot instead of
   in the button row above it. */
.hero-visual { text-align: center; }
.hero-visual .hero-video-trigger { margin-top: 1.1rem; }

/* PixelyChat Users stats moved from the hero down to the end of the
   Download section (reuses the exact same block/JS, just relocated —
   see js/main.js's [data-platform-stat] selector, which isn't scoped to
   any particular parent). */
.download-platform-stats { margin: 1.5rem auto 0; }
