/* ═══════════════════════════════════════════════════════════════════════
   FDN SITE CHROME
   Styles for header.php / footer.php / hub-shell.php / index.php —
   every page that isn't the homepage or a food/drink category page
   (those are covered by style.css). Same palette as style.css:
   black background, gold text, gold accent, dark-gold borders.
═══════════════════════════════════════════════════════════════════════ */

:root {
    --fdn-bg:        #000;
    --fdn-panel:     #111;
    --fdn-text:      #f5e1a4;
    --fdn-accent:    #f6d26b;
    --fdn-border:    #604a14;
    --fdn-font:      system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

#fdn-page-wrap {
    background: var(--fdn-bg);
    color: var(--fdn-text);
    font-family: var(--fdn-font);
}

.fdn-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* ───────────────────────────────────────────────────────────────────────
   HEADER
─────────────────────────────────────────────────────────────────────── */

.fdn-header {
    background: var(--fdn-bg);
    border-bottom: 1px solid var(--fdn-border);
    position: relative;
}

.fdn-topbar-row {
    display: grid;
    grid-template-columns: 1fr auto 1fr;
    align-items: center;
    gap: 16px;
    padding: 14px 20px 6px;
}

.fdn-topbar-phone {
    justify-self: start;
}

.fdn-phone-link {
    color: var(--fdn-accent);
    text-decoration: none;
    font-size: 0.85rem;
    font-weight: 700;
    letter-spacing: 0.06em;
}

.fdn-phone-link:hover {
    text-decoration: underline;
}

.fdn-topbar-title {
    justify-self: center;
    text-align: center;
}

.fdn-site-title-link {
    color: var(--fdn-accent);
    text-decoration: none;
    font-size: clamp(1.5rem, 3.4vw, 2.4rem);
    font-weight: 800;
    letter-spacing: 0.16em;
    text-transform: uppercase;
}

.fdn-topbar-language {
    justify-self: end;
}

