* {
    box-sizing: border-box;
}

:root {
    --background: #f4f5fa;
    --surface: #fff;
    --text: #25283a;
    --muted: #73798b;
    --border: #D1DCE4;
    --accent: #125D86;
    --accent-dark: #0D4565;
    --accent-light: #CAE9F9;
    --green: #16834a;
    --green-bg: #e4f7eb;
    --red: #c53240;
    --red-bg: #ffeaec;
    --yellow: #8c6500;
    --yellow-bg: #fff4ce;
    --blue: #245fc0;
    --blue-bg: #e7f0ff;
    --gray: #5c6373;
    --gray-bg: #b0b6bc;
}

/* =========================================================
   GENERAL
   ========================================================= */

html {
    font-size: 100%;
    -webkit-text-size-adjust: 100%;
    -ms-text-size-adjust: 100%;
}

body {
    margin: 0;
    padding: 10px;
    background: var(--background);
    color: var(--text);
    font-family: Arial, Helvetica, sans-serif;
}

main {
    max-width: 900px;
    margin: 0 auto;
}

header {
    text-align: center;
    margin-bottom: 20px;
}

.site-title {
    margin: 0;
    color: #125D86;
    font-size: clamp(32px, 6vw, 46px);
    letter-spacing: -1.5px;
    font-weight: 700;
}

.logo-name {
    color: #25283a;
}

.logo-bingo {
    color: #125D86;
}

.site-tagline {
    margin: 10px 0 0;
    color: #73798b;
    font-size: 16px;
    line-height: 1.5;
}

h1 {
    margin: 0 0 10px;
    font-size: clamp(32px, 6vw, 46px);
    letter-spacing: -1.5px;
}

header p {
    margin: 0;
    color: var(--muted);
    line-height: 1.6;
}

.panel {
    padding: 25px;
    margin-bottom: 20px;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 5px;
    box-shadow: 0 8px 28px rgba(30, 35, 60, .04);
}

.panel-title {
    margin-bottom: 20px;
    font-size: 25px;
    font-weight: bold;
    color: #125D86;
}

.dictionary-picker {
    display: grid;
    gap: 9px;
    margin-bottom: 24px;
    padding: 16px;
    background: #F3F8FB;
    border: 1px solid var(--border);
    border-radius: 5px;
}

.dictionary-picker label,
.field-label {
    font-size: 13px;
    font-weight: bold;
    margin: 5px 0 10px;
}

select,
input[type="number"] {
    max-width: 100%;
    padding: 11px 12px;
    border: 1px solid var(--border);
    border-radius: 5px;
    background: #fff;
    color: var(--text);
    font-size: 14px;
}

.dictionary-picker select {
    width: 100%;
}

.dictionary-help,
.muted {
    color: var(--muted);
    font-size: 12px;
    line-height: 1.6;
}

/* =========================================================
   NAMEBINGO HEADER
   ========================================================= */

.site-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 25px;
    width: 100%;
    margin: 0 0 20px;
    padding: 14px 16px;
    border-bottom: 1px solid #D1DCE4;
    text-align: left;
    position: relative;
    z-index: 100;
}

.site-brand {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    min-width: 0;
    text-decoration: none;
}

.site-header .site-title {
    margin: 0;
    padding: 0;
    color: #125D86;
    font-size: clamp(30px, 4vw, 36px);
    font-weight: 700;
    line-height: 1.15;
    letter-spacing: -1.5px;
    white-space: nowrap;
}

.site-header .site-tagline {
    margin: 5px 0 0;
    padding: 0;
    color: #73798b;
    font-size: 12px;
    line-height: 1.4;
    white-space: normal;
    overflow-wrap: anywhere;
    max-width: 100%;
}

/* Desktop navigation */

.site-navigation {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    flex-wrap: wrap;
    gap: 15px;
}

.site-navigation a {
    display: inline-block;
    padding: 5px 0;
    color: #25283a;
    font-family: Arial, Helvetica, sans-serif;
    font-size: 13px;
    font-weight: normal;
    text-decoration: none;
    white-space: nowrap;
}

.site-navigation a:hover {
    color: #25283a;
    text-decoration: underline;
    text-underline-offset: 4px;
}

/* Mobile menu button */

.site-menu-toggle {
    display: none;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 5px;
    width: 42px;
    height: 42px;
    flex: 0 0 auto;
    padding: 8px;
    border: 0;
    border-radius: 4px;
    background: transparent;
    color: #25283a;
    cursor: pointer;
}

.site-menu-toggle:hover {
    background: transparent;
    color: #25283a;
}

.site-menu-toggle span {
    display: block;
    width: 23px;
    height: 2px;
    border-radius: 2px;
    background: #25283a;
    transition: transform 0.2s ease, opacity 0.2s ease;
}

/* Hamburger animation */

.site-header.menu-open .site-menu-toggle span:nth-child(1) {
    transform: translateY(7px) rotate(45deg);
}

.site-header.menu-open .site-menu-toggle span:nth-child(2) {
    opacity: 0;
}

.site-header.menu-open .site-menu-toggle span:nth-child(3) {
    transform: translateY(-7px) rotate(-45deg);
}

/* =========================================================
   PERSONAL DICTIONARY FILE PICKER
   ========================================================= */

[id^="ownDictionaryFile"] {
    display: block;
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
    margin-top: 6px;
    padding: 8px;
    border: 1px dashed var(--border);
    border-radius: 5px;
    background: #fff;
    color: var(--text);
    font-size: 13px;
}

[id^="ownDictionaryFile"]::file-selector-button {
    margin: 0 12px 0 0;
    padding: 9px 13px;
    border: 0;
    border-radius: 5px;
    background: var(--accent);
    color: #fff;
    font: inherit;
    font-weight: 600;
    cursor: pointer;
    transition: filter .15s ease, transform .15s ease;
}

[id^="ownDictionaryFile"]::file-selector-button:hover {
    filter: brightness(.94);
}

[id^="ownDictionaryFile"]:focus-visible {
    outline: 2px solid var(--accent);
    outline-offset: 3px;
}

/* =========================================================
   WORD CARDS
   ========================================================= */

.words {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 30px minmax(0, 1fr);
    grid-template-rows: repeat(7, auto);
    align-items: stretch;
    gap: 0;
}

.word-box {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    grid-template-rows: subgrid;
    grid-row: 1 / span 7;
    align-content: stretch;
    min-width: 0;
    padding: 20px;
    position: relative;
    overflow: visible;
    text-align: center;
    background: #F3F8FB;
    border: 1px solid var(--border);
    border-radius: 5px;
}

.word-box:first-child {
    grid-column: 1;
}

.word-box:last-child {
    grid-column: 3;
}

