/* ===== DESIGN TOKENS — LIGHT (DEFAULT) ===== */
:root {
    --bg: #f5f7fb;
    --bg-card: #ffffff;
    --bg-pill: rgba(15, 23, 42, 0.05);
    --bg-hover: rgba(15, 23, 42, 0.08);
    --border: rgba(15, 23, 42, 0.06);
    --border-a: rgba(99, 102, 241, 0.4);
    --purple: #6366f1;
    --pink: #d946ef;
    --blue: #0ea5e9;
    --grad: linear-gradient(135deg, #6366f1 0%, #d946ef 100%);
    --txt: #0f172a;
    --txt2: #475569;
    --txt3: #94a3b8;
    --r1: 12px;
    --r2: 16px;
    --r3: 20px;
    --r4: 28px;
    --ease: 0.22s cubic-bezier(0.16, 1, 0.3, 1);
    --topbar-bg: rgba(255, 255, 255, 0.92);
    --tabs-bg: rgba(245, 247, 251, 0.85);
    --shadow-card: 0 4px 20px -2px rgba(15, 23, 42, 0.05), 0 2px 6px -1px rgba(15, 23, 42, 0.03);
}

/* ===== DARK / NIGHT MODE ===== */
html.dark {
    --bg: #090d16;
    --bg-card: #111726;
    --bg-pill: rgba(255, 255, 255, 0.05);
    --bg-hover: rgba(255, 255, 255, 0.09);
    --border: rgba(255, 255, 255, 0.07);
    --border-a: rgba(129, 140, 248, 0.45);
    --purple: #818cf8;
    --pink: #f472b6;
    --blue: #38bdf8;
    --grad: linear-gradient(135deg, #818cf8 0%, #f472b6 100%);
    --txt: #f8fafc;
    --txt2: #94a3b8;
    --txt3: #475569;
    --topbar-bg: rgba(9, 13, 22, 0.8);
    --tabs-bg: rgba(9, 13, 22, 0.85);
    --shadow-card: 0 4px 24px -3px rgba(0, 0, 0, 0.3);
}

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

html {
    scroll-behavior: smooth;
    transition: background-color 0.3s ease, color 0.3s ease;
}

body {
    font-family: 'DM Sans', system-ui, sans-serif;
    background: var(--bg);
    color: var(--txt);
    min-height: 100vh;
    overflow-x: hidden;
    transition: background-color 0.3s ease, color 0.3s ease;
}

/* ── Ambient orbs ── */
.orbs {
    position: fixed;
    inset: 0;
    pointer-events: none;
    z-index: 0;
    overflow: hidden;
}

.orb {
    position: absolute;
    border-radius: 50%;
    filter: blur(140px);
    opacity: 0.05;
    transition: opacity 0.5s ease;
}

html.dark .orb {
    opacity: 0.08;
}

.o1 {
    width: 800px;
    height: 800px;
    background: var(--purple);
    top: -300px;
    left: -300px;
    animation: odrift 35s ease-in-out infinite;
}

.o2 {
    width: 700px;
    height: 700px;
    background: var(--pink);
    bottom: -250px;
    right: -250px;
    animation: odrift 45s ease-in-out infinite reverse;
}

.o3 {
    width: 600px;
    height: 600px;
    background: var(--blue);
    top: 40%;
    left: 60%;
    transform: translate(-50%, -50%);
    animation: odrift 40s ease-in-out infinite 5s;
}

@keyframes odrift {

    0%,
    100% {
        transform: translate(0, 0) scale(1);
    }

    33% {
        transform: translate(50px, -30px) scale(1.08);
    }

    66% {
        transform: translate(-30px, 40px) scale(0.95);
    }
}

.wrap {
    position: relative;
    z-index: 1;
}

/* ── Top bar ── */
.topbar {
    position: sticky;
    top: 0;
    z-index: 100;
    background: var(--topbar-bg);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-bottom: 1px solid var(--border);
    padding: 0 80px;
    transition: background-color 0.3s ease, border-color 0.3s ease;
}

.topbar-inner {
    max-width: 1200px;
    margin: 0 auto;
    height: 70px;
    display: flex;
    align-items: center;
    gap: 20px;
}

.logo {
    display: flex;
    align-items: center;
    gap: 12px;
    text-decoration: none;
    flex-shrink: 0;
    transition: transform var(--ease);
}

.logo:hover {
    transform: scale(1.02);
}

.logo-icon {
    width: 38px;
    height: 38px;
    border-radius: 10px;
    background: var(--grad);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 19px;
    flex-shrink: 0;
    box-shadow: 0 4px 12px rgba(99, 102, 241, 0.2);
}

.logo-text {
    font-family: 'DM Sans', sans-serif;
    font-weight: 700;
    font-size: 21px;
    letter-spacing: -0.5px;
    background: var(--grad);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* ── Theme Toggle Button ── */
#theme-toggle {
    flex-shrink: 0;
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 16px;
    background: var(--bg-pill);
    border: 1px solid var(--border);
    border-radius: 100px;
    cursor: pointer;
    font-family: inherit;
    font-size: 13px;
    font-weight: 600;
    color: var(--txt2);
    transition: all var(--ease);
    white-space: nowrap;
}

#theme-toggle:hover {
    background: var(--bg-hover);
    border-color: var(--border-a);
    color: var(--txt);
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.03);
}

