/* ==========================================================================
   NovaHub 2.0 — Design System (single stylesheet, no framework)
   فارسی / RTL / تقویم شمسی — تم روشن + تاریک — ریسپانسیو کامل
   --------------------------------------------------------------------------
   Sections:
     01 Design tokens (light + dark)
     02 Reset & base
     03 Utilities (incl. the legacy utility subset used across views)
     04 Buttons
     05 Forms & validation
     06 Layout primitives (container / layout / section / stack / cluster)
     07 Header (glass) + nav + mega menu + search + icon buttons
     08 Drawer + mobile bottom nav
     09 Hero / pagehead / welcome banner
     10 Feed & product rows + vote buttons
     11 Sidebar panels / threads / menu
     12 Avatars / chips / tags / pills / badges
     13 Tabs
     14 Dropdowns / modals / disclosure
     15 Tables / cards / list groups / alerts / pagination
     16 Comments / composer / reviews / stars
     17 Product detail + gallery
     18 Profile / points / bio / taxonomy grid
     19 Skeletons / states / toasts
     20 Admin shell
     21 Footer
     22 Grid compat (row/col subset)
     23 Responsive & motion
   Behavior lives in /js/site.js (vanilla islands on window.NovaHub).
   ========================================================================== */

/* ============================== 01 Tokens =============================== */
/* Vazirmatn (SIL OFL 1.1) — bundled locally, no CDN. See fonts/vazirmatn/OFL.txt. */
@font-face { font-family: "Vazirmatn"; src: url("../fonts/vazirmatn/Vazirmatn-Regular.woff2") format("woff2"); font-weight: 400; font-display: swap; }
@font-face { font-family: "Vazirmatn"; src: url("../fonts/vazirmatn/Vazirmatn-Medium.woff2") format("woff2"); font-weight: 500; font-display: swap; }
@font-face { font-family: "Vazirmatn"; src: url("../fonts/vazirmatn/Vazirmatn-SemiBold.woff2") format("woff2"); font-weight: 600; font-display: swap; }
@font-face { font-family: "Vazirmatn"; src: url("../fonts/vazirmatn/Vazirmatn-Bold.woff2") format("woff2"); font-weight: 700; font-display: swap; }
@font-face { font-family: "Vazirmatn"; src: url("../fonts/vazirmatn/Vazirmatn-ExtraBold.woff2") format("woff2"); font-weight: 800; font-display: swap; }
@font-face { font-family: "Vazirmatn"; src: url("../fonts/vazirmatn/Vazirmatn-Black.woff2") format("woff2"); font-weight: 900; font-display: swap; }

