/* ============================================
   WordUnscrambles.com — Design System
   Premium dark theme with glassmorphism
   ============================================ */

/* --- Custom Properties --- */
:root {
    /* Background */
    --bg-primary: #07071a;
    --bg-secondary: #0d0d2b;
    --bg-card: rgba(255, 255, 255, 0.04);
    --bg-card-hover: rgba(255, 255, 255, 0.07);
    --bg-glass: rgba(255, 255, 255, 0.06);

    /* Text */
    --text-primary: #f0f2f8;
    --text-secondary: #8b8fa8;
    --text-muted: #555977;

    /* Accents */
    --accent-primary: #6366f1;
    --accent-primary-glow: rgba(99, 102, 241, 0.35);
    --accent-secondary: #22d3ee;
    --accent-scrabble: #f59e0b;
    --accent-wwf: #ec4899;
    --accent-wordle: #22c55e;

    /* Borders */
    --border-subtle: rgba(255, 255, 255, 0.06);
    --border-card: rgba(255, 255, 255, 0.08);

    /* Radius */
    --radius-sm: 8px;
    --radius-md: 12px;
    --radius-lg: 16px;
    --radius-xl: 24px;

    /* Shadows */
    --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.3);
    --shadow-md: 0 4px 24px rgba(0, 0, 0, 0.4);
    --shadow-lg: 0 8px 48px rgba(0, 0, 0, 0.5);
    --shadow-glow: 0 0 30px var(--accent-primary-glow);

    /* Typography */
    --font-primary: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    --font-mono: 'JetBrains Mono', 'Fira Code', monospace;

    /* Sizing */
    --container: 1100px;
    --nav-height: 64px;
}

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

html {
    scroll-behavior: smooth;
    -webkit-text-size-adjust: 100%;
}

body {
    font-family: var(--font-primary);
    background: var(--bg-primary);
    color: var(--text-primary);
    line-height: 1.6;
    min-height: 100vh;
    overflow-x: hidden;
    background-image:
        radial-gradient(ellipse 80% 60% at 50% 0%, rgba(99, 102, 241, 0.10) 0%, transparent 60%),
        radial-gradient(ellipse 60% 40% at 80% 100%, rgba(34, 211, 238, 0.06) 0%, transparent 50%);
}

a {
    color: var(--accent-secondary);
    text-decoration: none;
    transition: color 0.2s;
}

a:hover {
    color: var(--accent-primary);
}

img {
    max-width: 100%;
    height: auto;
}

/* --- Navigation --- */
.nav {
    position: sticky;
    top: 0;
    z-index: 100;
    background: rgba(7, 7, 26, 0.85);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-bottom: 1px solid var(--border-subtle);
    height: var(--nav-height);
}

.nav__container {
    max-width: var(--container);
    margin: 0 auto;
    padding: 0 20px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 100%;
}

.nav__logo {
    display: flex;
    align-items: center;
    gap: 10px;
    color: var(--text-primary);
    font-weight: 700;
    font-size: 1.15rem;
}

.nav__logo-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    background: linear-gradient(135deg, var(--accent-primary), #818cf8);
    border-radius: var(--radius-sm);
    font-family: var(--font-mono);
    font-weight: 800;
    font-size: 1.1rem;
    color: white;
    box-shadow: 0 2px 12px var(--accent-primary-glow);
}

.nav__logo-text {
    letter-spacing: -0.02em;
}

.nav__links {
    display: flex;
    gap: 8px;
}

.nav__link {
    color: var(--text-secondary);
    padding: 8px 16px;
    border-radius: var(--radius-sm);
    font-size: 0.9rem;
    font-weight: 500;
    transition: all 0.2s;
}

.nav__link:hover {
    color: var(--text-primary);
    background: var(--bg-card);
}

.nav__mobile-toggle {
    display: none;
    flex-direction: column;
    gap: 5px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 8px;
}

.nav__mobile-toggle span {
    display: block;
    width: 22px;
    height: 2px;
    background: var(--text-secondary);
    border-radius: 2px;
    transition: all 0.3s;
}

