/* Itinerio - static travel content site (New York guides)
   Framework mirrors a clean editorial travel magazine: sticky header + hero +
   multi-section card grid + CTA blocks + footer. All colors live in CSS vars. */

:root {
  --bg: #fbfaf7;
  --surface: #ffffff;
  --primary: #0e7c86;
  --primary-dark: #0a5a62;
  --accent: #e8743b;
  --text: #1c2b30;
  --muted: #5b6b70;
  --border: #e7e2d6;
  --card-shadow: 0 10px 30px rgba(16, 48, 47, 0.08);
  --footer-bg: #10302f;        /* anchor reserved padding must match this */
  --footer-text: #cfe3e0;
  --footer-muted: #8fb0ac;
  --maxw: 1180px;
  --radius: 14px;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: "Outfit", "Manrope", "Segoe UI", Arial, sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
body.has-anchor { padding-bottom: 60px; }

/* ad slots hidden by default until explicitly shown */
body.ads-hidden { padding-bottom: 0 !important; }
body.ads-hidden .adbox,
body.ads-hidden #adAnchor,
body.ads-hidden #adInterstitial,
body.ads-hidden .ad-slot { display: none !important; }

img { max-width: 100%; display: block; }

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

.container { width: min(100% - 40px, var(--maxw)); margin: 0 auto; }

/* ---------- Header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: saturate(140%) blur(8px);
  border-bottom: 1px solid var(--border);
}
.header-inner { display: flex; align-items: center; justify-content: flex-start; gap: 18px; min-height: 68px; padding: 12px 0; }
.brand { display: flex; align-items: center; gap: 10px; }
.brand img { height: 40px; width: auto; }

/* Nav bar shows ONLY on the homepage AND only on mobile (<=860px).
   On PC the category navigation lives inside the header as a mega-menu. */
.main-nav { display: none; background: rgba(255, 255, 255, 0.92); -webkit-backdrop-filter: saturate(140%) blur(8px); backdrop-filter: saturate(140%) blur(8px); border-bottom: 1px solid var(--border); padding: 8px 0; position: relative; z-index: 5; }
.main-nav .nav-inner { display: flex; align-items: center; gap: 14px; min-height: 54px; }
.nav-list { list-style: none; display: flex; flex-wrap: wrap; gap: 16px 24px; margin: 0; padding: 0; }

/* Expand button: no border, colored vertical divider on its left.
   Clicking it opens a separate dropdown box (see .nav-expand-panel) and does
   NOT change the original horizontal nav bar. */
.nav-expand {
  display: none; align-items: center; justify-content: center;
  width: 38px; height: 34px; margin-left: 12px; padding: 0; flex-shrink: 0;
  background: transparent; border: none;
  border-left: 2px solid var(--primary);
  border-radius: 0; cursor: pointer;
}
.nav-expand svg { display: block; width: 18px; height: 18px; fill: var(--text); margin: 0 auto; transition: transform 0.2s ease; }
.nav-expand:hover { background: var(--bg); }
.main-nav.is-expanded .nav-expand svg { transform: rotate(180deg); }

/* Expand dropdown: a panel that drops down from the bottom of the nav bar,
   styled like the category dropdown menu (floating card + vertical list) */
.nav-expand-panel {
  position: absolute; top: 100%; left: 10px; right: 10px; z-index: 6;
  background: #fff; border: 1px solid var(--border);
  border-radius: 12px;
  box-shadow: 0 16px 30px rgba(16,48,47,0.12);
  opacity: 0; visibility: hidden; transform: translateY(-8px); pointer-events: none;
  transition: opacity 0.18s ease, transform 0.18s ease, visibility 0.18s;
}
.main-nav.is-expanded .nav-expand-panel { opacity: 1; visibility: visible; transform: translateY(0); pointer-events: auto; }
.nav-expand-list { list-style: none; margin: 0; padding: 10px 16px 12px; }
.nav-expand-list li { margin: 2px 0; }
.nav-expand-list a {
  display: block; padding: 7px 4px; color: var(--text); font-weight: 600; font-size: 14px;
  border-radius: 6px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.nav-expand-list a:hover { background: var(--bg); color: var(--primary); }

/* Header search icon: sits in the header, to the LEFT of the hamburger.
   Icon only - no input box. Tapping it opens the dedicated search page. */
/* Header action cluster: search icon sits to the LEFT of the hamburger,
   12px gap between them */
.header-actions { display: flex; align-items: center; gap: 12px; margin-left: auto; }
.header-search {
  display: flex; align-items: center; justify-content: center;
  width: 40px; height: 40px; flex-shrink: 0;
  border: none; background: transparent; color: var(--text); cursor: pointer;
  border-radius: 10px; transition: background 0.2s ease, color 0.2s ease;
}
.header-search svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; }
.header-search:hover { background: var(--bg); color: var(--primary); }

/* ---------- Header category mega-menu (PC / homepage only) ---------- */
/* Hidden everywhere except the homepage at >=861px; safe to keep in every
   page's header because CSS suppresses it otherwise. */
.header-nav { display: none; }
.header-cats { display: none; }
@media (min-width: 861px) {
  body[data-page="home"] .header-cats { display: flex; align-items: center; gap: 8px; }
  body[data-page="home"] .header-nav { display: flex; align-items: center; }
}
.cat-trigger {
  display: inline-flex; align-items: center; gap: 7px;
  background: transparent; border: none; cursor: pointer;
  color: var(--text); font-family: inherit; font-weight: 600; font-size: 15px;
  padding: 8px 6px; border-radius: 8px; transition: color 0.2s ease;
}
.cat-trigger:hover, .cat-trigger:focus-visible { color: var(--primary); }
.cat-trigger-ico { width: 16px; height: 16px; fill: currentColor; transition: transform 0.2s ease; }
.header-nav.is-open .cat-trigger-ico { transform: rotate(180deg); }

.header-quick-cat {
  display: inline-flex; align-items: center;
  color: var(--text); font-family: inherit; font-weight: 600; font-size: 15px;
  padding: 8px 10px; border-radius: 8px;
  transition: background 0.2s ease, color 0.2s ease;
}
.header-quick-cat:hover, .header-quick-cat:focus-visible {
  background: var(--bg); color: var(--primary);
}

/* Panel is a direct child of .header-nav but positioned against the sticky
   header so it spans the full header width and drops just below it. */
.cat-mega {
  position: absolute; top: 100%; left: 0; right: 0; z-index: 60;
  background: #fff; border-bottom: 1px solid var(--border);
  box-shadow: 0 22px 44px rgba(16,48,47,0.14);
  padding: 26px 0 28px;
  opacity: 0; visibility: hidden; transform: translateY(-8px); pointer-events: none;
  transition: opacity 0.18s ease, transform 0.18s ease, visibility 0.18s;
}
/* invisible bridge so the cursor can travel from the trigger into the panel
   without the :hover state dropping and the panel closing */
.cat-mega::before { content: ""; position: absolute; top: -16px; left: 0; right: 0; height: 16px; }
.header-nav:hover .cat-mega,
.header-nav:focus-within .cat-mega,
.header-nav.is-open .cat-mega {
  opacity: 1; visibility: visible; transform: translateY(0); pointer-events: auto;
}
.cat-mega-grid {
  display: grid; grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 22px 28px;
}
.cat-mega-title {
  display: block; font-weight: 700; color: var(--primary-dark);
  font-size: 15px; margin-bottom: 8px; padding-bottom: 8px;
  border-bottom: 1px solid var(--border);
}
.cat-mega-col a.cat-mega-art {
  display: block; color: var(--text); font-size: 13.5px; line-height: 1.5;
  padding: 3px 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.cat-mega-col a.cat-mega-art:hover { color: var(--primary); }
.cat-mega-all { display: inline-block; margin-top: 6px; font-size: 12.5px; font-weight: 700; color: var(--primary); }
.cat-mega-foot {
  display: flex; gap: 26px; margin-top: 20px; padding-top: 16px;
  border-top: 1px solid var(--border);
}
.cat-mega-foot a { color: var(--text); font-weight: 600; font-size: 14px; }
.cat-mega-foot a:hover { color: var(--primary); }

/* Search page: a large stand-alone search box + inline results */
.search-page { padding: 44px 0 24px; }
.search-page-head { text-align: center; max-width: 640px; margin: 0 auto 22px; }
.search-page-head h1 { font-size: clamp(26px, 4vw, 36px); margin: 0 0 8px; }
.search-page-head p { color: var(--muted); margin: 0; }
.search-page-form {
  position: relative; display: flex; align-items: center; gap: 8px;
  max-width: 640px; margin: 0 auto;
  border: 1px solid var(--border); border-radius: 30px;
  background: #fff; padding: 6px 6px 6px 16px;
  box-shadow: 0 8px 26px rgba(16,48,47,0.08);
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}
.search-page-form:focus-within { border-color: var(--primary); box-shadow: 0 8px 26px rgba(14,124,134,0.16); }
.search-page-form .search-ico { width: 20px; height: 20px; fill: none; stroke: var(--muted); stroke-width: 2; stroke-linecap: round; flex-shrink: 0; }
.search-page-input {
  flex: 1; border: none; outline: none; background: transparent;
  font-size: 17px; font-family: inherit; color: var(--text); padding: 11px 8px;
}
.search-rotate {
  position: absolute; left: 52px; top: 50%; transform: translateY(-50%);
  color: var(--muted); font-size: 17px; pointer-events: none;
  opacity: 1; transition: opacity 0.35s ease;
  max-width: calc(100% - 200px); overflow: hidden; white-space: nowrap;
}
.search-rotate::before { content: "Try searching: "; opacity: 0.85; }
.search-rotate.hidden { opacity: 0; }
.search-page-btn {
  display: flex; align-items: center; justify-content: center; gap: 6px;
  align-self: stretch;
  border: none; border-radius: 24px; padding: 0 22px;
  background: var(--primary); color: #fff; font-size: 15px; font-weight: 700; cursor: pointer;
  transition: background 0.2s ease;
}
.search-page-btn svg { width: 17px; height: 17px; fill: none; stroke: currentColor; stroke-width: 2.4; stroke-linecap: round; }
.search-page-btn:hover { background: var(--primary-dark); }
input[type="search"]::-webkit-search-cancel-button,
input[type="search"]::-webkit-search-decoration { -webkit-appearance: none; appearance: none; display: none; }
.search-page-results { max-width: 720px; margin: 18px auto 0; display: grid; gap: 12px; }
.search-page-results a.sr-card {
  display: flex; align-items: center; gap: 14px; padding: 12px 14px;
  border: 1px solid var(--border); border-radius: 12px; background: #fff; color: var(--text);
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}
.search-page-results a.sr-card:hover { border-color: var(--primary); box-shadow: 0 6px 18px rgba(16,48,47,0.08); color: var(--primary); }
.search-page-results .sr-thumb { width: 80px; height: 60px; object-fit: cover; border-radius: 8px; flex-shrink: 0; }
.search-page-results .sr-body { flex: 1; min-width: 0; }
.search-page-results .sr-title { font-weight: 700; font-size: 16px; }
.search-page-results .sr-cat { font-size: 13px; color: var(--muted); margin-top: 3px; }
.search-page-results .sr-empty { padding: 22px; text-align: center; color: var(--muted); border: 1px dashed var(--border); border-radius: 12px; }
.search-page-results .sr-all { display: block; text-align: center; margin-top: 4px; color: var(--primary); font-weight: 700; }
.nav-list > li { position: relative; }
.nav-list > li > a {
  color: var(--text); font-weight: 600; font-size: 14px; letter-spacing: 0.2px;
  display: flex; align-items: center; gap: 5px;
}
.nav-list > li > a:hover,
.nav-list > li > a.active { color: var(--primary); }
.has-dropdown > a::after {
  content: ""; display: inline-block; width: 6px; height: 6px;
  border-right: 2px solid currentColor; border-bottom: 2px solid currentColor;
  transform: rotate(45deg); margin-top: -3px; opacity: 0.55;
}
.dropdown {
  position: absolute; top: calc(100% + 10px); left: 0; z-index: 60;
  min-width: 260px; max-width: 340px;
  background: #fff; border: 1px solid var(--border); border-radius: 12px;
  box-shadow: 0 16px 40px rgba(16,48,47,0.12);
  padding: 14px 18px;
  opacity: 0; visibility: hidden; pointer-events: none; transform: translateY(-6px);
  transition: opacity 0.2s ease, transform 0.2s ease, visibility 0.2s;
}
.has-dropdown:hover > .dropdown,
.has-dropdown:focus-within > .dropdown,
.dropdown:hover {
  opacity: 1; visibility: visible; pointer-events: auto; transform: translateY(0);
}
.dropdown-all {
  display: block; font-weight: 700; color: var(--primary);
  margin-bottom: 8px; padding-bottom: 8px; border-bottom: 1px solid var(--border);
}
.dropdown ul { list-style: none; margin: 0; padding: 0; }
.dropdown li { margin: 5px 0; }
.dropdown a {
  display: block; padding: 3px 0; color: var(--text); font-size: 14px;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.dropdown a:hover { color: var(--primary); }

/* Mobile-only nav controls */
.nav-expand,
.mobile-menu { display: none; }
.hamburger {
  display: none; background: transparent; border: none; cursor: pointer;
  width: 40px; height: 40px; padding: 10px; flex-shrink: 0;
  border-radius: 10px; color: var(--text);
  transition: background 0.2s ease, color 0.2s ease;
  transform: translateY(-3px);
}
.hamburger:hover { background: var(--bg); color: var(--primary); }
.hamburger span { display: block; height: 2px; background: currentColor; margin: 5px 0; border-radius: 2px; }

/* ---------- Hero ---------- */
.hero { position: relative; height: 460px; overflow: hidden; display: flex; align-items: flex-end; }
.hero-carousel { position: absolute; inset: 0; }
.hero-carousel .slide { position: absolute; inset: 0; opacity: 0; transition: opacity 0.8s ease; }
.hero-carousel .slide.is-active { opacity: 1; }
.hero-carousel .slide img { width: 100%; height: 100%; object-fit: cover; display: block; }
.hero-arrow { position: absolute; top: 50%; transform: translateY(-50%); z-index: 3; background: rgba(8,22,24,0.45); color: #fff; border: none; width: 42px; height: 42px; border-radius: 50%; cursor: pointer; font-size: 24px; line-height: 1; display: flex; align-items: center; justify-content: center; }
.hero-arrow.prev { left: 14px; }
.hero-arrow.next { right: 14px; }
.hero-arrow:hover { background: rgba(8,22,24,0.7); }
.hero-dots { position: absolute; bottom: 18px; left: 50%; transform: translateX(-50%); z-index: 3; display: flex; gap: 8px; }
.hero-dots .dot { width: 10px; height: 10px; border-radius: 50%; border: none; background: rgba(255,255,255,0.5); cursor: pointer; padding: 0; }
.hero-dots .dot.is-active { background: #fff; transform: scale(1.15); }
.hero-overlay { position: absolute; inset: 0; background: linear-gradient(180deg, rgba(8,22,24,0.15) 0%, rgba(8,22,24,0.68) 100%); }
.hero-content { position: relative; z-index: 2; padding: 0 0 42px; color: #fff; }
.hero-content h1 { font-size: clamp(30px, 5vw, 54px); margin: 0 0 8px; font-weight: 700; letter-spacing: -0.5px; }
.hero-content p { font-size: 18px; margin: 0; max-width: 620px; opacity: 0.92; }

/* ---------- Sections ---------- */
.section { padding: 46px 0 8px; }
.section-head { display: flex; align-items: baseline; justify-content: space-between; margin-bottom: 22px; border-bottom: 2px solid var(--border); padding-bottom: 10px; }
.section-head h2 { font-size: 26px; margin: 0; font-weight: 700; color: var(--primary-dark); }
.section-head .view-all { font-weight: 600; font-size: 14px; text-transform: uppercase; letter-spacing: 1px; }

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

.card { background: var(--surface); border-radius: var(--radius); overflow: hidden; box-shadow: var(--card-shadow); display: flex; flex-direction: column; transition: transform 0.2s ease, box-shadow 0.2s ease; }
.card:hover { transform: translateY(-4px); box-shadow: 0 16px 38px rgba(16,48,47,0.14); }
.card img { aspect-ratio: 3 / 2; object-fit: cover; width: 100%; }
.card-body { padding: 16px 18px 20px; display: flex; flex-direction: column; gap: 8px; flex: 1; }
.card-tag { font-size: 12px; font-weight: 700; text-transform: uppercase; letter-spacing: 1px; color: var(--accent); }
.card h3 { margin: 0; font-size: 19px; line-height: 1.3; }
.card h3 a { color: var(--text); }
.card h3 a:hover { color: var(--primary); }
.card .meta { font-size: 13px; color: var(--muted); display: flex; gap: 8px; align-items: center; }
.card .author-ico { width: 18px; height: 18px; border-radius: 50%; background: var(--primary); display: inline-block; }
.card .excerpt { font-size: 14px; color: var(--muted); margin: 0; }
.card .read-more { margin-top: auto; font-weight: 600; font-size: 14px; }

/* ---------- CTA block ---------- */
.cta { display: flex; gap: 30px; align-items: center; background: var(--surface); border-radius: var(--radius); padding: 28px; box-shadow: var(--card-shadow); margin: 30px 0; flex-wrap: wrap; }
.cta img { width: 240px; border-radius: 10px; object-fit: cover; aspect-ratio: 3 / 2; }
.cta-text { flex: 1; min-width: 240px; }
.cta-text h3 { margin: 0 0 8px; font-size: 22px; color: var(--primary-dark); }
.cta-text p { margin: 0 0 14px; color: var(--muted); }
.btn { display: inline-block; background: var(--primary); color: #fff; padding: 11px 22px; border-radius: 30px; font-weight: 600; border: none; cursor: pointer; }
.btn:hover { background: var(--primary-dark); color: #fff; }

/* ---------- Footer ---------- */
.site-footer { background: var(--footer-bg); color: var(--footer-text); margin-top: 50px; padding: 46px 0 26px; }
.footer-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 28px; }
.site-footer h4 { color: #fff; font-size: 15px; text-transform: uppercase; letter-spacing: 1px; margin: 0 0 14px; }
.site-footer a { color: var(--footer-muted); display: block; margin: 6px 0; font-size: 14px; }
.site-footer a:hover { color: #fff; }
.footer-intro { max-width: 640px; margin-bottom: 26px; padding: 0 20px; }
.footer-intro h4 { color: #fff; font-size: 15px; text-transform: uppercase; letter-spacing: 1px; margin: 0 0 14px; }
.footer-intro p { color: var(--footer-muted); font-size: 14px; }
.cookie-note { border-top: 1px solid rgba(255,255,255,0.12); margin-top: 28px; padding-top: 16px; font-size: 12.5px; color: var(--footer-muted); }
.footer-bottom { margin-top: 14px; font-size: 12.5px; color: var(--footer-muted); }

/* ---------- Ad boxes (inline + floating) ---------- */
.adbox { margin: 30px auto; max-width: 336px; text-align: center; }
.ad-label { display: block; font-size: 11px; letter-spacing: 1.5px; text-transform: uppercase; color: #9aa3a0; margin-bottom: 6px; }
.ad-slot { min-height: 250px; display: flex; align-items: center; justify-content: center; background: #f1efe7; border: 1px dashed var(--border); border-radius: 10px; word-break: break-word; }
/* reveal real creative, drop placeholder chrome (CSS :has, no JS) */
.adbox:has(iframe) .ad-slot,
.adbox:has(ins[data-ad-status="filled"]) .ad-slot { border: none; background: transparent; min-height: 0; padding: 0; }
.adbox:has(iframe) .ad-label,
.adbox:has(ins[data-ad-status="filled"]) .ad-label { display: none; }

/* floating bottom anchor bar - reserved padding matches footer background */
#adAnchor { position: fixed; left: 0; right: 0; bottom: 0; z-index: 60; background: var(--footer-bg); display: flex; justify-content: center; align-items: center; min-height: 54px; padding: 6px 0; }
#adAnchor .ad-slot { min-height: 50px; background: transparent; border: none; padding: 0; }
#adAnchor:has(.ad-slot:not(:has(iframe)):not(:has(ins[data-ad-status="filled"]))) { display: none; }

/* full-screen interstitial */
#adInterstitial { position: fixed; inset: 0; z-index: 90; display: none; align-items: center; justify-content: center; background: rgba(6,16,18,0.84); padding: 20px; }
#adInterstitial.is-open { display: flex; }
.inter-card { background: #fff; border-radius: 16px; padding: 18px; max-width: 340px; width: 100%; text-align: center; position: relative; }
.inter-card .ad-slot { min-height: 250px; background: #f1efe7; border: 1px dashed var(--border); border-radius: 10px; }
.inter-card .ad-slot:has(iframe),
.inter-card .ad-slot:has(ins[data-ad-status="filled"]) { border: none; background: transparent; min-height: 0; }
.inter-card .ad-slot:has(iframe) ~ .ad-label,
.inter-card .ad-slot:has(ins[data-ad-status="filled"]) ~ .ad-label { display: none; }
.inter-close { margin-top: 14px; }

/* back to top - 100px from bottom */
#toTop { position: fixed; right: 20px; bottom: 100px; z-index: 70; width: 46px; height: 46px; border-radius: 50%; background: var(--primary); color: #fff; border: none; cursor: pointer; display: none; align-items: center; justify-content: center; box-shadow: 0 8px 20px rgba(0,0,0,0.2); font-size: 20px; line-height: 1; }
#toTop.show { display: flex; }
#toTop:hover { background: var(--primary-dark); }

/* ---------- Detail / article page ---------- */
.article { padding: 34px 0 10px; }
.article-header { max-width: 760px; margin: 0 auto; }
.article-header .card-tag { display: block; margin-bottom: 8px; }
.article-header h1 { font-size: clamp(26px, 4vw, 40px); margin: 0 0 10px; line-height: 1.2; }
.article-meta { color: var(--muted); font-size: 14px; display: flex; gap: 12px; align-items: center; margin-bottom: 18px; }
.article-hero { max-width: 900px; margin: 0 auto 26px; border-radius: var(--radius); overflow: hidden; }
.article-body { max-width: 760px; margin: 0 auto; }
.article-body h3 { font-size: 22px; color: var(--primary-dark); margin: 30px 0 10px; }
.article-body p { margin: 0 0 18px; font-size: 17px; }
.article-body img { border-radius: 10px; margin: 18px 0; width: 100%; }
.related { padding: 30px 0; }
.related h2 { font-size: 24px; color: var(--primary-dark); margin: 0 0 20px; }

/* ---------- Categories page ---------- */
.cat-intro { max-width: 720px; margin: 0 auto 10px; color: var(--muted); }

/* ---------- Responsive ---------- */
@media (max-width: 860px) {
  /* Mobile header: brand + hamburger on top, scrollable category nav below */
  .header-inner { height: auto; flex-wrap: wrap; padding-top: 10px; padding-bottom: 6px; gap: 4px; }
  .hamburger { display: block; }

  /* the horizontal category nav bar shows on the homepage (mobile only) */
  body[data-page="home"] .main-nav { display: block; }

  /* horizontally scrollable category bar with expand button on the right */
  .main-nav {
    position: relative;
    width: 100%;
    padding: 6px 0 8px;
    background: rgba(255, 255, 255, 0.92);
    -webkit-backdrop-filter: saturate(140%) blur(8px);
    backdrop-filter: saturate(140%) blur(8px);
    border-bottom: 1px solid var(--border);
  }
  .main-nav .nav-inner {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    width: 100%;
    margin: 0;
  }
  .main-nav .nav-list {
    flex: 1;
    flex-direction: row;
    flex-wrap: nowrap;
    gap: 12px;
    width: auto;
    padding: 0 0 0 20px;
    overflow-x: auto;
    overflow-y: hidden;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
  }
  .main-nav .nav-list::-webkit-scrollbar { height: 0; display: none; }
  .main-nav .nav-list > li { flex-shrink: 0; }
  .main-nav .nav-list > li > a {
    display: inline-block;
    white-space: nowrap;
    padding: 6px 10px;
    font-size: 13px;
    background: var(--bg);
    border: 1px solid var(--border);
    border-radius: 20px;
  }
  .main-nav .nav-list > li > a.active,
  .main-nav .nav-list > li > a:hover {
    color: var(--primary);
    border-color: var(--primary);
  }
  .has-dropdown > a::after { display: none; }
  .dropdown { display: none; }

  /* expand/collapse button at the right of the nav (mobile only) */
  .nav-expand {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 42px;
    height: 40px;
    margin: 0 10px 0 12px;
    padding: 0;
    flex-shrink: 0;
    background: transparent;
    border: none;
    border-left: 2px solid var(--primary);
    border-radius: 0;
    cursor: pointer;
    overflow: visible;
    transition: background 0.2s ease;
  }
  .nav-expand:hover { background: var(--bg); }
  .nav-expand svg { display: block; width: 20px; height: 20px; fill: var(--text); margin: 0 auto; transition: transform 0.2s ease; }
  .main-nav.is-expanded .nav-expand svg { transform: rotate(180deg); }

  /* expand panel: a floating dropdown card (same look as category dropdown menu) */
  .nav-expand-panel { box-shadow: 0 14px 30px rgba(16,48,47,0.14); }
  .nav-expand-list { padding: 10px 16px 12px; }

  /* search page on mobile: tighter, cleaner input + button */
  .search-page-form { padding: 4px 4px 4px 12px; gap: 4px; border-radius: 24px; }
  .search-page-form .search-ico { width: 18px; height: 18px; }
  .search-page-input { font-size: 16px; padding: 10px 6px; }
  .search-rotate { left: 40px; font-size: 16px; }
  .search-rotate::before { content: "Try: "; }
  .search-page-btn { padding: 0 14px; border-radius: 20px; font-size: 14px; gap: 4px; }
  .search-page-btn svg { width: 15px; height: 15px; }
  .search-page-results a.sr-card { gap: 12px; padding: 10px 12px; }
  .search-page-results .sr-thumb { width: 64px; height: 48px; }

  /* hamburger full-site menu panel */
  .mobile-menu {
    display: none;
    position: absolute;
    top: 100%;
    left: 0; right: 0;
    background: #fff;
    border-bottom: 1px solid var(--border);
    box-shadow: 0 12px 24px rgba(0,0,0,0.08);
    padding: 8px 0 16px;
    z-index: 55;
  }
  .mobile-menu.is-open { display: block; }
  .mobile-menu ul { list-style: none; margin: 0; padding: 0; }
  .mobile-menu li { border-bottom: 1px solid var(--border); }
  .mobile-menu a {
    display: block;
    padding: 12px 20px;
    color: var(--text);
    font-weight: 600;
    font-size: 15px;
  }
  .mobile-menu a:hover { color: var(--primary); background: var(--bg); }
  .mobile-menu a.active {
    color: var(--primary);
    background: var(--bg);
    border-left: 3px solid var(--primary);
    padding-left: 17px;
    font-weight: 700;
  }

  .grid { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 600px) {
  .grid { grid-template-columns: 1fr; }
  .hero { height: 360px; }
  .cta { flex-direction: column; align-items: flex-start; }
  .cta img { width: 100%; }
  .hero-content p { font-size: 16px; }
}
