/* Farimacon.me - Italian Rhyme Finder */

:root {
    --primary: #2d5f8a;
    --primary-dark: #1e4060;
    --primary-light: #e8f0f7;
    --accent: #e8913a;
    --accent-light: #fdf0e2;
    --text: #2c3e50;
    --text-light: #6b7c8d;
    --bg: #fafbfc;
    --white: #ffffff;
    --border: #dde3e9;
    --radius: 8px;
    --shadow: 0 2px 8px rgba(0,0,0,0.08);
    --shadow-lg: 0 4px 20px rgba(0,0,0,0.12);
}

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

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    color: var(--text);
    background: var(--bg);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
}

a { color: var(--primary); text-decoration: none; }
a:hover { color: var(--primary-dark); }

/* Header */
.header {
    background: var(--white);
    border-bottom: 1px solid var(--border);
    padding: 1rem 0;
    position: sticky;
    top: 0;
    z-index: 100;
    box-shadow: var(--shadow);
}

.header--home {
    position: static;
    box-shadow: none;
}

.header--home .header-inner {
    justify-content: center;
    text-align: center;
}

.header--home .logo {
    justify-content: center;
    text-align: center;
}

.header-inner {
    max-width: 960px;
    margin: 0 auto;
    padding: 0 1rem;
    display: flex;
    align-items: center;
    gap: 1rem;
}

.logo {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--primary);
    white-space: nowrap;
    text-decoration: none;
}

.logo-tagline {
    font-size: 0.95rem;
    font-weight: 400;
    color: var(--text-light);
    margin-left: 0.25rem;
}

.logo-icon {
    font-size: 1.5rem;
}

/* Search */
.search-form {
    flex: 1;
    max-width: 480px;
    position: relative;
}

.search-input {
    width: 100%;
    padding: 0.6rem 1rem;
    padding-right: 3rem;
    border: 2px solid var(--border);
    border-radius: var(--radius);
    font-size: 1rem;
    color: var(--text);
    background: var(--bg);
    transition: border-color 0.2s;
    outline: none;
}

.search-input:focus {
    border-color: var(--primary);
    background: var(--white);
}

.search-input::placeholder {
    color: var(--text-light);
}

.search-btn {
    position: absolute;
    right: 4px;
    top: 50%;
    transform: translateY(-50%);
    background: var(--primary);
    color: var(--white);
    border: none;
    border-radius: 6px;
    padding: 0.4rem 0.75rem;
    font-size: 0.95rem;
    cursor: pointer;
    transition: background 0.2s;
}

.search-btn:hover {
    background: var(--primary-dark);
}

/* Autocomplete dropdown */
.autocomplete-list {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: var(--white);
    border: 1px solid var(--border);
    border-top: none;
    border-radius: 0 0 var(--radius) var(--radius);
    box-shadow: var(--shadow-lg);
    max-height: 280px;
    overflow-y: auto;
    display: none;
    z-index: 200;
    text-align: left;
}

.autocomplete-list.active { display: block; }

.autocomplete-item {
    padding: 0.5rem 1rem;
    cursor: pointer;
    border-bottom: 1px solid var(--border);
}

.autocomplete-item:hover,
.autocomplete-item.selected {
    background: var(--primary-light);
}

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

/* Main content */
.main {
    max-width: 960px;
    margin: 0 auto;
    padding: 1.5rem 1rem 3rem;
}

/* Word header */
.word-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 1.25rem;
    margin-bottom: 1.5rem;
}

.word-header-main {
    display: flex;
    align-items: center;
    gap: 1rem;
    min-width: 0;
}

.word-header-avatar-link {
    display: block;
    line-height: 0;
    flex-shrink: 0;
}

.dante-avatar {
    width: 68px;
    height: 68px;
    border-radius: 10px;
    border: 2px solid var(--border);
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.08);
    object-fit: cover;
    transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
}

.word-header-avatar-link:hover .dante-avatar {
    transform: scale(1.06);
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.12);
    border-color: var(--primary);
}