/* --- Main Layout --- */
.main {
    min-height: calc(100vh - var(--nav-height));
}

.container {
    max-width: var(--container);
    margin: 0 auto;
    padding: 0 20px;
}

/* --- Hero Section --- */
.hero {
    text-align: center;
    padding: 48px 20px 24px;
}

.hero__badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 14px;
    background: var(--bg-glass);
    border: 1px solid var(--border-card);
    border-radius: 100px;
    font-size: 0.8rem;
    color: var(--text-secondary);
    margin-bottom: 20px;
}

.hero__badge-dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: var(--accent-wordle);
    animation: pulse-dot 2s infinite;
}

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

.hero__title {
    font-size: clamp(2rem, 5vw, 3.2rem);
    font-weight: 900;
    letter-spacing: -0.03em;
    line-height: 1.1;
    margin-bottom: 14px;
    background: linear-gradient(135deg, var(--text-primary) 0%, var(--accent-secondary) 50%, var(--accent-primary) 100%);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

.hero__subtitle {
    font-size: clamp(0.95rem, 2vw, 1.15rem);
    color: var(--text-secondary);
    max-width: 520px;
    margin: 0 auto;
    line-height: 1.5;
}

/* --- Tool Section --- */
.tool {
    max-width: var(--container);
    margin: 0 auto;
    padding: 0 20px 40px;
}

.tool__card {
    background: var(--bg-card);
    border: 1px solid var(--border-card);
    border-radius: var(--radius-xl);
    padding: 32px;
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    box-shadow: var(--shadow-md);
}

/* --- Input Area --- */
.input-area {
    margin-bottom: 24px;
}

.input-area__label {
    display: block;
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--text-secondary);
    text-transform: uppercase;
    letter-spacing: 0.08em;
    margin-bottom: 10px;
}

.input-area__wrapper {
    position: relative;
    display: flex;
    gap: 12px;
}

.input-area__field {
    flex: 1;
    padding: 16px 20px;
    background: rgba(0, 0, 0, 0.3);
    border: 2px solid var(--border-card);
    border-radius: var(--radius-md);
    color: var(--text-primary);
    font-family: var(--font-mono);
    font-size: 1.35rem;
    font-weight: 600;
    letter-spacing: 0.15em;
    text-transform: uppercase;
    outline: none;
    transition: all 0.25s;
}

.input-area__field::placeholder {
    color: var(--text-muted);
    text-transform: none;
    letter-spacing: 0;
    font-size: 1rem;
    font-weight: 400;
}

.input-area__field:focus {
    border-color: var(--accent-primary);
    box-shadow: 0 0 0 4px var(--accent-primary-glow), var(--shadow-glow);
}

.input-area__btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 16px 28px;
    background: linear-gradient(135deg, var(--accent-primary), #818cf8);
    color: white;
    border: none;
    border-radius: var(--radius-md);
    font-family: var(--font-primary);
    font-size: 1rem;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.25s;
    white-space: nowrap;
    box-shadow: 0 4px 16px var(--accent-primary-glow);
}

.input-area__btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 24px var(--accent-primary-glow);
}

.input-area__btn:active {
    transform: translateY(0);
}

.input-area__btn svg {
    width: 18px;
    height: 18px;
}

/* Tile preview */
.tiles-preview {
    display: flex;
    gap: 6px;
    margin-top: 12px;
    flex-wrap: wrap;
    min-height: 50px;
}

.tile {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 50px;
    background: linear-gradient(135deg, rgba(99, 102, 241, 0.15), rgba(99, 102, 241, 0.05));
    border: 1px solid rgba(99, 102, 241, 0.3);
    border-radius: var(--radius-sm);
    font-family: var(--font-mono);
    font-size: 1.3rem;
    font-weight: 700;
    color: var(--text-primary);
    position: relative;
    animation: tile-pop 0.2s ease-out;
    text-transform: uppercase;
}

.tile--wildcard {
    background: linear-gradient(135deg, rgba(245, 158, 11, 0.15), rgba(245, 158, 11, 0.05));
    border-color: rgba(245, 158, 11, 0.4);
    color: var(--accent-scrabble);
}