.word-label {
    position: absolute;
    top: -12px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 2;
    margin: 0;
    padding: 5px 10px;
    color: var(--muted);
    background: #fff;
    font-size: 11px;
    line-height: 14px;
    font-weight: bold;
}

.word {
    grid-row: 2;
    position: relative;
    justify-self: center;
    width: max-content;
    max-width: none;
    min-width: 0;
    margin: 20px 0;
    left: auto;
    transform: none;
    overflow-wrap: normal;
    word-break: normal;
    font-size: clamp(24px, 5vw, 40px);
    font-weight: bold;
    letter-spacing: -1px;
    text-align: center;
    z-index: 2;
}

.translation {
    grid-row: 3;
    position: relative;
    justify-self: center;
    width: max-content;
    max-width: none;
    min-width: 0;
    margin: 0 0 10px;
    left: auto;
    transform: none;
    color: var(--muted);
    font-size: 16px;
    line-height: 1.5;
    text-align: center;
    overflow-wrap: normal;
    word-break: normal;
    z-index: 2;
}

.plus {
    display: flex;
    align-items: center;
    justify-content: center;
    color: #9a9db0;
    font-size: 25px;
    font-weight: bold;
}

/* =========================================================
   BUTTONS
   ========================================================= */

button {
    padding: 12px 18px;
    border: 0;
    border-radius: 5px;
    background: var(--accent);
    color: #fff;
    font-size: 14px;
    font-weight: normal;
    cursor: pointer;
}

button:hover {
    background: var(--accent-dark);
    color: #fff;
}

button:disabled {
    opacity: .5;
    cursor: not-allowed;
}

.small-button {
    width: 100%;
    margin-top: 10px;
    padding: 12px 8px;
    background: #CAE9F9;
    color: var(--accent-dark);
    font-size: 14px;
}

.secondary {
    background: #b0b6bc;
    color: var(--text);
}

.secondary:hover {
    background: #8f9499;
    color: var(--text);
}

/* Keep buttons and dictionary panels in their original rows */

#change1,
#change2 {
    grid-row: 4;
    align-self: end;
}

#loadDictionary1,
#loadDictionary2 {
    grid-row: 5;
    align-self: end;
    margin-top: 8px;
}

#dictionaryPanel1,
#dictionaryPanel2 {
    grid-row: 6;
    align-self: start;
    margin-top: 12px;
    text-align: left;
}

#dictionarySelect1,
#dictionarySelect2 {
    width: 100%;
    margin-top: 6px;
}

#ownDictionaryPicker1,
#ownDictionaryPicker2 {
    margin-top: 10px;
}

#typeWords1,
#typeWords2 {
    grid-row: 7;
    align-self: end;
}


/* Generate Name button:
   Keeps the button width stable when the text changes to "Generating...",
   preventing the surrounding buttons from shifting. */
   
#spin, #checkSingle {
    width: 150px;
    min-width: 150px;
    flex: 0 0 150px;
    white-space: nowrap;
    box-sizing: border-box;
}


/* Mobile */

@media (max-width: 600px) {
    #spin, #checkSingle {
        width: 100%;
        min-width: 0;
        flex: 1 1 100%;
    }
}


/* =========================================================
   RESULT
   ========================================================= */

.result {
    margin-top: 18px;
    padding: 25px 15px 15px;
    text-align: center;
    background: var(--accent-light);
    border-radius: 5px;
}

.result-label {
    color: var(--accent-dark);
    font-size: 12px;
    font-weight: bold;
    letter-spacing: 1.5px;
}

.domain {
    overflow-wrap: anywhere;
    margin: 12px 0;
    font-size: clamp(27px, 6vw, 43px);
    font-weight: bold;
    letter-spacing: -1px;
}

.meaning {
    color: #456579;
    font-size: 14px;
    line-height: 1.7;
}

.actions {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 20px;
}

.settings {
    display: flex;
    justify-content: center;
    align-items: center;
    flex-wrap: wrap;
    gap: 18px;
    width: 100%;
    margin-top: 22px;
    color: var(--muted);
    font-size: 14px;
}

.settings label {
    display: flex;
    align-items: center;
    gap: 7px;
}

input[type="checkbox"] {
    accent-color: var(--accent);
}

.settings-options {
    display: flex;
    flex: 0 0 100%;
    align-items: center;
    justify-content: center;
    gap: 16px;
    width: 100%;
}

/* =========================================================
   STATUS AND AVAILABILITY
   ========================================================= */

.status {
    min-height: 20px;
    margin-top: 16px;
    text-align: center;
    color: var(--muted);
    font-size: 13px;
    line-height: 1.6;
}

.availability {
    margin: 14px auto 0;
    text-align: center;
}

.availability-message {
    margin-top: 6px;
    color: var(--muted);
    font-size: 12px;
    line-height: 1.5;
}

.domain-status {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0;
    border-radius: 5px;
    font-size: 12px;
    font-weight: bold;
    line-height: 1.4;
    text-align: center;
}

.status-available {
    color: var(--green);
}

.status-registered {
    color: var(--red);
}

.status-redemption {
    color: var(--yellow);
}

.status-reserved {
    color: var(--blue);
}

.status-pending {
    color: #125D86;
}

.status-unknown {
    color: var(--gray);
}

/* Hide general status message */

#status {
    display: none !important;
}

/* =========================================================
   BULK GENERATOR
   ========================================================= */

.bulk-controls {
    display: flex;
    align-items: center;
    margin: 25px 0;
}

.field {
    display: grid;
    align-content: start;
    gap: 8px;
    min-width: 0;
}

.field select,
.field input {
    width: 100%;
}

.bulk-count-field {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 12px;
}

.bulk-count-field .field-label {
    margin: 0;
}

.bulk-count-options {
    display: flex;
    align-items: center;
    gap: 8px;
}

.bulk-count-option {
    position: relative;
    display: inline-flex;
    align-items: center;
    cursor: pointer;
}

.bulk-count-option input {
    position: absolute;
    opacity: 0;
    pointer-events: none;
}

.bulk-count-option span {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 90px;
    padding: 12px 18px;
    border: 1px solid var(--border);
    border-radius: 5px;
    background: #fff;
    color: var(--text);
    font-size: 14px;
    transition: background .15s, color .15s, border-color .15s;
}

.bulk-count-option input:checked + span {
    background: var(--accent);
    border-color: var(--accent);
    color: #fff;
}

.bulk-count-option input:focus-visible + span {
    outline: 2px solid var(--accent);
    outline-offset: 3px;
}

.bulk-checks {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 12px 24px;
    margin: 16px 0 20px;
    color: var(--muted);
    font-size: 14px;
}

.bulk-checks label {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    white-space: nowrap;
}

.bulk-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 18px;
}

.bulk-actions button {
    flex: 1 1 170px;
}

.results-summary {
    margin-top: 20px;
    color: var(--muted);
    font-size: 13px;
    line-height: 1.6;
}