.word-header-text {
    min-width: 0;
}

.word-header h1 {
    font-size: 1.75rem;
    color: var(--primary-dark);
    margin-bottom: 0.25rem;
}

.word-header h1 em {
    font-style: normal;
    color: var(--primary);
}

.word-meta {
    color: var(--text-light);
    font-size: 0.95rem;
}

/* Social share bar */
.word-share-bar {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    flex-shrink: 0;
}

.share-label {
    font-size: 0.82rem;
    color: var(--text-light);
    font-weight: 500;
}

.share-icons {
    display: flex;
    align-items: center;
    gap: 0.4rem;
}

.share-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 34px;
    height: 34px;
    border-radius: 50%;
    border: 1px solid var(--border);
    background: var(--white);
    color: var(--text-light);
    text-decoration: none;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    cursor: pointer;
    padding: 0;
    font: inherit;
    position: relative;
}

.share-btn svg {
    transition: transform 0.15s ease;
}

.share-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.08);
}

.share-btn:hover svg {
    transform: scale(1.1);
}

/* Identifiable Brand Accents at rest & on mobile */
.share-btn.share-whatsapp {
    color: #25d366;
    background: #f0fdf4;
    border-color: #bbf7d0;
}
.share-btn.share-whatsapp:hover {
    background: #25d366;
    border-color: #25d366;
    color: #ffffff;
}

.share-btn.share-telegram {
    color: #229ed9;
    background: #f0f9ff;
    border-color: #bae6fd;
}
.share-btn.share-telegram:hover {
    background: #229ed9;
    border-color: #229ed9;
    color: #ffffff;
}

.share-btn.share-x {
    color: #000000;
    background: #f8fafc;
    border-color: #cbd5e1;
}
.share-btn.share-x:hover {
    background: #000000;
    border-color: #000000;
    color: #ffffff;
}

.share-btn.share-facebook {
    color: #1877f2;
    background: #eff6ff;
    border-color: #bfdbfe;
}
.share-btn.share-facebook:hover {
    background: #1877f2;
    border-color: #1877f2;
    color: #ffffff;
}

.share-btn.share-threads {
    color: #000000;
    background: #f8fafc;
    border-color: #cbd5e1;
}
.share-btn.share-threads:hover {
    background: #000000;
    border-color: #000000;
    color: #ffffff;
}

.share-btn.share-reddit {
    color: #ff4500;
    background: #fff5f5;
    border-color: #fecaca;
}
.share-btn.share-reddit:hover {
    background: #ff4500;
    border-color: #ff4500;
    color: #ffffff;
}

.share-btn.share-bluesky {
    color: #0285ff;
    background: #f0f9ff;
    border-color: #bae6fd;
}
.share-btn.share-bluesky:hover {
    background: #0285ff;
    border-color: #0285ff;
    color: #ffffff;
}

.share-btn.share-copy {
    color: #475569;
    background: #f8fafc;
    border-color: #e2e8f0;
}
.share-btn.share-copy:hover,
.share-btn.share-copy.copied {
    color: #0f172a;
    background: #e2e8f0;
    border-color: #cbd5e1;
}

.share-btn.share-native {
    color: var(--primary);
    background: #eff6ff;
    border-color: #bfdbfe;
}
.share-btn.share-native:hover {
    background: var(--primary);
    border-color: var(--primary);
    color: #ffffff;
}

/* Toast feedback for copy link */
.share-toast {
    position: fixed;
    bottom: 24px;
    left: 50%;
    transform: translateX(-50%) translateY(20px);
    background: #0f172a;
    color: #f8fafc;
    padding: 8px 16px;
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: 500;
    opacity: 0;
    pointer-events: none;
    transition: all 0.25s ease;
    z-index: 1000;
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
}
.share-toast.show {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
}