.tile__score {
    position: absolute;
    bottom: 2px;
    right: 4px;
    font-size: 0.55rem;
    color: var(--text-muted);
    font-weight: 500;
}

@keyframes tile-pop {
    0% { transform: scale(0.5); opacity: 0; }
    70% { transform: scale(1.1); }
    100% { transform: scale(1); opacity: 1; }
}

/* --- Mode Selector --- */
.modes {
    display: flex;
    gap: 8px;
    margin-bottom: 20px;
    flex-wrap: wrap;
}

.mode-btn {
    flex: 1;
    min-width: 140px;
    padding: 12px 16px;
    background: var(--bg-glass);
    border: 1.5px solid var(--border-card);
    border-radius: var(--radius-md);
    color: var(--text-secondary);
    font-family: var(--font-primary);
    font-size: 0.9rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.25s;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.mode-btn:hover {
    background: var(--bg-card-hover);
    color: var(--text-primary);
}

.mode-btn.active {
    color: white;
    box-shadow: var(--shadow-sm);
}

.mode-btn[data-mode="scrabble"].active {
    background: linear-gradient(135deg, rgba(245, 158, 11, 0.2), rgba(245, 158, 11, 0.08));
    border-color: rgba(245, 158, 11, 0.5);
    color: var(--accent-scrabble);
}

.mode-btn[data-mode="wwf"].active {
    background: linear-gradient(135deg, rgba(236, 72, 153, 0.2), rgba(236, 72, 153, 0.08));
    border-color: rgba(236, 72, 153, 0.5);
    color: var(--accent-wwf);
}

.mode-btn[data-mode="wordle"].active {
    background: linear-gradient(135deg, rgba(34, 197, 94, 0.2), rgba(34, 197, 94, 0.08));
    border-color: rgba(34, 197, 94, 0.5);
    color: var(--accent-wordle);
}

.mode-btn__icon {
    font-size: 1.1rem;
}

/* --- Dictionary Selector --- */
.dict-selector {
    margin-bottom: 18px;
}

.dict-selector__track {
    display: inline-flex;
    gap: 2px;
    padding: 3px;
    background: rgba(0, 0, 0, 0.3);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-md);
    width: 100%;
}

.dict-btn {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    padding: 8px 14px;
    background: transparent;
    border: 1.5px solid transparent;
    border-radius: calc(var(--radius-md) - 2px);
    color: var(--text-muted);
    font-family: var(--font-primary);
    font-size: 0.8rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
    white-space: nowrap;
    position: relative;
}

.dict-btn__icon {
    font-size: 0.95rem;
    line-height: 1;
}

.dict-btn__label {
    line-height: 1;
}

.dict-btn:hover {
    color: var(--text-secondary);
    background: rgba(255, 255, 255, 0.03);
}

.dict-btn.active {
    background: rgba(34, 211, 238, 0.08);
    border-color: rgba(34, 211, 238, 0.25);
    color: var(--accent-secondary);
    box-shadow: 0 1px 8px rgba(34, 211, 238, 0.1);
}

/* --- Filters --- */
.filters {
    margin-bottom: 20px;
}

.filters__toggle {
    display: flex;
    align-items: center;
    gap: 8px;
    background: none;
    border: none;
    color: var(--text-secondary);
    font-family: var(--font-primary);
    font-size: 0.85rem;
    font-weight: 600;
    cursor: pointer;
    padding: 6px 0;
    transition: color 0.2s;
}

.filters__toggle:hover {
    color: var(--text-primary);
}

.filters__toggle-arrow {
    transition: transform 0.3s;
    font-size: 0.7rem;
}

.filters__toggle.open .filters__toggle-arrow {
    transform: rotate(180deg);
}

.filters__panel {
    display: none;
    grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
    gap: 12px;
    margin-top: 12px;
    padding: 20px;
    background: rgba(0, 0, 0, 0.2);
    border-radius: var(--radius-md);
    border: 1px solid var(--border-subtle);
}