.bulk-results {
    display: grid;
    gap: 0;
    margin-top: 14px;
    max-height: 560px;
    overflow: auto;
    background: #F3F8FB;
    border: 1px solid var(--border);
    border-radius: 5px;
}

.bulk-item {
    display: grid;
    grid-template-columns: 22px minmax(0, 1fr) auto;
    align-items: center;
    gap: 10px;
    padding: 12px;
    border-bottom: 1px solid var(--border);
}

.bulk-item:last-child {
    border-bottom: 0;
}

.bulk-select {
    width: 17px;
    height: 17px;
    margin: 0;
    cursor: pointer;
    accent-color: var(--accent);
}

.bulk-content {
    min-width: 0;
}

.bulk-name {
    overflow-wrap: anywhere;
    font-size: 14px;
    font-weight: bold;
}

.bulk-meaning {
    margin-top: 5px;
    color: var(--muted);
    font-size: 12px;
    line-height: 1.5;
}

.copy-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 34px;
    height: 34px;
    padding: 0;
    border-radius: 5px;
    background: #b0b6bc;
    color: var(--text);
    font-size: 20px;
    line-height: 1;
}

.copy-icon:hover {
    background: #8f9499;
    color: var(--text);
}

.bulk-status-cell {
    display: flex;
    justify-content: flex-end;
    align-items: center;
    min-width: 94px;
}

.bulk-status-cell .domain-status {
    max-width: 100%;
    overflow-wrap: anywhere;
}

/* =========================================================
   INFORMATION AND FOOTER
   ========================================================= */

.info {
    color: var(--muted);
    font-size: 14px;
    line-height: 1.8;
}

footer {
    padding: 0 0 20px;
    color: var(--muted);
    text-align: center;
    font-size: 13px;
}

[hidden] {
    display: none !important;
}

/* =========================================================
   DOMAIN TICKER
   ========================================================= */

.domain-ticker {
    --ticker-speed: 50;
    width: 100%;
    overflow: hidden;
    white-space: nowrap;
    margin: 10px 0 20px;
}

.domain-ticker-track {
    display: flex;
    flex-wrap: nowrap;
    width: max-content;
    white-space: nowrap;
    will-change: transform;
}

.domain-ticker-list {
    display: flex;
    flex: 0 0 auto;
    flex-wrap: nowrap;
    width: max-content;
    white-space: nowrap;
}

.domain-ticker-item {
    display: inline-block;
    flex: 0 0 auto;
    margin-right: 30px;
    white-space: nowrap;
}

.domain-ticker-item a {
    display: inline-block;
    color: #036899;
    text-decoration: none;
    white-space: nowrap;
}

@keyframes domain-scroll {
    from {
        transform: translateX(0);
    }

    to {
        transform: translateX(-50%);
    }
}

/* =========================================================
   BUY ME A COFFEE
   ========================================================= */

.support-widget {
    position: fixed;
    right: 22px;
    bottom: 22px;
    z-index: 9999;
    font-family: Arial, sans-serif;
}

.support-toggle {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 54px;
    height: 54px;
    padding: 0;
    border: none;
    border-radius: 12px;
    background: #125D86;
    color: #ffffff;
    font-size: 27px;
    cursor: pointer;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.2);
    transition: filter 0.2s ease, transform 0.2s ease;
}

.support-toggle:hover {
    filter: brightness(85%);
    transform: translateY(-2px);
}

.support-popup {
    display: none;
    position: absolute;
    right: 0;
    bottom: 66px;
    width: 250px;
    padding: 20px;
    background: #ffffff;
    border: 1px solid #e4e8ed;
    border-radius: 14px;
    box-shadow: 0 5px 25px rgba(0, 0, 0, 0.15);
    box-sizing: border-box;
    text-align: center;
}

.support-popup.open {
    display: block;
}

.support-popup * {
    box-sizing: border-box;
}

.support-close {
    position: absolute;
    top: 7px;
    right: 10px;
    padding: 0;
    border: none;
    background: transparent;
    color: #626a78;
    font-size: 23px;
    cursor: pointer;
}

.support-coffee {
    font-size: 30px;
    margin-bottom: 8px;
}

.support-title {
    margin-bottom: 8px;
    color: #25283a;
    font-size: 17px;
    font-weight: 700;
}

.support-text {
    margin: 0 0 15px;
    color: #626a78;
    font-size: 13px;
    line-height: 1.5;
}

.support-button {
    display: block;
    padding: 11px 12px;
    border-radius: 8px;
    background: #125D86;
    color: #ffffff;
    font-size: 14px;
    font-weight: 700;
    text-decoration: none;
    transition: filter 0.2s ease;
}

.support-button:hover {
    filter: brightness(85%);
}

/* =========================================================
   FLIP BUTTON BETWEEN WORD CARDS
   ========================================================= */

.word-connector {
    grid-column: 2;
    grid-row: 1 / span 6;
    position: relative;
    z-index: 2;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 30px;
    min-width: 30px;
    height: auto;
    margin: 0;
    padding: 0;
    overflow: visible;
    align-self: stretch;
}

.flip-button {
    position: absolute;
    left: 50%;
    top: 50%;
    transform: translate(-50%, -50%);
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    padding: 0;
    border: none;
    border-radius: 0;
    background: transparent;
    color: #555555;
    cursor: pointer;
    box-shadow: none;
}

.flip-button svg {
    width: 24px;
    height: 24px;
}

.flip-button:hover {
    background: transparent;
    border: none;
    color: #125D86;
    box-shadow: none;
}

/* =========================================================
   DICTIONARY EXAMPLE LINKS
   ========================================================= */

.dictionary-example-link,
.dictionary-example-link:visited {
    color: #25283a;
    text-decoration: none;
}

.dictionary-example-link:hover {
    color: #25283a;
    text-decoration: none;
}

/* =========================================================
   SERVER DICTIONARY HELP
   ========================================================= */

#serverDictionaryHelp {
    margin: 0 0 20px;
    padding: 14px 16px;
    border: 1px solid #CAE9F9;
    border-radius: 5px;
    background: #fff;
    color: #125D86;
    font-size: 14px;
    line-height: 1.6;
}

#serverDictionaryHelp a {
    color: #125D86;
    text-decoration: none;
    text-underline-offset: 2px;
}

#serverDictionaryHelp a:hover {
    color: #0D4565;
}

/* =========================================================
   SAVED DOMAINS
   ========================================================= */

#savedDomainsSection {
    margin-top: 30px;
}

.saved-domains-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 12px;
}

.saved-domains-title {
    color: var(--accent);
    font-size: 20px;
    font-weight: bold;
}

.saved-domains-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.saved-domains-actions button {
    padding: 10px 14px;
}

.saved-domains-toolbar {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 12px;
    margin-top: 12px;
}