.fdn-lang-menu {
    list-style: none;
    display: flex;
    gap: 10px;
    margin: 0;
    padding: 0;
    font-size: 0.78rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.fdn-lang-menu a {
    color: var(--fdn-text);
    text-decoration: none;
}

.fdn-lang-menu a:hover,
.fdn-lang-menu .fdn-lang-active a {
    color: var(--fdn-accent);
}

/* ── Search ── */

.fdn-search-row {
    display: flex;
    justify-content: center;
    padding: 6px 20px 14px;
}

.fdn-search-form {
    display: flex;
    width: 100%;
    max-width: 480px;
}

.fdn-search-input {
    flex: 1;
    padding: 8px 14px;
    background: var(--fdn-panel);
    border: 1px solid var(--fdn-border);
    border-right: none;
    border-radius: 999px 0 0 999px;
    color: var(--fdn-text);
    font-family: inherit;
    outline: none;
}

.fdn-search-input::placeholder {
    color: #a0895a;
}

.fdn-search-input:focus {
    border-color: var(--fdn-accent);
}

.fdn-search-submit {
    padding: 8px 20px;
    background: var(--fdn-accent);
    color: #000;
    font-weight: 700;
    text-transform: uppercase;
    font-size: 0.8rem;
    letter-spacing: 0.06em;
    border: 1px solid var(--fdn-accent);
    border-radius: 0 999px 999px 0;
    cursor: pointer;
}

.fdn-search-submit:hover {
    background: #ffe08a;
}

/* WordPress's default get_search_form() markup (search-form/search-field/
   search-submit) — some pages render this instead of the custom
   fdn-search-form above. Styled to match so the site looks consistent
   regardless of which one a given template uses. */
.search-form {
    display: flex;
    width: 100%;
    max-width: 480px;
    margin: 0 auto;
}

.search-form label {
    flex: 1;
    margin: 0;
}

.search-form .search-field {
    width: 100%;
    padding: 8px 14px;
    background: var(--fdn-panel);
    border: 1px solid var(--fdn-border);
    border-right: none;
    border-radius: 999px 0 0 999px;
    color: var(--fdn-text);
    font-family: inherit;
    outline: none;
    box-sizing: border-box;
}

.search-form .search-field::placeholder {
    color: #a0895a;
}

.search-form .search-field:focus {
    border-color: var(--fdn-accent);
}

.search-form .search-submit {
    padding: 8px 20px;
    background: var(--fdn-accent);
    color: #000;
    font-weight: 700;
    text-transform: uppercase;
    font-size: 0.8rem;
    letter-spacing: 0.06em;
    border: 1px solid var(--fdn-accent);
    border-radius: 0 999px 999px 0;
    cursor: pointer;
    flex-shrink: 0;
}

.search-form .search-submit:hover {
    background: #ffe08a;
}

/* ── Ticker (shared look for header + footer) ── */

.fdn-ticker-row,
.fdn-ticker-wrap {
    display: flex;
    align-items: center;
    height: 38px;
    border-top: 1px solid var(--fdn-border);
    border-bottom: 1px solid var(--fdn-border);
    background: var(--fdn-panel);
    overflow: hidden;
}

.fdn-ticker-label {
    flex-shrink: 0;
    padding: 0 16px;
    font-size: 0.7rem;
    font-weight: 800;
    letter-spacing: 0.12em;
    color: #000;
    background: var(--fdn-accent);
    height: 100%;
    display: flex;
    align-items: center;
}

.fdn-ticker-track-wrap {
    flex: 1;
    overflow: hidden;
    height: 100%;
    display: flex;
    align-items: center;
}

.fdn-ticker-track {
    display: flex;
    align-items: center;
    white-space: nowrap;
    animation: fdn-ticker-scroll 40s linear infinite;
    will-change: transform;
}

.fdn-ticker-track:hover {
    animation-play-state: paused;
}

/* Explicit pause state driven by fdn-navigation.js's ticker pause/play
   button, independent of :hover (needed since the pause button also
   sits inside .fdn-ticker-wrap, and touch devices have no hover state). */
.fdn-ticker-track.is-paused {
    animation-play-state: paused;
}

@keyframes fdn-ticker-scroll {
    0%   { transform: translateX(0); }
    100% { transform: translateX(-50%); }
}

.fdn-ticker-item,
.fdn-ticker-link {
    color: var(--fdn-text);
    text-decoration: none;
    font-size: 0.82rem;
    padding: 0 8px;
}

.fdn-ticker-item:hover,
.fdn-ticker-link:hover {
    color: var(--fdn-accent);
    text-decoration: underline;
}

.fdn-ticker-sep {
    color: var(--fdn-accent);
    opacity: 0.6;
    font-size: 0.6rem;
}

.fdn-ticker-controls {
    flex-shrink: 0;
    display: flex;
    gap: 4px;
    padding: 0 12px;
}

.fdn-ticker-btn {
    background: transparent;
    border: none;
    color: var(--fdn-text);
    cursor: pointer;
    font-size: 0.7rem;
    padding: 4px;
}

.fdn-ticker-btn:hover {
    color: var(--fdn-accent);
}

/* ── Primary Nav + Mega Menu ── */

.fdn-main-nav {
    border-top: 1px solid var(--fdn-border);
    padding: 8px 20px;
    position: relative;
}

.fdn-main-menu {
    list-style: none;
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 14px;
    margin: 0;
    padding: 0;
}

.fdn-main-menu > li {
    position: relative;
}

.fdn-main-menu > li > a {
    display: inline-block;
    padding: 6px 14px;
    color: var(--fdn-text);
    text-decoration: none;
    text-transform: uppercase;
    font-size: 0.8rem;
    letter-spacing: 0.08em;
    border-radius: 999px;
    transition: background 0.2s ease, color 0.2s ease;
}

.fdn-main-menu > li > a:hover,
.fdn-main-menu > li.fdn-active > a {
    background: var(--fdn-accent);
    color: #000;
}

.fdn-main-menu > li.menu-item-has-children > a::after {
    content: "▾";
    display: inline-block;
    margin-left: 5px;
    font-size: 0.7em;
    vertical-align: middle;
}

.fdn-main-menu > li > .sub-menu {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    min-width: 240px;
    background: var(--fdn-panel);
    border: 1px solid var(--fdn-border);
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.6);
    z-index: 70;
    list-style: none;
    margin: 6px 0 0;
    padding: 10px 0;
    text-align: left;
}

.fdn-main-menu > li.menu-item-has-children:hover > .sub-menu,
.fdn-main-menu > li.menu-item-has-children.fdn-dropdown-open > .sub-menu {
    display: block;
}

.fdn-main-menu .sub-menu a {
    display: block;
    padding: 8px 18px;
    color: var(--fdn-text);
    text-decoration: none;
    text-transform: none;
    letter-spacing: normal;
    font-size: 0.85rem;
    white-space: nowrap;
}

.fdn-main-menu .sub-menu a:hover {
    background: var(--fdn-accent);
    color: #000;
}

/* Grandchildren (e.g. Beer Nation under Alcoholic) render as an indented
   list inside the same dropdown panel, rather than a separate flyout. */
.fdn-main-menu .sub-menu .sub-menu {
    position: static;
    display: block;
    background: transparent;
    border: none;
    box-shadow: none;
    margin: 0;
    padding: 0;
}

.fdn-main-menu .sub-menu .sub-menu a {
    padding-left: 34px;
    font-size: 0.78rem;
    opacity: 0.8;
}