.filters__panel.open {
    display: grid;
}

.filter-group {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.filter-group label {
    font-size: 0.75rem;
    font-weight: 600;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.06em;
}

.filter-group input {
    padding: 8px 12px;
    background: rgba(0, 0, 0, 0.3);
    border: 1px solid var(--border-card);
    border-radius: var(--radius-sm);
    color: var(--text-primary);
    font-family: var(--font-primary);
    font-size: 0.85rem;
    outline: none;
    transition: border-color 0.2s;
}

.filter-group input:focus {
    border-color: var(--accent-primary);
}

/* --- Wordle Mode UI --- */
.wordle-input {
    display: none;
    flex-direction: column;
    gap: 16px;
    margin-bottom: 20px;
}

.wordle-input.active {
    display: flex;
}

.wordle-grid {
    display: flex;
    gap: 8px;
    justify-content: center;
}

.wordle-cell {
    width: 56px;
    height: 60px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: var(--font-mono);
    font-size: 1.5rem;
    font-weight: 800;
    text-transform: uppercase;
    border: 2px solid var(--border-card);
    border-radius: var(--radius-sm);
    cursor: pointer;
    transition: all 0.2s;
    user-select: none;
    color: var(--text-primary);
    background: rgba(0,0,0,0.3);
}

.wordle-cell:focus {
    outline: none;
    border-color: var(--accent-primary);
    box-shadow: 0 0 0 3px var(--accent-primary-glow);
}

.wordle-cell[data-state="green"] {
    background: rgba(34, 197, 94, 0.25);
    border-color: rgba(34, 197, 94, 0.7);
    color: var(--accent-wordle);
}

.wordle-cell[data-state="yellow"] {
    background: rgba(245, 158, 11, 0.2);
    border-color: rgba(245, 158, 11, 0.6);
    color: var(--accent-scrabble);
}

.wordle-cell[data-state="gray"] {
    background: rgba(255, 255, 255, 0.05);
    border-color: rgba(255, 255, 255, 0.15);
    color: var(--text-muted);
}

.wordle-hint {
    text-align: center;
    font-size: 0.8rem;
    color: var(--text-muted);
}

.wordle-excluded {
    margin-top: 4px;
}

.wordle-excluded label {
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--text-secondary);
    display: block;
    margin-bottom: 6px;
}

.wordle-excluded input {
    width: 100%;
    max-width: 400px;
    padding: 10px 14px;
    background: rgba(0, 0, 0, 0.3);
    border: 1px solid var(--border-card);
    border-radius: var(--radius-sm);
    color: var(--text-primary);
    font-family: var(--font-mono);
    font-size: 1rem;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    outline: none;
    transition: border-color 0.2s;
}

.wordle-excluded input:focus {
    border-color: var(--accent-wordle);
}

/* --- Results --- */
.results {
    margin-top: 28px;
}

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

.results__count {
    font-size: 0.9rem;
    color: var(--text-secondary);
}

.results__count strong {
    color: var(--accent-secondary);
    font-weight: 700;
}

.results__sort {
    display: flex;
    gap: 4px;
}

.sort-btn {
    padding: 6px 14px;
    background: var(--bg-glass);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-sm);
    color: var(--text-muted);
    font-family: var(--font-primary);
    font-size: 0.8rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
}

.sort-btn:hover {
    color: var(--text-secondary);
}

.sort-btn.active {
    background: var(--accent-primary);
    border-color: var(--accent-primary);
    color: white;
}

/* Results group by length */
.results-group {
    margin-bottom: 24px;
    animation: fade-up 0.35s ease-out both;
}

.results-group:nth-child(2) { animation-delay: 0.05s; }
.results-group:nth-child(3) { animation-delay: 0.1s; }
.results-group:nth-child(4) { animation-delay: 0.15s; }
.results-group:nth-child(5) { animation-delay: 0.2s; }

.results-group__title {
    font-size: 0.8rem;
    font-weight: 700;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.1em;
    margin-bottom: 10px;
    padding-bottom: 6px;
    border-bottom: 1px solid var(--border-subtle);
}

