/* =========================================================
   GN PDF v2 — additive styles for tools, mega menu, search,
   tool-shell pages, blog, layer controls, etc.
   Loaded AFTER style.css so anything below wins on tie.
   ========================================================= */

/* ---------- Header: mega menu + search ---------- */
.gn-nav__group { position: relative; display: inline-flex; }
.gn-nav__group-btn {
  display: inline-flex; align-items: center; gap: 4px;
  background: transparent; border: 0; font: inherit;
  color: var(--text); cursor: pointer; padding: 6px 0;
}
.gn-nav__group-btn svg { transition: transform .2s; }
.gn-tools-mega.is-open .gn-nav__group-btn svg { transform: rotate(180deg); }

.gn-mega {
  position: absolute; top: 100%; left: -20px;
  display: none; grid-template-columns: repeat(5, minmax(170px, 1fr));
  gap: 18px; padding: 22px; min-width: 920px;
  background: var(--bg-card, #ffffff);
  border: 1px solid var(--border);
  border-radius: 14px;
  box-shadow: 0 24px 60px rgba(26,15,36,.22);
  z-index: 120;
  opacity: 1;
}
[data-theme="dark"] .gn-mega { background: #1f1729; box-shadow: 0 24px 60px rgba(0,0,0,.55); }
.gn-tools-mega.is-open .gn-mega { display: grid; }
.gn-mega__col h5 {
  font-size: 11px; text-transform: uppercase; letter-spacing: .08em;
  color: var(--text-soft); margin: 0 0 10px;
}
.gn-mega__col ul { list-style: none; padding: 0; margin: 0; }
.gn-mega__col li { margin: 2px 0; }
.gn-mega__col a {
  display: flex; align-items: center; gap: 10px;
  padding: 8px 10px; border-radius: 8px;
  color: var(--text); text-decoration: none; font-size: 14px;
  transition: background .15s;
}
.gn-mega__col a:hover { background: rgba(132,3,158,.06); }
.gn-mega__ico { display:inline-flex; flex: 0 0 18px; }
.gn-mega__name { flex: 1; }

.gn-soon-badge, .gn-beta-badge {
  display: inline-block; font-style: normal; font-size: 9.5px;
  padding: 2px 6px; border-radius: 999px; vertical-align: middle;
  font-weight: 700; letter-spacing: .04em; text-transform: uppercase;
  margin-left: 6px;
}
.gn-soon-badge { background: rgba(201,162,39,.16); color: #8a6b00; }
.gn-beta-badge { background: rgba(31,157,85,.16); color: #0e6a3a; }
[data-theme="dark"] .gn-soon-badge { background: rgba(201,162,39,.22); color: #ffd166; }
[data-theme="dark"] .gn-beta-badge { background: rgba(31,157,85,.22); color: #6cd9a1; }

/* Live search */
.gn-search { position: relative; }
.gn-search__ico {
  position: absolute; left: 10px; top: 50%; transform: translateY(-50%);
  color: var(--text-soft); pointer-events: none;
}
.gn-search input[type="search"] {
  background: var(--bg-soft); border: 1px solid var(--border);
  border-radius: 999px; padding: 8px 14px 8px 34px;
  width: 200px; height: 36px; color: var(--text); font-size: 14px;
  transition: width .2s, border-color .2s, background .2s;
}
.gn-search input[type="search"]:focus {
  outline: none; width: 260px; border-color: var(--brand);
  background: var(--bg-card);
}
.gn-search__results {
  display: none; position: absolute; top: calc(100% + 8px); right: 0;
  width: 360px; max-width: 90vw;
  background: var(--bg-card, #ffffff);
  border: 1px solid var(--border); border-radius: 12px;
  box-shadow: 0 24px 60px rgba(26,15,36,.22);
  overflow: hidden; z-index: 130;
  opacity: 1;
}
[data-theme="dark"] .gn-search__results { background: #1f1729; box-shadow: 0 24px 60px rgba(0,0,0,.55); }
.gn-search__results.is-open { display: block; }
.gn-search__row {
  display: block; padding: 10px 14px; text-decoration: none; color: var(--text);
  border-bottom: 1px solid var(--border);
}
.gn-search__row:last-child { border-bottom: 0; }
.gn-search__row:hover { background: rgba(132,3,158,.06); }
.gn-search__name { display: block; font-weight: 600; font-size: 14px; }
.gn-search__desc { display: block; color: var(--text-soft); font-size: 12.5px; margin-top: 2px; }
.gn-search__empty { padding: 14px; color: var(--text-soft); font-size: 14px; }
.gn-search mark { background: rgba(201,162,39,.35); color: inherit; padding: 0 1px; }

/* ---------- Tools sections on home & /tools.php ---------- */
.gn-tools-section { padding: 60px 0; }
.gn-tools-cat { margin-bottom: 44px; }
.gn-tools-cat__head { margin-bottom: 14px; display: flex; align-items: baseline; gap: 14px; flex-wrap: wrap; }
.gn-tools-cat__head h3 { margin: 0; font-size: 22px; }
.gn-tools-cat__head p { margin: 0; color: var(--text-soft); font-size: 14px; }

.gn-tools-grid {
  display: grid; gap: 14px;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
}
.gn-tool-card {
  display: grid; grid-template-columns: 44px 1fr 18px; gap: 14px; align-items: center;
  background: var(--bg-card); border: 1px solid var(--border);
  border-radius: 14px; padding: 14px 16px; text-decoration: none; color: var(--text);
  transition: transform .12s ease, border-color .12s, box-shadow .12s;
}
.gn-tool-card:hover {
  transform: translateY(-2px); border-color: var(--brand);
  box-shadow: 0 16px 30px -18px rgba(132,3,158,.55);
}
.gn-tool-card__ico {
  width: 44px; height: 44px; border-radius: 12px;
  display: inline-flex; align-items: center; justify-content: center;
}
.gn-tool-card__body h4 { margin: 0 0 2px; font-size: 16px; }
.gn-tool-card__body p { margin: 0; color: var(--text-soft); font-size: 13px; line-height: 1.45; }
.gn-tool-card__arrow {
  font-size: 18px; color: var(--text-soft);
  transition: transform .15s;
}
.gn-tool-card:hover .gn-tool-card__arrow { transform: translateX(4px); color: var(--brand); }

/* ---------- Tool page (tool-shell.php) ---------- */
.gn-breadcrumb {
  padding: 22px 0 6px; font-size: 13.5px; color: var(--text-soft);
}
.gn-breadcrumb a { color: var(--text-soft); text-decoration: none; }
.gn-breadcrumb a:hover { color: var(--brand); }
.gn-breadcrumb span[aria-current] { color: var(--text); }

.gn-tool-hero { padding: 20px 0 30px; }
.gn-tool-hero__eyebrow {
  display: inline-flex; align-items: center; gap: 6px;
  font-size: 12px; font-weight: 700; text-transform: uppercase; letter-spacing: .08em;
}
.gn-tool-hero__title {
  margin: 10px 0 12px;
  font-family: 'Playfair Display', serif;
  font-size: clamp(28px, 4vw, 48px); line-height: 1.1; letter-spacing: -0.02em;
}
.gn-tool-hero__sub { color: var(--text-soft); max-width: 760px; font-size: 17px; line-height: 1.55; }
.gn-tool-soon-pill {
  display: inline-block; background: rgba(201,162,39,.14); color: #6e5300;
  padding: 8px 14px; border-radius: 999px; margin-top: 14px; font-size: 14px;
}
[data-theme="dark"] .gn-tool-soon-pill { background: rgba(201,162,39,.18); color: #ffd166; }
.gn-tool-soon-pill a { color: var(--brand); font-weight: 600; }

.gn-tool-workspace { padding: 20px 0 50px; }
.gn-tool-dropzone {
  border: 2px dashed var(--border-strong);
  border-radius: 16px; padding: 50px 24px; text-align: center;
  background: var(--bg-soft); transition: border-color .15s, background .15s;
}
.gn-tool-dropzone.is-drag { border-color: var(--brand); background: rgba(132,3,158,.04); }
.gn-tool-dropzone h2 { margin: 12px 0 4px; font-size: 22px; }
.gn-tool-dropzone p { color: var(--text-soft); }
.gn-tool-list {
  margin: 24px 0; display: grid; gap: 10px;
}
.gn-tool-file-row {
  display: grid; grid-template-columns: 28px 1fr auto auto; gap: 12px; align-items: center;
  background: var(--bg-card); border: 1px solid var(--border); border-radius: 10px; padding: 10px 14px;
}
.gn-tool-file-row__name { font-weight: 600; font-size: 14px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.gn-tool-file-row__meta { color: var(--text-soft); font-size: 12.5px; }
.gn-tool-file-row__del {
  background: transparent; border: 0; color: var(--text-soft); cursor: pointer; font-size: 22px; line-height: 1;
}
.gn-tool-file-row__del:hover { color: #c0392b; }
.gn-tool-actions { margin-top: 22px; display: flex; gap: 12px; flex-wrap: wrap; justify-content: center; }

.gn-tool-content { padding: 30px 0; background: var(--bg-soft); }
.gn-tool-content__inner h2 {
  font-family: 'Playfair Display', serif; font-size: clamp(24px, 3vw, 36px);
  margin: 28px 0 12px; letter-spacing: -0.01em;
}
.gn-tool-content__inner h3 { margin: 22px 0 8px; font-size: 19px; }
.gn-tool-content__inner p { line-height: 1.75; color: var(--text); }
.gn-tool-content__inner ul, .gn-tool-content__inner ol { padding-left: 22px; line-height: 1.75; }
.gn-tool-content__inner li { margin: 6px 0; }

.gn-related-tools { padding: 50px 0; }
.gn-related-tools h2 { font-size: 24px; margin: 0 0 18px; }

.gn-faq { padding: 50px 0; background: var(--bg-soft); }
.gn-faq h2 { font-family: 'Playfair Display', serif; font-size: clamp(24px, 3vw, 36px); margin: 0 0 18px; }
.gn-faq__list { display: grid; gap: 10px; }
.gn-faq__item {
  background: var(--bg-card); border: 1px solid var(--border); border-radius: 12px;
  padding: 0; transition: border-color .15s;
}
.gn-faq__item[open] { border-color: var(--brand); }
.gn-faq__item summary {
  padding: 16px 20px; font-weight: 600; cursor: pointer;
  list-style: none; display: flex; justify-content: space-between; align-items: center;
}
.gn-faq__item summary::after {
  content: '+'; color: var(--brand); font-size: 22px; line-height: 1; margin-left: 10px; transition: transform .2s;
}
.gn-faq__item[open] summary::after { content: '−'; }
.gn-faq__a { padding: 0 20px 18px; color: var(--text-soft); line-height: 1.65; }

/* ---------- Blog ---------- */
.gn-blog-feed { padding: 60px 0; }
.gn-blog-grid { display: grid; gap: 18px; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); }
.gn-blog-card {
  background: var(--bg-card); border: 1px solid var(--border); border-radius: 14px;
  padding: 22px; text-decoration: none; color: var(--text); transition: transform .12s, border-color .12s;
}
.gn-blog-card:hover { transform: translateY(-2px); border-color: var(--brand); }
.gn-blog-card__tag {
  display: inline-block; padding: 3px 10px; border-radius: 999px;
  background: rgba(132,3,158,.1); color: var(--brand);
  font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: .06em;
}
.gn-blog-card h3 {
  font-family: 'Playfair Display', serif; font-size: 21px;
  margin: 10px 0 8px; line-height: 1.25;
}
.gn-blog-card p { color: var(--text-soft); font-size: 14px; line-height: 1.55; margin: 0 0 12px; }
.gn-blog-card__meta { color: var(--text-soft); font-size: 12px; }

.gn-post {
  padding: 30px 0 60px; max-width: 760px; margin: 0 auto;
}
.gn-post h1 {
  font-family: 'Playfair Display', serif;
  font-size: clamp(28px, 4vw, 48px); line-height: 1.1; letter-spacing: -0.02em; margin: 0 0 16px;
}
.gn-post__meta { color: var(--text-soft); font-size: 14px; margin-bottom: 24px; }
.gn-post__cover {
  width: 100%; aspect-ratio: 16/8; border-radius: 16px; margin-bottom: 28px;
  background: linear-gradient(135deg, #84039e 0%, #c9a227 100%);
  display: flex; align-items: center; justify-content: center;
  color: #fff; font-family: 'Playfair Display', serif; font-size: 28px;
}
.gn-post p { line-height: 1.85; font-size: 17px; margin: 0 0 18px; }
.gn-post h2 { font-family: 'Playfair Display', serif; font-size: 28px; margin: 38px 0 12px; }
.gn-post h3 { font-size: 21px; margin: 30px 0 10px; }
.gn-post ul, .gn-post ol { line-height: 1.85; padding-left: 22px; }
.gn-post blockquote {
  border-left: 4px solid var(--brand); padding: 6px 18px; margin: 24px 0;
  color: var(--text-soft); font-style: italic;
}
.gn-post__cta {
  margin: 36px 0; padding: 28px; background: var(--bg-soft); border-radius: 14px;
  display: flex; align-items: center; justify-content: space-between; gap: 18px; flex-wrap: wrap;
}

/* ---------- Footer additions ---------- */
.gn-footer__col--brand { grid-column: span 2; }
.gn-footer__more { color: var(--brand); font-weight: 600; }
.gn-footer__bottom { padding: 18px 0; border-top: 1px solid var(--border); color: var(--text-soft); font-size: 13px; }

/* ---------- Hero animation art ---------- */
.gn-hero__art { display: flex; justify-content: center; margin-top: 18px; }

/* ---------- Ad placeholder polish ---------- */
.gn-ad { position: relative; margin: 24px 0; }
.gn-ad__label {
  display: block; font-size: 10px; text-transform: uppercase; letter-spacing: .12em;
  color: var(--text-soft); margin-bottom: 4px; opacity: .6;
}
.gn-ad-placeholder {
  background: var(--bg-soft); border: 1px dashed var(--border-strong); border-radius: 10px;
  padding: 26px; text-align: center; color: var(--text-soft); font-size: 13px;
  min-height: 90px; display: flex; align-items: center; justify-content: center;
}

/* ---------- Mobile ---------- */
@media (max-width: 900px) {
  .gn-mega { position: static; min-width: 0; grid-template-columns: 1fr 1fr; box-shadow: none; }
  .gn-search input[type="search"] { width: 130px; }
  .gn-search input[type="search"]:focus { width: 170px; }
  .gn-footer__col--brand { grid-column: 1; }
}
@media (max-width: 600px) {
  .gn-search { display: none; }
  .gn-mega { grid-template-columns: 1fr; }
}

/* ============================================================
   V2.1 — Advanced Tool UIs (Watermark / Protect / Redact /
   HTML→PDF / Word→PDF / Excel→PDF / PPT→PDF / PDF→Word /
   PDF→Excel / PDF→PowerPoint)
   ============================================================ */
.gn-tool-opts { margin-top: 22px; }
.gn-tool-opts__head {
  display: flex; align-items: center; justify-content: space-between;
  gap: 14px; margin: 0 0 18px; padding-bottom: 14px;
  border-bottom: 1px dashed var(--border);
}
.gn-tool-opts__head h3 { margin: 0; font-size: 18px; }

.gn-opt-grid {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 14px; margin-bottom: 18px;
}
.gn-opt-card {
  background: var(--bg-soft); border: 1px solid var(--border);
  border-radius: 12px; padding: 14px 16px;
}
.gn-opt-card h4 {
  margin: 0 0 10px; font-size: 13px;
  color: var(--brand); text-transform: uppercase; letter-spacing: .04em;
}
.gn-opt-card label {
  display: block; font-size: 13px; color: var(--text-soft);
  margin-bottom: 10px;
}
.gn-opt-card input[type="text"],
.gn-opt-card input[type="password"],
.gn-opt-card input[type="number"],
.gn-opt-card input[type="url"],
.gn-opt-card select,
.gn-opt-card textarea {
  width: 100%; height: 38px; padding: 0 12px;
  border: 1px solid var(--border-strong); border-radius: 8px;
  background: var(--bg); color: var(--text); font: inherit;
  margin-top: 4px;
}
.gn-opt-card textarea { min-height: 220px; padding: 10px 12px; resize: vertical; }
.gn-opt-card input[type="color"] {
  width: 100%; height: 36px; padding: 2px; border-radius: 8px;
  border: 1px solid var(--border-strong); background: var(--bg);
}
.gn-opt-card input[type="range"] { width: 100%; }
.gn-opt-card input[type="file"] { width: 100%; font-size: 13px; }
.gn-opt-checkbox {
  display: flex; align-items: center; gap: 8px; margin: 6px 0;
}
.gn-opt-hint { font-size: 12px; color: var(--text-muted); margin: 6px 0 0; }

.gn-pill-row { display: flex; gap: 6px; flex-wrap: wrap; }
.gn-pill {
  background: var(--bg); border: 1px solid var(--border-strong);
  padding: 7px 14px; border-radius: 999px; font-size: 13px;
  color: var(--text); cursor: pointer; transition: all .15s;
}
.gn-pill:hover { background: var(--bg-soft); }
.gn-pill.is-active {
  background: var(--brand); color: #fff; border-color: var(--brand);
}

.gn-tool-tabs { display: flex; gap: 8px; margin-bottom: 16px; }
.gn-html-panel { margin-bottom: 18px; }
.gn-html-panel label { display: block; }

.gn-preview-wrap { margin-top: 18px; }

/* Password strength bar */
.gn-pwbar {
  height: 6px; border-radius: 999px; background: rgba(0,0,0,.08);
  overflow: hidden; margin-top: 8px;
}
.gn-pwbar > div { height: 100%; transition: width .2s, background .2s; background: #e74c3c; width: 0; }

/* Redact tool */
.gn-redact-ws { margin-top: 18px; }
.gn-redact-toolbar {
  display: flex; align-items: center; gap: 12px; flex-wrap: wrap;
  padding: 12px 14px; background: var(--bg-soft); border-radius: 10px;
  border: 1px solid var(--border); margin-bottom: 14px;
}
.gn-redact-toolbar input[type="text"] {
  height: 32px; padding: 0 10px; border-radius: 6px;
  border: 1px solid var(--border-strong); background: var(--bg); color: var(--text);
  min-width: 200px;
}
.gn-redact-pages { display: flex; flex-direction: column; gap: 14px; align-items: center; }
.gn-rd-pg {
  position: relative; display: inline-block;
  box-shadow: 0 4px 18px rgba(0,0,0,.08);
}
.gn-rd-pg canvas { display: block; max-width: 100%; height: auto; }
.gn-rd-overlay {
  position: absolute; left: 0; top: 0; cursor: crosshair;
}
.gn-rd-mark {
  position: absolute; opacity: 0.85;
  cursor: move; min-width: 2px; min-height: 2px;
  border: 1px solid rgba(255,255,255,.4);
}
.gn-rd-x {
  position: absolute; top: -8px; right: -8px; width: 18px; height: 18px;
  background: #fff; color: #c0392b; border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-weight: 700; cursor: pointer; font-size: 13px;
  box-shadow: 0 2px 4px rgba(0,0,0,.2);
}

/* PowerPoint preview cards */
.gn-slides-prev {
  display: grid; grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
  gap: 12px; margin: 16px 0;
}
.gn-slide-card {
  background: #fff; border: 1px solid var(--border); border-radius: 10px;
  padding: 14px; min-height: 130px;
  color: #1a0f24; font-size: 12px; line-height: 1.4;
}
.gn-slide-card__title {
  color: var(--brand); font-weight: 700; margin-bottom: 8px;
  font-size: 13px; overflow: hidden; text-overflow: ellipsis;
}
.gn-slide-card ul { margin: 0; padding-left: 18px; }

/* In-content home ads slot wrapper */
.gn-home-ad-row {
  margin: 36px 0; padding: 18px 0;
  border-top: 1px dashed var(--border);
  border-bottom: 1px dashed var(--border);
}

/* Home long-form SEO section */
.gn-home-seo { padding: 60px 0 40px; }
.gn-home-seo h2 {
  font-family: 'Playfair Display', serif;
  font-size: clamp(24px, 3.6vw, 36px); margin: 36px 0 12px;
  color: var(--text);
}
.gn-home-seo h3 {
  font-size: clamp(18px, 2.6vw, 22px); margin: 26px 0 10px;
  color: var(--brand);
}
.gn-home-seo p, .gn-home-seo li {
  color: var(--text-soft); line-height: 1.75; font-size: 16px;
}
.gn-home-seo ul, .gn-home-seo ol { padding-left: 22px; margin: 8px 0 18px; }
.gn-home-seo li { margin-bottom: 8px; }
.gn-home-seo strong { color: var(--text); }
.gn-home-seo .gn-stat-row {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 18px; margin: 26px 0;
}
.gn-home-seo .gn-stat {
  text-align: center; padding: 22px 14px;
  background: var(--bg-soft); border-radius: 12px;
  border: 1px solid var(--border);
}
.gn-home-seo .gn-stat__n {
  display: block; font-family: 'Playfair Display', serif;
  font-size: 32px; color: var(--brand); font-weight: 800;
}
.gn-home-seo .gn-stat__l {
  display: block; color: var(--text-soft); font-size: 13px; margin-top: 4px;
}

/* Legal pages */
.gn-legal-page .gn-home-seo h2 { margin-top: 32px; }
.gn-legal-page code { background: var(--bg-soft); padding: 2px 6px; border-radius: 4px; font-size: 13px; }

/* Contact form */
.gn-contact-form textarea { min-height: 180px; }

/* ============================================================
   V2.4 — Hero side-by-side, mobile mega-menu fix, ads layout,
   blog post hero image, mobile search, header logo image.
   ============================================================ */

/* Hero side-by-side */
.gn-hero__grid {
  display: grid;
  grid-template-columns: 1.15fr 1fr;
  gap: 50px;
  align-items: center;
}
.gn-hero__copy { min-width: 0; }
.gn-hero__art {
  width: 100%;
  display: flex;
  justify-content: center;
  align-items: center;
}
.gn-hero__art > svg,
.gn-hero__art img {
  max-width: 100%;
  height: auto;
}
@media (max-width: 980px) {
  .gn-hero__grid { grid-template-columns: 1fr; gap: 30px; }
  .gn-hero__art { order: 2; max-width: 460px; margin: 0 auto; }
}

/* Header logo as image (favicon-based) */
.gn-logo__mark img {
  display: block;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  box-shadow: 0 4px 12px rgba(132,3,158,.25);
}

/* Ads — fix Sponsored label position so it sits inside the ad container */
.gn-ad {
  margin: 22px auto;
  text-align: center;
  position: relative;
  max-width: 100%;
}
.gn-ad__inner {
  display: inline-block;
  width: 100%;
  max-width: 970px;
  padding: 22px 16px 16px;
  border-radius: 12px;
  background: var(--bg-soft);
  border: 1px dashed var(--border-strong);
  position: relative;
  box-sizing: border-box;
}
.gn-ad__label {
  position: absolute;
  top: 6px;
  left: 14px;
  font-size: 10px;
  letter-spacing: .15em;
  text-transform: uppercase;
  color: var(--text-muted);
  font-weight: 600;
  z-index: 2;
  background: var(--bg-soft);
  padding: 0 6px;
}
.gn-ad__body { width: 100%; }
.gn-ad__body .gn-ad-placeholder {
  background: rgba(132, 3, 158, 0.04);
  border: 1px dashed var(--border-strong);
  border-radius: 8px;
  min-height: 90px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: 'JetBrains Mono', monospace;
  font-size: 12px;
  color: var(--text-muted);
  width: 100%;
  margin: 0;
}
.gn-ad--sidebar .gn-ad__body .gn-ad-placeholder { min-height: 600px; }
.gn-ad--download_page .gn-ad__body .gn-ad-placeholder,
.gn-ad--tool_after_download .gn-ad__body .gn-ad-placeholder { min-height: 280px; }

/* Mobile mega-menu — fixed full-width drawer instead of floating dropdown */
@media (max-width: 960px) {
  .gn-nav { width: 100%; }
  .gn-nav__group { width: 100%; }
  .gn-tools-mega .gn-mega {
    position: static !important;
    transform: none !important;
    width: 100% !important;
    box-shadow: none !important;
    border-radius: 0;
    padding: 12px 0 !important;
    background: var(--bg-soft);
    grid-template-columns: 1fr !important;
    margin-top: 10px;
  }
  .gn-tools-mega .gn-mega__col { padding: 8px 14px; }
  .gn-tools-mega .gn-mega__col h5 {
    color: var(--brand);
    font-size: 11px;
    margin: 4px 0 6px;
    letter-spacing: .12em;
  }
  .gn-tools-mega .gn-mega ul { margin: 0; }
  .gn-tools-mega .gn-mega ul li a {
    padding: 10px 4px;
    display: flex;
    align-items: center;
    gap: 12px;
  }
}

/* Mobile search — keep visible inside the mobile drawer */
@media (max-width: 960px) {
  .gn-header__tools .gn-search {
    order: 99;
    width: 100%;
    margin: 8px 0 0;
  }
  .gn-header__tools .gn-search input { width: 100%; }
  .gn-nav.is-open { display: flex; flex-direction: column; gap: 4px; }
  .gn-nav.is-open + .gn-header__tools { display: flex; flex-wrap: wrap; width: 100%; }
}
@media (max-width: 720px) {
  /* When the menu is open, show a search field at the top of the drawer */
  .gn-nav.is-open::before {
    content: '';
    display: block;
  }
}

/* Blog post hero image — full-width banner under title */
.gn-post__hero {
  margin: 18px 0 28px;
  border-radius: 14px;
  overflow: hidden;
  box-shadow: 0 12px 30px rgba(132, 3, 158, 0.10);
  background: var(--bg-soft);
}
.gn-post__hero img {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 1200/630;
  object-fit: cover;
}

/* Blog grid card image polish — when card includes <img> */
.gn-blog-card { overflow: hidden; padding-top: 0; }
.gn-blog-card > img + .gn-blog-card__tag,
.gn-blog-card > img + span { margin-top: 0; }

/* ---- Mobile search visibility fix ---- */
/* On tablets and below, allow .gn-header__tools to wrap so the
   search field gets its own row below the toolbar buttons. */
@media (max-width: 960px) {
  .gn-header__inner {
    flex-wrap: wrap;
    row-gap: 8px;
  }
  .gn-header__tools {
    flex-wrap: wrap;
    justify-content: flex-end;
  }
  .gn-search {
    order: 10;
    width: 100%;
    margin-top: 8px;
  }
  .gn-search input[type="search"] {
    width: 100% !important;
  }
  .gn-search input[type="search"]:focus { width: 100% !important; }
  .gn-search__results {
    right: 0;
    left: 0;
    width: 100% !important;
    max-width: 100% !important;
  }
}

/* Ensure floating mega doesn't overflow on mobile */
@media (max-width: 720px) {
  .gn-tools-mega { width: 100%; }
  .gn-tools-mega .gn-nav__group-btn {
    width: 100%;
    justify-content: space-between;
    padding: 12px 8px;
    background: transparent;
    border: 0;
    color: var(--text);
    font-size: 16px;
    cursor: pointer;
    display: flex;
    align-items: center;
  }
}