.fdn-mega-panel-backdrop {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.65);
    z-index: 74;
}

.fdn-mega-panel-backdrop.is-open {
    display: block;
}

.fdn-mega-panel {
    display: none;
    position: absolute;
    left: 50%;
    top: 100%;
    transform: translateX(-50%);
    width: min(1100px, calc(100% - 40px));
    max-height: 60vh;
    overflow-y: auto;
    background: var(--fdn-panel);
    border: 1px solid var(--fdn-border);
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.7);
    padding: 24px 28px;
    z-index: 75;
}

.fdn-mega-panel-inner {
    width: 100%;
}

.fdn-mega-panel.is-open {
    display: block;
}

.fdn-mega-panel-header {
    margin-bottom: 18px;
    padding-bottom: 14px;
    border-bottom: 2px solid var(--fdn-accent);
}

.fdn-mega-panel-title-link {
    color: var(--fdn-accent);
    font-size: 0.95rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    text-decoration: none;
}

.fdn-mega-panel-title-link:hover {
    text-decoration: underline;
}

.fdn-mega-panel-groups {
    display: flex !important;
    flex-direction: column !important;
    width: 100% !important;
    gap: 20px;
}

.fdn-mega-panel-category {
    display: grid !important;
    grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)) !important;
    width: 100% !important;
    gap: 4px 22px;
    align-items: start;
}

.fdn-mega-panel-category-title {
    grid-column: 1 / -1;
    color: var(--fdn-accent);
    font-size: 1rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin: 0 0 8px;
    padding-bottom: 8px;
    border-bottom: 1px solid var(--fdn-border);
}

.fdn-mega-panel-subcategory {
    margin-bottom: 14px;
}

.fdn-mega-panel-subcategory-title {
    color: var(--fdn-text);
    font-size: 0.74rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    margin: 0 0 6px;
    opacity: 0.8;
}

.fdn-mega-panel-subsubcategory {
    margin-bottom: 12px;
}

.fdn-mega-panel-subsubcategory-title {
    color: var(--fdn-text);
    font-size: 0.7rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.03em;
    margin: 0 0 4px;
    opacity: 0.7;
}

.fdn-mega-panel-links {
    list-style: none;
    margin: 0;
    padding: 0;
}

.fdn-mega-panel-links li {
    margin-bottom: 4px;
}

.fdn-mega-panel-links a {
    color: #cbb98a;
    text-decoration: none;
    font-size: 0.85rem;
}

.fdn-mega-panel-links a:hover {
    color: var(--fdn-accent);
    text-decoration: underline;
}

.fdn-mega-panel-pending,
.fdn-mega-panel-empty {
    display: inline-block;
    color: #6b5d42;
    font-size: 0.85rem;
    font-style: italic;
}

@media (max-width: 900px) {
    .fdn-mega-panel {
        width: calc(100% - 24px);
        max-height: 60vh;
        padding: 18px 20px;
    }

    .fdn-mega-panel-category {
        grid-template-columns: 1fr;
        gap: 4px;
    }
}

.fdn-gold-divider {
    height: 3px;
    background: linear-gradient(90deg, transparent, var(--fdn-accent) 15%, var(--fdn-accent) 85%, transparent);
}

/* Nation page intro content -- shown between the title and the map
   only when the page has real written content (page-nation.php). */
.fdn-nation-intro {
    margin: 0 0 24px;
    padding: 18px 20px;
    background: var(--fdn-panel);
    border: 1px solid var(--fdn-border);
    border-radius: 4px;
    color: #cbb98a;
    font-size: 0.95rem;
    line-height: 1.6;
}

.fdn-nation-intro > *:last-child {
    margin-bottom: 0;
}

.fdn-nation-intro h1,
.fdn-nation-intro h2,
.fdn-nation-intro h3,
.fdn-nation-intro h4 {
    color: var(--fdn-accent);
}

.fdn-nation-intro a {
    color: var(--fdn-accent);
}

/* Plain wrapper — page-specific layout (grid, etc.) is added by the
   page content itself (e.g. front-page.php's own .fdn-layout). */
#fdn-main.fdn-main-layout {
    background: var(--fdn-bg);
    min-height: 40vh;
}

/* ───────────────────────────────────────────────────────────────────────
   SHARED BUTTONS (base .fdn-btn comes from style.css, loaded site-wide)
─────────────────────────────────────────────────────────────────────── */

.fdn-btn-sm {
    padding: 4px 14px;
    font-size: 0.72rem;
}

.fdn-btn-primary {
    background: var(--fdn-accent);
    color: #000;
}