.saved-domains-toolbar .results-summary {
    flex: 1 1 auto;
    min-width: 0;
    margin: 0;
    color: var(--muted);
    font-size: 13px;
    font-weight: normal;
    line-height: 1.6;
}

.saved-domains-buttons {
    display: flex;
    align-items: baseline;
    justify-content: flex-end;
    flex: 0 0 auto;
    gap: 12px;
}

.saved-copy-link {
    flex: 0 0 auto;
    padding: 0;
    margin: 0;
    border: none;
    border-radius: 0;
    background: transparent;
    color: var(--accent-dark);
    font-family: inherit;
    font-size: 13px;
    font-weight: normal;
    line-height: 1.6;
    text-align: right;
    text-decoration: none;
    cursor: pointer;
    white-space: nowrap;
}

.saved-copy-link:hover:not(:disabled) {
    background: transparent;
    color: var(--accent-dark);
    text-decoration: none;
}

.saved-copy-link.saved-remove-link,
.saved-copy-link.saved-remove-link:hover:not(:disabled) {
    background: transparent;
    color: var(--red);
    text-decoration: none;
}

.saved-copy-link:disabled {
    background: transparent;
    color: var(--accent-dark);
    opacity: 0.45;
    cursor: default;
}

.saved-copy-link.saved-remove-link:disabled {
    background: transparent;
    color: var(--red);
    opacity: 0.45;
    cursor: default;
}

#savedDomainsList {
    margin-top: 14px;
}

#savedDomainsList .saved-domain-item {
    grid-template-columns: 22px minmax(0, 1fr) auto;
}

#savedDomainsList .bulk-select {
    width: 17px;
    height: 17px;
    margin: 0;
}

#savedDomainsList .bulk-content {
    min-width: 0;
}

#savedDomainsList .bulk-name {
    overflow-wrap: anywhere;
    font-size: 14px;
    font-weight: bold;
}

#savedDomainsList .bulk-status-cell {
    display: flex;
    justify-content: flex-end;
    align-items: center;
    min-width: 94px;
}

#savedDomainsList .domain-status {
    max-width: 100%;
    overflow-wrap: anywhere;
}

/* =========================================================
   GENERATION HISTORY
   ========================================================= */

.history-link,
.history-link:hover,
.history-link:focus {
    padding: 0;
    margin: 0;
    border: 0;
    border-radius: 0;
    background: transparent;
    color: var(--accent-dark);
    font-family: inherit;
    font-size: inherit;
    font-weight: normal;
    line-height: inherit;
    text-decoration: none;
    cursor: pointer;
}

.history-link:hover {
    color: var(--accent);
}

#historySection {
    margin-top: 30px;
}

#historyList {
    margin-top: 14px;
}

#historyList .saved-domain-item {
    grid-template-columns: 22px minmax(0, 1fr) auto;
}

#historyList .bulk-select {
    width: 17px;
    height: 17px;
    margin: 0;
}

#historyList .bulk-content {
    min-width: 0;
}

#historyList .bulk-name {
    overflow-wrap: anywhere;
    font-size: 14px;
    font-weight: bold;
}

#historyList .bulk-status-cell {
    display: flex;
    justify-content: flex-end;
    align-items: center;
    min-width: 94px;
}

#historyList .domain-status {
    max-width: 100%;
    overflow-wrap: anywhere;
}

/* =========================================================
   MANUAL WORD ENTRY MODAL
   ========================================================= */

.manual-words-overlay[hidden] {
    display: none !important;
}

.manual-words-overlay {
    position: fixed;
    inset: 0;
    z-index: 10000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 18px;
    background: rgba(25, 35, 48, 0.58);
}

.manual-words-dialog {
    width: min(100%, 500px);
    max-height: min(90vh, 720px);
    overflow-y: auto;
    padding: 24px;
    background: #fff;
    border: 1px solid var(--border);
    border-radius: 7px;
    box-shadow: 0 16px 50px rgba(0, 0, 0, 0.22);
    text-align: left;
}

.manual-words-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 18px;
}

.manual-words-header h2 {
    margin: 0;
    color: var(--text);
    font-size: 21px;
    font-weight: 600;
}

.manual-words-close {
    flex: 0 0 auto;
    width: 34px;
    height: 34px;
    padding: 0;
    border: 0;
    border-radius: 5px;
    background: transparent;
    color: var(--muted);
    font-size: 27px;
    line-height: 1;
    cursor: pointer;
}

.manual-words-close:hover {
    background: #f0f3f6;
    color: var(--text);
}

.manual-words-card-label {
    display: block;
    margin-bottom: 7px;
    color: var(--accent-dark);
    font-size: 13px;
    font-weight: bold;
}

.manual-words-help {
    margin: 0 0 12px;
    color: var(--muted);
    font-size: 13px;
    line-height: 1.6;
}

#manualWordsInput {
    display: block;
    width: 100%;
    min-height: 180px;
    padding: 12px;
    border: 1px solid var(--border);
    border-radius: 5px;
    background: #fff;
    color: var(--text);
    font: inherit;
    font-size: 14px;
    line-height: 1.6;
    resize: vertical;
    box-sizing: border-box;
}

#manualWordsInput:focus {
    outline: 2px solid var(--accent-light);
    border-color: var(--accent);
}

.manual-words-count {
    min-height: 20px;
    margin-top: 8px;
    color: var(--muted);
    font-size: 12px;
}

.manual-words-actions {
    display: flex;
    justify-content: flex-end;
    gap: 10px;
    margin-top: 18px;
}

.manual-words-actions button {
    min-width: 105px;
}

.manual-words-cancel {
    background: #e8edf1;
    color: var(--text);
}

.manual-words-cancel:hover {
    background: #dce3e9;
    color: var(--text);
}

.manual-words-use {
    background: var(--accent);
    color: #fff;
}

.manual-words-use:hover {
    background: var(--accent-dark);
}

/* =========================================================
   CENTRAL SUPPORT REMINDER
   ========================================================= */

.support-reminder-overlay[hidden] {
    display: none !important;
}

.support-reminder-overlay {
    position: fixed;
    inset: 0;
    z-index: 10001;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    background: rgba(25, 35, 48, 0.58);
    font-family: Arial, sans-serif;
}

.support-reminder-dialog {
    position: relative;
    width: min(100%, 380px);
    padding: 30px 25px;
    background: #fff;
    border: 1px solid #e4e8ed;
    border-radius: 14px;
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.22);
    text-align: center;
}

.support-reminder-close {
    position: absolute;
    top: 10px;
    right: 12px;
    padding: 0;
    border: 0;
    background: transparent;
    color: #73798b;
    font-size: 25px;
    cursor: pointer;
}

.support-reminder-close:hover {
    background: transparent;
    color: #25283a;
}

.support-reminder-coffee {
    margin-bottom: 12px;
    font-size: 38px;
}