:root {
  /* Brand — coral heritage evolved into the NovaHub gradient identity */
  --nh-accent: #ff6154;
  --nh-accent-600: #ee4d40;
  --nh-accent-700: #d63b2f;
  --nh-accent-2: #ff9351;
  --nh-grad: linear-gradient(135deg, #ff6154 0%, #ff9351 100%);
  --nh-accent-soft: #fff1ee;
  --nh-accent-ring: rgba(255, 97, 84, .32);

  /* Surfaces & text — light theme */
  --nh-bg: #f9fafb;
  --nh-surface: #ffffff;
  --nh-surface-2: #f9fafb;
  --nh-surface-3: #f2f4f7;
  --nh-border: #eaecf0;
  --nh-border-strong: #d0d5dd;
  --nh-ink: #101828;
  --nh-ink-2: #344054;
  --nh-muted: #475467;
  --nh-faint: #667085;
  --nh-nav-highlight: #f5f8ff;

  /* Semantic */
  --nh-success: #00b37e;   --nh-success-soft: #e6f7f1;
  --nh-warning: #d98a00;   --nh-warning-soft: #fdf3e2;
  --nh-danger: #e5484d;    --nh-danger-soft: #ffefef;
  --nh-info: #2f6fed;      --nh-info-soft: #eaf1fe;

  /* Typography */
  --nh-font: "Vazirmatn", "IRANSans", "IRANYekan", ui-sans-serif, system-ui, "Segoe UI", Tahoma, sans-serif;
  --nh-fs-xs: .75rem;
  --nh-fs-sm: .875rem;
  --nh-fs-base: 1rem;
  --nh-fs-md: 1.125rem;
  --nh-fs-lg: 1.375rem;
  --nh-fs-xl: 1.75rem;
  --nh-fs-2xl: 2.25rem;
  --nh-lh: 1.7;

  /* Spacing (4pt) */
  --nh-1: .25rem; --nh-2: .5rem; --nh-3: .75rem; --nh-4: 1rem;
  --nh-5: 1.5rem; --nh-6: 2rem; --nh-7: 3rem; --nh-8: 4rem;

  /* Radius */
  --nh-radius-sm: 8px;
  --nh-radius: 12px;
  --nh-radius-lg: 16px;
  --nh-radius-xl: 22px;
  --nh-radius-pill: 999px;

  /* Elevation */
  --nh-shadow-xs: 0 1px 2px rgba(16, 24, 40, .05);
  --nh-shadow-sm: 0 2px 6px rgba(16, 24, 40, .06);
  --nh-shadow: 0 8px 24px -6px rgba(16, 24, 40, .12);
  --nh-shadow-lg: 0 16px 48px -12px rgba(16, 24, 40, .18);
  --nh-shadow-accent: 0 6px 20px -6px rgba(255, 97, 84, .45);

  /* Motion */
  --nh-t-fast: 140ms cubic-bezier(.4, 0, .2, 1);
  --nh-t: 220ms cubic-bezier(.4, 0, .2, 1);
  --nh-t-slow: 320ms cubic-bezier(.4, 0, .2, 1);

  /* Z-stack */
  --nh-z-header: 1030;
  --nh-z-dropdown: 1050;
  --nh-z-drawer: 1060;
  --nh-z-modal: 1070;
  --nh-z-toast: 1080;

  /* Shell */
  --nh-header-h: 64px;
  --nh-container: 1280px;
  --nh-glass: rgba(255, 255, 255, .78);

  color-scheme: light;
}

/* Dark theme — applied via <html data-theme="dark"> (set pre-paint in _Layout) */
:root[data-theme="dark"] {
  --nh-bg: #0b0e14;
  --nh-surface: #121722;
  --nh-surface-2: #171d2a;
  --nh-surface-3: #1d2433;
  --nh-border: #222a3a;
  --nh-border-strong: #31394d;
  --nh-ink: #f2f4f7;
  --nh-ink-2: #cdd5e0;
  --nh-muted: #98a2b3;
  --nh-faint: #8391a8;
  --nh-nav-highlight: #1a2130;

  --nh-accent-soft: rgba(255, 97, 84, .13);
  --nh-success-soft: rgba(0, 179, 126, .15);
  --nh-warning-soft: rgba(217, 138, 0, .16);
  --nh-danger-soft: rgba(229, 72, 77, .16);
  --nh-info-soft: rgba(47, 111, 237, .16);

  --nh-shadow-xs: 0 1px 2px rgba(0, 0, 0, .4);
  --nh-shadow-sm: 0 2px 6px rgba(0, 0, 0, .45);
  --nh-shadow: 0 8px 24px -6px rgba(0, 0, 0, .55);
  --nh-shadow-lg: 0 16px 48px -12px rgba(0, 0, 0, .65);

  --nh-glass: rgba(13, 17, 25, .72);
  color-scheme: dark;
}

/* ============================ 02 Reset & base ============================ */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  font-family: var(--nh-font);
  font-size: var(--nh-fs-base);
  line-height: var(--nh-lh);
  color: var(--nh-ink);
  background: var(--nh-bg);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  transition: background-color var(--nh-t), color var(--nh-t);
}
/* Soft brand halo behind the top of every page */
body::before {
  content: "";
  position: fixed;
  inset-block-start: -180px;
  inset-inline: 0;
  height: 420px;
  background: radial-gradient(60% 100% at 50% 0%, var(--nh-accent-soft) 0%, transparent 70%);
  pointer-events: none;
  z-index: 0;
}
h1, h2, h3, h4, h5, h6 { margin: 0 0 var(--nh-3); font-weight: 800; line-height: 1.35; letter-spacing: -.01em; }
h1 { font-size: var(--nh-fs-2xl); }
h2 { font-size: var(--nh-fs-xl); }
h3 { font-size: var(--nh-fs-lg); }
h4, h5, .h5 { font-size: var(--nh-fs-md); }
h6 { font-size: var(--nh-fs-base); }
p { margin: 0 0 var(--nh-3); }
a { color: inherit; text-decoration: none; }
a:hover { color: var(--nh-accent-600); }
img, svg, video { max-width: 100%; height: auto; }
button { font-family: inherit; }
input, select, textarea { font-family: inherit; }
hr { border: 0; border-block-start: 1px solid var(--nh-border); margin-block: var(--nh-4); }
ul, ol { padding-inline-start: 1.4rem; margin: 0 0 var(--nh-3); }
::selection { background: var(--nh-accent); color: #fff; }
:focus-visible { outline: 3px solid var(--nh-accent-ring); outline-offset: 2px; border-radius: 6px; }
/* Thin, theme-aware scrollbars */
* { scrollbar-width: thin; scrollbar-color: var(--nh-border-strong) transparent; }

/* ============================= 03 Utilities ============================= */
.nh-container { max-width: var(--nh-container); margin-inline: auto; padding-inline: clamp(1rem, 3vw, 2rem); position: relative; z-index: 1; width: 100%; }
.nh-main { flex: 1 1 auto; width: 100%; position: relative; z-index: 1; }
.nh-muted { color: var(--nh-muted); }
.nh-ink-2 { color: var(--nh-ink-2); }
.nh-tnum { font-feature-settings: "tnum"; }
.nh-truncate { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.nh-clamp-2 { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.nh-divider { border: 0; border-block-start: 1px solid var(--nh-border); margin-block: var(--nh-3); }
.nh-elevate { box-shadow: var(--nh-shadow-sm); }
.nh-grad-text { background: var(--nh-grad); -webkit-background-clip: text; background-clip: text; color: transparent; }
.nh-fade-in { animation: nh-fade-in .35s var(--nh-t-fast) both; }
@keyframes nh-fade-in { from { opacity: 0; transform: translateY(4px); } to { opacity: 1; transform: none; } }

/* Legacy utility subset (kept so existing markup keeps working) */
.small { font-size: var(--nh-fs-sm); }
.w-100 { width: 100% !important; }
.w-auto { width: auto !important; }
.h-100 { height: 100% !important; }
.d-flex { display: flex !important; }
.d-none { display: none !important; }
.d-inline { display: inline !important; }
.d-inline-flex { display: inline-flex !important; }
.flex-wrap { flex-wrap: wrap !important; }
.align-items-center { align-items: center !important; }
.justify-content-end { justify-content: flex-end !important; }
.justify-content-center { justify-content: center !important; }
.justify-content-between { justify-content: space-between !important; }
.gap-1 { gap: var(--nh-1) !important; }
.gap-2 { gap: var(--nh-2) !important; }
.mb-0 { margin-block-end: 0 !important; }
.mb-1 { margin-block-end: var(--nh-1) !important; }
.mb-2 { margin-block-end: var(--nh-2) !important; }
.mb-3 { margin-block-end: var(--nh-4) !important; }
.mb-4 { margin-block-end: var(--nh-5) !important; }
.mt-1 { margin-block-start: var(--nh-1) !important; }
.mt-2 { margin-block-start: var(--nh-2) !important; }
.mt-3 { margin-block-start: var(--nh-4) !important; }
.mt-4 { margin-block-start: var(--nh-5) !important; }
.ms-2 { margin-inline-start: var(--nh-2) !important; }
.p-2 { padding: var(--nh-2) !important; }
.py-4 { padding-block: var(--nh-5) !important; }
.text-center { text-align: center !important; }
.text-end { text-align: end !important; }
.text-nowrap { white-space: nowrap !important; }
.text-muted { color: var(--nh-muted) !important; }
.text-danger { color: var(--nh-danger) !important; }
.text-success { color: var(--nh-success) !important; }
.text-dark { color: var(--nh-ink) !important; }
.bg-light { background: var(--nh-surface-3) !important; }
.border { border: 1px solid var(--nh-border) !important; }
.border-success { border-color: var(--nh-success) !important; }
.border-danger { border-color: var(--nh-danger) !important; }
.rounded { border-radius: var(--nh-radius) !important; }
.rounded-pill { border-radius: var(--nh-radius-pill) !important; }
.shadow-sm { box-shadow: var(--nh-shadow-sm) !important; }
.fade { /* modal compat — transitions are handled by the design system */ }
.visually-hidden-focusable:not(:focus):not(:focus-within) {
  position: absolute !important; width: 1px; height: 1px; margin: -1px;
  overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0; padding: 0;
}
.visually-hidden-focusable:focus {
  position: fixed; inset-block-start: var(--nh-2); inset-inline-start: var(--nh-2);
  z-index: calc(var(--nh-z-toast) + 1); background: var(--nh-surface); color: var(--nh-ink);
  padding: var(--nh-2) var(--nh-4); border-radius: var(--nh-radius); box-shadow: var(--nh-shadow-lg);
}
@media (min-width: 576px) { .d-sm-inline-flex { display: inline-flex !important; } }
@media (min-width: 768px) {
  .d-md-none { display: none !important; }
  .d-md-inline-flex { display: inline-flex !important; }
}

/* ============================== 04 Buttons ============================== */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .45rem;
  border: 1px solid transparent; border-radius: var(--nh-radius-pill);
  padding: .55rem 1.25rem; font-size: var(--nh-fs-sm); font-weight: 700;
  cursor: pointer; white-space: nowrap; text-decoration: none;
  color: var(--nh-ink-2); background: transparent;
  transition: all var(--nh-t-fast); line-height: 1.5; user-select: none;
}
.btn:hover { transform: translateY(-1px); }
.btn:active { transform: translateY(0); }
.btn:disabled, .btn.disabled { opacity: .55; pointer-events: none; }
.btn-sm { padding: .35rem .95rem; font-size: var(--nh-fs-xs); }

.btn-primary { background: var(--nh-grad); color: #fff; box-shadow: var(--nh-shadow-accent); }
.btn-primary:hover { color: #fff; filter: brightness(1.06); }
.btn-secondary { background: var(--nh-ink); color: var(--nh-bg); }
.btn-secondary:hover { color: var(--nh-bg); opacity: .88; }
.btn-light { background: var(--nh-surface); color: var(--nh-ink-2); border-color: var(--nh-border); }
.btn-light:hover { border-color: var(--nh-border-strong); color: var(--nh-ink); box-shadow: var(--nh-shadow-sm); }
.btn-success { background: var(--nh-success); color: #fff; }
.btn-success:hover { color: #fff; filter: brightness(1.06); }
.btn-danger { background: var(--nh-danger); color: #fff; }
.btn-danger:hover { color: #fff; filter: brightness(1.06); }
.btn-link { border: 0; background: none; color: var(--nh-accent-600); font-weight: 700; padding-inline: .35rem; }
.btn-ghost { background: transparent; color: var(--nh-ink-2); }
.btn-ghost:hover { background: var(--nh-surface-3); color: var(--nh-ink); }

.btn-outline-primary { border-color: var(--nh-accent); color: var(--nh-accent-600); }
.btn-outline-primary:hover { background: var(--nh-accent-soft); color: var(--nh-accent-700); }
.btn-outline-secondary { border-color: var(--nh-border-strong); color: var(--nh-ink-2); }
.btn-outline-secondary:hover { background: var(--nh-surface-3); }
.btn-outline-success { border-color: var(--nh-success); color: var(--nh-success); }
.btn-outline-success:hover { background: var(--nh-success-soft); }
.btn-outline-danger { border-color: var(--nh-danger); color: var(--nh-danger); }
.btn-outline-danger:hover { background: var(--nh-danger-soft); }
.btn-outline-warning { border-color: var(--nh-warning); color: var(--nh-warning); }
.btn-outline-warning:hover { background: var(--nh-warning-soft); }
.btn-outline-info { border-color: var(--nh-info); color: var(--nh-info); }
.btn-outline-info:hover { background: var(--nh-info-soft); }

.btn-close {
  border: 0; background: transparent; cursor: pointer; color: var(--nh-faint);
  width: 32px; height: 32px; border-radius: var(--nh-radius-pill);
  display: inline-grid; place-items: center; font-size: 1rem; line-height: 1;
  transition: all var(--nh-t-fast); padding: 0;
}
.btn-close::before { content: "✕"; }
.btn-close:hover { background: var(--nh-surface-3); color: var(--nh-ink); }

/* Header submit CTA */
.nh-submit {
  background: var(--nh-grad); color: #fff !important; border: 0;
  border-radius: var(--nh-radius-pill); font-weight: 700; white-space: nowrap;
  box-shadow: var(--nh-shadow-accent);
}
.nh-submit:hover { filter: brightness(1.06); }
.nh-submit svg, .nh-submit span { color: #fff !important; }

/* ======================== 05 Forms & validation ========================= */
.form-label { display: inline-block; margin-block-end: .35rem; font-size: var(--nh-fs-sm); font-weight: 700; color: var(--nh-ink-2); }
.form-text { display: block; margin-block-start: .3rem; font-size: var(--nh-fs-xs); color: var(--nh-faint); }
.form-control, .form-select {
  display: block; width: 100%;
  padding: .6rem .95rem; font-size: var(--nh-fs-sm); color: var(--nh-ink);
  background: var(--nh-surface); border: 1px solid var(--nh-border);
  border-radius: var(--nh-radius); transition: border-color var(--nh-t-fast), box-shadow var(--nh-t-fast);
  line-height: 1.6; appearance: none;
}
textarea.form-control { min-height: 96px; resize: vertical; }
.form-control::placeholder { color: var(--nh-faint); }
.form-control:focus, .form-select:focus {
  border-color: var(--nh-accent); outline: none;
  box-shadow: 0 0 0 4px var(--nh-accent-ring);
  background: var(--nh-surface);
}
.form-control:disabled, .form-select:disabled { background: var(--nh-surface-3); color: var(--nh-muted); }
.form-control-sm, .form-select-sm { padding: .35rem .7rem; font-size: var(--nh-fs-xs); border-radius: var(--nh-radius-sm); }
.form-select {
  padding-inline-end: 2.4rem;
  background-image: url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%23667085' stroke-width='2.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: left .9rem center;
}
.form-check { display: flex; align-items: center; gap: .5rem; margin-block-end: .35rem; }
.form-check-input {
  appearance: none; width: 18px; height: 18px; flex: 0 0 auto; margin: 0;
  border: 1.5px solid var(--nh-border-strong); border-radius: 5px;
  background: var(--nh-surface); cursor: pointer; transition: all var(--nh-t-fast);
  display: inline-grid; place-items: center;
}
.form-check-input:checked { background: var(--nh-grad); border-color: transparent; }
.form-check-input:checked::before { content: "✓"; color: #fff; font-size: .7rem; font-weight: 900; }
.form-check-input[type="radio"] { border-radius: 50%; }
.form-check-input[type="radio"]:checked::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: #fff; }
.form-check-label { font-size: var(--nh-fs-sm); color: var(--nh-ink-2); cursor: pointer; }
.input-group { display: flex; width: 100%; gap: .5rem; }
.input-group .form-control { flex: 1 1 auto; }
.input-group-lg .form-control { padding: .8rem 1.1rem; font-size: var(--nh-fs-base); }

/* jQuery-unobtrusive validation states */
.input-validation-error { border-color: var(--nh-danger) !important; }
.input-validation-error:focus { box-shadow: 0 0 0 4px var(--nh-danger-soft) !important; }
.field-validation-error { display: block; margin-block-start: .3rem; font-size: var(--nh-fs-xs); color: var(--nh-danger); }
.validation-summary-errors {
  background: var(--nh-danger-soft); border: 1px solid var(--nh-danger);
  color: var(--nh-danger); border-radius: var(--nh-radius); padding: var(--nh-3) var(--nh-4);
  margin-block-end: var(--nh-4); font-size: var(--nh-fs-sm);
}
.validation-summary-errors ul { margin: 0; padding-inline-start: 1.1rem; }
.validation-summary-valid { display: none; }

/* ========================= 06 Layout primitives ========================= */
.nh-layout { display: grid; grid-template-columns: minmax(0, 1fr); gap: 2rem; align-items: start; }
@media (min-width: 992px) {
  .nh-layout { grid-template-columns: minmax(0, 1fr) 340px; }
  .nh-layout--reverse { grid-template-columns: 340px minmax(0, 1fr); }
}
.nh-aside { display: flex; flex-direction: column; gap: var(--nh-4); min-width: 0; }
@media (min-width: 992px) {
  .nh-aside { position: sticky; inset-block-start: calc(var(--nh-header-h) + 1rem); }
}
.nh-stack { display: flex; flex-direction: column; gap: var(--nh-3); }
.nh-cluster { display: flex; align-items: center; gap: var(--nh-3); flex-wrap: wrap; }

.nh-section { margin-block: var(--nh-6); }
.nh-section__head { display: flex; align-items: center; gap: var(--nh-3); margin-block-end: var(--nh-4); flex-wrap: wrap; }
.nh-section__title { margin: 0; font-size: var(--nh-fs-lg); font-weight: 800; letter-spacing: -.01em; }
.nh-section__sub { color: var(--nh-muted); font-size: var(--nh-fs-sm); margin: 0; }
.nh-section__action { margin-inline-start: auto; font-size: var(--nh-fs-sm); font-weight: 700; color: var(--nh-accent-600); display: inline-flex; align-items: center; gap: .3rem; }
.nh-section__action:hover { gap: .55rem; }

.nh-seeall {
  display: flex; justify-content: center; padding: var(--nh-3);
  border-radius: var(--nh-radius); font-size: var(--nh-fs-sm); font-weight: 700;
  color: var(--nh-accent-600); transition: background var(--nh-t-fast);
}
.nh-seeall:hover { background: var(--nh-accent-soft); }

/* ====================== 07 Header + nav + search ======================== */
.nh-header {
  position: sticky; inset-block-start: 0; z-index: var(--nh-z-header);
  height: var(--nh-header-h);
  background: var(--nh-glass);
  backdrop-filter: blur(14px) saturate(1.4);
  -webkit-backdrop-filter: blur(14px) saturate(1.4);
  border-block-end: 1px solid var(--nh-border);
}
.nh-header__inner {
  max-width: var(--nh-container); margin-inline: auto; height: 100%;
  padding-inline: clamp(1rem, 3vw, 2rem);
  display: flex; align-items: center; gap: 1rem;
}
.nh-header__actions { display: flex; align-items: center; gap: .55rem; }

.nh-brand { display: inline-flex; align-items: center; gap: .6rem; font-weight: 900; font-size: 1.1rem; letter-spacing: -.02em; color: var(--nh-ink); }
.nh-brand:hover { color: var(--nh-ink); }
.nh-brand__mark {
  width: 48px; height: 40px; flex: 0 0 auto;
  display: inline-block; overflow: hidden;
  /* Transparent icon-only glyph — works on both light and dark themes (no white tile). */
  background: url("../logo-mark.png") center / contain no-repeat;
  color: transparent; font-size: 0; line-height: 0; text-indent: -9999px;
  transition: transform var(--nh-t);
}
.nh-brand:hover .nh-brand__mark { transform: scale(1.06); }

.nh-search { position: relative; flex: 0 1 300px; min-width: 0; }
.nh-search__input {
  width: 100%; height: 42px; border: 1px solid transparent; border-radius: var(--nh-radius-pill);
  background: var(--nh-surface-3); color: var(--nh-ink);
  font-family: inherit; font-size: var(--nh-fs-sm);
  padding-inline: 2.6rem 1rem; transition: all var(--nh-t-fast);
}
.nh-search__input::placeholder { color: var(--nh-faint); }
.nh-search__input:focus { border-color: var(--nh-accent); background: var(--nh-surface); box-shadow: 0 0 0 4px var(--nh-accent-ring); outline: none; }
.nh-search__icon { position: absolute; inset-inline-start: .9rem; inset-block-start: 50%; translate: 0 -50%; color: var(--nh-faint); display: inline-flex; pointer-events: none; }

.nh-nav { display: none; align-items: center; gap: .1rem; min-width: 0; }
@media (min-width: 992px) { .nh-nav { display: flex; } }
.nh-nav__link {
  display: inline-flex; align-items: center; gap: .3rem; white-space: nowrap;
  padding: .5rem .8rem; border-radius: var(--nh-radius-pill);
  font-size: var(--nh-fs-sm); font-weight: 600; color: var(--nh-ink-2);
  transition: all var(--nh-t-fast);
}
.nh-nav__link:hover { background: var(--nh-surface-3); color: var(--nh-ink); }
.nh-nav__link.is-active { color: var(--nh-accent-600); background: var(--nh-accent-soft); }
.nh-nav__caret { font-size: .6rem; color: var(--nh-faint); transition: transform var(--nh-t-fast); display: inline-flex; align-self: center; }
.dropdown:hover .nh-nav__caret, .dropdown.is-open .nh-nav__caret { transform: rotate(180deg); color: var(--nh-accent-600); }
.nh-nav .dropdown:hover > .nh-nav__link { color: var(--nh-accent-600); }

.nh-iconbtn {
  width: 42px; height: 42px; flex: 0 0 auto; border-radius: var(--nh-radius-pill);
  border: 1px solid var(--nh-border); background: var(--nh-surface); color: var(--nh-ink-2);
  display: inline-grid; place-items: center; cursor: pointer; position: relative;
  transition: all var(--nh-t-fast); text-decoration: none; font-size: 1rem; padding: 0;
}
.nh-iconbtn:hover { border-color: var(--nh-border-strong); transform: translateY(-1px); box-shadow: var(--nh-shadow-sm); color: var(--nh-ink); }

.nh-count-badge {
  position: absolute; inset-block-start: -4px; inset-inline-end: -4px;
  min-width: 18px; height: 18px; padding-inline: 4px; border-radius: var(--nh-radius-pill);
  background: var(--nh-grad); color: #fff; font-size: .62rem; font-weight: 800;
  display: inline-grid; place-items: center; line-height: 1;
  box-shadow: 0 0 0 2px var(--nh-surface);
}

/* Theme toggle (sun/moon swap driven by [data-theme]) */
.nh-themetoggle .nh-ic-sun { display: none; }
:root[data-theme="dark"] .nh-themetoggle .nh-ic-sun { display: inline-flex; }
:root[data-theme="dark"] .nh-themetoggle .nh-ic-moon { display: none; }

/* Notification bell panel */
.nh-bell { position: relative; }
.nh-bell__panel {
  position: absolute; inset-inline-end: 0; inset-block-start: calc(100% + 10px);
  width: min(360px, calc(100vw - 2rem)); max-height: 420px; overflow: auto;
  background: var(--nh-surface); border: 1px solid var(--nh-border);
  border-radius: var(--nh-radius-lg); box-shadow: var(--nh-shadow-lg);
  opacity: 0; visibility: hidden; transform: translateY(8px);
  transition: opacity var(--nh-t), transform var(--nh-t), visibility var(--nh-t);
  z-index: var(--nh-z-dropdown);
}
.nh-bell.is-open .nh-bell__panel { opacity: 1; visibility: visible; transform: none; }
.nh-bell__head {
  display: flex; align-items: center; justify-content: space-between;
  padding: var(--nh-3) var(--nh-4); border-block-end: 1px solid var(--nh-border);
  font-weight: 800; font-size: var(--nh-fs-sm);
  position: sticky; inset-block-start: 0; background: var(--nh-surface); z-index: 1;
}
.nh-notif { display: flex; gap: var(--nh-3); padding: var(--nh-3) var(--nh-4); border-block-end: 1px solid var(--nh-border); align-items: flex-start; transition: background var(--nh-t-fast); }
.nh-notif:last-child { border-block-end: 0; }
a.nh-notif:hover { background: var(--nh-surface-2); }
.nh-notif__dot { width: 9px; height: 9px; border-radius: 50%; background: var(--nh-accent); margin-block-start: .5rem; flex: 0 0 auto; }
.nh-notif__dot.is-read { background: var(--nh-border-strong); }
.nh-notif__body { min-width: 0; }
.nh-notif__title { font-weight: 700; font-size: var(--nh-fs-sm); }
.nh-notif__text { color: var(--nh-muted); font-size: var(--nh-fs-xs); }

/* Mega menu + icon-row menus (data from NavTaxonomy component) */
.nh-mega { width: min(580px, calc(100vw - 2rem)); padding: var(--nh-3); }
.nh-mega__promo {
  display: flex; gap: var(--nh-3); align-items: flex-start;
  background: linear-gradient(135deg, var(--nh-accent-soft), transparent 65%);
  border-radius: var(--nh-radius); padding: var(--nh-3); margin-block-end: var(--nh-2);
}
.nh-mega__promoicon {
  width: 44px; height: 44px; border-radius: var(--nh-radius);
  background: var(--nh-grad); color: #fff; display: inline-grid; place-items: center;
  font-size: 1.3rem; flex: 0 0 auto; box-shadow: var(--nh-shadow-accent);
}
.nh-mega__promotitle { font-weight: 800; font-size: var(--nh-fs-sm); }
.nh-mega__promosub { color: var(--nh-muted); font-size: var(--nh-fs-xs); margin-block: .15rem .4rem; }
.nh-mega__promolink { display: inline-flex; margin-inline-end: var(--nh-3); color: var(--nh-accent-600); font-size: var(--nh-fs-xs); font-weight: 700; }
.nh-mega__cols { display: grid; grid-template-columns: 1fr 1fr; gap: var(--nh-2); }
.nh-mega__list { display: flex; flex-direction: column; }
.nh-mega__item {
  display: block; padding: .45rem .7rem; border-radius: var(--nh-radius-sm);
  font-size: var(--nh-fs-sm); color: var(--nh-ink-2); transition: all var(--nh-t-fast);
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.nh-mega__item:hover, .nh-mega__item.is-active { background: var(--nh-nav-highlight); color: var(--nh-ink); }
.nh-mega__panel { border-inline-start: 1px solid var(--nh-border); padding-inline-start: var(--nh-3); }
.nh-mega__paneltitle { font-size: var(--nh-fs-xs); font-weight: 800; color: var(--nh-faint); padding: .45rem .7rem .2rem; }
.nh-mega__panellink { display: block; padding: .35rem .7rem; border-radius: var(--nh-radius-sm); font-size: var(--nh-fs-sm); color: var(--nh-ink-2); }
.nh-mega__panellink:hover { background: var(--nh-nav-highlight); color: var(--nh-ink); }

.nh-navrow { display: flex; align-items: center; gap: var(--nh-3); padding: .55rem .7rem; border-radius: var(--nh-radius); transition: background var(--nh-t-fast); }
.nh-navrow:hover { background: var(--nh-nav-highlight); }
.nh-navrow__icon {
  width: 40px; height: 40px; flex: 0 0 auto; border-radius: var(--nh-radius);
  display: inline-grid; place-items: center; font-size: 1.15rem;
  background: var(--nh-surface-3);
}
.nh-navrow__icon--blue { background: var(--nh-info-soft); }
.nh-navrow__icon--pink { background: #fdeef5; }
.nh-navrow__icon--green { background: var(--nh-success-soft); }
.nh-navrow__icon--peach { background: var(--nh-accent-soft); }
:root[data-theme="dark"] .nh-navrow__icon--pink { background: rgba(217, 79, 162, .16); }
.nh-navrow__title { font-weight: 700; font-size: var(--nh-fs-sm); color: var(--nh-ink); }
.nh-navrow__sub { display: block; color: var(--nh-muted); font-size: var(--nh-fs-xs); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

/* ===================== 08 Drawer + mobile bottom nav ==================== */
body.nh-no-scroll { overflow: hidden; }
.nh-drawer { position: fixed; inset: 0; z-index: var(--nh-z-drawer); pointer-events: none; visibility: hidden; }
.nh-drawer.is-open { visibility: visible; }
.nh-drawer__backdrop {
  position: absolute; inset: 0; background: rgba(16, 24, 40, .5);
  opacity: 0; transition: opacity var(--nh-t);
  backdrop-filter: blur(2px); -webkit-backdrop-filter: blur(2px);
}
.nh-drawer__panel {
  position: absolute; inset-block: 0; inset-inline-start: 0;
  width: min(320px, 86vw); background: var(--nh-surface);
  box-shadow: var(--nh-shadow-lg); padding: var(--nh-4);
  overflow-y: auto; display: flex; flex-direction: column; gap: .15rem;
  transform: translateX(var(--nh-drawer-shift, -100%));
  transition: transform var(--nh-t-slow);
}
html[dir="rtl"] .nh-drawer__panel { --nh-drawer-shift: 100%; }
.nh-drawer.is-open { pointer-events: auto; }
.nh-drawer.is-open .nh-drawer__backdrop { opacity: 1; }
.nh-drawer.is-open .nh-drawer__panel { transform: none; }
.nh-drawer__head { display: flex; align-items: center; justify-content: space-between; margin-block-end: var(--nh-3); }

.nh-menu { display: flex; flex-direction: column; gap: .15rem; }
.nh-menu__item {
  display: flex; align-items: center; gap: .6rem;
  padding: .6rem .8rem; border-radius: var(--nh-radius);
  font-size: var(--nh-fs-sm); font-weight: 600; color: var(--nh-ink-2);
  transition: all var(--nh-t-fast);
}
.nh-menu__item:hover { background: var(--nh-surface-3); color: var(--nh-ink); }
.nh-menu__item.is-active { background: var(--nh-accent-soft); color: var(--nh-accent-600); }

/* Collapsible sidebar groups */
.nh-menu__group { border-radius: var(--nh-radius); }
.nh-menu__grouphead {
  display: flex; align-items: center; justify-content: space-between; gap: .5rem;
  padding: .55rem .8rem; border-radius: var(--nh-radius); cursor: pointer;
  font-size: var(--nh-fs-xs, .72rem); font-weight: 700; letter-spacing: .02em;
  color: var(--nh-faint); text-transform: none; user-select: none;
  list-style: none; transition: all var(--nh-t-fast);
}
.nh-menu__grouphead::-webkit-details-marker { display: none; }
.nh-menu__grouphead:hover { background: var(--nh-surface-3); color: var(--nh-ink-2); }
.nh-menu__chev { flex: none; transition: transform var(--nh-t-fast); opacity: .7; }
.nh-menu__group[open] > .nh-menu__grouphead { color: var(--nh-ink-2); }
.nh-menu__group[open] > .nh-menu__grouphead .nh-menu__chev { transform: rotate(180deg); }
.nh-menu__grouplist { display: flex; flex-direction: column; gap: .15rem; padding-inline-start: .35rem; }

/* App-like bottom navigation on phones */
.nh-bnav {
  position: fixed; inset-block-end: 0; inset-inline: 0; z-index: var(--nh-z-header);
  height: 62px; display: grid; grid-template-columns: repeat(5, 1fr);
  background: var(--nh-glass);
  backdrop-filter: blur(14px) saturate(1.4); -webkit-backdrop-filter: blur(14px) saturate(1.4);
  border-block-start: 1px solid var(--nh-border);
  padding-block-end: env(safe-area-inset-bottom, 0);
}
@media (min-width: 768px) { .nh-bnav { display: none; } }
@media (max-width: 767.98px) { body { padding-block-end: 62px; } }
.nh-bnav__item {
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px;
  font-size: .62rem; font-weight: 700; color: var(--nh-faint);
}
.nh-bnav__item.is-active, .nh-bnav__item:hover { color: var(--nh-accent-600); }
.nh-bnav__fab {
  width: 46px; height: 46px; border-radius: 16px; margin-block-start: -18px;
  background: var(--nh-grad); color: #fff; display: inline-grid; place-items: center;
  box-shadow: var(--nh-shadow-accent); font-size: 1.4rem; line-height: 1;
}

/* ==================== 09 Hero / pagehead / welcome ====================== */
.nh-hero {
  text-align: center; padding: clamp(2rem, 6vw, 3.5rem) var(--nh-4);
  background:
    radial-gradient(50% 90% at 50% 0%, var(--nh-accent-soft) 0%, transparent 75%),
    var(--nh-surface);
  border: 1px solid var(--nh-border); border-radius: var(--nh-radius-xl);
  margin-block: var(--nh-5);
}
.nh-hero h1 { margin-block-end: var(--nh-2); font-size: clamp(1.5rem, 3.4vw, var(--nh-fs-2xl)); font-weight: 900; }
.nh-hero p { color: var(--nh-muted); max-width: 62ch; margin-inline: auto; }

.nh-pagehead { padding-block: var(--nh-6) var(--nh-2); }
.nh-pagehead h1 { margin: 0; font-size: clamp(1.4rem, 3vw, var(--nh-fs-2xl)); font-weight: 900; letter-spacing: -.02em; }
.nh-pagehead p { margin: .4rem 0 0; color: var(--nh-muted); font-size: var(--nh-fs-sm); }

.nh-welcome {
  display: flex; align-items: flex-start; gap: var(--nh-3);
  background: linear-gradient(135deg, var(--nh-accent-soft), transparent 70%), var(--nh-surface);
  border: 1px solid var(--nh-border); border-radius: var(--nh-radius-lg);
  padding: var(--nh-4); margin-block-start: var(--nh-5);
}
.nh-welcome__icon { font-size: 1.6rem; line-height: 1; }
.nh-welcome__title { font-weight: 800; }
.nh-welcome__text { color: var(--nh-muted); font-size: var(--nh-fs-sm); margin: 0; }
.nh-welcome__close { margin-inline-start: auto; }

/* ==================== 10 Feed & product rows + vote ===================== */
.nh-feed { display: flex; flex-direction: column; gap: .65rem; }

.nh-product {
  position: relative;
  display: grid; grid-template-columns: 56px minmax(0, 1fr) auto;
  gap: var(--nh-4); align-items: center;
  background: var(--nh-surface); border: 1px solid var(--nh-border);
  border-radius: var(--nh-radius-lg); padding: .9rem 1rem;
  transition: transform var(--nh-t), box-shadow var(--nh-t), border-color var(--nh-t);
}
.nh-product:hover { transform: translateY(-2px); box-shadow: var(--nh-shadow); border-color: var(--nh-border-strong); }

.nh-product__thumb {
  width: 56px; height: 56px; border-radius: var(--nh-radius);
  display: grid; place-items: center; overflow: hidden; flex: 0 0 auto;
  font-size: 1.4rem; font-weight: 800; color: #fff;
  background: var(--nh-grad);
}
.nh-product__thumb img { width: 100%; height: 100%; object-fit: cover; }
/* Real product logos: white tile + contain so transparent PNGs don't sit on a gradient. */
.nh-product__thumb.has-logo { background: #fff !important; }
.nh-product__thumb.has-logo img { object-fit: contain; padding: 4px; }
.nh-product-logo { position: relative; overflow: hidden; }
.nh-product-logo > img { width: 100%; height: 100%; object-fit: contain; padding: 4px; }
.nh-product-logo__fallback {
  position: absolute; inset: 0; display: grid; place-items: center;
  background: var(--nh-grad); color: #fff; font: inherit;
}
.nh-product-logo__fallback[hidden] { display: none; }
/* Rotate the letter-tile palette so the feed feels alive without markup changes */
.nh-product:nth-child(6n+2) .nh-product__thumb { background: linear-gradient(135deg, #7c5cff, #4f8dff); }
.nh-product:nth-child(6n+3) .nh-product__thumb { background: linear-gradient(135deg, #00b37e, #00d2a8); }
.nh-product:nth-child(6n+4) .nh-product__thumb { background: linear-gradient(135deg, #2f6fed, #39c0ed); }
.nh-product:nth-child(6n+5) .nh-product__thumb { background: linear-gradient(135deg, #d94fa2, #ff6f91); }
.nh-product:nth-child(6n+6) .nh-product__thumb { background: linear-gradient(135deg, #e8a13a, #f5c76b); }

.nh-product__body { min-width: 0; }
.nh-product__title {
  font-weight: 800; font-size: var(--nh-fs-md); letter-spacing: -.01em; color: var(--nh-ink);
  display: inline-flex; align-items: center; gap: .5rem; max-width: 100%;
}
.nh-product__title:hover { color: var(--nh-accent-600); }
.nh-product__rank {
  position: absolute; inset-block-start: -9px; inset-inline-start: -9px;
  min-width: 26px; height: 26px; padding-inline: .35rem; border-radius: 9px;
  display: grid; place-items: center;
  font-size: .78rem; font-weight: 800; font-feature-settings: "tnum";
  background: var(--nh-surface); border: 1px solid var(--nh-border); color: var(--nh-muted);
  box-shadow: var(--nh-shadow-xs);
}
/* Top-3 get the brand medal */
.nh-product:nth-child(-n+3) .nh-product__rank {
  background: var(--nh-grad); border-color: transparent; color: #fff;
  box-shadow: var(--nh-shadow-accent);
}
.nh-product__tagline { color: var(--nh-muted); font-size: var(--nh-fs-sm); margin-block-start: .15rem; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.nh-product__meta { display: flex; align-items: center; gap: .5rem; margin-block-start: .45rem; font-size: var(--nh-fs-xs); color: var(--nh-faint); flex-wrap: wrap; }
.nh-product__dot { color: var(--nh-border-strong); }
.nh-product__topic {
  background: var(--nh-surface-3); border-radius: var(--nh-radius-pill);
  padding: .12rem .7rem; font-weight: 600; color: var(--nh-muted);
  transition: all var(--nh-t-fast);
}
.nh-product__topic:hover { background: var(--nh-accent-soft); color: var(--nh-accent-600); }
.nh-product__actions { display: flex; gap: .5rem; align-items: center; }

.nh-vote {
  display: inline-flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px;
  min-width: 56px; padding: .5rem .4rem;
  border: 1px solid var(--nh-border); border-radius: var(--nh-radius);
  background: var(--nh-surface); color: var(--nh-ink-2);
  cursor: pointer; font-family: inherit; text-decoration: none;
  transition: all var(--nh-t-fast);
}
.nh-vote:hover { border-color: var(--nh-accent); color: var(--nh-accent-600); background: var(--nh-accent-soft); }
.nh-vote:hover .nh-vote__caret { transform: translateY(-2px); }
.nh-vote__caret { display: inline-flex; transition: transform var(--nh-t-fast); }
.nh-vote__count { font-size: var(--nh-fs-sm); font-weight: 800; font-feature-settings: "tnum"; line-height: 1.2; }
.nh-vote.is-voted { background: var(--nh-grad); border-color: transparent; color: #fff; box-shadow: var(--nh-shadow-accent); }
.nh-vote.is-voted:hover { color: #fff; }
.nh-vote.is-pulsing { animation: nh-pop .5s cubic-bezier(.34, 1.56, .64, 1); }
@keyframes nh-pop { 40% { transform: scale(1.12); } }
.nh-vote--ghost { border-style: dashed; }
.nh-vote--ghost:hover { border-color: var(--nh-info); color: var(--nh-info); background: var(--nh-info-soft); }
/* Large CTA variant on the product-detail header */
.nh-vote--cta {
  flex-direction: row; gap: .5rem; min-width: 0;
  padding: .75rem 1.6rem; font-size: var(--nh-fs-md); font-weight: 800;
  border-radius: var(--nh-radius-pill);
  background: var(--nh-grad); border-color: transparent; color: #fff;
  box-shadow: var(--nh-shadow-accent);
}
.nh-vote--cta:hover { color: #fff; background: var(--nh-grad); filter: brightness(1.06); transform: translateY(-1px); }
.nh-vote--cta.is-voted { background: var(--nh-surface); color: var(--nh-accent-600); border: 1px solid var(--nh-accent); box-shadow: none; filter: none; }
.nh-vote--cta.is-voted:hover { color: var(--nh-accent-700); }

/* =================== 11 Sidebar panels / threads ======================== */
.nh-panel {
  background: var(--nh-surface); border: 1px solid var(--nh-border);
  border-radius: var(--nh-radius-lg); overflow: hidden; min-width: 0;
}
.nh-panel__head {
  display: flex; align-items: center; gap: .55rem;
  padding: .9rem 1.1rem; border-block-end: 1px solid var(--nh-border);
  font-weight: 800; font-size: var(--nh-fs-sm);
}
.nh-panel__head .nh-section__action { font-size: var(--nh-fs-xs); }
.nh-panel__body { padding: var(--nh-4); }

/* --- Forum shell (PH-style /forums: sidebar nav + community header + thread rows) --- */
.nh-forum { display: grid; grid-template-columns: 260px minmax(0, 1fr); gap: 2rem; align-items: start; padding-block: var(--nh-5) 0; }
.nh-fnav { display: flex; flex-direction: column; gap: .15rem; min-width: 0; }
@media (min-width: 992px) {
  .nh-fnav { position: sticky; inset-block-start: calc(var(--nh-header-h) + 1rem); }
}
.nh-fnav__group { margin: var(--nh-4) 0 .25rem; padding-inline: .8rem; font-size: var(--nh-fs-xs); font-weight: 800; color: var(--nh-faint); }
.nh-fnav__item {
  display: flex; align-items: center; gap: .6rem; width: 100%;
  padding: .5rem .8rem; border: 0; border-radius: var(--nh-radius);
  background: transparent; font-family: inherit; font-size: var(--nh-fs-sm); font-weight: 600;
  color: var(--nh-ink-2); text-align: start; cursor: pointer;
  transition: all var(--nh-t-fast); white-space: nowrap; text-decoration: none;
}
.nh-fnav__item:hover { background: var(--nh-surface-3); color: var(--nh-ink); }
.nh-fnav__item.is-active { background: var(--nh-surface-3); color: var(--nh-ink); font-weight: 800; }
.nh-fnav__icon {
  width: 30px; height: 30px; flex: 0 0 auto; border-radius: 9px;
  display: inline-grid; place-items: center; font-size: .9rem;
  background: var(--nh-surface-3); color: var(--nh-ink-2);
}
.nh-fnav__item.is-active .nh-fnav__icon { background: var(--nh-accent-soft); color: var(--nh-accent-600); }
.nh-fnav__note { padding: .3rem .8rem; font-size: var(--nh-fs-xs); color: var(--nh-faint); white-space: normal; }

.nh-fhead {
  display: flex; align-items: center; gap: var(--nh-4); flex-wrap: wrap;
  background: var(--nh-surface); border: 1px solid var(--nh-border);
  border-radius: var(--nh-radius-xl); padding: var(--nh-5);
  margin-block-end: var(--nh-4);
}
.nh-fhead__icon {
  width: 64px; height: 64px; flex: 0 0 auto; border-radius: var(--nh-radius-lg);
  display: grid; place-items: center; font-size: 1.7rem;
  background: var(--nh-surface-2); border: 1px solid var(--nh-border);
}
.nh-fhead__title { margin: 0; font-size: clamp(1.25rem, 2.4vw, var(--nh-fs-xl)); font-weight: 900; letter-spacing: -.02em; }
.nh-fhead__sub { margin: .15rem 0 0; color: var(--nh-muted); font-size: var(--nh-fs-sm); }
.nh-fhead__cta { margin-inline-start: auto; }
@media (max-width: 767.98px) { .nh-fhead__cta { margin-inline-start: 0; width: 100%; } }

.nh-fsort {
  display: inline-flex; align-items: center; gap: .3rem;
  border: 0; background: none; padding: .3rem .2rem; cursor: pointer;
  font-family: inherit; font-size: var(--nh-fs-sm); font-weight: 800;
  color: var(--nh-accent-600);
}
.nh-fsort .nh-nav__caret { color: var(--nh-accent-600); }

.nh-fthread {
  display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: var(--nh-4);
  align-items: start;
  background: var(--nh-surface); border: 1px solid var(--nh-border);
  border-radius: var(--nh-radius-lg); padding: var(--nh-4) var(--nh-5);
  transition: transform var(--nh-t), box-shadow var(--nh-t), border-color var(--nh-t);
}
.nh-fthread:hover { transform: translateY(-2px); box-shadow: var(--nh-shadow); border-color: var(--nh-border-strong); }
.nh-fthread__head { display: flex; align-items: center; gap: .5rem; flex-wrap: wrap; font-size: var(--nh-fs-xs); color: var(--nh-faint); }
.nh-fthread__author { font-weight: 700; color: var(--nh-ink-2); }
.nh-fthread__title { display: block; margin-block-start: .4rem; font-weight: 800; font-size: var(--nh-fs-md); color: var(--nh-ink); transition: color var(--nh-t-fast); }
.nh-fthread:hover .nh-fthread__title { color: var(--nh-accent-600); }
.nh-fthread__preview {
  margin-block-start: .3rem; color: var(--nh-muted); font-size: var(--nh-fs-sm);
  white-space: pre-line; overflow-wrap: anywhere;
  display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden;
}
.nh-fthread__counts { display: flex; gap: .5rem; }

@media (max-width: 991.98px) {
  .nh-forum { grid-template-columns: minmax(0, 1fr); gap: var(--nh-4); }
  /* Sidebar becomes a horizontal chip rail above the list on small screens. */
  .nh-fnav { flex-direction: row; overflow-x: auto; padding-block-end: .35rem; scrollbar-width: none; }
  .nh-fnav::-webkit-scrollbar { display: none; }
  .nh-fnav__group, .nh-fnav__note, .nh-fnav .nh-divider { display: none; }
  .nh-fnav__item { flex: 0 0 auto; width: auto; border: 1px solid var(--nh-border); border-radius: var(--nh-radius-pill); padding-block: .35rem; }
  .nh-fnav__icon { width: 22px; height: 22px; font-size: .75rem; border-radius: 7px; }
}
@media (max-width: 575.98px) { .nh-fthread { padding: var(--nh-4); } }

.nh-thread { display: block; padding-block: .6rem; }
.nh-thread + .nh-thread { border-block-start: 1px dashed var(--nh-border); }
.nh-thread__source { font-size: var(--nh-fs-xs); color: var(--nh-faint); }
.nh-thread__title {
  font-weight: 700; font-size: var(--nh-fs-sm); line-height: 1.55; color: var(--nh-ink);
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
  transition: color var(--nh-t-fast);
}
.nh-thread:hover .nh-thread__title { color: var(--nh-accent-600); }
.nh-thread__meta { font-size: var(--nh-fs-xs); color: var(--nh-faint); margin-block-start: .2rem; }

/* ================ 12 Avatars / chips / tags / pills ===================== */
.nh-avatar {
  width: 42px; height: 42px; border-radius: var(--nh-radius-pill); flex: 0 0 auto;
  display: inline-grid; place-items: center; overflow: hidden;
  background: linear-gradient(135deg, #7c5cff, #4f8dff); color: #fff;
  font-weight: 800; font-size: .95rem; text-transform: uppercase;
  border: 2px solid var(--nh-surface); box-shadow: var(--nh-shadow-sm);
}
.nh-avatar img { width: 100%; height: 100%; object-fit: cover; }
.nh-avatar--sm { width: 32px; height: 32px; font-size: .75rem; border-width: 1.5px; }
.nh-avatar--xl { width: 96px; height: 96px; font-size: 2rem; border-radius: 28px; }
.nh-avatar--2xl { width: 144px; height: 144px; font-size: 3rem; border-radius: 36px; }
.nh-avatar--product-logo { background: #fff; }
.nh-avatar--product-logo > img { object-fit: contain; padding: 2px; }
.nh-avatar__fallback {
  width: 100%; height: 100%; display: grid; place-items: center;
  background: linear-gradient(135deg, #7c5cff, #4f8dff); color: #fff;
}
.nh-avatar__fallback[hidden] { display: none; }

.nh-chip {
  display: inline-flex; align-items: center; gap: .35rem;
  border: 1px solid var(--nh-border); background: var(--nh-surface);
  border-radius: var(--nh-radius-pill); padding: .35rem 1rem;
  font-size: var(--nh-fs-sm); font-weight: 600; color: var(--nh-ink-2);
  cursor: pointer; transition: all var(--nh-t-fast); text-decoration: none;
}
.nh-chip:hover { border-color: var(--nh-border-strong); transform: translateY(-1px); color: var(--nh-ink); }
.nh-chip.is-active, .nh-chip.is-on { background: var(--nh-ink); border-color: var(--nh-ink); color: var(--nh-bg); }

.nh-tag {
  display: inline-flex; align-items: center; gap: .3rem;
  background: var(--nh-surface-3); color: var(--nh-muted);
  border-radius: var(--nh-radius-pill); padding: .15rem .75rem;
  font-size: var(--nh-fs-xs); font-weight: 600; transition: all var(--nh-t-fast);
}
a.nh-tag:hover { background: var(--nh-accent-soft); color: var(--nh-accent-600); }

.nh-pill {
  display: inline-flex; align-items: center; gap: .3rem;
  border-radius: var(--nh-radius-pill); padding: .18rem .8rem;
  font-size: var(--nh-fs-xs); font-weight: 700;
  background: var(--nh-surface-3); color: var(--nh-ink-2);
}
.nh-pill--success { background: var(--nh-success-soft); color: var(--nh-success); }
.nh-pill--info { background: var(--nh-info-soft); color: var(--nh-info); }
.nh-pill--warning { background: var(--nh-warning-soft); color: var(--nh-warning); }
.nh-pill--danger { background: var(--nh-danger-soft); color: var(--nh-danger); }
.nh-pill--muted { background: var(--nh-surface-3); color: var(--nh-faint); }

/* Selectable pill (e.g. owner-edit topics): a visually-hidden checkbox toggles the pill's colour on
   click, so it reads as a tag you turn on/off rather than a checkbox + label. */
.nh-pill--select { cursor: pointer; user-select: none; border: 1px solid var(--nh-border); background: var(--nh-surface-2); color: var(--nh-ink-2); transition: background .15s, border-color .15s, color .15s; }
.nh-pill--select:hover { border-color: var(--nh-accent); }
.nh-pill--select:has(input:checked) { background: var(--nh-accent-soft); color: var(--nh-accent-600); border-color: var(--nh-accent); }

.badge {
  display: inline-flex; align-items: center; gap: .3rem;
  border-radius: var(--nh-radius-pill); padding: .22rem .75rem;
  font-size: var(--nh-fs-xs); font-weight: 700; line-height: 1.4;
  background: var(--nh-surface-3); color: var(--nh-ink-2);
}
.badge.bg-success { background: var(--nh-success-soft) !important; color: var(--nh-success); }
.badge.bg-secondary { background: var(--nh-surface-3) !important; color: var(--nh-muted); }
.badge.bg-danger { background: var(--nh-danger-soft) !important; color: var(--nh-danger); }
.badge.bg-primary { background: var(--nh-accent-soft) !important; color: var(--nh-accent-600); }
.badge.bg-light { background: var(--nh-surface-3) !important; color: var(--nh-ink-2); }

/* =============================== 13 Tabs ================================ */
.nh-tabs {
  display: flex; align-items: center; gap: .25rem;
  border-block-end: 1px solid var(--nh-border);
  overflow-x: auto; scrollbar-width: none;
}
.nh-tabs::-webkit-scrollbar { display: none; }
.nh-tab {
  appearance: none; background: transparent; border: 0; cursor: pointer;
  padding: .65rem 1rem; margin-block-end: -1px;
  font-family: inherit; font-size: var(--nh-fs-sm); font-weight: 600; color: var(--nh-muted);
  border-block-end: 2px solid transparent; white-space: nowrap;
  transition: all var(--nh-t-fast); text-decoration: none; display: inline-flex; align-items: center; gap: .35rem;
}
.nh-tab:hover { color: var(--nh-ink); }
.nh-tab.is-active { color: var(--nh-ink); font-weight: 800; border-color: var(--nh-accent); }
/* Pill variant (profile) */
.nh-tabs--pills { border: 0; gap: .35rem; }
.nh-tabs--pills .nh-tab { border: 0; border-radius: var(--nh-radius-pill); padding: .45rem 1.1rem; margin: 0; }
.nh-tabs--pills .nh-tab.is-active { background: var(--nh-surface-3); color: var(--nh-ink); }

/* =================== 14 Dropdowns / modals / disclosure ================= */
.dropdown { position: relative; }
.dropdown-menu {
  position: absolute; inset-inline-start: 0; inset-block-start: calc(100% + 8px);
  min-width: 220px; padding: var(--nh-2);
  background: var(--nh-surface); border: 1px solid var(--nh-border);
  border-radius: var(--nh-radius-lg); box-shadow: var(--nh-shadow-lg);
  opacity: 0; visibility: hidden; transform: translateY(8px);
  transition: opacity var(--nh-t), transform var(--nh-t), visibility var(--nh-t);
  z-index: var(--nh-z-dropdown); list-style: none; margin: 0;
}
.dropdown-menu-end { inset-inline-start: auto; inset-inline-end: 0; }
/* Nav dropdowns open on hover/focus (desktop); any dropdown opens with .is-open (JS click) */
@media (hover: hover) and (min-width: 992px) {
  .nh-nav .dropdown:hover > .dropdown-menu,
  .nh-nav .dropdown:focus-within > .dropdown-menu { opacity: 1; visibility: visible; transform: none; }
}
.dropdown.is-open > .dropdown-menu { opacity: 1; visibility: visible; transform: none; }
.dropdown-menu li { list-style: none; }
.dropdown-item {
  display: block; width: 100%; padding: .5rem .8rem; border-radius: var(--nh-radius-sm);
  font-size: var(--nh-fs-sm); font-weight: 600; color: var(--nh-ink-2);
  background: transparent; border: 0; text-align: start; cursor: pointer;
  transition: all var(--nh-t-fast); text-decoration: none;
}
.dropdown-item:hover { background: var(--nh-nav-highlight); color: var(--nh-ink); }
.dropdown-header { padding: .5rem .8rem .25rem; font-size: var(--nh-fs-xs); font-weight: 800; color: var(--nh-faint); margin: 0; }
.dropdown-divider { border: 0; border-block-start: 1px solid var(--nh-border); margin: .4rem 0; }

/* Modal (vanilla — opened via [data-nh-modal-open="#id"], closed via [data-nh-modal-close]) */
.modal {
  position: fixed; inset: 0; z-index: var(--nh-z-modal);
  display: none; place-items: center; padding: var(--nh-4);
  background: rgba(16, 24, 40, .55);
  backdrop-filter: blur(3px); -webkit-backdrop-filter: blur(3px);
  overflow-y: auto;
}
.modal.is-open { display: grid; }
.modal-dialog { width: min(480px, 100%); margin: 0; }
.modal-content {
  background: var(--nh-surface); border: 1px solid var(--nh-border);
  border-radius: var(--nh-radius-xl); box-shadow: var(--nh-shadow-lg);
  overflow: hidden; animation: nh-modal-in .28s var(--nh-t-fast) both;
}
@keyframes nh-modal-in { from { opacity: 0; transform: translateY(14px) scale(.98); } to { opacity: 1; transform: none; } }
.modal-header {
  display: flex; align-items: center; justify-content: space-between;
  padding: var(--nh-4) var(--nh-5); border-block-end: 1px solid var(--nh-border);
}
.modal-title { margin: 0; font-size: var(--nh-fs-md); font-weight: 800; }
.modal-body { padding: var(--nh-5); }
.modal-footer { display: flex; justify-content: flex-end; gap: var(--nh-2); padding: var(--nh-4) var(--nh-5); border-block-start: 1px solid var(--nh-border); }

/* Disclosure — [data-nh-toggle="#id"] toggles [hidden]; <details class="nh-acc"> for FAQs */
.collapse:not(.show):not(.is-open) { display: none; }
.nh-acc {
  border: 1px solid var(--nh-border); border-radius: var(--nh-radius-lg);
  background: var(--nh-surface); margin-block-end: var(--nh-3); overflow: hidden;
}
.nh-acc summary {
  list-style: none; cursor: pointer; display: flex; align-items: center; gap: .6rem;
  padding: var(--nh-4) var(--nh-5); font-weight: 700; font-size: var(--nh-fs-sm);
  transition: background var(--nh-t-fast);
}
.nh-acc summary::-webkit-details-marker { display: none; }
.nh-acc summary::after { content: "▾"; margin-inline-start: auto; color: var(--nh-faint); transition: transform var(--nh-t-fast); font-size: .75rem; }
.nh-acc[open] summary::after { transform: rotate(180deg); color: var(--nh-accent-600); }
.nh-acc summary:hover { background: var(--nh-surface-2); }
.nh-acc__body { padding: 0 var(--nh-5) var(--nh-4); color: var(--nh-muted); font-size: var(--nh-fs-sm); }

/* ============ 15 Tables / cards / list groups / alerts / paging ========= */
.table-responsive { overflow-x: auto; -webkit-overflow-scrolling: touch; border-radius: var(--nh-radius-lg); border: 1px solid var(--nh-border); background: var(--nh-surface); }
.table { width: 100%; border-collapse: collapse; font-size: var(--nh-fs-sm); margin: 0; }
.table th, .table td { padding: .8rem 1rem; text-align: start; border-block-end: 1px solid var(--nh-border); }
.table thead th {
  font-size: var(--nh-fs-xs); font-weight: 800; color: var(--nh-faint);
  background: var(--nh-surface-2); border-block-end: 1px solid var(--nh-border);
  white-space: nowrap;
}
.table tbody tr { transition: background var(--nh-t-fast); }
.table tbody tr:last-child td { border-block-end: 0; }
.table-striped tbody tr:nth-child(even) { background: var(--nh-surface-2); }
.table-hover tbody tr:hover { background: var(--nh-nav-highlight); }
.align-middle { vertical-align: middle; }

.card {
  background: var(--nh-surface); border: 1px solid var(--nh-border);
  border-radius: var(--nh-radius-lg); overflow: hidden;
  transition: box-shadow var(--nh-t);
  display: flex; flex-direction: column; min-width: 0;
}
.card:hover { box-shadow: var(--nh-shadow-sm); }
.card-header { padding: var(--nh-3) var(--nh-4); border-block-end: 1px solid var(--nh-border); font-weight: 800; font-size: var(--nh-fs-sm); background: var(--nh-surface-2); }
.card-body { padding: var(--nh-4); flex: 1 1 auto; }
.card-footer { padding: var(--nh-3) var(--nh-4); border-block-start: 1px solid var(--nh-border); background: var(--nh-surface-2); }

.list-group { display: flex; flex-direction: column; border: 1px solid var(--nh-border); border-radius: var(--nh-radius-lg); overflow: hidden; padding: 0; margin: 0; background: var(--nh-surface); }
.list-group-flush { border-inline: 0; border-radius: 0; }
.list-group-item { list-style: none; padding: var(--nh-3) var(--nh-4); border-block-end: 1px solid var(--nh-border); font-size: var(--nh-fs-sm); background: transparent; }
.list-group-item:last-child { border-block-end: 0; }

.alert {
  display: block; padding: var(--nh-3) var(--nh-4); border-radius: var(--nh-radius);
  border: 1px solid var(--nh-border); background: var(--nh-surface-2);
  font-size: var(--nh-fs-sm); margin-block-end: var(--nh-4);
}
.alert-info { background: var(--nh-info-soft); border-color: transparent; color: var(--nh-info); }
.alert-success { background: var(--nh-success-soft); border-color: transparent; color: var(--nh-success); }
.alert-danger { background: var(--nh-danger-soft); border-color: transparent; color: var(--nh-danger); }

.pagination { display: flex; align-items: center; gap: .35rem; padding: 0; margin: var(--nh-5) 0 0; list-style: none; justify-content: center; flex-wrap: wrap; }
.page-item { list-style: none; }
.page-link {
  display: inline-flex; align-items: center; justify-content: center;
  min-width: 38px; height: 38px; padding-inline: .7rem;
  border: 1px solid var(--nh-border); border-radius: var(--nh-radius);
  background: var(--nh-surface); color: var(--nh-ink-2);
  font-size: var(--nh-fs-sm); font-weight: 700; font-feature-settings: "tnum";
  transition: all var(--nh-t-fast); text-decoration: none; cursor: pointer;
}
.page-link:hover { border-color: var(--nh-accent); color: var(--nh-accent-600); background: var(--nh-accent-soft); }
.page-item.active .page-link, .page-link.is-active { background: var(--nh-grad); border-color: transparent; color: #fff; box-shadow: var(--nh-shadow-accent); }
.page-item.disabled .page-link { opacity: .45; pointer-events: none; }

/* ================ 16 Comments / composer / reviews ====================== */
.nh-comments { margin-block-start: var(--nh-4); }
.nh-comment { display: flex; gap: var(--nh-3); padding: var(--nh-4) 0; border-block-end: 1px solid var(--nh-border); }
.nh-comment:last-child { border-block-end: 0; }
.nh-comment__body { min-width: 0; flex: 1 1 auto; }
.nh-comment__head { display: flex; align-items: center; gap: .4rem; flex-wrap: wrap; }
.nh-comment__author { font-weight: 700; font-size: var(--nh-fs-sm); color: var(--nh-ink); }
.nh-comment__author:hover { color: var(--nh-accent-600); }
.nh-comment__time { color: var(--nh-faint); font-size: var(--nh-fs-xs); }
.nh-comment__text { margin: .3rem 0 .4rem; font-size: var(--nh-fs-sm); color: var(--nh-ink-2); overflow-wrap: anywhere; }
.nh-comment__actions { display: flex; align-items: center; gap: var(--nh-3); }
.nh-comment__action {
  border: 0; background: none; padding: 0; cursor: pointer;
  font-family: inherit; font-size: var(--nh-fs-xs); font-weight: 700; color: var(--nh-faint);
  transition: color var(--nh-t-fast); display: inline-flex; align-items: center; gap: .25rem;
}
.nh-comment__action:hover { color: var(--nh-accent-600); }
.nh-comment__replies { margin-block-start: var(--nh-2); padding-inline-start: var(--nh-4); border-inline-start: 2px solid var(--nh-border); }
.nh-comment__reply { margin-block-start: var(--nh-2); }

.nh-composer { display: flex; gap: var(--nh-3); align-items: flex-start; margin-block: var(--nh-4); }
.nh-composer__box {
  flex: 1 1 auto; border: 1px solid var(--nh-border); border-radius: var(--nh-radius-lg);
  background: var(--nh-surface); padding: var(--nh-2) var(--nh-3);
  transition: border-color var(--nh-t-fast), box-shadow var(--nh-t-fast);
}
.nh-composer__box:focus-within { border-color: var(--nh-accent); box-shadow: 0 0 0 4px var(--nh-accent-ring); }
.nh-composer__box textarea, .nh-composer__box .form-control { border: 0; box-shadow: none !important; padding: .4rem .2rem; background: transparent; }

.nh-reviews { margin-block-start: var(--nh-4); }
.nh-stars { color: var(--nh-warning); letter-spacing: .1em; font-size: 1.05rem; white-space: nowrap; }
.nh-stars-input { display: inline-flex; gap: .15rem; cursor: pointer; font-size: 1.5rem; color: var(--nh-warning); user-select: none; }
.nh-stars-input [data-star] { transition: transform var(--nh-t-fast); }
.nh-stars-input [data-star]:hover { transform: scale(1.2); }

/* ==================== 17 Product detail + gallery ======================= */
.nh-detail__header { display: flex; gap: var(--nh-4); align-items: center; flex-wrap: wrap; padding-block: var(--nh-5); }
.nh-detail__logo {
  width: 84px; height: 84px; border-radius: var(--nh-radius-lg); flex: 0 0 auto;
  display: grid; place-items: center; overflow: hidden;
  background: var(--nh-grad); color: #fff; font-size: 2rem; font-weight: 800;
  box-shadow: var(--nh-shadow-sm);
}
.nh-detail__logo img { width: 100%; height: 100%; object-fit: cover; }
/* When the logo is the element itself (real thumbnail), sit it on white + contain
   so transparent/PNG logos render cleanly instead of on the gradient fallback. */
img.nh-detail__logo { background: #fff; object-fit: contain; padding: 6px; }
.nh-detail__logo.nh-detail__logo--compare { width: 48px; height: 48px; font-size: 1.2rem; }
.nh-detail__title { margin: 0; font-size: clamp(1.35rem, 3vw, var(--nh-fs-xl)); font-weight: 900; letter-spacing: -.02em; }
.nh-detail__tagline { color: var(--nh-muted); margin: .2rem 0 0; }
.nh-detail__meta { display: flex; align-items: center; gap: .6rem; flex-wrap: wrap; margin-block-start: .5rem; font-size: var(--nh-fs-sm); color: var(--nh-faint); }
.nh-detail__actions { margin-inline-start: auto; display: flex; align-items: center; gap: .6rem; flex-wrap: wrap; }
@media (max-width: 767.98px) { .nh-detail__actions { margin-inline-start: 0; width: 100%; } }

.nh-gallery {
  display: grid; grid-auto-flow: column; grid-auto-columns: min(420px, 82vw);
  gap: var(--nh-3); overflow-x: auto; padding-block-end: var(--nh-2);
  scroll-snap-type: x mandatory; -webkit-overflow-scrolling: touch;
}
.nh-gallery > * { scroll-snap-align: start; }
.nh-gallery img {
  width: 100%; aspect-ratio: 16 / 10; object-fit: cover;
  border-radius: var(--nh-radius-lg); border: 1px solid var(--nh-border);
  background: var(--nh-surface-3);
}

/* ================= 18 Profile / points / taxonomy ======================= */
.nh-profilehead { display: flex; gap: var(--nh-5); align-items: flex-start; flex-wrap: wrap; padding-block: var(--nh-6) var(--nh-4); }
.nh-profilehead__stats { display: flex; align-items: center; gap: var(--nh-4); flex-wrap: wrap; color: var(--nh-muted); font-size: var(--nh-fs-sm); }

.nh-pointsbox {
  border: 1px solid var(--nh-border); border-radius: var(--nh-radius-lg);
  background: linear-gradient(135deg, var(--nh-accent-soft), transparent 65%), var(--nh-surface);
  padding: var(--nh-3) var(--nh-4); display: inline-block; min-width: 200px;
}
.nh-pointsbox__main { font-weight: 800; font-size: var(--nh-fs-md); }
.nh-pointsbox__accent { color: var(--nh-accent-600); font-size: var(--nh-fs-sm); font-weight: 700; }

.nh-biobox {
  background: var(--nh-surface-2); border-radius: var(--nh-radius-lg);
  padding: var(--nh-4) var(--nh-5); font-size: var(--nh-fs-sm); color: var(--nh-ink-2);
}
.nh-biobox a { text-decoration: underline; font-weight: 700; color: var(--nh-ink); }
.nh-biobox a:hover { color: var(--nh-accent-600); }

.nh-taxgrid { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: var(--nh-3); }
.nh-taxgrid__card {
  display: block; background: var(--nh-surface); border: 1px solid var(--nh-border);
  border-radius: var(--nh-radius-lg); padding: var(--nh-4);
  transition: all var(--nh-t); min-width: 0;
}
.nh-taxgrid__card:hover { transform: translateY(-3px); box-shadow: var(--nh-shadow); border-color: var(--nh-border-strong); }
.nh-taxgrid__name { font-weight: 800; font-size: var(--nh-fs-sm); color: var(--nh-ink); }
.nh-taxgrid__desc { color: var(--nh-muted); font-size: var(--nh-fs-xs); margin-block-start: .2rem; }

/* --- Apps page: decorative CSS phone mockup (no image assets) --- */
.nh-phone {
  width: 230px; aspect-ratio: 9 / 18; margin-inline: auto; position: relative;
  border: 10px solid var(--nh-ink); border-radius: 38px;
  background: var(--nh-bg); box-shadow: var(--nh-shadow-lg);
  padding: 2rem .8rem 1rem; overflow: hidden; flex: 0 0 auto;
}
.nh-phone::before {
  content: ""; position: absolute; inset-block-start: 8px; inset-inline-start: 50%;
  translate: -50% 0; width: 74px; height: 16px; border-radius: 10px; background: var(--nh-ink);
}
html[dir="rtl"] .nh-phone::before { translate: 50% 0; }
.nh-phone__brand {
  width: 34px; height: 34px; border-radius: 11px; margin-block-end: .7rem;
  background: var(--nh-grad); color: #fff; font-weight: 900;
  display: grid; place-items: center; box-shadow: var(--nh-shadow-accent);
}
.nh-phone__row {
  display: grid; grid-template-columns: 30px 1fr 22px; gap: .45rem; align-items: center;
  background: var(--nh-surface); border: 1px solid var(--nh-border);
  border-radius: 10px; padding: .45rem; margin-block-end: .45rem;
}
.nh-phone__thumb { width: 30px; height: 30px; border-radius: 8px; background: var(--nh-grad); }
.nh-phone__row:nth-child(odd) .nh-phone__thumb { background: linear-gradient(135deg, #7c5cff, #4f8dff); }
.nh-phone__lines > span { display: block; height: 6px; border-radius: 99px; background: var(--nh-surface-3); }
.nh-phone__lines > span:first-child { width: 70%; margin-block-end: 4px; background: var(--nh-border-strong); }
.nh-phone__vote { height: 26px; border: 1px solid var(--nh-border); border-radius: 7px; }

/* =================== 19 Skeletons / states / toasts ===================== */
.nh-skeleton {
  position: relative; overflow: hidden; background: var(--nh-surface-3);
  border-radius: var(--nh-radius-sm);
}
.nh-skeleton::after {
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, .45), transparent);
  animation: nh-shimmer 1.4s infinite;
}
:root[data-theme="dark"] .nh-skeleton::after { background: linear-gradient(90deg, transparent, rgba(255, 255, 255, .06), transparent); }
@keyframes nh-shimmer { to { transform: translateX(-100%); } }
.nh-skeleton--title { height: 14px; width: 55%; margin-block-end: .4rem; }
.nh-skeleton--line { height: 10px; width: 85%; }
.nh-skeleton--avatar { width: 42px; height: 42px; border-radius: var(--nh-radius-pill); }
.nh-skeleton-card {
  display: grid; grid-template-columns: 56px 1fr auto; gap: var(--nh-4); align-items: center;
  background: var(--nh-surface); border: 1px solid var(--nh-border);
  border-radius: var(--nh-radius-lg); padding: .9rem 1rem;
}

.nh-state {
  text-align: center; padding: var(--nh-7) var(--nh-4);
  border: 1.5px dashed var(--nh-border-strong); border-radius: var(--nh-radius-lg);
  background: var(--nh-surface);
}
.nh-state__icon { font-size: 2.2rem; margin-block-end: var(--nh-2); }
.nh-state__title { font-weight: 800; margin-block-end: .3rem; }
.nh-state__text { color: var(--nh-muted); font-size: var(--nh-fs-sm); max-width: 46ch; margin-inline: auto; }
.nh-state--error { border-color: var(--nh-danger); background: var(--nh-danger-soft); }

.nh-toasts {
  position: fixed; z-index: var(--nh-z-toast);
  inset-block-start: calc(var(--nh-header-h) + .75rem); inset-inline-start: 1rem;
  display: flex; flex-direction: column; gap: .5rem; max-width: min(380px, calc(100vw - 2rem));
}
.nh-toast {
  display: flex; align-items: center; gap: .6rem;
  background: var(--nh-ink); color: var(--nh-bg);
  border-radius: var(--nh-radius); padding: .65rem 1rem;
  font-size: var(--nh-fs-sm); font-weight: 600; box-shadow: var(--nh-shadow-lg);
  animation: nh-toast-in .3s var(--nh-t-fast) both;
}
:root[data-theme="dark"] .nh-toast { background: var(--nh-surface-3); color: var(--nh-ink); border: 1px solid var(--nh-border-strong); }
@keyframes nh-toast-in { from { opacity: 0; transform: translateY(-8px); } to { opacity: 1; transform: none; } }
.nh-toast.is-leaving { animation: nh-toast-out .25s var(--nh-t-fast) both; }
@keyframes nh-toast-out { to { opacity: 0; transform: translateY(-8px); } }
.nh-toast__icon {
  width: 20px; height: 20px; border-radius: 50%; flex: 0 0 auto;
  display: inline-grid; place-items: center; font-size: .7rem; font-weight: 900;
  background: rgba(255, 255, 255, .18);
}
.nh-toast--success .nh-toast__icon { background: var(--nh-success); color: #fff; }
.nh-toast--error .nh-toast__icon { background: var(--nh-danger); color: #fff; }
.nh-toast--info .nh-toast__icon { background: var(--nh-info); color: #fff; }
.nh-toast__close {
  border: 0; background: none; color: inherit; opacity: .7; cursor: pointer;
  font-size: 1.05rem; line-height: 1; margin-inline-start: auto; padding: 0 .1rem;
}
.nh-toast__close:hover { opacity: 1; }
@media (max-width: 575.98px) { .nh-toasts { inset-inline: 1rem; max-width: none; } }

/* ============================ 20 Admin shell ============================ */
.nh-admin { display: grid; grid-template-columns: 264px minmax(0, 1fr); min-height: 100vh; }
.nh-admin__side {
  background: var(--nh-surface); border-inline-end: 1px solid var(--nh-border);
  padding: var(--nh-4); position: sticky; inset-block-start: 0; height: 100vh; overflow-y: auto;
}
.nh-admin__main { min-width: 0; display: flex; flex-direction: column; }
.nh-admin__bar {
  position: sticky; inset-block-start: 0; z-index: 20;
  display: flex; align-items: center; justify-content: space-between; gap: var(--nh-3);
  padding: var(--nh-3) var(--nh-5);
  background: var(--nh-glass);
  backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px);
  border-block-end: 1px solid var(--nh-border);
}
.nh-admin__content { padding: var(--nh-5); }
.nh-admin__burger { display: none; }
@media (max-width: 767.98px) {
  .nh-admin { grid-template-columns: 1fr; }
  /* The static sidebar is replaced by the slide-in drawer (#nhAdminDrawer) on mobile. */
  .nh-admin__side { display: none; }
  .nh-admin__burger { display: inline-flex; }
}

/* ============================== 21 Footer =============================== */
/* Modern compact footer: brand + newsletter row, navigation and Android download columns,
   eNamad trust card, slim bottom bar. Mobile-first: short and airy on phones. */
.nh-footer { margin-block-start: var(--nh-7); background: #101828; color: #98a2b3; position: relative; z-index: 1; }
:root[data-theme="dark"] .nh-footer { background: #0d1119; border-block-start: 1px solid var(--nh-border); }
.nh-footer::before { content: ""; position: absolute; inset-block-start: 0; inset-inline: 0; height: 3px; background: var(--nh-grad); }
.nh-footer__inner {
  max-width: var(--nh-container); margin-inline: auto;
  padding: var(--nh-6) clamp(1rem, 3vw, 2rem) var(--nh-5);
  display: grid; gap: var(--nh-6);
}

/* Row 1 — brand + newsletter */
.nh-footer__top { display: grid; gap: var(--nh-5); align-items: center; }
@media (min-width: 768px) { .nh-footer__top { grid-template-columns: 1fr minmax(300px, 420px); } }
.nh-footer .nh-brand, .nh-footer .nh-brand:hover { color: #fff; }
.nh-footer__brand p { margin: .4rem 0 0; font-size: var(--nh-fs-sm); color: #98a2b3; max-width: 40ch; }
.nh-footer__social { display: flex; gap: .4rem; margin-block-start: .8rem; }
.nh-footer .nh-iconbtn { background: rgba(255, 255, 255, .06); border-color: rgba(255, 255, 255, .12); color: #cdd5e0; }
.nh-footer .nh-iconbtn:hover { color: #fff; border-color: rgba(255, 255, 255, .3); }

.nh-footer__news {
  background: rgba(255, 255, 255, .04);
  border: 1px solid rgba(255, 255, 255, .09);
  border-radius: var(--nh-radius-lg);
  padding: var(--nh-4);
  display: grid; gap: .65rem;
}
.nh-footer__news strong { display: block; color: #fff; font-size: var(--nh-fs-sm); }
.nh-footer__news span { font-size: var(--nh-fs-xs); color: #98a2b3; }
.nh-footer__newsrow { display: flex; gap: .5rem; }
.nh-footer__newsrow input {
  flex: 1; min-width: 0;
  background: rgba(255, 255, 255, .06);
  border: 1px solid rgba(255, 255, 255, .14);
  color: #fff; font: inherit; font-size: var(--nh-fs-sm);
  border-radius: var(--nh-radius); padding: .45rem .75rem;
  transition: border-color var(--nh-t-fast);
}
.nh-footer__newsrow input::placeholder { color: #667085; }
.nh-footer__newsrow input:focus { outline: none; border-color: var(--nh-accent); }

/* Row 2 — link columns + trust card */
.nh-footer__mid { display: grid; gap: var(--nh-6); align-items: start; }
@media (min-width: 992px) { .nh-footer__mid { grid-template-columns: 1fr minmax(280px, 330px); } }
.nh-footer__cols { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: var(--nh-4); }
@media (max-width: 767.98px) { .nh-footer__cols { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.nh-footer h6 { color: #fff; font-size: var(--nh-fs-sm); margin-block-end: var(--nh-2); }
.nh-footer__links { list-style: none; padding: 0; margin: 0; }
.nh-footer__links a { display: inline-block; font-size: var(--nh-fs-sm); padding-block: .3rem; color: #98a2b3; transition: color var(--nh-t-fast); }
.nh-footer__links a:hover { color: #fff; }
.nh-footer__app-links { display: grid; gap: .4rem; }
.nh-footer__app-links a {
  width: 100%; display: flex; align-items: center; gap: .5rem;
  padding: .48rem .55rem; border: 1px solid rgba(255, 255, 255, .1);
  border-radius: var(--nh-radius); background: rgba(255, 255, 255, .04);
  line-height: 1.2; transition: color var(--nh-t-fast), border-color var(--nh-t-fast), background var(--nh-t-fast), transform var(--nh-t-fast);
}
.nh-footer__app-links a:hover { border-color: rgba(255, 255, 255, .28); background: rgba(255, 255, 255, .08); transform: translateY(-1px); }
.nh-footer__app-links small { color: #667085; font-size: .65rem; direction: ltr; unicode-bidi: isolate; }
.nh-footer__app-icon {
  width: 1.65rem; height: 1.65rem; flex: none; display: inline-grid; place-items: center;
  border-radius: .5rem; background: rgba(255, 255, 255, .96); overflow: hidden;
  box-shadow: 0 1px 4px rgba(0, 0, 0, .22);
}
.nh-footer__app-icon img { width: 100%; height: 100%; display: block; object-fit: contain; }
.nh-footer__app-links li:first-child .nh-footer__app-icon img { object-fit: cover; }

/* eNamad trust card — white seal tile on a glass card so the badge reads crisply on dark. */
.nh-footer__trustcard {
  display: flex; align-items: center; gap: var(--nh-3);
  background: rgba(255, 255, 255, .04);
  border: 1px solid rgba(255, 255, 255, .09);
  border-radius: var(--nh-radius-lg);
  padding: var(--nh-3) var(--nh-4);
  color: inherit; text-decoration: none;
  transition: border-color var(--nh-t-fast), transform var(--nh-t-fast), box-shadow var(--nh-t-fast);
}
.nh-footer__trustcard:hover { border-color: rgba(255, 255, 255, .28); transform: translateY(-2px); box-shadow: var(--nh-shadow); color: inherit; }
.nh-footer__seal { flex: none; display: inline-flex; background: #fff; border-radius: var(--nh-radius); padding: .45rem; }
.nh-footer__seal img { display: block; height: 56px; width: auto; }
.nh-footer__trusttext { min-width: 0; display: grid; gap: .15rem; }
.nh-footer__trusttext strong { color: #fff; font-size: var(--nh-fs-sm); }
.nh-footer__trusttext span { font-size: var(--nh-fs-xs); color: #98a2b3; }

/* Bottom bar */
.nh-footer__bottom {
  max-width: var(--nh-container); margin-inline: auto;
  padding: var(--nh-4) clamp(1rem, 3vw, 2rem);
  border-block-start: 1px solid rgba(255, 255, 255, .08);
  font-size: var(--nh-fs-xs);
  display: flex; flex-wrap: wrap; gap: .5rem 1.25rem;
  align-items: center; justify-content: space-between;
}
.nh-footer__mini { display: flex; gap: 1.25rem; }
.nh-footer__mini a { color: #98a2b3; transition: color var(--nh-t-fast); }
.nh-footer__mini a:hover { color: #fff; }

/* ====================== 22 Grid compat (row/col) ======================== */
.row { display: grid; grid-template-columns: repeat(12, 1fr); gap: var(--nh-4); }
.g-3 { gap: var(--nh-4); }
.row > * { grid-column: span 12; min-width: 0; }
.col-6 { grid-column: span 6; }
@media (min-width: 576px) {
  .col-sm-4 { grid-column: span 4; }
  .col-sm-8 { grid-column: span 8; }
}
@media (min-width: 768px) {
  .col-md-3 { grid-column: span 3; }
  .col-md-4 { grid-column: span 4; }
  .col-md-6 { grid-column: span 6; }
  .col-md-8 { grid-column: span 8; }
  .col-md-9 { grid-column: span 9; }
}
@media (min-width: 992px) { .col-lg-3 { grid-column: span 3; } }

/* ---- File manager (admin) ---- */
.nh-fm-tree { display: flex; flex-direction: column; gap: 1px; max-height: 70vh; overflow-y: auto; }
.nh-fm-tree__item { display: flex; align-items: center; gap: .4rem; padding: .35rem .5rem; border-radius: var(--nh-radius); color: var(--nh-ink); text-decoration: none; font-size: var(--nh-fs-sm); }
.nh-fm-tree__item:hover { background: var(--nh-surface-2); }
.nh-fm-tree__item.is-active { background: var(--nh-accent-soft); color: var(--nh-accent); font-weight: 700; }
.nh-fm-tree__count { margin-inline-start: auto; font-size: var(--nh-fs-xs); color: var(--nh-muted); }
.nh-fm-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: var(--nh-3); }
.nh-fm-card { display: flex; flex-direction: column; border: 1px solid var(--nh-border); border-radius: var(--nh-radius-lg); overflow: hidden; background: var(--nh-surface); }
.nh-fm-card__thumb { position: relative; aspect-ratio: 1 / 1; background: var(--nh-surface-2); display: flex; align-items: center; justify-content: center; overflow: hidden; }
.nh-fm-card__thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }
.nh-fm-card__thumb a { display: block; width: 100%; height: 100%; }
.nh-fm-card__icon { font-size: 2.4rem; color: var(--nh-muted); }
.nh-fm-card__ext { position: absolute; inset-block-start: .4rem; inset-inline-start: .4rem; font-size: var(--nh-fs-xs); background: rgba(0,0,0,.6); color: #fff; padding: .1rem .4rem; border-radius: var(--nh-radius); }
.nh-fm-card__body { padding: .5rem .55rem; display: flex; flex-direction: column; gap: .25rem; }
.nh-fm-card__name { font-size: var(--nh-fs-sm); word-break: break-all; direction: ltr; text-align: start; }
.nh-fm-card__meta { font-size: var(--nh-fs-xs); color: var(--nh-muted); display: flex; justify-content: space-between; gap: .5rem; }

/* ---- File manager 2.0 (admin, card-grid layout) ---- */
.nhfm { display: grid; grid-template-columns: 1fr; gap: var(--nh-4); align-items: start; }
@media (min-width: 992px) { .nhfm { grid-template-columns: 300px minmax(0, 1fr); } }
.nhfm__side { display: flex; flex-direction: column; gap: var(--nh-4); }
.nhfm-panel { background: var(--nh-surface); border: 1px solid var(--nh-border); border-radius: var(--nh-radius-lg); padding: var(--nh-4); }
.nhfm-panel h2 { font-size: var(--nh-fs-base); margin: 0 0 var(--nh-3); }

.nhfm-types { list-style: none; margin: 0; padding: 0; }
.nhfm-type { display: flex; align-items: center; gap: .7rem; padding: .7rem .15rem; border-block-end: 1px solid var(--nh-border); }
.nhfm-type:last-child { border-block-end: 0; }
.nhfm-type__ic { width: 34px; height: 34px; border-radius: 9px; display: flex; align-items: center; justify-content: center; flex: 0 0 auto; }
.nhfm-type__name { font-size: var(--nh-fs-sm); font-weight: 600; }
.nhfm-type__name span { color: var(--nh-muted); font-weight: 400; }
.nhfm-type__size { margin-inline-start: auto; color: var(--nh-muted); font-size: var(--nh-fs-sm); white-space: nowrap; }

.nhfm-storage__title { display: flex; align-items: center; gap: .5rem; font-weight: 700; margin-bottom: var(--nh-3); }
.nhfm-meter { height: 8px; border-radius: 99px; background: var(--nh-surface-2); overflow: hidden; }
.nhfm-meter__bar { height: 100%; border-radius: 99px; background: linear-gradient(90deg, var(--nh-accent-500, #ff8a7a), var(--nh-accent, #ff6154)); }
.nhfm-storage__label { margin-top: .55rem; font-size: var(--nh-fs-sm); color: var(--nh-muted); }

.nhfm__head h1 { font-size: var(--nh-fs-xl); margin: 0; }
.nhfm__head p { color: var(--nh-muted); margin: .15rem 0 0; font-size: var(--nh-fs-sm); }
.nhfm-toolbar { display: flex; flex-wrap: wrap; gap: .5rem; margin: var(--nh-4) 0; }
.nhfm-tbtn { display: inline-flex; align-items: center; gap: .4rem; padding: .5rem .9rem; border-radius: var(--nh-radius); border: 1px solid var(--nh-border); background: var(--nh-surface); color: var(--nh-ink); font-size: var(--nh-fs-sm); font-weight: 600; cursor: pointer; }
.nhfm-tbtn:hover { background: var(--nh-surface-2); }
.nhfm-tbtn[disabled] { opacity: .45; cursor: not-allowed; }
.nhfm-tbtn--danger:not([disabled]):hover { border-color: var(--nh-danger); color: var(--nh-danger); }

.nhfm-path { display: flex; align-items: center; gap: .3rem; background: var(--nh-surface); border: 1px solid var(--nh-border); border-radius: var(--nh-radius); padding: .4rem .5rem; margin-bottom: var(--nh-4); }
.nhfm-path__nav { display: inline-flex; align-items: center; justify-content: center; width: 30px; height: 30px; border-radius: 8px; color: var(--nh-muted); text-decoration: none; border: 0; background: transparent; cursor: pointer; }
.nhfm-path__nav:hover { background: var(--nh-surface-2); color: var(--nh-ink); }
.nhfm-path__nav[aria-disabled="true"] { opacity: .4; pointer-events: none; }
.nhfm-crumbs { display: flex; align-items: center; gap: .2rem; flex: 1; min-width: 0; overflow-x: auto; padding-inline: .3rem; }
.nhfm-crumbs a, .nhfm-crumbs span { font-size: var(--nh-fs-sm); color: var(--nh-muted); text-decoration: none; white-space: nowrap; }
.nhfm-crumbs a:hover { color: var(--nh-accent); }
.nhfm-crumbs .is-current { color: var(--nh-ink); font-weight: 700; }
.nhfm-crumbs .sep { color: var(--nh-border); }

.nhfm-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(148px, 1fr)); gap: var(--nh-3); }
.nhfm-item { position: relative; background: var(--nh-surface); border: 1px solid var(--nh-border); border-radius: var(--nh-radius-lg); padding: var(--nh-4) var(--nh-3); display: flex; flex-direction: column; align-items: center; gap: .55rem; text-align: center; cursor: pointer; transition: border-color var(--nh-t-fast), box-shadow var(--nh-t-fast); }
.nhfm-item:hover { border-color: var(--nh-accent); box-shadow: var(--nh-shadow); }
.nhfm-item.is-selected { border-color: var(--nh-accent); box-shadow: 0 0 0 2px var(--nh-accent-soft); }
.nhfm-ic { width: 60px; height: 60px; border-radius: 12px; display: flex; align-items: center; justify-content: center; flex: 0 0 auto; overflow: hidden; }
.nhfm-ic img { width: 100%; height: 100%; object-fit: cover; }
.nhfm-ic__badge { font-size: 11px; font-weight: 800; letter-spacing: .3px; text-transform: uppercase; }
.nhfm-item__name { font-size: var(--nh-fs-sm); font-weight: 600; word-break: break-word; direction: ltr; line-height: 1.35; }
.nhfm-item__meta { font-size: var(--nh-fs-xs); color: var(--nh-muted); }
.nhfm-empty { text-align: center; color: var(--nh-muted); padding: var(--nh-7) var(--nh-4); }

/* colored type icons */
.tc-folder { background: #fef0e6; color: #f79009; }
.tc-image { background: #eafaf0; color: #12b76a; }
.tc-document { background: #eef4ff; color: #2e90fa; }
.tc-code { background: #eef0ff; color: #6172f3; }
.tc-pdf { background: #fef3f2; color: #f04438; }
.tc-archive { background: #f4f3ff; color: #7a5af8; }
.tc-audio { background: #fdf2fa; color: #ee46bc; }
.tc-video { background: #ecfdff; color: #06aed4; }
.tc-other { background: var(--nh-surface-2); color: var(--nh-muted); }
:root[data-theme="dark"] .tc-folder { background: rgba(247, 144, 9, .16); }
:root[data-theme="dark"] .tc-image { background: rgba(18, 183, 106, .16); }
:root[data-theme="dark"] .tc-document { background: rgba(46, 144, 250, .16); }
:root[data-theme="dark"] .tc-code { background: rgba(97, 114, 243, .16); }
:root[data-theme="dark"] .tc-pdf { background: rgba(240, 68, 56, .16); }
:root[data-theme="dark"] .tc-archive { background: rgba(122, 90, 248, .16); }
:root[data-theme="dark"] .tc-audio { background: rgba(238, 70, 188, .16); }
:root[data-theme="dark"] .tc-video { background: rgba(6, 174, 212, .16); }

/* ====================== 23 Responsive & motion ========================== */
@media (max-width: 767.98px) {
  :root { --nh-header-h: 60px; }
  .nh-product { grid-template-columns: 48px minmax(0, 1fr) auto; gap: var(--nh-3); padding: .75rem .8rem; }
  .nh-product__thumb { width: 48px; height: 48px; font-size: 1.15rem; }
  .nh-product__title { font-size: var(--nh-fs-base); }
  .nh-product__tagline { white-space: normal; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; }
  .nh-vote { min-width: 48px; padding: .4rem .3rem; }
  .nh-search { flex: 1 1 auto; }
  .nh-detail__logo { width: 64px; height: 64px; font-size: 1.5rem; }
  .nh-hero { padding: var(--nh-5) var(--nh-4); }
  .nh-pagehead { padding-block-start: var(--nh-5); }
  .nh-profilehead { gap: var(--nh-4); }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: .01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: .01ms !important;
  }
  html { scroll-behavior: auto; }
}

/* -------------------------- Rich text (prose) ---------------------------- */
/* Rendered from the safe Markdown subset (product descriptions, RTL). */
.nh-prose { line-height: 2; color: var(--nh-ink-1, inherit); word-break: break-word; }
.nh-prose > :first-child { margin-block-start: 0; }
.nh-prose > :last-child { margin-block-end: 0; }
.nh-prose p { margin: 0 0 var(--nh-3); }
.nh-prose h3 { font-size: var(--nh-fs-lg); font-weight: 800; margin: var(--nh-4) 0 var(--nh-2); }
.nh-prose h4 { font-size: var(--nh-fs-md); font-weight: 800; margin: var(--nh-4) 0 var(--nh-2); }
.nh-prose h5 { font-size: var(--nh-fs-sm); font-weight: 700; margin: var(--nh-3) 0 var(--nh-2); }
.nh-prose ul, .nh-prose ol { margin: 0 0 var(--nh-3); padding-inline-start: 1.6em; }
.nh-prose li { margin: .25em 0; }
.nh-prose blockquote {
  margin: 0 0 var(--nh-3); padding: .4em 1em;
  border-inline-start: 3px solid var(--nh-accent-500, #ff6154);
  background: var(--nh-surface-2, rgba(0,0,0,.03)); border-radius: 6px;
}
.nh-prose code {
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: .9em;
  background: var(--nh-surface-2, rgba(0,0,0,.06)); padding: .1em .35em; border-radius: 5px; direction: ltr;
}
.nh-prose a { color: var(--nh-accent-600, #d94a3d); text-decoration: underline; }

/* Markdown editor toolbar (submit wizard) */
.nh-mdbar { display: flex; flex-wrap: wrap; gap: .25rem; margin-bottom: .4rem; }
.nh-mdbar button {
  font-size: var(--nh-fs-sm); font-weight: 700; line-height: 1; padding: .35rem .6rem;
  border: 1px solid var(--nh-border, #ddd); border-radius: 8px; background: var(--nh-surface-1, #fff);
  color: inherit; cursor: pointer;
}
.nh-mdbar button:hover { background: var(--nh-surface-2, #f4f4f5); }
.nh-md-preview { border: 1px dashed var(--nh-border, #ddd); border-radius: 10px; padding: var(--nh-3); min-height: 3rem; }

/* Public collections directory (/collections/explore) */
.nh-collgrid { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: var(--nh-3); }
.nh-collcard {
  display: flex; flex-direction: column; gap: var(--nh-3);
  padding: var(--nh-4); background: var(--nh-surface); border: 1px solid var(--nh-border);
  border-radius: var(--nh-radius-lg); text-decoration: none; color: inherit;
  transition: transform .15s ease, box-shadow .15s ease, border-color .15s ease;
}
.nh-collcard:hover { transform: translateY(-3px); box-shadow: var(--nh-shadow); border-color: var(--nh-border-strong); }
.nh-collcard__logos { display: flex; align-items: center; gap: var(--nh-2); }
.nh-collcard__logo, .nh-collcard__more {
  width: 44px; height: 44px; border-radius: var(--nh-radius-sm); overflow: hidden;
  background: var(--nh-surface-3); border: 1px solid var(--nh-border);
  display: inline-flex; align-items: center; justify-content: center; flex: 0 0 auto;
}
.nh-collcard__logo img { width: 100%; height: 100%; object-fit: cover; }
.nh-collcard__logo-ph { font-weight: 800; color: var(--nh-muted); }
.nh-collcard__more { font-weight: 700; font-size: var(--nh-fs-xs); color: var(--nh-muted); background: var(--nh-surface-2); }
.nh-collcard__title { font-weight: 800; font-size: var(--nh-fs-md); color: var(--nh-ink); }
.nh-collcard__meta { display: flex; gap: .35rem; flex-wrap: wrap; color: var(--nh-muted); font-size: var(--nh-fs-xs); margin-block-start: .25rem; }