.word-meta .syllables {
    font-family: 'Courier New', monospace;
    background: var(--primary-light);
    padding: 0.15rem 0.5rem;
    border-radius: 4px;
    color: var(--primary);
    font-weight: 500;
}

.word-meta .badge-pos {
    display: inline-block;
    padding: 0.15rem 0.55rem;
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--primary-dark);
    background: var(--primary-light);
    border: 1px solid var(--border);
    border-radius: 9999px;
    vertical-align: middle;
}

/* Tabs */
.tabs {
    display: flex;
    gap: 0;
    border-bottom: 2px solid var(--border);
    margin-bottom: 1.5rem;
}

.tab-btn {
    padding: 0.75rem 1.25rem;
    background: none;
    border: none;
    font-size: 0.95rem;
    font-weight: 600;
    color: var(--text-light);
    cursor: pointer;
    border-bottom: 2px solid transparent;
    margin-bottom: -2px;
    transition: color 0.2s, border-color 0.2s;
    white-space: nowrap;
}

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

.tab-btn.active {
    color: var(--primary);
    border-bottom-color: var(--primary);
}

.tab-btn .count {
    font-weight: 400;
    color: var(--text-light);
    font-size: 0.85rem;
}

.tab-content { display: none; }
.tab-content.active { display: block; }

/* Filters bar (syllable + morphology) */
.filter-bar {
    display: flex;
    align-items: center;
    gap: 1.25rem;
    margin-bottom: 1.25rem;
    flex-wrap: wrap;
}