.support-reminder-title {
    margin: 0 0 12px;
    color: #25283a;
    font-size: 23px;
    font-weight: 700;
}

.support-reminder-text {
    margin: 0 0 22px;
    color: #626a78;
    font-size: 15px;
    line-height: 1.6;
}

.support-reminder-button {
    display: block;
    width: 100%;
    padding: 13px 16px;
    border: 0;
    border-radius: 8px;
    background: #125D86;
    color: #fff;
    font-size: 15px;
    font-weight: 700;
    text-decoration: none;
    cursor: pointer;
}

.support-reminder-button:hover {
    background: #0D4565;
    color: #fff;
}

.support-reminder-later {
    display: block;
    width: 100%;
    margin-top: 10px;
    padding: 10px;
    border: 0;
    border-radius: 8px;
    background: transparent;
    color: #73798b;
    font-size: 13px;
    cursor: pointer;
}

.support-reminder-later:hover {
    background: #f4f5fa;
    color: #25283a;
}

/* =========================================================
   DOMAIN GENERATION NAVIGATION
   ========================================================= */

.domain-navigation {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    padding: 0 34px;
    margin: 0;
    box-sizing: border-box;
}

button.generation-nav-button,
button.generation-nav-button:hover,
button.generation-nav-button:focus,
button.generation-nav-button:active,
button.generation-nav-button:focus-visible {
    all: unset !important;
    position: absolute !important;
    top: 50% !important;
    transform: translateY(-50%) !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    width: 28px !important;
    height: 28px !important;
    padding: 0 !important;
    margin: 0 !important;
    border: 0 !important;
    border-radius: 0 !important;
    outline: none !important;
    box-shadow: none !important;
    background: transparent !important;
    color: #125D86 !important;
    cursor: pointer !important;
    z-index: 5 !important;
    -webkit-tap-highlight-color: transparent !important;
}

#previousGeneration {
    left: 0 !important;
}

#nextGeneration {
    right: 0 !important;
}

.generation-nav-button svg {
    display: block;
    width: 24px;
    height: 24px;
}

button.generation-nav-button::before,
button.generation-nav-button::after {
    content: none !important;
    display: none !important;
}

button.generation-nav-button:disabled {
    opacity: 0.3 !important;
    cursor: default !important;
}

/* =========================================================
   NAMEBINGO EXTENSION PICKER
   ========================================================= */

.nb-extension-picker {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center;
    gap: 7px;
    width: 100%;
    margin: 8px 0;
}

.nb-extension-tag {
    appearance: none;
    border: 1px solid #d5d9e0;
    background: #fff;
    color: #25283a;
    border-radius: 7px;
    padding: 12px 18px;
    font: inherit;
    font-size: 14px;
    line-height: 1.2;
    cursor: pointer;
    transition: background .15s, color .15s, border-color .15s;
}

.nb-extension-tag:hover {
    border-color: #125D86;
}

.nb-extension-tag.is-selected {
    background: #125D86;
    border-color: #125D86;
    color: #fff;
}

.nb-add-extension {
    appearance: none;
    border: 1px dashed #9aa4b2;
    background: transparent;
    color: #125D86;
    border-radius: 7px;
    padding: 12px 18px;
    font: inherit;
    font-size: 14px;
    cursor: pointer;
    white-space: nowrap;
}

.nb-add-extension:hover,
.nb-add-extension:focus,
.nb-add-extension:active {
    background-color: #125D86 !important;
    border-color: #125D86 !important;
    color: #fff !important;
}

/* =========================================================
   CUSTOM EXTENSION MODAL
   ========================================================= */

.nb-extension-modal {
    position: fixed;
    inset: 0;
    z-index: 10020;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 18px;
    background: rgba(15, 20, 30, .55);
}

.nb-extension-modal[hidden] {
    display: none !important;
}

.nb-extension-dialog {
    width: min(100%, 480px);
    max-height: min(85vh, 700px);
    overflow: auto;
    background: #fff;
    color: #25283a;
    border-radius: 12px;
    padding: 22px;
    box-shadow: 0 15px 50px rgba(0,0,0,.2);
}

.nb-extension-dialog h2 {
    margin: 0 0 7px;
    font-size: 21px;
}

.nb-extension-dialog p {
    margin: 0 0 16px;
    color: #667085;
    font-size: 14px;
}

.nb-extension-list {
    display: flex;
    flex-direction: column;
    gap: 7px;
    margin: 14px 0 20px;
}

.nb-extension-list-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    border: 1px solid #e5e7eb;
    border-radius: 7px;
    padding: 8px 10px;
}

.nb-extension-remove {
    border: 0;
    background: transparent;
    color: #b42318;
    font-size: 20px;
    line-height: 1;
    cursor: pointer;
    padding: 2px 6px;
}

.nb-extension-add-row {
    display: flex;
    gap: 8px;
    margin: 12px 0;
}

.nb-extension-add-row input {
    box-sizing: border-box !important;
    min-width: 0 !important;
    flex: 1 1 auto !important;
    width: 100% !important;
    padding: 10px 12px !important;
    margin: 0 !important;
    border: 1px solid #cbd3dc !important;
    border-radius: 6px !important;
    background: #fff !important;
    color: #25283a !important;
    font-family: inherit !important;
    font-size: 14px !important;
    outline: none !important;
    box-shadow: none !important;
}

.nb-extension-add-row input:focus,
.nb-extension-add-row input:focus-visible {
    border-color: #aebbc8 !important;
    outline: none !important;
    box-shadow: none !important;
}

.nb-extension-add-row button,
.nb-extension-add-row button:hover,
.nb-extension-add-row button:focus,
.nb-extension-add-row button:active {
    background: #125D86 !important;
    border: 1px solid #125D86 !important;
    color: #fff !important;
}

.nb-extension-modal-actions {
    display: flex;
    justify-content: flex-end;
    gap: 8px;
    margin-top: 18px;
}

.nb-extension-modal-actions button {
    border: 1px solid #125D86;
    background: #125D86;
    color: #fff;
    border-radius: 7px;
    padding: 9px 13px;
    cursor: pointer;
}

.nb-extension-modal-actions .nb-extension-cancel,
.nb-extension-modal-actions .nb-extension-cancel:hover,
.nb-extension-modal-actions .nb-extension-cancel:focus,
.nb-extension-modal-actions .nb-extension-cancel:active {
    background: #fff !important;
    color: #25283a !important;
    border: 1px solid #cbd3dc !important;
}

.nb-extension-error {
    color: #b42318;
    font-size: 13px;
    min-height: 18px;
}

/* =========================================================
   TOP CONTROLS: HISTORY, TRANSLATION AND ONE WORD MODE
   ========================================================= */

.nb-top-controls {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center;
    gap: 8px;
    width: 100%;
    margin: 8px 0;
}