/* Marks the currently-selected role button (e.g. "Tea Sommeliers") when
   viewing the People breakdown under the map, and a lower-emphasis
   style for the "← Back" link that returns to the default People/
   Companies/Cities row. */
.fdn-btn-active {
    background: var(--fdn-accent);
    color: #000;
}

.fdn-btn-ghost {
    opacity: 0.65;
}

.fdn-btn-ghost:hover {
    opacity: 1;
}

/* ───────────────────────────────────────────────────────────────────────
   PEOPLE DIRECTORY (page-nation.php) -- shown below the map/buttons
   when a People role category (e.g. Tea Sommeliers) has real data in
   fdn_get_people_directory(). Cards mirror .hot-buy-box's dark/gold
   styling further down this cascade (style.css) for visual consistency
   with the other box-based sections on this page, but stacked as
   name-over-location rather than a single centered label.
   ─────────────────────────────────────────────────────────────────────── */
.fdn-people-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(210px, 1fr));
    gap: 14px;
}

.fdn-people-card {
    background-color: #1a1a1a;
    border: 1px solid #c9a84c;
    border-radius: 8px;
    padding: 14px 16px;
    display: flex;
    flex-direction: column;
    gap: 4px;
    transition: all 0.3s ease;
}

.fdn-people-card:hover {
    background-color: #222;
    border-color: #e8c96a;
    transform: translateY(-3px);
    box-shadow: 0 6px 20px rgba(201, 168, 76, 0.3);
}

.fdn-people-name {
    color: #f3d98b;
    font-size: 0.95rem;
    font-weight: 700;
}

.fdn-people-location {
    color: #c9a84c;
    font-size: 0.8rem;
    opacity: 0.8;
}

.fdn-people-source {
    margin-top: 18px;
    font-size: 0.78rem;
    color: #999;
    text-align: center;
}

.fdn-people-source a {
    color: #c9a84c;
}

/* ───────────────────────────────────────────────────────────────────────
   HUB SHELL (hub-shell.php)
─────────────────────────────────────────────────────────────────────── */

.fdn-hub-main {
    display: block;
    padding-bottom: 40px;
}

.fdn-hub-header {
    padding: 30px 0 20px;
    border-bottom: 3px solid var(--fdn-accent);
    margin-bottom: 30px;
}