#theme-toggle .theme-icon {
    font-size: 15px;
    line-height: 1;
    transition: transform 0.5s cubic-bezier(0.34, 1.56, 0.64, 1);
}

#theme-toggle:hover .theme-icon {
    transform: rotate(45deg) scale(1.1);
}

#theme-toggle .theme-label {
    display: none;
}

@media (min-width: 480px) {
    #theme-toggle .theme-label {
        display: inline;
    }
}

/* ── Header Navigation ── */
.header-nav {
    margin-left: auto;
    display: flex;
    align-items: center;
    gap: 20px;
}

.nav-links {
    display: flex;
    align-items: center;
    gap: 24px;
    list-style: none;
}

.nav-link {
    font-size: 14px;
    font-weight: 600;
    color: var(--txt2);
    text-decoration: none;
    transition: color var(--ease);
    padding: 6px 0;
    position: relative;
}

.nav-link:hover,
.nav-link.active {
    color: var(--purple);
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 2px;
    background: var(--purple);
    transform: scaleX(0);
    transform-origin: right;
    transition: transform 0.22s cubic-bezier(0.16, 1, 0.3, 1);
}

.nav-link:hover::after,
.nav-link.active::after {
    transform: scaleX(1);
    transform-origin: left;
}

/* Hamburger button */
.hamburger-btn {
    display: none;
    background: none;
    border: none;
    cursor: pointer;
    flex-direction: column;
    gap: 5px;
    padding: 6px;
    z-index: 105;
}

.hamburger-btn span {
    display: block;
    width: 22px;
    height: 2px;
    background: var(--txt);
    border-radius: 2px;
    transition: transform 0.3s ease, opacity 0.3s ease;
}

/* Hamburger open animation */
.hamburger-btn.active span:nth-child(1) {
    transform: translateY(7px) rotate(45deg);
}

.hamburger-btn.active span:nth-child(2) {
    opacity: 0;
}

.hamburger-btn.active span:nth-child(3) {
    transform: translateY(-7px) rotate(-45deg);
}

@media (max-width: 768px) {
    .topbar {
        padding: 0 20px;
    }

    .hamburger-btn {
        display: flex;
    }

    .nav-links {
        position: fixed;
        top: 70px;
        left: 0;
        right: 0;
        height: calc(100vh - 70px);
        background: var(--topbar-bg);
        backdrop-filter: blur(20px);
        -webkit-backdrop-filter: blur(20px);
        flex-direction: column;
        align-items: center;
        justify-content: flex-start;
        padding-top: 40px;
        gap: 32px;
        transform: translateY(-100%);
        opacity: 0;
        pointer-events: none;
        transition: transform 0.35s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.3s ease;
        z-index: 99;
        border-top: 1px solid var(--border);
    }

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

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

/* ── Search ── */
.srch-wrap {
    width: 100%;
    max-width: 580px;
    margin: 0 auto 36px;
    position: relative;
}

.srch-icon {
    position: absolute;
    left: 18px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--txt3);
    pointer-events: none;
    transition: color var(--ease);
    display: flex;
    align-items: center;
}