#toggleHistory,
#addTranslationButton,
#oneWordModeButton,
#toggleHistory:hover,
#toggleHistory:focus,
#toggleHistory:active,
#toggleHistory.history-link-open,
#toggleHistory.history-link-open:hover,
#addTranslationButton:hover,
#addTranslationButton:focus,
#addTranslationButton:active,
#addTranslationButton.is-active,
#oneWordModeButton:hover,
#oneWordModeButton:focus,
#oneWordModeButton:active {
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    box-sizing: border-box !important;
    min-height: 34px !important;
    padding: 12px 18px !important;
    margin: 0 !important;
    border: 1px solid #d5d9e0 !important;
    border-radius: 7px !important;
    background: transparent !important;
    box-shadow: none !important;
    font-family: inherit !important;
    font-size: 14px !important;
    line-height: 18px !important;
    white-space: nowrap !important;
}

#toggleHistory,
#addTranslationButton {
    color: #000 !important;
}

#toggleHistory.history-link-open,
#addTranslationButton.is-active {
    color: red !important;
}

#oneWordModeButton {
    cursor: pointer !important;
    touch-action: manipulation;
}

#oneWordModeButton.is-active {
    background: #125D86 !important;
    border-color: #125D86 !important;
    color: #fff !important;
}

/* =========================================================
   HYPHEN TOGGLE
   ========================================================= */

.try-hyphen-control {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    margin-top: 10px;
    cursor: pointer;
    user-select: none;
    font-size: 13px;
}

.try-hyphen-control[hidden] {
    display: none;
}

.try-hyphen-control input {
    position: absolute;
    opacity: 0;
    width: 1px;
    height: 1px;
    margin: 0;
}

.try-hyphen-slider {
    position: relative;
    display: inline-block;
    width: 40px;
    height: 22px;
    flex: 0 0 40px;
    border-radius: 20px;
    background: #b8bec8;
    transition: background 0.2s ease;
}

.try-hyphen-slider::before {
    content: "";
    position: absolute;
    width: 16px;
    height: 16px;
    left: 3px;
    top: 3px;
    border-radius: 50%;
    background: #fff;
    transition: transform 0.2s ease;
}

.try-hyphen-control input:checked + .try-hyphen-slider {
    background: #125D86;
}

.try-hyphen-control input:checked + .try-hyphen-slider::before {
    transform: translateX(18px);
}

.try-hyphen-control input:focus-visible + .try-hyphen-slider {
    outline: 2px solid #125D86;
    outline-offset: 3px;
}

.try-hyphen-control input:disabled + .try-hyphen-slider {
    opacity: 0.6;
    cursor: not-allowed;
}

/* =========================================================
   AVAILABILITY CHECK METHODS AND RESULT BOTTOM BAR
   ========================================================= */

.result-bottom-bar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 25px;
    padding: 15px 0 0;
    border: 0;
    border-top: 1px solid #fff;
}

.availability-methods {
    display: flex;
    align-items: center;
    gap: 10px;
    margin: 0;
    padding: 0;
    border: 0;
    background: transparent;
}

.availability-method {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    margin: 0;
    padding: 0;
    border: 0;
    background: transparent;
    cursor: pointer;
    user-select: none;
}

.availability-method input {
    position: absolute;
    opacity: 0;
    width: 1px;
    height: 1px;
}

.radio-dot {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 11px;
    height: 11px;
    flex: 0 0 11px;
    border: 1px solid #aeb6c0;
    border-radius: 50%;
    background: transparent;
}

.availability-method input:checked + .radio-dot {
    border-color: var(--accent);
}

.availability-method input:checked + .radio-dot::after {
    content: "";
    width: 5px;
    height: 5px;
    border-radius: 50%;
    background: var(--accent);
}

.method-name {
    color: #858c98;
    font-size: 14px;
    font-weight: 500;
    line-height: 20px;
}

.availability-method input:checked ~ .method-name {
    color: var(--accent);
}

/* Case controls */

.domain-case-controls {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 5px;
    margin: 0;
    padding: 0;
    border: 0;
    background: transparent;
}

.case-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 25px;
    height: 20px;
    margin: 0;
    padding: 0 3px;
    border: 0;
    border-radius: 0;
    background: transparent;
    color: #858c98;
    font-family: inherit;
    font-size: 13px;
    font-weight: 600;
    line-height: 20px;
    cursor: pointer;
}

.case-button:hover,
.case-button.active {
    background: transparent;
    color: var(--accent);
}

/* =========================================================
   NAMESILO API SETTINGS MODAL
   ========================================================= */

.api-settings-overlay {
    position: fixed;
    inset: 0;
    z-index: 10000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    background: rgba(20, 30, 45, 0.48);
}

.api-settings-dialog {
    width: 100%;
    max-width: 390px;
    padding: 24px;
    border-radius: 5px;
    box-sizing: border-box;
    background: #fff;
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.18);
}

.api-settings-header {
    margin-bottom: 20px;
}

.api-settings-header h3 {
    margin: 0;
    color: var(--text);
    font-size: 18px;
    font-weight: 700;
}

.api-settings-dialog label,
.api-settings-dialog > label {
    display: block;
    margin-top: 0;
    margin-bottom: 12px;
    color: var(--text);
    font-size: 13px;
    font-weight: 600;
}

.api-settings-dialog input {
    width: 100%;
    height: 42px;
    padding: 0 12px;
    border: 1px solid var(--border);
    border-radius: 5px;
    outline: none;
    color: var(--text);
    font-size: 14px;
}

.api-settings-dialog input:focus {
    border-color: var(--accent);
    box-shadow: 0 0 0 3px rgba(18, 93, 134, 0.1);
}

#nameSiloApiKey {
    width: 100%;
    box-sizing: border-box;
    border-radius: 5px;
}

.api-settings-actions {
    display: flex;
    width: 100%;
    justify-content: flex-end;
    gap: 10px;
    margin-top: 20px;
}

.api-settings-actions button {
    flex: 1;
    min-width: 0;
    box-sizing: border-box;
    padding: 9px 15px;
    border: 1px solid var(--border);
    border-radius: 7px;
    background: #fff;
    color: var(--text);
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
}

.api-settings-actions button.save {
    border-color: var(--accent);
    background: var(--accent);
    color: #fff;
}

.api-settings-actions button:hover {
    opacity: 0.88;
}

/* =========================================================
   ACTIVE WORD SOURCE BUTTON
   ========================================================= */

.small-button.source-active {
    background: #9AD9F9;
    color: #0D4565;
}

.small-button.source-active:hover {
    background: #125D86;
    color: #ffffff;
}

.small-button.source-active:focus,
.small-button.source-active:active {
    background: #9AD9F9;
    color: #0D4565;
}

/* =========================================================
   BRAND NAMES PAGE
   ========================================================= */