.fdn-hub-header--drink   { border-bottom-color: #b46a4f; }
.fdn-hub-header--guides  { border-bottom-color: #7fa8c9; }
.fdn-hub-header--events  { border-bottom-color: #9fc97f; }
.fdn-hub-header--map     { border-bottom-color: #c97fbf; }

.fdn-breadcrumb-list {
    list-style: none;
    display: flex;
    justify-content: flex-start;
    text-align: left;
    gap: 8px;
    margin: 0 0 14px;
    padding: 0;
    font-size: 0.78rem;
    color: #a0895a;
}

.fdn-breadcrumb-list a {
    color: #a0895a;
    text-decoration: none;
}

.fdn-breadcrumb-list a:hover {
    color: var(--fdn-accent);
}

.fdn-breadcrumb-sep {
    opacity: 0.6;
}

.fdn-hub-title {
    font-size: clamp(1.6rem, 4vw, 2.4rem);
    color: var(--fdn-accent);
    text-transform: uppercase;
    letter-spacing: 0.08em;
    margin: 0;
}

.fdn-hub-layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 280px;
    gap: 32px;
    align-items: start;
}

.fdn-hub-posts-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
    gap: 20px;
}

.fdn-hub-post-card {
    background: var(--fdn-panel);
    border: 1px solid var(--fdn-border);
    border-radius: 4px;
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

.fdn-hub-post-thumb img {
    width: 100%;
    display: block;
    aspect-ratio: 16 / 10;
    object-fit: cover;
}

.fdn-hub-post-body {
    padding: 14px 16px 18px;
    display: flex;
    flex-direction: column;
    gap: 8px;
    flex: 1;
}

.fdn-hub-post-title {
    font-size: 1rem;
    margin: 0;
}

.fdn-hub-post-title a {
    color: var(--fdn-text);
    text-decoration: none;
}

.fdn-hub-post-title a:hover {
    color: var(--fdn-accent);
}

.fdn-hub-post-excerpt {
    font-size: 0.85rem;
    color: #cbb98a;
    flex: 1;
}

.fdn-hub-sidebar {
    background: var(--fdn-panel);
    border: 1px solid var(--fdn-border);
    border-radius: 4px;
    padding: 18px;
}

.fdn-no-content,
.fdn-hub-not-found {
    padding: 40px 0;
    text-align: center;
    color: #cbb98a;
}

.fdn-hub-not-found h1 {
    color: var(--fdn-accent);
    margin-bottom: 10px;
}

/* ───────────────────────────────────────────────────────────────────────
   INDEX / ARCHIVE (index.php)
─────────────────────────────────────────────────────────────────────── */

.fdn-index-main {
    padding: 30px 0 50px;
}

.fdn-page-header {
    margin-bottom: 24px;
}

.fdn-page-title {
    color: var(--fdn-accent);
    text-transform: uppercase;
    letter-spacing: 0.06em;
    font-size: clamp(1.5rem, 3.6vw, 2.2rem);
}

.fdn-posts-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
    gap: 24px;
}

.fdn-post-card {
    background: var(--fdn-panel);
    border: 1px solid var(--fdn-border);
    border-radius: 4px;
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

.fdn-post-card-thumb img {
    width: 100%;
    display: block;
    aspect-ratio: 16 / 9;
    object-fit: cover;
}

.fdn-post-card-body {
    padding: 16px 18px 20px;
    display: flex;
    flex-direction: column;
    gap: 8px;
    flex: 1;
}

.fdn-post-card-meta {
    font-size: 0.72rem;
    color: #a0895a;
    text-transform: uppercase;
    letter-spacing: 0.06em;
}

.fdn-post-card-title {
    margin: 0;
    font-size: 1.1rem;
}

.fdn-post-card-title a {
    color: var(--fdn-text);
    text-decoration: none;
}

.fdn-post-card-title a:hover {
    color: var(--fdn-accent);
}

.fdn-post-card-excerpt {
    font-size: 0.88rem;
    color: #cbb98a;
    flex: 1;
}

.fdn-pagination {
    margin-top: 36px;
    display: flex;
    justify-content: center;
}

.fdn-pagination .nav-links {
    display: flex;
    gap: 8px;
}

.fdn-pagination a.page-numbers,
.fdn-pagination span.page-numbers {
    display: inline-block;
    padding: 6px 14px;
    border: 1px solid var(--fdn-border);
    border-radius: 999px;
    color: var(--fdn-text);
    text-decoration: none;
    font-size: 0.85rem;
}

.fdn-pagination a.page-numbers:hover,
.fdn-pagination span.page-numbers.current {
    background: var(--fdn-accent);
    color: #000;
    border-color: var(--fdn-accent);
}

.fdn-no-content-title {
    color: var(--fdn-accent);
    margin-bottom: 8px;
}

.fdn-no-content-text {
    color: #cbb98a;
    margin-bottom: 20px;
}

/* ───────────────────────────────────────────────────────────────────────
   FOOTER (footer.php)
─────────────────────────────────────────────────────────────────────── */

.fdn-footer {
    background: var(--fdn-bg);
    border-top: 1px solid var(--fdn-border);
    margin-top: 40px;
}

.fdn-footer-topbar {
    border-bottom: 1px solid var(--fdn-border);
}

.fdn-footer-topbar-inner {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 0;
    font-size: 0.78rem;
}

.fdn-footer-topbar-label {
    color: #a0895a;
    letter-spacing: 0.05em;
}

.fdn-footer-language,
.fdn-footer-language--fallback {
    display: flex;
    align-items: center;
    gap: 8px;
    color: var(--fdn-accent);
}

.fdn-language-menu {
    list-style: none;
    display: flex;
    gap: 8px;
    margin: 0;
    padding: 0;
}

.fdn-language-menu a {
    color: var(--fdn-text);
    text-decoration: none;
}

.fdn-language-menu a:hover,
.fdn-lang-current a {
    color: var(--fdn-accent);
}

.fdn-footer-top {
    padding: 30px 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 14px;
    text-align: center;
    border-bottom: 1px solid var(--fdn-border);
}

.fdn-footer-logo img {
    max-height: 48px;
}

.fdn-footer-site-name {
    color: var(--fdn-accent);
    font-size: 1.6rem;
    font-weight: 800;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    text-decoration: none;
}

.fdn-footer-tagline {
    color: #cbb98a;
    font-size: 0.85rem;
    margin: 0;
}

.fdn-footer-social {
    display: flex;
    gap: 10px;
}

.fdn-social-link {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 34px;
    height: 34px;
    border-radius: 50%;
    border: 1px solid var(--fdn-border);
    color: var(--fdn-text);
}

.fdn-social-link:hover {
    background: var(--fdn-accent);
    color: #000;
    border-color: var(--fdn-accent);
}

.fdn-footer-widgets {
    padding: 30px 0;
    border-bottom: 1px solid var(--fdn-border);
}

.fdn-footer-widget-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
}

.fdn-footer-widget-col {
    font-size: 0.85rem;
    color: #cbb98a;
}

.fdn-footer-hubs {
    padding: 26px 0;
    border-bottom: 1px solid var(--fdn-border);
    text-align: center;
}

.fdn-footer-hubs-title {
    color: var(--fdn-accent);
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 0.14em;
    margin-bottom: 16px;
}

.fdn-footer-hub-list {
    list-style: none;
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 10px;
    margin: 0;
    padding: 0;
}

.fdn-footer-hub-link {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 8px 16px;
    border: 1px solid var(--fdn-border);
    border-radius: 999px;
    color: var(--fdn-text);
    text-decoration: none;
    font-size: 0.82rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.fdn-footer-hub-link:hover {
    background: var(--fdn-accent);
    color: #000;
    border-color: var(--fdn-accent);
}

.fdn-footer-legal-inner {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 10px;
    padding: 18px 0;
    font-size: 0.75rem;
    color: #a0895a;
}

.fdn-footer-copyright-link {
    color: var(--fdn-accent);
    text-decoration: none;
}

.fdn-footer-legal-menu {
    list-style: none;
    display: flex;
    flex-wrap: wrap;
    gap: 14px;
    margin: 0;
    padding: 0;
}

.fdn-footer-legal-menu a {
    color: #a0895a;
    text-decoration: none;
}

.fdn-footer-legal-menu a:hover {
    color: var(--fdn-accent);
}

.fdn-back-to-top {
    position: fixed;
    right: 20px;
    bottom: 20px;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: var(--fdn-accent);
    color: #000;
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 6px 18px rgba(0, 0, 0, 0.5);
    z-index: 80;
}

.fdn-back-to-top:hover {
    background: #ffe08a;
}

/* ───────────────────────────────────────────────────────────────────────
   NATION PAGE — CHILD PAGES GRID (page-nation.php)
─────────────────────────────────────────────────────────────────────── */

.fdn-nation-children {
    padding: 30px 0;
    border-bottom: 1px solid var(--fdn-border);
}

.fdn-children-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
    gap: 20px;
}

.fdn-child-page-card {
    display: flex;
    flex-direction: column;
    background: var(--fdn-panel);
    border: 1px solid var(--fdn-border);
    border-radius: 4px;
    overflow: hidden;
    text-decoration: none;
    transition: border-color 0.2s ease;
}

.fdn-child-page-card:hover {
    border-color: var(--fdn-accent);
}

.fdn-child-page-thumb img {
    width: 100%;
    display: block;
    aspect-ratio: 16 / 10;
    object-fit: cover;
}

.fdn-child-page-body {
    padding: 14px 16px 18px;
}

.fdn-child-page-title {
    color: var(--fdn-text);
    font-size: 1rem;
    margin: 0 0 6px;
}

.fdn-child-page-card:hover .fdn-child-page-title {
    color: var(--fdn-accent);
}

.fdn-child-page-excerpt {
    color: #cbb98a;
    font-size: 0.85rem;
    margin: 0;
}

/* Grouped Explore layout (Category > Sub-category > linked pages) */
.fdn-explore-groups {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 30px;
    align-items: start;
}

.fdn-explore-category-title {
    color: var(--fdn-accent);
    font-size: 1.15rem;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    margin: 0 0 16px;
    padding-bottom: 10px;
    border-bottom: 2px solid var(--fdn-border);
    /* Title spans the full category width, sitting above the columns
       below rather than being flowed into the first one. */
    column-span: all;
}

/* Let each category's own content (its subcategories, or a flat link
   list for a category with no subcategory layer yet) flow into as many
   columns as its width allows. Alcoholic (7 subcategories, 31 items)
   and Non-Alcoholic (10 subcategories, 34 items) both benefit from
   this -- otherwise they'd each render as one long single column
   instead of spreading sideways -- and it naturally collapses to a
   single column on narrow categories without needing a separate
   breakpoint.

   Now that Business Types is skipped from this render loop (see the
   `continue` in page-nation.php -- it duplicated the sidebar links
   above the map, and was still all placeholders), Alcoholic and
   Non-Alcoholic are the only two categories sharing .fdn-explore-groups'
   row, so each gets roughly half the page width instead of a third.
   220px was sized for a narrower third-of-the-page box; at half width
   it under-uses the extra room, so it's narrowed to 150px (matching
   Food's .fdn-food-explore-subcat-groups) to fit more columns in the
   space now available. */
.fdn-explore-category {
    column-width: 150px;
    column-gap: 18px;
}

.fdn-explore-subcategory {
    margin-bottom: 18px;
    /* Keep a subcategory's heading and its links together rather than
       letting a column break land in the middle of a list. */
    break-inside: avoid-column;
    -webkit-column-break-inside: avoid;
    page-break-inside: avoid;
}

/* Same treatment for a category with no subcategory layer (its links
   sit directly under the category title, e.g. Alcoholic today). */
.fdn-explore-category > .fdn-explore-links {
    break-inside: avoid-column;
    -webkit-column-break-inside: avoid;
    page-break-inside: avoid;
}

.fdn-explore-subcategory-title {
    color: var(--fdn-text);
    font-size: 0.82rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin: 0 0 8px;
    opacity: 0.85;
}

.fdn-explore-links {
    list-style: none;
    margin: 0;
    padding: 0;
}

.fdn-explore-links li {
    margin-bottom: 5px;
}

.fdn-explore-links a {
    color: #cbb98a;
    text-decoration: none;
    font-size: 0.88rem;
}

.fdn-explore-links a:hover {
    color: var(--fdn-accent);
    text-decoration: underline;
}

.fdn-explore-link-pending {
    display: inline-block;
    color: #6b5d42;
    font-size: 0.88rem;
    font-style: italic;
}

/* ───────────────────────────────────────────────────────────────────────
   FOOD NATION — ANIMAL / PLANT / SEAFOOD EXPLORE LAYOUT (page-nation.php)
   All three categories hold real Category > Sub-category (> Sub-sub-
   category, for Animal's Game group) data and share the same column-
   width auto-flow treatment via .fdn-food-explore-subcat-groups, since
   all three have sub-categories of uneven size that a fixed column
   split can't balance well.

   Animal and Seafood (close enough in size at 40 and 58 items to share
   a row comfortably) sit side by side in a two-column top row. Plant
   -- placed last in the markup -- spans the full row width via
   .fdn-food-explore-category--wide's grid-column: 1 / -1, wrapping
   onto its own row underneath. At ~176 items, roughly 3x Animal's or
   Seafood's, Plant needs the entire page width to flow its sub-
   categories into enough columns to avoid running far taller than the
   other two; a shared third of the page was tried and rejected for
   this reason.
   ─────────────────────────────────────────────────────────────────────── */
/* Collapses a nation's whole Explore grid behind a toggle instead of
   always showing it expanded -- Food's Animal/Plant/Seafood grid alone
   totals ~274 items, pushing everything below it (Hot Buys, Event
   Listings, Articles) far down the page; Drink's Alcoholic/Non-
   Alcoholic/Business Types grid is smaller (~65 items) but uses the
   same toggle for a consistent experience across nations. <details>/
   <summary> is used instead of a JS-driven show/hide so it works with
   no JavaScript, keyboard focus, and screen readers for free. The
   toggle reuses .fdn-view-all-btn (style.css) -- the same class Hot
   Buys, Event Listings, and Articles already use for their own "View
   All ... →" links -- so it looks identical to those rather than
   introducing a new button style; only the handful of <summary>-
   specific resets below are added on top. Shared by both Food's own
   .fdn-food-explore-groups grid and the generic .fdn-explore-groups
   grid Drink (and any future nation with real Explore data) uses.

   Centering uses flex + align-self on the summary rather than
   text-align: center on a wrapping element, since text-align would
   inherit down into the grid and center-align every item name and
   sub-category heading inside it along with the button. */
.fdn-explore-toggle {
    display: flex;
    flex-direction: column;
    margin-top: 10px;
}

.fdn-explore-toggle-summary {
    align-self: center;
    list-style: none;
    cursor: pointer;
    user-select: none;
}

.fdn-explore-toggle-summary::-webkit-details-marker {
    display: none;
}

.fdn-explore-toggle .fdn-food-explore-groups,
.fdn-explore-toggle .fdn-explore-groups {
    margin-top: 26px;
}

.fdn-food-explore-groups {
    display: grid;
    grid-template-columns: repeat(2, minmax(280px, 1fr));
    gap: 30px;
    align-items: start;
}

.fdn-food-explore-category--wide {
    grid-column: 1 / -1;
}

@media (max-width: 700px) {
    .fdn-food-explore-groups {
        grid-template-columns: 1fr;
    }
}

/* Animal's sub-categories range from 3 items (Ground Game) to 10
   (Livestock, Big Game); Plant's from 7 (Stems) to 31 (Fruits);
   Seafood's from 2 (Echinoderms) to 24 (Fish). Either way, a fixed
   column split (like Animal's old three-way one) would leave some
   columns much longer than others no matter how it's divided.
   column-width lets the browser flow as many sub-category blocks per
   row as fit and balance the total height itself -- the same technique
   already used for Drink's Alcoholic/Non-Alcoholic groups via
   .fdn-explore-category above. .fdn-explore-subcategory's existing
   break-inside: avoid-column keeps each sub-category's heading
   attached to its own list (and, for Animal's Game group,
   .fdn-explore-subsubcategory does the same one level deeper). */
/* column-width was originally 220px, but with three equal category
   boxes each getting roughly a third of the page (~380-410px on a
   typical desktop width, based on how these boxes measured out before
   sub-categories existed), two 220px columns plus the 28px gap need
   about 468px -- more than any one box actually has, so every category
   was falling back to a single tall column instead of flowing
   sideways. 150px (with a smaller 18px gap) fits two columns in
   roughly 318px, comfortably inside that ~380-410px box, and will
   still expand to more columns automatically on wider screens --
   including Plant, which uses this same rule but has the full page
   width to itself via .fdn-food-explore-category--wide above, so it
   naturally ends up with far more columns than Animal or Seafood's
   narrower half-width boxes without needing its own override. */
.fdn-food-explore-subcat-groups {
    column-width: 150px;
    column-gap: 18px;
}

/* Sub-sub-category styling (currently only Animal's Game -> Big Game /
   Winged Game / Ground Game uses this) -- reuses .fdn-explore-subcategory's
   break-inside handling but hadn't been styled at all until now, since
   the only other place this 3rd nesting level exists (Drink's Business
   Types -> Point of Sale -> business types, via the generic explore
   branch further down this file) has always rendered with empty
   "Coming soon" lists so the gap went unnoticed. Sized a step down from
   .fdn-explore-subcategory-title, matching the same size relationship
   already established between .fdn-mega-panel-subcategory-title and
   .fdn-mega-panel-subsubcategory-title in the header's mega menu. */
.fdn-explore-subsubcategory {
    margin: 0 0 14px 12px;
    break-inside: avoid-column;
    -webkit-column-break-inside: avoid;
    page-break-inside: avoid;
}

/* Animal's Game groups specifically render with no <h5> label (see
   page-nation.php), so the indent + gap that separates a labeled
   sub-sub-category from the next one isn't needed here -- without a
   label to visually anchor, that gap just reads as unexplained
   whitespace. Scoped to this food-specific wrapper only, so the
   generic .fdn-explore-subsubcategory spacing above (used by Drink's
   Point of Sale groups, which do have labels) is untouched. */
.fdn-food-explore-subcat-groups .fdn-explore-subsubcategory {
    margin: 0;
}

.fdn-explore-subsubcategory-title {
    color: var(--fdn-text);
    font-size: 0.76rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    margin: 0 0 6px;
    opacity: 0.7;
}

/* ───────────────────────────────────────────────────────────────────────
   JOB NATION — INTERACTIVE POINT-OF-SALE PICKER (page-nation.php)
─────────────────────────────────────────────────────────────────────── */

.fdn-job-picker {
    display: grid;
    grid-template-columns: repeat(3, minmax(200px, 1fr));
    gap: 30px;
    align-items: start;
}

.fdn-job-picker-sublist {
    list-style: none;
    margin: 6px 0 0;
    padding-left: 16px;
}

/* Column 1: Producer/Processor have no destination page, but still get
   a hover highlight for visual consistency with the rest of the
   picker (scoped to this picker only -- .fdn-explore-link-pending
   stays non-interactive everywhere else on the site). */
.fdn-job-picker-business-types .fdn-explore-link-pending {
    cursor: default;
    transition: color 0.15s ease;
}

.fdn-job-picker-business-types .fdn-explore-link-pending:hover {
    color: var(--fdn-accent);
}

.fdn-job-picker-trigger {
    background: none;
    border: none;
    padding: 0;
    margin: 0;
    font: inherit;
    font-size: 0.88rem;
    color: #cbb98a;
    cursor: pointer;
    text-align: left;
    text-decoration: underline dotted;
    transition: color 0.15s ease;
}

.fdn-job-picker-trigger:hover,
.fdn-job-picker-trigger[aria-expanded="true"],
.fdn-job-picker-trigger.is-active {
    color: var(--fdn-accent);
}

.fdn-job-picker-pos[hidden] {
    display: none;
}

@media (max-width: 900px) {
    .fdn-job-picker {
        grid-template-columns: 1fr;
    }
}

/* ───────────────────────────────────────────────────────────────────────
   MOBILE
─────────────────────────────────────────────────────────────────────── */

@media (max-width: 900px) {
    .fdn-hub-layout {
        grid-template-columns: 1fr;
    }

    .fdn-footer-widget-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 600px) {
    .fdn-topbar-row {
        grid-template-columns: 1fr;
        justify-items: center;
        text-align: center;
        gap: 6px;
    }

    .fdn-main-menu {
        justify-content: flex-start;
        overflow-x: auto;
        flex-wrap: nowrap;
    }

    .fdn-posts-grid,
    .fdn-hub-posts-grid,
    .fdn-children-grid {
        grid-template-columns: 1fr;
    }

    .fdn-footer-legal-inner {
        flex-direction: column;
        text-align: center;
    }
}