#search {
    width: 100%;
    height: 52px;
    padding: 0 46px 0 50px;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 100px;
    color: var(--txt);
    font-size: 15px;
    font-family: inherit;
    outline: none;
    transition: all var(--ease);
    box-shadow: var(--shadow-card);
}

#search::placeholder {
    color: var(--txt3);
}

#search:focus {
    border-color: var(--purple);
    box-shadow: 0 15px 35px -5px rgba(99, 102, 241, 0.15), 0 0 0 3px rgba(99, 102, 241, 0.15);
}

#search:focus~.srch-icon,
.srch-wrap:focus-within .srch-icon {
    color: var(--purple);
}

#search-kbd {
    position: absolute;
    right: 16px;
    top: 50%;
    transform: translateY(-50%);
    font-size: 11px;
    font-weight: 600;
    color: var(--txt3);
    background: var(--bg-pill);
    border: 1px solid var(--border);
    border-radius: 6px;
    padding: 3px 6px;
    pointer-events: none;
    font-family: inherit;
}

#search-clear {
    position: absolute;
    right: 14px;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    color: var(--txt3);
    cursor: pointer;
    font-size: 13px;
    padding: 5px;
    border-radius: 50%;
    display: none;
    align-items: center;
    justify-content: center;
    line-height: 1;
    transition: all var(--ease);
}

#search-clear:hover {
    color: var(--txt);
    background: var(--bg-pill);
}

#search-clear.vis {
    display: flex;
}

/* ── Hero ── */
.hero {
    text-align: center;
    padding: 70px 24px 48px;
    max-width: 800px;
    margin: 0 auto;
}

.hero-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 6px 16px;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 100px;
    font-size: 13px;
    font-weight: 500;
    color: var(--txt2);
    margin-bottom: 24px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.02);
}

.hero-badge b {
    color: var(--purple);
    font-weight: 600;
}

.hero h1 {
    font-family: 'DM Sans', sans-serif;
    font-size: clamp(34px, 5.5vw, 56px);
    font-weight: 700;
    line-height: 1.1;
    letter-spacing: -1.2px;
    margin-bottom: 18px;
    color: var(--txt);
}

.hero h1 em {
    font-style: normal;
    background: var(--grad);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    position: relative;
    display: inline-block;
}

.hero p {
    font-size: 16px;
    color: var(--txt2);
    line-height: 1.6;
    max-width: 580px;
    margin: 0 auto 32px;
}

.hero-stats {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 16px;
    flex-wrap: wrap;
}

.stat {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--r2);
    padding: 12px 24px;
    min-width: 120px;
    box-shadow: var(--shadow-card);
    transition: transform var(--ease), border-color var(--ease);
}

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

.stat .num {
    font-family: 'DM Sans', sans-serif;
    font-size: 24px;
    font-weight: 700;
    background: var(--grad);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: 2px;
}

.stat .lbl {
    font-size: 11px;
    font-weight: 600;
    color: var(--txt3);
    text-transform: uppercase;
    letter-spacing: 1px;
}

/* ── Category tabs ── */
.tabs-wrap {
    position: sticky;
    top: 70px;
    z-index: 90;
    background: var(--tabs-bg);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-bottom: 1px solid var(--border);
    transition: background-color 0.3s ease;
}

.tabs {
    max-width: 1200px;
    margin: 0 auto;
    padding: 12px 24px;
    display: flex;
    gap: 6px;
    overflow-x: auto;
    scrollbar-width: none;
    -ms-overflow-style: none;
}

.tabs::-webkit-scrollbar {
    display: none;
}

.tab {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 16px;
    border-radius: 100px;
    border: 1px solid transparent;
    font-size: 13px;
    font-weight: 500;
    font-family: inherit;
    color: var(--txt2);
    white-space: nowrap;
    cursor: pointer;
    background: transparent;
    transition: all var(--ease);
    flex-shrink: 0;
}

.tab:hover {
    color: var(--txt);
    background: var(--bg-pill);
    border-color: var(--border);
}

.tab.active {
    color: var(--purple);
    background: rgba(99, 102, 241, 0.1);
    border-color: rgba(99, 102, 241, 0.25);
    font-weight: 600;
}