.brandname-page .brandname-controls {
    display: grid;
    gap: 20px;
    margin-bottom: 20px;
}

.brandname-page .brandname-length {
    display: grid;
    gap: 8px;
    max-width: 240px;
}

.brandname-page .brandname-length label,
.brandname-page .brandname-rules legend {
    color: var(--text);
    font-size: 15px;
    font-weight: bold;
	background-color: #fff;
}

/* Fixed letter positions */

.brandname-page .brandname-length select {
    width: 100%;
}

.brandname-page .brandname-position-section {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 7px;
}

.brandname-page .brandname-positions-heading {
    color: var(--text);
    font-size: 14px;
    font-weight: 600;
}

.brandname-page .brandname-positions-help {
    color: var(--muted);
    font-size: 13px;
}

.brandname-page #brandNamePositions {
    width: 100%;
    margin-top: 5px;
}

.brandname-page .brandname-position-row {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    align-items: center;
}

.brandname-page .brandname-position-row input {
    width: 44px;
    height: 44px;
    min-width: 44px;
    flex: 0 0 44px;
    box-sizing: border-box;
    padding: 0;
    text-align: center;
    font-size: 20px;
    font-weight: 400;
    text-transform: uppercase;
    color: #125D86;
}

/* Generation rules */

.brandname-page .brandname-rules {
    min-width: 0;
    margin: 0;
    padding: 0 16px 16px;
    border: 1px solid var(--border);
    border-radius: 5px;
    background: #F3F8FB;
}

.brandname-page #brandNameRules {
    display: flex;
    flex-wrap: wrap;
    gap: 12px 24px;
    color: var(--muted);
    font-size: 14px;
}

.brandname-page #brandNameRules h3 {
    width: 100%;
    margin: 8px 0 2px;
    color: var(--text);
    font-size: 14px;
}

.brandname-page #brandNameRules label {
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.brandname-page .brandname-extra-fields {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 12px 24px;
    width: 100%;
	margin-top: 15px;
}

.brandname-page .brandname-extra-field {
    display: flex;
    flex-direction: column;
    align-items: stretch !important;
    gap: 8px !important;
    box-sizing: border-box;
}

.brandname-page .brandname-extra-field span {
    color: var(--text);
    font-size: 13px;
    font-weight: 600;
}

.brandname-page .brandname-extra-field input {
    width: 100%;
    box-sizing: border-box;
    padding: 8px 10px;
}

.brandname-page .brandname-vowel-limits {
    display: flex;
    flex-wrap: wrap;
    gap: 16px;
    width: 100%;
	margin-top: 15px;
}

.brandname-page .brandname-vowel-limits label {
    display: flex;
    flex-direction: column;
    align-items: flex-start !important;
    gap: 6px !important;
}

.brandname-page .brandname-vowel-limits input {
    width: 80px;
}

/* Result area */

.brandname-page .brandname-result {
    background: var(--accent-light);
    border-radius: 5px;
}

.brandname-page .brandname-result .result-label {
    color: var(--accent-dark);
}

.brandname-page #brandNameResult {
    min-height: 1.3em;
}

.brandname-page #brandNameMessage {
    min-height: 20px;
}

/* Extension selector */

.brandname-page .brandname-settings {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 10px;
    margin-top: 16px;
}

.brandname-page .brandname-settings > label {
    color: var(--text);
    font-size: 13px;
    font-weight: 600;
}

.brandname-page .brandname-extension-picker {
    display: inline-flex;
    align-items: center;
    padding: 4px;
    border: 1px solid var(--border);
    border-radius: 7px;
    background: #fff;
}

.brandname-page .brandname-extension-picker select {
    min-width: 100px;
    padding: 7px 28px 7px 10px;
    border: 0;
    border-radius: 5px;
    background: transparent;
    color: var(--accent-dark);
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
}

/* Saved domains and bulk generator */

.brandname-page #brandSavedDomainsSection {
    margin-top: 22px;
}

.brandname-page #brandSavedDomainsSection[hidden],
.brandname-page #brandSavedDomainsList[hidden],
.brandname-page #brandBulkResults[hidden] {
    display: none;
}

.brandname-page #brandNameStatus {
    min-height: 20px;
}

.brandname-page #brandBulkGenerator {
    margin-top: 24px;
}

/* =========================================================
   RESPONSIVE
   ========================================================= */

@media (max-width: 800px) {

    .site-header {
        flex-wrap: wrap;
        gap: 0;
        padding: 12px 0 14px;
    }

    .site-brand {
        flex: 1 1 0;
        min-width: 0;
    }

    .site-header .site-title {
        font-size: 32px;
    }

    .site-header .site-tagline {
        font-size: 12px;
        white-space: normal;
        overflow-wrap: anywhere;
        max-width: 100%;
    }

    .site-menu-toggle {
        display: flex;
        flex-shrink: 0;
    }

    .site-navigation {
        display: none;
        flex: 0 0 100%;
        flex-direction: column;
        align-items: flex-start;
        gap: 0;
        width: 100%;
        margin-top: 14px;
        padding-top: 8px;
        border-top: 1px solid #D1DCE4;
    }

    .site-header.menu-open .site-navigation {
        display: flex;
    }

    .site-navigation a {
        display: block;
        width: 100%;
        padding: 11px 2px;
        font-size: 14px;
        border-bottom: 1px solid #edf0f3;
    }

    .site-navigation a:last-child {
        border-bottom: 0;
    }
}

@media (max-width: 650px) {

    .domain-navigation {
        padding: 0;
    }

    .support-widget {
        right: 12px;
        bottom: 12px;
    }

    .support-toggle {
        width: 48px;
        height: 48px;
        border-radius: 10px;
        font-size: 24px;
    }

    .support-popup {
        width: 235px;
        bottom: 60px;
    }

    .bulk-count-field {
        align-items: flex-start;
        flex-direction: column;
        gap: 10px;
    }

    .bulk-checks {
        align-items: flex-start;
        flex-direction: column;
        gap: 12px;
    }

    button.generation-nav-button,
    button.generation-nav-button:hover,
    button.generation-nav-button:focus,
    button.generation-nav-button:active,
    button.generation-nav-button:focus-visible {
        display: none !important;
    }
}