.filter-group {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.filter-group label {
    font-weight: 600;
    font-size: 0.9rem;
    color: var(--text-light);
    white-space: nowrap;
}

.filter-group select {
    padding: 0.4rem 0.75rem;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    font-size: 0.9rem;
    background: var(--white);
    color: var(--text);
    cursor: pointer;
    transition: border-color 0.15s, box-shadow 0.15s;
}

.filter-group select:focus {
    border-color: var(--primary);
    outline: none;
    box-shadow: 0 0 0 2px var(--primary-light);
}

.no-results-filter {
    padding: 1.25rem 0.5rem;
    text-align: center;
    color: var(--text-light);
    font-size: 0.95rem;
    font-style: italic;
}

.tab-intro-badge {
    display: inline-block;
    background: var(--bg-card, #f8fafc);
    color: var(--text-light, #64748b);
    padding: 0.35rem 0.85rem;
    border-radius: 9999px;
    font-size: 0.85rem;
    margin-bottom: 1rem;
    border: 1px solid var(--border, #e2e8f0);
}

/* Word lists */
.word-list {
    list-style: none;
    column-count: 3;
    column-gap: 1.5rem;
}

.word-list li {
    break-inside: avoid;
    margin-bottom: 0.15rem;
}

.word-list a {
    display: block;
    padding: 0.3rem 0.5rem;
    border-radius: 4px;
    transition: background 0.15s;
    color: var(--text);
}

.word-list a:hover {
    background: var(--primary-light);
    color: var(--primary);
}

.word-list .syl-badge {
    font-size: 0.75rem;
    color: var(--text-light);
    margin-left: 0.25rem;
}

/* No results */
.no-results {
    text-align: center;
    padding: 2rem;
    color: var(--text-light);
    font-size: 1.1rem;
}

/* Results summary */
.results-summary {
    display: inline-block;
    white-space: nowrap;
    max-width: 100%;
    background: var(--primary-light);
    color: var(--primary-dark);
    font-size: 0.85rem;
    font-weight: 500;
    padding: 0.38rem 0.95rem;
    border-radius: 9999px;
    margin-bottom: 0.75rem;
    border: 1px solid rgba(45, 95, 138, 0.2);
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.04);
    line-height: 1.35;
}

.results-summary strong {
    font-weight: 700;
}

.results-summary:empty {
    display: none;
}

/* Pagination */
.pagination-container {
    margin: 2rem 0 1.5rem;
    display: flex;
    justify-content: center;
}

.pagination-bar {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.75rem;
    width: 100%;
    max-width: 340px;
}

/* Centered modern pill dock */
.pagination-pill {
    display: inline-flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
    background: var(--white);
    padding: 0.35rem 0.5rem;
    border-radius: 50px;
    border: 1px solid var(--border);
    box-shadow: 0 4px 14px rgba(0, 0, 0, 0.06);
    width: 100%;
    max-width: 290px;
}

/* Circular touch icon buttons */
.page-circle-btn {
    width: 42px;
    height: 42px;
    border-radius: 50%;
    border: none;
    background: var(--primary-light);
    color: var(--primary);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    flex-shrink: 0;
    touch-action: manipulation;
    user-select: none;
}

.page-circle-btn:hover:not(:disabled) {
    background: var(--primary);
    color: var(--white);
    transform: scale(1.05);
}

.page-circle-btn:active:not(:disabled) {
    transform: scale(0.95);
}

.page-circle-btn:disabled {
    opacity: 0.35;
    cursor: not-allowed;
    background: transparent;
    color: var(--text-light);
}

/* Center badge with transparent overlay select */
.page-badge-wrapper {
    position: relative;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.35rem;
    padding: 0.4rem 0.85rem;
    background: var(--bg);
    border-radius: 20px;
    border: 1px solid var(--border);
    cursor: pointer;
    transition: background 0.15s, border-color 0.15s;
}

.page-badge-wrapper:hover {
    background: var(--primary-light);
    border-color: rgba(45, 95, 138, 0.3);
}

.page-badge-text {
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--primary-dark);
    white-space: nowrap;
}

.page-badge-arrow {
    color: var(--primary);
    display: inline-block;
    vertical-align: middle;
}

.page-select-hidden {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    cursor: pointer;
    font-size: 16px; /* Prevents auto-zoom on iOS Safari */
    z-index: 2;
}

/* Show all button */
.show-all-btn {
    background: none;
    border: none;
    color: var(--text-light);
    font-size: 0.8rem;
    font-weight: 500;
    cursor: pointer;
    padding: 0.3rem 0.6rem;
    transition: color 0.15s;
    touch-action: manipulation;
}

.show-all-btn:hover {
    color: var(--primary);
    text-decoration: underline;
}

.page-toggle-pill {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.6rem 1.25rem;
    border-radius: 30px;
    background: var(--white);
    border: 1.5px solid var(--primary);
    color: var(--primary);
    font-weight: 600;
    font-size: 0.88rem;
    box-shadow: 0 2px 8px rgba(45, 95, 138, 0.08);
    cursor: pointer;
    transition: all 0.2s;
    touch-action: manipulation;
}

.page-toggle-pill:hover {
    background: var(--primary-light);
}

/* Home hero */
.hero {
    text-align: center;
    padding: 3rem 1rem 2rem;
}

.hero h1 {
    font-size: 2.25rem;
    color: var(--primary-dark);
    margin-bottom: 1.5rem;
}

.hero .search-form {
    max-width: 520px;
    margin: 0 auto 1.5rem auto;
    position: relative;
}

.hero .search-input {
    width: 100%;
    padding: 0.85rem 1.25rem;
    padding-right: 3.8rem;
    font-size: 1.15rem;
    border: 2px solid var(--border);
    border-radius: var(--radius);
    background: var(--white);
    box-shadow: var(--shadow);
    transition: border-color 0.2s, box-shadow 0.2s;
}

.hero .search-input:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(45, 95, 138, 0.15), var(--shadow);
}

.hero .search-btn {
    position: absolute;
    right: 6px;
    top: 50%;
    transform: translateY(-50%);
    padding: 0.55rem 1rem;
    font-size: 1.05rem;
    border-radius: 6px;
}

.hero p {
    color: var(--text-light);
    font-size: 1.05rem;
    margin-bottom: 0;
    max-width: 520px;
    margin-left: auto;
    margin-right: auto;
}

/* Sample words section */
.sample-section {
    text-align: center;
    margin-top: 1.5rem;
}

.sample-label {
    color: var(--text-light);
    margin-bottom: 0.75rem;
    font-size: 0.95rem;
}

.sample-list {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 0.5rem;
}

.sample-pill {
    display: inline-block;
    padding: 0.4rem 0.9rem;
    background: var(--primary-light);
    color: var(--primary);
    border-radius: 20px;
    font-size: 0.9rem;
    font-weight: 500;
    text-decoration: none;
    transition: all 0.2s;
}

.sample-pill:hover {
    background: var(--primary);
    color: var(--white);
    transform: translateY(-1px);
}

/* Comments section */
.comments-section {
    margin-top: 3rem;
    border-top: 1px solid var(--border);
    padding-top: 2rem;
}

.comments-section h2 {
    font-size: 1.25rem;
    margin-bottom: 1rem;
    color: var(--primary-dark);
}

.comment-error {
    background-color: #fee2e2;
    border: 1px solid #f87171;
    color: #b91c1c;
    padding: 0.75rem 1rem;
    border-radius: var(--radius);
    font-size: 0.9rem;
    margin-bottom: 1rem;
}

.comment-form {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    margin-bottom: 1.5rem;
}

.comment-form .cf-turnstile {
    margin: 0.25rem 0;
}

.comment-form input,
.comment-form textarea {
    padding: 0.6rem 0.75rem;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    font-size: 0.95rem;
    font-family: inherit;
    resize: vertical;
}

.comment-form textarea { min-height: 80px; }

.comment-form button {
    align-self: flex-start;
    padding: 0.6rem 1.5rem;
    background: var(--primary);
    color: var(--white);
    border: none;
    border-radius: var(--radius);
    font-size: 0.95rem;
    cursor: pointer;
    transition: background 0.2s;
}

.comment-form button:hover { background: var(--primary-dark); }

.comments-list { list-style: none; }

.comment {
    padding: 1rem;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    margin-bottom: 0.75rem;
    background: var(--white);
}

.comment-author {
    font-weight: 600;
    color: var(--primary-dark);
}

.comment-date {
    font-size: 0.8rem;
    color: var(--text-light);
    margin-left: 0.5rem;
}

.comment-text {
    margin-top: 0.4rem;
    color: var(--text);
}

/* Footer */
.footer {
    background: var(--primary-dark);
    color: rgba(255,255,255,0.7);
    text-align: center;
    padding: 2rem 1rem;
    font-size: 0.9rem;
}

.footer a { color: rgba(255,255,255,0.9); }

/* Ad slot */
.ad-slot {
    background: var(--white);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 0.75rem;
    margin: 1.5rem 0;
    text-align: center;
    min-height: 90px;
}

/* Responsive */
@media (max-width: 768px) {
    /* Compact single-row header */
    .header {
        padding: 0.45rem 0;
    }

    .header-inner {
        flex-direction: row;
        align-items: center;
        gap: 0.5rem;
        padding: 0 0.75rem;
    }

    .logo {
        font-size: 1.1rem;
        gap: 0.25rem;
        flex-shrink: 0;
    }

    .header--home .logo {
        white-space: normal;
        flex-shrink: 1;
        line-height: 1.3;
        justify-content: center;
        text-align: center;
    }

    .header--home .logo-tagline {
        font-size: 0.85rem;
    }

    .logo-icon {
        font-size: 1.25rem;
    }

    .search-form {
        flex: 1;
        min-width: 0;
        max-width: none;
    }

    .search-input {
        padding: 0.4rem 2.2rem 0.4rem 0.65rem;
        font-size: 0.88rem;
        height: 36px;
        border-width: 1.5px;
    }

    .search-btn {
        right: 3px;
        padding: 0.25rem 0.5rem;
        font-size: 0.85rem;
        height: 28px;
    }

    .autocomplete-item {
        padding: 0.45rem 0.75rem;
        font-size: 0.88rem;
    }

    /* Tighten vertical spacing */
    .main {
        padding: 0.75rem 0.75rem 2rem;
    }

    .word-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.6rem;
        margin-bottom: 0.75rem;
    }

    .word-header-main {
        gap: 0.75rem;
        width: 100%;
    }

    .dante-avatar {
        width: 52px;
        height: 52px;
        border-radius: 8px;
    }

    .word-header h1 {
        font-size: 1.35rem;
        margin-bottom: 0.2rem;
    }

    .word-meta {
        font-size: 0.85rem;
        line-height: 1.4;
        margin-bottom: 0.35rem;
    }

    .word-share-bar {
        width: 100%;
        justify-content: flex-start;
        padding-top: 0.35rem;
        border-top: 1px dashed var(--border);
    }

    .share-btn {
        width: 30px;
        height: 30px;
    }

    .tabs {
        margin-bottom: 0.6rem;
        overflow-x: visible;
        width: 100%;
        display: flex;
    }

    .tab-btn {
        flex: 1 1 0;
        min-width: 0;
        text-align: center;
        padding: 0.5rem 0.25rem;
        font-size: 0.82rem;
    }

    .tab-btn .count {
        font-size: 0.78rem;
    }

    .filter-bar {
        display: flex;
        flex-direction: row;
        align-items: center;
        justify-content: flex-start;
        gap: 0.6rem;
        margin-bottom: 0.6rem;
    }

    .filter-group {
        flex: 1 1 auto;
        min-width: 110px;
        gap: 0.35rem;
    }

    .filter-group label {
        font-size: 0.82rem;
    }

    .filter-group select {
        padding: 0.35rem 0.5rem;
        font-size: 0.82rem;
        width: 100%;
    }

    .results-summary {
        margin-bottom: 0.5rem;
        font-size: 0.82rem;
        padding: 0.32rem 0.85rem;
        white-space: nowrap;
    }

    .hero {
        padding: 1.5rem 0.5rem 1rem;
    }

    .hero h1 {
        font-size: 1.5rem;
        margin-bottom: 1rem;
    }

    .hero .search-form {
        margin-bottom: 1rem;
    }

    .hero .search-input {
        padding: 0.7rem 1rem;
        padding-right: 3.2rem;
        font-size: 1rem;
        height: 44px;
    }

    .hero .search-btn {
        right: 4px;
        padding: 0.4rem 0.75rem;
        font-size: 0.95rem;
        height: 34px;
    }

    .hero p {
        font-size: 0.92rem;
        margin-bottom: 0.5rem;
    }

    /* 2 Columns on mobile phone screens */
    .word-list {
        column-count: 2;
        column-gap: 0.6rem;
    }

    .word-list li {
        margin-bottom: 0.1rem;
    }

    .word-list a {
        padding: 0.3rem 0.35rem;
        font-size: 0.88rem;
        overflow: hidden;
        text-overflow: ellipsis;
        white-space: nowrap;
    }

    .word-list .syl-badge {
        font-size: 0.72rem;
        float: right;
        margin-left: 0.25rem;
        line-height: 1.35;
    }
}

@media (max-width: 480px) {
    .header-inner {
        gap: 0.4rem;
        padding: 0 0.5rem;
    }

    .logo {
        font-size: 1rem;
    }

    .logo-icon {
        font-size: 1.15rem;
    }

    .search-input {
        font-size: 0.85rem;
        padding: 0.35rem 2rem 0.35rem 0.55rem;
    }

    .word-header h1 {
        font-size: 1.25rem;
    }

    .pagination-pill {
        max-width: 270px;
        gap: 0.5rem;
    }

    .page-circle-btn {
        width: 38px;
        height: 38px;
    }

    .page-badge-text {
        font-size: 0.8rem;
    }
}

@media (min-width: 769px) {
    .pagination-bar,
    .results-summary {
        display: none !important;
    }
}

@media (min-width: 1024px) {
    .word-list { column-count: 4; }
}