html.dark .tab.active {
    background: rgba(129, 140, 248, 0.15);
    border-color: rgba(129, 140, 248, 0.3);
}

.tab-icon {
    font-size: 15px;
    line-height: 1;
}

/* ── Main ── */
.main {
    max-width: 1200px;
    margin: 0 auto;
    padding: 28px 24px 20px;
}

/* ── Status bar ── */
.status-bar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 20px;
    min-height: 28px;
}

.status-title {
    font-family: 'DM Sans', sans-serif;
    font-size: 17px;
    font-weight: 600;
}

.status-count {
    font-size: 12px;
    color: var(--txt3);
}

.status-count b {
    color: var(--purple);
}

/* ── No results ── */
#no-results {
    display: none;
    text-align: center;
    padding: 100px 24px;
    color: var(--txt3);
}

#no-results .nr-icon {
    font-size: 52px;
    margin-bottom: 14px;
    filter: drop-shadow(0 10px 20px rgba(99, 102, 241, 0.15));
}

#no-results p {
    font-size: 16px;
    font-weight: 500;
}

/* ── Emoji sections ── */
.section-block {
    margin-bottom: 44px;
}

.section-hdr {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 16px;
    flex-wrap: wrap;
    gap: 8px;
}

.section-name {
    font-family: 'DM Sans', sans-serif;
    font-size: 17px;
    font-weight: 700;
    display: flex;
    align-items: center;
    gap: 10px;
    color: var(--txt);
}

.section-name span {
    font-size: 20px;
    line-height: 1;
}

.section-badge {
    font-size: 12px;
    font-weight: 600;
    color: var(--txt2);
    background: var(--bg-pill);
    padding: 4px 10px;
    border-radius: 100px;
}

.section-sep {
    height: 1px;
    background: var(--border);
    margin-bottom: 20px;
}

/* ── Emoji grid ── */
.emoji-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(60px, 1fr));
    gap: 8px;
}

.search-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(90px, 1fr));
    gap: 10px;
}

/* ── Emoji button ── */
.emo {
    background: var(--bg-card);
    border: 1px solid var(--border);
    cursor: pointer;
    width: 60px;
    height: 60px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 28px;
    line-height: 1;
    border-radius: var(--r1);
    transition: all var(--ease);
    color: inherit;
    user-select: none;
    position: relative;
    box-shadow: 0 2px 8px -2px rgba(15, 23, 42, 0.04);
}

.emo:hover {
    background: var(--bg-card);
    border-color: var(--purple);
    transform: scale(1.16) translateY(-2px);
    box-shadow: 0 10px 20px -8px rgba(99, 102, 241, 0.3);
    z-index: 2;
}

.emo:active {
    transform: scale(0.92);
}

.emo.popped {
    animation: pop 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    background: rgba(99, 102, 241, 0.12);
    border-color: rgba(99, 102, 241, 0.4);
}

html.dark .emo.popped {
    background: rgba(129, 140, 248, 0.16);
    border-color: rgba(129, 140, 248, 0.4);
}

@keyframes pop {
    0% {
        transform: scale(1);
    }

    50% {
        transform: scale(1.3);
    }

    100% {
        transform: scale(1);
    }
}

/* ── Search result card ── */
.srcard {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--r2);
    padding: 16px 12px 12px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    cursor: pointer;
    transition: all var(--ease);
    position: relative;
    overflow: hidden;
    box-shadow: var(--shadow-card);
}

.srcard:hover {
    border-color: var(--purple);
    background: var(--bg-card);
    transform: translateY(-4px);
    box-shadow: 0 12px 28px -8px rgba(99, 102, 241, 0.15);
}

html.dark .srcard:hover {
    box-shadow: 0 12px 28px -8px rgba(0, 0, 0, 0.4);
}

.srcard:active {
    transform: translateY(0);
}

.srcard.popped {
    animation: pop 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    border-color: var(--purple);
    background: rgba(99, 102, 241, 0.08);
}

html.dark .srcard.popped {
    border-color: var(--purple);
    background: rgba(129, 140, 248, 0.12);
}

.srcard-emoji {
    font-size: 36px;
    line-height: 1;
}