@media (max-width: 600px) {

    body {
        padding: 12px;
    }

    .panel {
        padding: 16px;
        border-radius: 5px;
    }

    .word {
        font-size: clamp(20px, 5vw, 30px);
        margin-bottom: 10px;
    }

    .word-box {
        padding: 15px;
    }

    .translation {
        font-size: 14px;
    }

    .actions button {
        flex: 1 1 100%;
    }

    .bulk-item {
        grid-template-columns: 20px minmax(0, 1fr) auto;
        gap: 8px;
    }

    .bulk-status-cell {
        grid-column: auto;
        grid-row: auto;
        justify-content: flex-end;
        min-width: 0;
    }

    .bulk-status-cell .domain-status {
        padding: 5px 7px;
        font-size: 11px;
    }

    .saved-domains-header {
        align-items: flex-start;
    }

    .saved-domains-title {
        font-size: 18px;
    }

    .saved-domains-actions {
        width: 100%;
    }

    .saved-domains-actions button {
        flex: 1 1 auto;
    }

    #savedDomainsList .saved-domain-item,
    #historyList .saved-domain-item {
        grid-template-columns: 20px minmax(0, 1fr) auto;
        gap: 8px;
    }

    #savedDomainsList .bulk-status-cell,
    #historyList .bulk-status-cell {
        grid-column: auto;
        grid-row: auto;
        justify-content: flex-end;
        min-width: 0;
    }

    #savedDomainsList .domain-status,
    #historyList .domain-status {
        padding: 5px 7px;
        font-size: 11px;
    }

    #serverDictionaryHelp {
        padding: 12px;
        font-size: 14px;
    }

    .manual-words-dialog {
        padding: 19px;
    }

    .manual-words-actions button {
        flex: 1 1 0;
        min-width: 0;
    }

    .nb-extension-picker {
        gap: 6px;
    }

    .nb-extension-dialog {
        padding: 16px;
    }

    .nb-extension-modal {
        align-items: flex-start !important;
        justify-content: center !important;
        padding: 12px !important;
        overflow-y: auto !important;
    }

    .nb-extension-dialog {
        width: 100% !important;
        max-height: calc(100vh - 24px) !important;
        max-height: calc(100dvh - 24px) !important;
        overflow-y: auto !important;
        box-sizing: border-box !important;
        margin: auto 0 !important;
        border-radius: 10px !important;
    }

    .nb-extension-list {
        margin: 10px 0 12px !important;
        gap: 5px !important;
    }

    .nb-extension-modal-actions {
        position: sticky !important;
        bottom: 0 !important;
        margin-top: 12px !important;
        padding: 10px 0 4px !important;
        background: #fff !important;
    }

    .try-hyphen-control {
        font-size: 13px;
    }
}

@media (max-width: 500px) {

    .saved-domains-toolbar {
        gap: 8px;
    }

    .saved-domains-buttons {
        gap: 10px;
    }

    .support-reminder-dialog {
        padding: 27px 20px;
    }
}

@media (max-width: 480px) {

    .availability-methods {
        gap: 8px;
    }

    .method-name {
        font-size: 12px;
    }

    .api-settings-dialog {
        padding: 20px;
    }
}

@media (max-width: 380px) {

    .site-header .site-title {
        font-size: 29px;
    }

    .site-header .site-tagline {
        font-size: 11px;
    }
}

@media (max-width: 600px) {

    .brandname-page .brandname-controls {
        gap: 16px;
    }

    .brandname-page .brandname-length {
        max-width: none;
    }

    .brandname-page .brandname-position-row {
        gap: 6px;
    }

    .brandname-page .brandname-position-row input {
        width: 40px;
        height: 40px;
        min-width: 40px;
        flex-basis: 40px;
    }

    .brandname-page .brandname-rules {
        padding: 0 12px 12px;
    }

    .brandname-page .brandname-extra-fields {
        grid-template-columns: 1fr;
    }
}



/* --------------------------------------------------
   BRAND NAME RULES — RESPONSIVE TWO-COLUMN LAYOUT
   Desktop: 6 checkboxes on the left, 5 on the right.
   Mobile: all checkboxes in one vertical column.
-------------------------------------------------- */

.brandname-rule-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    grid-template-rows: repeat(6, auto);
    grid-auto-flow: column;
    column-gap: 24px;
    row-gap: 10px;
    width: 100%;
}

.brandname-rule-grid > .brandname-rule-option {
    min-width: 0;
}

/* Mobile layout */
@media (max-width: 640px) {
    .brandname-rule-grid {
        grid-template-columns: minmax(0, 1fr);
        grid-template-rows: none;
        grid-auto-flow: row;
    }
}


/* --------------------------------------------------
   GENERATION CONFLICT MODAL
   Popup displayed when conflicting generation rules
   prevent the Brand Name Generator from creating a name.
-------------------------------------------------- */

#brandGenerationConflictModal {
    position: fixed;
    inset: 0;
    z-index: 999999;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    background: rgba(0, 0, 0, 0.58);
    box-sizing: border-box;
}

#brandGenerationConflictModal .brand-conflict-dialog {
    width: 100%;
    max-width: 480px;
    max-height: 85vh;
    overflow-y: auto;
    box-sizing: border-box;
    padding: 20px;
    border-radius: 10px;
    background: #fff;
    color: #181818;
    box-shadow: 0 15px 50px rgba(0, 0, 0, 0.25);
}

#brandGenerationConflictModal .brand-conflict-heading {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 20px;
}

#brandGenerationConflictModal .brand-conflict-heading h2 {
    margin: 0;
    font-size: 21px;
    font-weight: 700;
    color: #A91C00;
}

#brandGenerationConflictModal .brand-conflict-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    flex: 0 0 30px;
    width: 30px;
    height: 30px;
    border-radius: 20%;
    background: #A91C00;
    color: #fbfbfb;
    font-weight: 800;
    font-size: 19px;
}

#brandGenerationConflictModal .brand-conflict-label {
    margin-bottom: 12px;
    font-weight: 300;
	color: #A91C00;
}

#brandGenerationConflictModal .brand-conflict-list {
    margin: 0;
    padding-left: 24px;
}

#brandGenerationConflictModal .brand-conflict-list li {
    margin-bottom: 10px;
    line-height: 1.5;
}

#brandGenerationConflictModal .brand-conflict-help {
    margin: 10px 0;
    color: #666;
    font-size: 14px;
    line-height: 1.5;
}

#brandGenerationConflictModal .brand-conflict-actions {
    display: flex;
    justify-content: flex-end;
    margin-top: 10px;
}

#brandGenerationConflictModal #brandConflictOk {
    border: 0;
    border-radius: 5px;
    padding: 12px 18px;
    background: #125D86;
    color: #fff;
    font-size: 14px;
    font-weight: 300;
    cursor: pointer;
}

#brandGenerationConflictModal #brandConflictOk:hover {
    opacity: 0.85;
}




/* =========================================================
   NUMERIC GENERATOR — EXTRACTED INLINE STYLES
   ========================================================= */

.numeric-generation-conflict-modal {
    display: none;
}

.numeric-generation-conflict-modal.is-visible {
    display: flex;
}

.numeric-copy-fallback {
    position: fixed;
    opacity: 0;
}

.numeric-copy-selection-active {
    background-color: #125D86;
    color: #ffffff;
    border-color: #125D86;
}