.results-group__words {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.word-card {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 10px 16px;
    background: var(--bg-glass);
    border: 1px solid var(--border-card);
    border-radius: var(--radius-md);
    cursor: pointer;
    transition: all 0.2s;
    text-decoration: none;
}

.word-card:hover {
    background: var(--bg-card-hover);
    border-color: rgba(99, 102, 241, 0.4);
    transform: translateY(-1px);
    box-shadow: var(--shadow-sm);
    color: var(--text-primary);
}

.word-card__text {
    font-family: var(--font-mono);
    font-size: 1rem;
    font-weight: 600;
    color: var(--text-primary);
    text-transform: uppercase;
    letter-spacing: 0.08em;
}

.word-card__score {
    font-size: 0.75rem;
    font-weight: 700;
    padding: 2px 8px;
    border-radius: 100px;
    background: rgba(99, 102, 241, 0.15);
    color: var(--accent-primary);
}

.mode-scrabble .word-card__score {
    background: rgba(245, 158, 11, 0.15);
    color: var(--accent-scrabble);
}

.mode-wwf .word-card__score {
    background: rgba(236, 72, 153, 0.15);
    color: var(--accent-wwf);
}

@keyframes fade-up {
    from {
        opacity: 0;
        transform: translateY(12px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Loading state */
.results__loading {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    padding: 40px;
    color: var(--text-secondary);
    font-size: 0.9rem;
}

.spinner {
    width: 20px;
    height: 20px;
    border: 2px solid var(--border-card);
    border-top-color: var(--accent-primary);
    border-radius: 50%;
    animation: spin 0.7s linear infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* Empty/Error state */
.results__empty {
    text-align: center;
    padding: 40px 20px;
    color: var(--text-muted);
}

.results__empty-icon {
    font-size: 2.5rem;
    margin-bottom: 12px;
    opacity: 0.5;
}

.results__empty-text {
    font-size: 0.95rem;
    margin-bottom: 4px;
    color: var(--text-secondary);
}

.results__empty-hint {
    font-size: 0.8rem;
}

/* --- SEO Content Section --- */
.content-section {
    max-width: var(--container);
    margin: 40px auto;
    padding: 0 20px;
}

.content-card {
    background: var(--bg-card);
    border: 1px solid var(--border-card);
    border-radius: var(--radius-xl);
    padding: 40px;
    backdrop-filter: blur(12px);
}

.content-card h2 {
    font-size: 1.6rem;
    font-weight: 800;
    color: var(--text-primary);
    margin-bottom: 16px;
    letter-spacing: -0.02em;
}

.content-card h3 {
    font-size: 1.15rem;
    font-weight: 700;
    color: var(--text-primary);
    margin-top: 28px;
    margin-bottom: 10px;
}

.content-card p {
    color: var(--text-secondary);
    margin-bottom: 14px;
    line-height: 1.7;
}

.content-card ul,
.content-card ol {
    color: var(--text-secondary);
    margin-bottom: 14px;
    padding-left: 24px;
    line-height: 1.8;
}

.content-card li {
    margin-bottom: 4px;
}

.content-card strong {
    color: var(--text-primary);
    font-weight: 600;
}

/* Steps grid */
.steps-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 16px;
    margin: 24px 0;
}

.step-card {
    padding: 20px;
    background: rgba(0, 0, 0, 0.2);
    border-radius: var(--radius-md);
    border: 1px solid var(--border-subtle);
}

.step-card__number {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    background: linear-gradient(135deg, var(--accent-primary), #818cf8);
    border-radius: 50%;
    font-size: 0.85rem;
    font-weight: 700;
    color: white;
    margin-bottom: 10px;
}

.step-card h4 {
    font-size: 0.95rem;
    font-weight: 700;
    margin-bottom: 6px;
}

.step-card p {
    font-size: 0.85rem;
    color: var(--text-muted);
    margin-bottom: 0;
}

/* --- FAQ --- */
.faq-list {
    list-style: none;
    padding: 0;
}

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

.faq-item:last-child {
    border-bottom: none;
}

.faq-question {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    padding: 18px 0;
    background: none;
    border: none;
    color: var(--text-primary);
    font-family: var(--font-primary);
    font-size: 1rem;
    font-weight: 600;
    text-align: left;
    cursor: pointer;
    transition: color 0.2s;
}

.faq-question:hover {
    color: var(--accent-secondary);
}

.faq-question__arrow {
    transition: transform 0.3s;
    font-size: 0.8rem;
    color: var(--text-muted);
}

.faq-item.open .faq-question__arrow {
    transform: rotate(180deg);
}

.faq-answer {
    display: none;
    padding: 0 0 18px;
    color: var(--text-secondary);
    font-size: 0.9rem;
    line-height: 1.7;
}

.faq-item.open .faq-answer {
    display: block;
}

/* --- Internal links grid --- */
.links-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 16px;
}

.links-grid a {
    padding: 8px 16px;
    background: var(--bg-glass);
    border: 1px solid var(--border-card);
    border-radius: var(--radius-sm);
    font-size: 0.85rem;
    font-weight: 500;
    color: var(--text-secondary);
    transition: all 0.2s;
}

.links-grid a:hover {
    border-color: var(--accent-primary);
    color: var(--text-primary);
    background: var(--bg-card-hover);
}

/* --- Footer --- */
.footer {
    background: rgba(0, 0, 0, 0.3);
    border-top: 1px solid var(--border-subtle);
    padding: 48px 0 32px;
    margin-top: 60px;
}

.footer__container {
    max-width: var(--container);
    margin: 0 auto;
    padding: 0 20px;
}

.footer__grid {
    display: grid;
    grid-template-columns: 1.5fr repeat(3, 1fr);
    gap: 40px;
    margin-bottom: 40px;
}

.footer__logo {
    display: flex;
    align-items: center;
    gap: 10px;
    color: var(--text-primary);
    font-weight: 700;
    font-size: 1.05rem;
    margin-bottom: 12px;
}

.footer__tagline {
    color: var(--text-muted);
    font-size: 0.85rem;
    line-height: 1.6;
}

.footer__heading {
    font-size: 0.8rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: var(--text-secondary);
    margin-bottom: 14px;
}

.footer__list {
    list-style: none;
}

.footer__list li {
    margin-bottom: 8px;
}

.footer__list a {
    color: var(--text-muted);
    font-size: 0.85rem;
    transition: color 0.2s;
}

.footer__list a:hover {
    color: var(--text-primary);
}

.footer__bottom {
    padding-top: 24px;
    border-top: 1px solid var(--border-subtle);
    text-align: center;
}

.footer__bottom p {
    font-size: 0.8rem;
    color: var(--text-muted);
    margin-bottom: 6px;
}

.footer__disclaimer {
    font-size: 0.7rem !important;
    color: var(--text-muted);
    max-width: 680px;
    margin: 0 auto;
    line-height: 1.5;
}

/* --- SEO Page Specific --- */
.seo-hero {
    padding: 40px 20px 20px;
    text-align: center;
}

.seo-hero__word {
    font-family: var(--font-mono);
    font-size: clamp(2rem, 6vw, 3.5rem);
    font-weight: 900;
    letter-spacing: 0.12em;
    color: var(--accent-primary);
    text-transform: uppercase;
    margin-bottom: 8px;
}

.seo-hero__subtitle {
    font-size: 1.1rem;
    color: var(--text-secondary);
}

.seo-stats {
    display: flex;
    gap: 20px;
    justify-content: center;
    margin: 24px 0;
    flex-wrap: wrap;
}

.seo-stat {
    padding: 14px 24px;
    background: var(--bg-glass);
    border: 1px solid var(--border-card);
    border-radius: var(--radius-md);
    text-align: center;
}

.seo-stat__value {
    font-size: 1.5rem;
    font-weight: 800;
    color: var(--accent-secondary);
    display: block;
}

.seo-stat__label {
    font-size: 0.75rem;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.06em;
}

/* --- Setup Page --- */
.setup-page {
    max-width: 700px;
    margin: 40px auto;
    padding: 0 20px;
}

.setup-card {
    background: var(--bg-card);
    border: 1px solid var(--border-card);
    border-radius: var(--radius-xl);
    padding: 40px;
}

.setup-card h1 {
    font-size: 1.8rem;
    font-weight: 800;
    margin-bottom: 20px;
}

.setup-card .success {
    color: var(--accent-wordle);
    padding: 12px 16px;
    background: rgba(34, 197, 94, 0.1);
    border-radius: var(--radius-sm);
    margin-bottom: 12px;
}

.setup-card .error {
    color: #ef4444;
    padding: 12px 16px;
    background: rgba(239, 68, 68, 0.1);
    border-radius: var(--radius-sm);
    margin-bottom: 12px;
}

.setup-card .info {
    color: var(--accent-secondary);
    padding: 12px 16px;
    background: rgba(34, 211, 238, 0.08);
    border-radius: var(--radius-sm);
    margin-bottom: 12px;
    font-size: 0.9rem;
}

.setup-card form {
    margin-top: 20px;
}

.setup-card input[type="file"],
.setup-card input[type="submit"],
.setup-card button {
    display: block;
    margin-top: 12px;
}

.setup-card input[type="submit"],
.setup-card button {
    padding: 12px 28px;
    background: linear-gradient(135deg, var(--accent-primary), #818cf8);
    color: white;
    border: none;
    border-radius: var(--radius-sm);
    font-family: var(--font-primary);
    font-weight: 700;
    font-size: 0.95rem;
    cursor: pointer;
}

.progress-bar {
    width: 100%;
    height: 8px;
    background: rgba(0,0,0,0.3);
    border-radius: 4px;
    overflow: hidden;
    margin: 16px 0;
}

.progress-bar__fill {
    height: 100%;
    background: linear-gradient(90deg, var(--accent-primary), var(--accent-secondary));
    border-radius: 4px;
    transition: width 0.3s;
}

/* --- Responsive --- */
@media (max-width: 768px) {
    .nav__links {
        display: none;
        position: absolute;
        top: var(--nav-height);
        left: 0;
        right: 0;
        background: rgba(7, 7, 26, 0.95);
        backdrop-filter: blur(20px);
        flex-direction: column;
        padding: 16px;
        border-bottom: 1px solid var(--border-subtle);
    }

    .nav__links.open {
        display: flex;
    }

    .nav__mobile-toggle {
        display: flex;
    }

    .hero {
        padding: 32px 16px 16px;
    }

    .tool__card {
        padding: 20px 16px;
        border-radius: var(--radius-lg);
    }

    .input-area__wrapper {
        flex-direction: column;
    }

    .input-area__btn {
        width: 100%;
        justify-content: center;
    }

    .modes {
        flex-direction: column;
    }

    .mode-btn {
        min-width: unset;
    }

    .filters__panel {
        grid-template-columns: 1fr;
    }

    .wordle-cell {
        width: 48px;
        height: 52px;
        font-size: 1.3rem;
    }

    .content-card {
        padding: 24px 20px;
        border-radius: var(--radius-lg);
    }

    .footer__grid {
        grid-template-columns: 1fr;
        gap: 28px;
    }

    .steps-grid {
        grid-template-columns: 1fr;
    }

    .word-card {
        padding: 8px 12px;
    }

    .word-card__text {
        font-size: 0.9rem;
    }

    .results-group__words {
        gap: 6px;
    }
}

@media (max-width: 480px) {
    .hero__title {
        font-size: 1.8rem;
    }

    .input-area__field {
        font-size: 1.1rem;
        padding: 14px 16px;
    }

    .tile {
        width: 38px;
        height: 44px;
        font-size: 1.1rem;
    }

    .wordle-cell {
        width: 42px;
        height: 46px;
        font-size: 1.2rem;
    }

    .seo-hero__word {
        font-size: 2rem;
    }
}

/* --- Utility --- */
.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    border: 0;
}

.hidden {
    display: none !important;
}