.srcard-name {
    font-size: 11px;
    font-weight: 500;
    color: var(--txt);
    text-align: center;
    line-height: 1.4;
    word-break: break-word;
    overflow: hidden;
    text-overflow: ellipsis;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
}

.srcard-cat {
    font-size: 9px;
    font-weight: 600;
    color: var(--purple);
    opacity: 0.8;
    margin-top: auto;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* ── Toast ── */
#toast {
    position: fixed;
    bottom: 32px;
    left: 50%;
    transform: translateX(-50%) translateY(80px);
    background: rgba(255, 255, 255, 0.85);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid rgba(99, 102, 241, 0.25);
    border-radius: var(--r2);
    padding: 12px 20px;
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 14px;
    color: var(--txt);
    z-index: 1000;
    opacity: 0;
    pointer-events: none;
    white-space: nowrap;
    box-shadow: 0 10px 30px -10px rgba(99, 102, 241, 0.2);
    transition: transform 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.15), opacity 0.25s ease;
}

html.dark #toast {
    background: rgba(17, 23, 38, 0.85);
    border-color: rgba(129, 140, 248, 0.25);
    box-shadow: 0 10px 40px -10px rgba(0, 0, 0, 0.5);
}

#toast.show {
    transform: translateX(-50%) translateY(0);
    opacity: 1;
}

#toast-emoji {
    font-size: 24px;
}

#toast-sub {
    font-size: 12px;
    color: var(--txt2);
    font-weight: 500;
}

/* ── Scroll top ── */
#stb {
    position: fixed;
    bottom: 32px;
    right: 32px;
    width: 46px;
    height: 46px;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--r1);
    cursor: pointer;
    color: var(--txt);
    font-size: 18px;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transform: translateY(20px);
    transition: all var(--ease);
    z-index: 200;
    box-shadow: var(--shadow-card);
}

#stb.vis {
    opacity: 1;
    transform: translateY(0);
}

#stb:hover {
    border-color: var(--purple);
    color: var(--purple);
    transform: translateY(-3px);
    box-shadow: 0 8px 24px -6px rgba(99, 102, 241, 0.2);
}

/* ── Footer ── */
/* ── Footer ── */
.footer {
    border-top: 1px solid var(--border);
    padding: 60px 40px 30px;
    background: rgba(255, 255, 255, 0.01);
    margin-top: 40px;
}

.footer-inner {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    gap: 60px;
    flex-wrap: wrap;
    padding-bottom: 40px;
    border-bottom: 1px solid var(--border);
}

.footer-brand {
    flex: 1 1 300px;
}

.footer-logo {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 20px;
    font-weight: 700;
    color: var(--txt);
    margin-bottom: 16px;
}

.footer-desc {
    color: var(--txt3);
    font-size: 14px;
    line-height: 1.6;
    margin-bottom: 20px;
    max-width: 320px;
}

.footer-badge {
    display: inline-block;
    padding: 6px 12px;
    border-radius: 20px;
    background: var(--card-bg);
    border: 1px solid var(--border);
    font-size: 12px;
    color: var(--txt2);
}

.footer-links-grid {
    display: flex;
    gap: 80px;
    flex-wrap: wrap;
}

.footer-link-group h4 {
    font-size: 14px;
    font-weight: 600;
    color: var(--txt);
    margin-bottom: 18px;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.footer-link-group ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.footer-link-group li {
    margin-bottom: 10px;
}

.footer-link-group a {
    color: var(--txt2);
    font-size: 14px;
    text-decoration: none;
    transition: color 0.2s, transform 0.2s;
    display: inline-block;
}

.footer-link-group a:hover {
    color: var(--purple);
    transform: translateX(3px);
}

.footer-bottom {
    max-width: 1200px;
    margin: 0 auto;
    padding-top: 24px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 20px;
    font-size: 13px;
    color: var(--txt3);
}

.footer-os {
    margin: 0;
}

.footer-copy {
    margin: 0;
}

@media (max-width: 768px) {
    .footer {
        padding: 40px 20px 20px;
    }
    .footer-inner {
        flex-direction: column;
        gap: 40px;
    }
    .footer-links-grid {
        gap: 40px;
        width: 100%;
        justify-content: space-between;
    }
    .footer-bottom {
        flex-direction: column;
        text-align: center;
        align-items: center;
    }
}


/* ── Responsive ── */
@media (max-width: 640px) {

    .hero {
        padding: 36px 16px 24px;
    }

    .main {
        padding: 18px 12px 15px;
    }

    .emoji-grid {
        grid-template-columns: repeat(auto-fill, minmax(46px, 1fr));
        gap: 2px;
    }

    .emo {
        width: 46px;
        height: 46px;
        font-size: 22px;
    }

    .search-grid {
        grid-template-columns: repeat(auto-fill, minmax(70px, 1fr));
        gap: 6px;
    }
}

/* ── Fade-in ── */
@keyframes fadeUp {
    from {
        opacity: 0;
        transform: translateY(16px)
    }

    to {
        opacity: 1;
        transform: translateY(0)
    }
}

.section-block {
    animation: fadeUp .35s ease both;
}

/* ── Text Page Container ── */
.text-container {
    width: 90%;
    max-width: 1200px;
    margin: 40px auto;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--r3);
    padding: 48px;
    box-shadow: var(--shadow-card);
    animation: fadeUp 0.4s ease both;
}

.text-container h1 {
    font-family: 'DM Sans', sans-serif;
    font-size: 32px;
    font-weight: 700;
    margin-bottom: 8px;
    color: var(--txt);
}

.text-container .last-updated {
    font-size: 13px;
    color: var(--txt3);
    margin-bottom: 32px;
}

.text-container h2 {
    font-family: 'DM Sans', sans-serif;
    font-size: 20px;
    font-weight: 600;
    margin-top: 32px;
    margin-bottom: 12px;
    color: var(--txt);
}

.text-container p {
    font-size: 15px;
    line-height: 1.7;
    color: var(--txt2);
    margin-bottom: 16px;
}

.text-container a {
    color: var(--purple);
    text-decoration: none;
    font-weight: 500;
}

.text-container a:hover {
    text-decoration: underline;
}

.text-container ul {
    margin-bottom: 20px;
    padding-left: 24px;
}

.text-container li {
    font-size: 15px;
    line-height: 1.7;
    color: var(--txt2);
    margin-bottom: 8px;
}

.text-container h3 {
    font-family: 'DM Sans', sans-serif;
    font-size: 17px;
    font-weight: 600;
    margin-top: 24px;
    margin-bottom: 8px;
    color: var(--txt);
}

.text-container ol {
    margin-bottom: 20px;
    padding-left: 24px;
}

.text-container ol li {
    font-size: 15px;
    line-height: 1.7;
    color: var(--txt2);
    margin-bottom: 8px;
}

.text-container pre {
    background: var(--bg-pill);
    padding: 16px;
    border-radius: var(--r1);
    overflow-x: auto;
    margin-bottom: 16px;
    border: 1px solid var(--border);
}

.text-container code {
    font-family: monospace;
    font-size: 14px;
    color: var(--txt);
}

.text-container hr {
    border: none;
    border-top: 1px solid var(--border);
    margin: 32px 0;
}


@media (max-width: 640px) {
    .text-container {
        width: auto;
        padding: 28px 20px;
        margin: 20px 12px;
    }
    .content-grid, .step-grid {
        grid-template-columns: 1fr !important;
    }
}

/* ── Contact Form ── */
.contact-form {
    margin-top: 32px;
    margin-bottom: 32px;
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 8px;
    text-align: left;
}

.form-group label {
    font-size: 13px;
    font-weight: 600;
    color: var(--txt);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 12px 16px;
    background: var(--bg-pill);
    border: 1px solid var(--border);
    border-radius: var(--r1);
    color: var(--txt);
    font-size: 14px;
    font-family: inherit;
    outline: none;
    transition: all var(--ease);
}

.form-group input::placeholder,
.form-group textarea::placeholder {
    color: var(--txt3);
}

.form-group input:focus,
.form-group textarea:focus {
    background: var(--bg-card);
    border-color: var(--purple);
    box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.15);
}

.submit-btn {
    align-self: flex-start;
    padding: 12px 28px;
    background: var(--grad);
    border: none;
    border-radius: var(--r1);
    color: #ffffff;
    font-size: 14px;
    font-weight: 600;
    font-family: inherit;
    cursor: pointer;
    transition: all var(--ease);
    box-shadow: 0 4px 12px rgba(99, 102, 241, 0.2);
}

.submit-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(99, 102, 241, 0.35);
}

.submit-btn:active {
    transform: translateY(0);
}

.alternative-contact {
    border-top: 1px solid var(--border);
    padding-top: 24px;
    margin-top: 24px;
    font-size: 14px;
    text-align: center;
}

/* ── Content Decoration Styles ── */
.step-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(min(250px, 100%), 1fr));
    gap: 20px;
    margin: 24px 0 32px 0;
}

.step-card {
    background: var(--bg-pill);
    border: 1px solid var(--border);
    border-radius: var(--r2);
    padding: 24px;
    transition: all var(--ease);
    position: relative;
    overflow: hidden;
}

.step-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 4px;
    height: 100%;
    background: var(--grad);
    opacity: 0;
    transition: opacity var(--ease);
}

.step-card:hover {
    transform: translateY(-3px);
    background: var(--bg-card);
    border-color: var(--border-a);
    box-shadow: var(--shadow-card);
}

.step-card:hover::before {
    opacity: 1;
}

.content-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(min(280px, 100%), 1fr));
    gap: 24px;
    margin: 24px 0 36px 0;
}

.content-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--r2);
    padding: 28px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.01);
    transition: all var(--ease);
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

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

.emoji-highlight-box {
    background: rgba(99, 102, 241, 0.05);
    border-left: 4px solid var(--purple);
    padding: 14px 18px;
    border-radius: 4px var(--r2) var(--r2) 4px;
    margin: 16px 0;
    font-size: 16px;
    letter-spacing: 1px;
}

html.dark .emoji-highlight-box {
    background: rgba(129, 140, 248, 0.1);
}
/* =====================================================================
   LANGUAGE SWITCHER
   ===================================================================== */
.lang-switcher {
    position: relative;
    display: inline-flex;
    align-items: center;
}

.lang-btn {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 6px 10px;
    background: var(--glass, rgba(255,255,255,.08));
    border: 1px solid var(--border, rgba(255,255,255,.15));
    border-radius: 8px;
    color: var(--text, #e2e8f0);
    font-size: 13px;
    font-family: inherit;
    cursor: pointer;
    white-space: nowrap;
    transition: background .2s, border-color .2s;
}

.lang-btn:hover { background: rgba(255,255,255,.14); }

.lang-globe { font-size: 15px; }
.lang-arrow { font-size: 10px; opacity: .7; }

.lang-dropdown {
    display: none;
    position: absolute;
    top: calc(100% + 6px);
    right: 0;
    min-width: 150px;
    background: var(--card, #1e293b);
    border: 1px solid var(--border, rgba(255,255,255,.12));
    border-radius: 10px;
    padding: 6px 0;
    list-style: none;
    margin: 0;
    box-shadow: 0 8px 24px rgba(0,0,0,.35);
    z-index: 999;
}

.lang-dropdown.open { display: block; }

.lang-dropdown li a {
    display: block;
    padding: 8px 16px;
    font-size: 13px;
    color: var(--text-muted, #94a3b8);
    text-decoration: none;
    transition: background .15s, color .15s;
}

.lang-dropdown li a:hover,
.lang-dropdown li a.lang-active {
    background: rgba(139,92,246,.15);
    color: var(--accent, #a78bfa);
}

/* Light-mode overrides */
html:not(.dark) .lang-btn {
    background: rgba(0,0,0,.06);
    border-color: rgba(0,0,0,.12);
    color: #374151;
}
html:not(.dark) .lang-btn:hover { background: rgba(0,0,0,.10); }
html:not(.dark) .lang-dropdown {
    background: #fff;
    border-color: rgba(0,0,0,.12);
    box-shadow: 0 8px 24px rgba(0,0,0,.12);
}
html:not(.dark) .lang-dropdown li a { color: #374151; }
html:not(.dark) .lang-dropdown li a:hover,
html:not(.dark) .lang-dropdown li a.lang-active {
    background: rgba(139,92,246,.08);
    color: #6d28d9;
}

@media (max-width: 768px) {
    .lang-switcher { order: -1; }
    .lang-dropdown { right: auto; left: 0; }
}
