/* ==========================================================================
   RandomNickname - Random Nickname Maker
   Professional, human-friendly design system.
   ========================================================================== */

:root {
  /* Brand */
  --brand: #0f9d6a;
  --brand-dark: #0a7d54;
  --brand-light: #e8f8f1;
  --brand-ring: rgba(15, 157, 106, .18);

  /* Accents */
  --accent-2: #f59e0b;
  --accent-3: #7c3aed;
  --accent-4: #0ea5e9;
  --accent-5: #ef4444;

  /* Neutrals */
  --ink: #12211c;
  --ink-soft: #3f534b;
  --muted: #6b7f77;
  --line: #e2ece7;
  --line-strong: #cbdcd4;
  --surface: #ffffff;
  --surface-alt: #f7fbf9;
  --bg: #f4f9f6;

  /* Shape */
  --r-sm: 10px;
  --r-md: 14px;
  --r-lg: 20px;
  --r-xl: 28px;
  --r-pill: 999px;

  /* Shadow */
  --sh-xs: 0 1px 2px rgba(16, 40, 32, .05);
  --sh-sm: 0 2px 8px rgba(16, 40, 32, .06);
  --sh-md: 0 10px 30px rgba(16, 40, 32, .08);
  --sh-lg: 0 24px 60px rgba(16, 40, 32, .12);

  --ease: .18s cubic-bezier(.2, .8, .3, 1);
  --wrap: 1180px;

  --font-display: "Plus Jakarta Sans", "Segoe UI", system-ui, sans-serif;
  --font-body: "DM Sans", "Segoe UI", system-ui, sans-serif;
}

/* ------------------------------ Reset ---------------------------------- */
*, *::before, *::after { box-sizing: border-box; }

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
  scroll-padding-top: 96px;
}

body {
  margin: 0;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 16.5px;
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

main { flex: 1 0 auto; }

img, svg { max-width: 100%; display: block; }
a { color: var(--brand-dark); text-decoration: none; }
a:hover { color: var(--brand); }
button { font: inherit; color: inherit; }
h1, h2, h3, h4 {
  font-family: var(--font-display);
  color: var(--ink);
  line-height: 1.22;
  letter-spacing: -.02em;
  margin: 0 0 .6em;
  font-weight: 800;
}
h1 { font-size: clamp(2rem, 1.35rem + 2.6vw, 3.25rem); }
h2 { font-size: clamp(1.45rem, 1.15rem + 1.1vw, 2rem); }
h3 { font-size: clamp(1.1rem, 1rem + .4vw, 1.28rem); }
p { margin: 0 0 1.1em; }
ul, ol { margin: 0 0 1.2em; padding-left: 1.3em; }
li { margin-bottom: .45em; }
strong { color: var(--ink); font-weight: 700; }
code { background: var(--surface-alt); padding: .1em .35em; border-radius: 6px; font-size: .92em; }

:focus-visible {
  outline: 3px solid var(--brand-ring);
  outline-offset: 2px;
  border-radius: 6px;
}

::selection { background: var(--brand-light); color: var(--ink); }

.sr-only {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}

.skip-link {
  position: fixed; left: 12px; top: -60px; z-index: 999;
  background: var(--brand); color: #fff; padding: 10px 18px;
  border-radius: var(--r-pill); font-weight: 700;
  transition: top var(--ease);
}
.skip-link:focus { top: 12px; color: #fff; }

.wrap {
  width: 100%;
  max-width: var(--wrap);
  margin-inline: auto;
  padding-inline: 20px;
}

.icon { width: 20px; height: 20px; flex: 0 0 auto; }
.icon-sm { width: 17px; height: 17px; flex: 0 0 auto; }
.icon-md { width: 24px; height: 24px; flex: 0 0 auto; }

/* ------------------------------ Buttons -------------------------------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 11px 18px;
  border-radius: var(--r-pill);
  border: 1.5px solid transparent;
  font-family: var(--font-display);
  font-size: .92rem;
  font-weight: 700;
  line-height: 1.2;
  cursor: pointer;
  white-space: nowrap;
  transition: transform var(--ease), background-color var(--ease),
              border-color var(--ease), box-shadow var(--ease), color var(--ease);
}

.btn-primary {
  background: linear-gradient(135deg, var(--brand), #10b981);
  color: #fff;
  box-shadow: 0 8px 20px rgba(15, 157, 106, .28);
}
.btn-primary:hover {
  color: #fff;
  transform: translateY(-2px);
  box-shadow: 0 12px 26px rgba(15, 157, 106, .34);
}
.btn-primary:active { transform: translateY(0); }

.btn-ghost {
  background: var(--surface);
  border-color: var(--line);
  color: var(--ink-soft);
  box-shadow: var(--sh-xs);
}
.btn-ghost:hover {
  border-color: var(--brand);
  color: var(--brand-dark);
  background: var(--brand-light);
}

.btn-lg { padding: 15px 26px; font-size: 1rem; }

/* ------------------------------ Header --------------------------------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(255, 255, 255, .86);
  border-bottom: 1px solid var(--line);
  backdrop-filter: saturate(180%) blur(14px);
}

.header-inner {
  display: flex;
  align-items: center;
  gap: 20px;
  min-height: 74px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 11px;
  color: var(--ink);
  flex: 0 0 auto;
}
.brand:hover { color: var(--ink); }

.brand-mark {
  width: 42px; height: 42px;
  display: grid; place-items: center;
  border-radius: 13px;
  background: linear-gradient(135deg, var(--brand), #22c55e);
  color: #fff;
  box-shadow: 0 6px 16px rgba(15, 157, 106, .3);
}
.brand-icon { width: 23px; height: 23px; }

.brand-text { display: flex; flex-direction: column; line-height: 1.1; }
.brand-text strong {
  font-family: var(--font-display);
  font-size: 1.16rem;
  font-weight: 800;
  letter-spacing: -.02em;
}
.brand-text strong span { color: var(--brand); }
.brand-text em {
  font-style: normal;
  font-size: .7rem;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--muted);
  font-weight: 600;
}

.header-search {
  position: relative;
  flex: 1 1 auto;
  max-width: 340px;
  display: flex;
  align-items: center;
}
.header-search .search-icon {
  position: absolute;
  left: 14px;
  width: 17px; height: 17px;
  color: var(--muted);
  pointer-events: none;
}
.header-search input {
  width: 100%;
  padding: 10px 14px 10px 40px;
  border-radius: var(--r-pill);
  border: 1.5px solid var(--line);
  background: var(--surface-alt);
  font-size: .88rem;
  color: var(--ink);
  transition: border-color var(--ease), background-color var(--ease), box-shadow var(--ease);
}
.header-search input:focus {
  outline: none;
  border-color: var(--brand);
  background: #fff;
  box-shadow: 0 0 0 4px var(--brand-ring);
}

.main-nav {
  display: flex;
  align-items: center;
  gap: 4px;
  margin-left: auto;
}
.main-nav a {
  padding: 8px 13px;
  border-radius: var(--r-pill);
  font-size: .88rem;
  font-weight: 600;
  color: var(--ink-soft);
  transition: background-color var(--ease), color var(--ease);
}
.main-nav a:hover { background: var(--surface-alt); color: var(--ink); }
.main-nav a.active {
  background: var(--brand-light);
  color: var(--brand-dark);
}

.nav-toggle {
  display: none;
  width: 44px; height: 44px;
  align-items: center;
  justify-content: center;
  border: 1.5px solid var(--line);
  border-radius: 12px;
  background: var(--surface);
  cursor: pointer;
  color: var(--ink);
}
.nav-toggle .icon-close { display: none; }
.nav-toggle[aria-expanded="true"] .icon-open { display: none; }
.nav-toggle[aria-expanded="true"] .icon-close { display: block; }

/* ------------------------------ Hero ----------------------------------- */
.hero {
  position: relative;
  overflow: hidden;
  padding: clamp(46px, 7vw, 86px) 0 clamp(40px, 6vw, 72px);
  background:
    radial-gradient(900px 420px at 12% -10%, rgba(16, 185, 129, .17), transparent 60%),
    radial-gradient(760px 380px at 92% 0%, rgba(14, 165, 233, .14), transparent 62%),
    linear-gradient(180deg, #ffffff 0%, var(--bg) 100%);
  border-bottom: 1px solid var(--line);
}

.hero::after {
  content: "";
  position: absolute;
  inset: auto 0 0 0;
  height: 120px;
  background: linear-gradient(180deg, transparent, rgba(244, 249, 246, .9));
  pointer-events: none;
}

.hero-inner { position: relative; max-width: 860px; text-align: center; margin-inline: auto; }

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 7px 14px;
  border-radius: var(--r-pill);
  background: var(--brand-light);
  color: var(--brand-dark);
  border: 1px solid rgba(15, 157, 106, .18);
  font-size: .78rem;
  font-weight: 700;
  letter-spacing: .04em;
  text-transform: uppercase;
  margin-bottom: 18px;
}

.hero h1 { margin-bottom: 16px; }

.hero-lead {
  font-size: clamp(1.02rem, .95rem + .35vw, 1.18rem);
  color: var(--ink-soft);
  max-width: 680px;
  margin: 0 auto 28px;
}

.hero-search {
  position: relative;
  display: flex;
  align-items: center;
  gap: 8px;
  max-width: 620px;
  margin: 0 auto 22px;
  padding: 7px;
  background: var(--surface);
  border: 1.5px solid var(--line);
  border-radius: var(--r-pill);
  box-shadow: var(--sh-md);
}
.hero-search .search-icon {
  position: absolute;
  left: 22px;
  width: 19px; height: 19px;
  color: var(--muted);
  pointer-events: none;
}
.hero-search input {
  flex: 1 1 auto;
  min-width: 0;
  padding: 12px 12px 12px 44px;
  border: 0;
  background: transparent;
  font-size: .96rem;
  color: var(--ink);
}
.hero-search input:focus { outline: none; }

.hero-cta {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  justify-content: center;
  margin-bottom: 30px;
}

.hero-stats {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 10px 34px;
  padding: 0;
  margin: 0;
  font-size: .88rem;
  color: var(--muted);
}
.hero-stats strong {
  display: block;
  font-family: var(--font-display);
  font-size: 1.35rem;
  color: var(--brand-dark);
  line-height: 1.2;
}

/* ------------------------------ Sections -------------------------------- */
.section { padding: clamp(40px, 5.5vw, 66px) 0; }
.section-alt {
  background: var(--surface);
  border-block: 1px solid var(--line);
}

.section-head { max-width: 720px; margin-bottom: 28px; }
.section-head h2 { margin-bottom: 8px; }
.section-head p { color: var(--muted); margin: 0; }
.section-head-row { display: flex; align-items: end; justify-content: space-between; gap: 20px; max-width: none; }

.category-block + .category-block { margin-top: 46px; }
.category-block .section-head h2 { font-size: clamp(1.3rem, 1.1rem + .7vw, 1.6rem); margin-bottom: 2px; }
.category-block .section-head p { font-size: .85rem; }
.category-block .section-head { margin-bottom: 16px; }

.page-head {
  padding: clamp(30px, 4.5vw, 54px) 0 clamp(24px, 3.5vw, 36px);
  background: linear-gradient(180deg, #fff, var(--bg));
  border-bottom: 1px solid var(--line);
}
.page-head h1 { margin-bottom: 10px; }
.page-head .lead { color: var(--ink-soft); max-width: 720px; margin: 0; }

.breadcrumb { margin-bottom: 14px; }
.breadcrumb ol {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  padding: 0;
  margin: 0;
  font-size: .8rem;
  color: var(--muted);
}
.breadcrumb li { margin: 0; display: flex; align-items: center; gap: 8px; }
.breadcrumb li + li::before { content: "/"; color: var(--line-strong); }
.breadcrumb a { color: var(--muted); font-weight: 600; }
.breadcrumb a:hover { color: var(--brand-dark); }

.page-search {
  position: relative;
  display: flex;
  gap: 8px;
  align-items: center;
  max-width: 560px;
  margin-top: 22px;
}
.page-search .search-icon {
  position: absolute; left: 15px; width: 18px; height: 18px;
  color: var(--muted); pointer-events: none;
}
.page-search input {
  flex: 1 1 auto;
  min-width: 0;
  padding: 12px 16px 12px 44px;
  border-radius: var(--r-pill);
  border: 1.5px solid var(--line);
  background: var(--surface);
  font-size: .92rem;
}
.page-search input:focus {
  outline: none;
  border-color: var(--brand);
  box-shadow: 0 0 0 4px var(--brand-ring);
}

/* ------------------------------ Cards ---------------------------------- */
.card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 14px;
}
.card-grid-narrow { margin-top: 28px; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); }

.generator-card {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 16px 16px;
  background: var(--surface);
  border: 1.5px solid var(--line);
  border-radius: var(--r-lg);
  color: var(--ink);
  box-shadow: var(--sh-xs);
  transition: transform var(--ease), box-shadow var(--ease), border-color var(--ease);
}
.generator-card:hover {
  transform: translateY(-3px);
  border-color: rgba(15, 157, 106, .4);
  box-shadow: var(--sh-md);
  color: var(--ink);
}

.card-icon {
  width: 46px; height: 46px;
  flex: 0 0 auto;
  display: grid; place-items: center;
  border-radius: 13px;
  background: var(--brand-light);
  color: var(--brand-dark);
  transition: background-color var(--ease), color var(--ease);
}
.generator-card:hover .card-icon { background: var(--brand); color: #fff; }

.card-grid .generator-card:nth-child(4n+2) .card-icon {
  background: #eff6ff; color: #2563eb;
}
.card-grid .generator-card:nth-child(4n+3) .card-icon {
  background: #f5f3ff; color: #7c3aed;
}
.card-grid .generator-card:nth-child(4n+4) .card-icon {
  background: #fffbeb; color: #b45309;
}
.card-grid .generator-card:nth-child(4n+2):hover .card-icon,
.card-grid .generator-card:nth-child(4n+3):hover .card-icon,
.card-grid .generator-card:nth-child(4n+4):hover .card-icon {
  background: var(--brand); color: #fff;
}

.card-body { display: flex; flex-direction: column; min-width: 0; flex: 1 1 auto; }
.card-body strong {
  font-family: var(--font-display);
  font-size: .97rem;
  font-weight: 700;
  line-height: 1.3;
}
.card-body span { font-size: .78rem; color: var(--muted); }

.card-arrow {
  width: 18px; height: 18px;
  color: var(--line-strong);
  transition: transform var(--ease), color var(--ease);
  flex: 0 0 auto;
}
.generator-card:hover .card-arrow { transform: translateX(3px); color: var(--brand); }

/* Steps */
.steps-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 16px;
}
.step-card {
  position: relative;
  padding: 26px 22px 22px;
  background: var(--surface-alt);
  border: 1.5px solid var(--line);
  border-radius: var(--r-lg);
}
.step-number {
  display: grid; place-items: center;
  width: 40px; height: 40px;
  border-radius: 12px;
  background: linear-gradient(135deg, var(--brand), #22c55e);
  color: #fff;
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 1.05rem;
  margin-bottom: 14px;
  box-shadow: 0 6px 14px rgba(15, 157, 106, .25);
}
.step-card h3 { margin-bottom: 6px; }
.step-card p { margin: 0; color: var(--ink-soft); font-size: .94rem; }

/* ------------------------------ Tool ----------------------------------- */
.tool-hero { padding: clamp(26px, 4vw, 44px) 0 0; }
.tool-hero h1 { margin-bottom: 12px; }
.tool-hero .lead { color: var(--ink-soft); max-width: 780px; margin: 0; }

.tool-section { padding: 24px 0 8px; }

.tool-card {
  background: var(--surface);
  border: 1.5px solid var(--line);
  border-radius: var(--r-xl);
  box-shadow: var(--sh-md);
  padding: clamp(16px, 2.6vw, 26px);
}

.tool-toolbar {
  display: flex;
  flex-wrap: wrap;
  gap: 9px;
  padding-bottom: 16px;
  border-bottom: 1px dashed var(--line);
}

.tool-settings {
  margin-top: 16px;
  padding: 16px;
  border-radius: var(--r-md);
  background: var(--surface-alt);
  border: 1.5px solid var(--line);
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 14px;
}

.tool-settings[hidden] { display: none; }

.field { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.field label {
  font-size: .8rem;
  font-weight: 700;
  color: var(--ink-soft);
  font-family: var(--font-display);
}
.field input[type="number"],
.field input[type="text"],
.field input[type="email"],
.field textarea,
.field select {
  width: 100%;
  padding: 10px 13px;
  border: 1.5px solid var(--line);
  border-radius: var(--r-sm);
  background: var(--surface);
  font: inherit;
  font-size: .92rem;
  color: var(--ink);
  transition: border-color var(--ease), box-shadow var(--ease);
}
.field textarea { resize: vertical; min-height: 110px; }
.field input:focus,
.field textarea:focus,
.field select:focus {
  outline: none;
  border-color: var(--brand);
  box-shadow: 0 0 0 4px var(--brand-ring);
}
.field-wide { grid-column: 1 / -1; }
.field-check label {
  flex-direction: row;
  display: flex;
  align-items: center;
  gap: 9px;
  font-weight: 600;
  font-size: .88rem;
  color: var(--ink-soft);
  cursor: pointer;
}
.field-check input[type="checkbox"] {
  width: 18px; height: 18px;
  accent-color: var(--brand);
  cursor: pointer;
}

.result-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(210px, 1fr));
  gap: 10px;
  margin-top: 18px;
  min-height: 80px;
}

.result-chip {
  display: flex;
  align-items: center;
  gap: 10px;
  width: 100%;
  padding: 13px 14px;
  text-align: left;
  background: var(--surface-alt);
  border: 1.5px solid var(--line);
  border-radius: var(--r-md);
  cursor: pointer;
  color: var(--ink);
  transition: transform var(--ease), border-color var(--ease),
              background-color var(--ease), box-shadow var(--ease);
  animation: chipIn .22s ease both;
}
.result-chip:hover {
  border-color: var(--brand);
  background: var(--brand-light);
  transform: translateY(-2px);
  box-shadow: var(--sh-sm);
}
.result-chip:active { transform: translateY(0) scale(.99); }

.chip-text {
  flex: 1 1 auto;
  min-width: 0;
  font-size: .95rem;
  font-weight: 500;
  overflow-wrap: anywhere;
}
.chip-hex { font-style: normal; font-size: .76rem; color: var(--muted); }
.chip-copy {
  width: 16px; height: 16px;
  color: var(--muted);
  opacity: 0;
  transition: opacity var(--ease), color var(--ease);
  flex: 0 0 auto;
}
.result-chip:hover .chip-copy { opacity: 1; color: var(--brand-dark); }

.swatch {
  width: 26px; height: 26px;
  border-radius: 8px;
  border: 1px solid rgba(0, 0, 0, .08);
  flex: 0 0 auto;
}

.result-chip.is-copied {
  border-color: var(--brand);
  background: var(--brand-light);
}

@keyframes chipIn {
  from { opacity: 0; transform: translateY(6px); }
  to { opacity: 1; transform: translateY(0); }
}

.result-status {
  margin: 16px 0 0;
  font-size: .82rem;
  color: var(--muted);
}

.tool-card.is-loading .result-grid { opacity: .45; transition: opacity var(--ease); }

/* ------------------------------ Prose ---------------------------------- */
.prose {
  max-width: 860px;
  padding-top: clamp(34px, 4.5vw, 54px);
  padding-bottom: clamp(30px, 4vw, 44px);
}
.prose h2 {
  margin-top: 1.9em;
  padding-bottom: .3em;
  border-bottom: 2px solid var(--line);
}
.prose h2:first-child { margin-top: 0; }
.prose p, .prose li { color: var(--ink-soft); }
.prose a { font-weight: 600; text-decoration: underline; text-decoration-color: var(--brand-ring); text-underline-offset: 2px; }
.prose a:hover { text-decoration-color: var(--brand); }

.benefits { list-style: none; padding: 0; display: grid; gap: 10px; }
.benefits li {
  display: flex;
  gap: 11px;
  align-items: flex-start;
  padding: 13px 16px;
  background: var(--surface);
  border: 1.5px solid var(--line);
  border-radius: var(--r-md);
  margin: 0;
}
.benefits .icon-sm { color: var(--brand); margin-top: 3px; }

.steps { counter-reset: step; list-style: none; padding: 0; display: grid; gap: 10px; }
.steps li {
  counter-increment: step;
  position: relative;
  padding: 14px 16px 14px 52px;
  background: var(--surface);
  border: 1.5px solid var(--line);
  border-radius: var(--r-md);
  margin: 0;
}
.steps li::before {
  content: counter(step);
  position: absolute;
  left: 14px; top: 13px;
  width: 26px; height: 26px;
  display: grid; place-items: center;
  border-radius: 50%;
  background: var(--brand-light);
  color: var(--brand-dark);
  font-size: .8rem;
  font-weight: 800;
  font-family: var(--font-display);
}

/* ------------------------------ FAQ ------------------------------------ */
.faq-section { max-width: 860px; padding-bottom: clamp(30px, 4vw, 46px); }
.faq-list { display: grid; gap: 10px; }
.faq-list-wide { max-width: 900px; }

.faq {
  background: var(--surface);
  border: 1.5px solid var(--line);
  border-radius: var(--r-md);
  box-shadow: var(--sh-xs);
  transition: border-color var(--ease), box-shadow var(--ease);
}
.faq:hover { border-color: var(--line-strong); }
.faq[open] { border-color: rgba(15, 157, 106, .35); box-shadow: var(--sh-sm); }

.faq summary {
  position: relative;
  list-style: none;
  cursor: pointer;
  padding: 16px 52px 16px 18px;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: .98rem;
  color: var(--ink);
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {
  content: "";
  position: absolute;
  right: 20px; top: 50%;
  width: 9px; height: 9px;
  border-right: 2px solid var(--muted);
  border-bottom: 2px solid var(--muted);
  transform: translateY(-70%) rotate(45deg);
  transition: transform var(--ease);
}
.faq[open] summary::after { transform: translateY(-30%) rotate(-135deg); border-color: var(--brand); }

.faq-body { padding: 0 18px 17px; }
.faq-body p { margin: 0; color: var(--ink-soft); font-size: .94rem; }

/* ------------------------------ Related -------------------------------- */
.related-section { padding-bottom: clamp(34px, 4.5vw, 56px); }
.related-section h2 { margin-bottom: 18px; }

/* ------------------------------ Contact -------------------------------- */
.contact-layout {
  display: grid;
  grid-template-columns: minmax(0, .9fr) minmax(0, 1.1fr);
  gap: 26px;
  align-items: start;
}

.contact-info {
  padding: clamp(20px, 3vw, 30px);
  background: linear-gradient(160deg, var(--brand-light), #f2fbf7 65%);
  border: 1.5px solid rgba(15, 157, 106, .18);
  border-radius: var(--r-xl);
}
.contact-info h2 { margin-bottom: 10px; }
.contact-list { list-style: none; padding: 0; display: grid; gap: 12px; margin: 20px 0; }
.contact-list li { display: flex; gap: 11px; align-items: flex-start; margin: 0; }
.contact-list .icon-sm { color: var(--brand-dark); margin-top: 4px; }
.contact-list span { display: flex; flex-direction: column; font-size: .92rem; color: var(--ink-soft); }
.contact-list strong { font-size: .95rem; }
.contact-email { display: flex; align-items: center; gap: 8px; margin: 0; font-weight: 600; }
.contact-email .icon-sm { color: var(--brand-dark); }

.contact-form-wrap {
  padding: clamp(20px, 3vw, 30px);
  background: var(--surface);
  border: 1.5px solid var(--line);
  border-radius: var(--r-xl);
  box-shadow: var(--sh-sm);
}
.contact-form { display: grid; gap: 15px; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.form-note { margin: 0; font-size: .8rem; color: var(--muted); }
.form-note a { text-decoration: underline; }

.alert { padding: 14px 16px; border-radius: var(--r-md); margin-bottom: 18px; font-size: .92rem; }
.alert ul { margin: 8px 0 0; padding-left: 20px; }
.alert p { margin: 4px 0 0; }
.alert-success { background: #ecfdf5; border: 1.5px solid #a7f3d0; color: #065f46; }
.alert-error { background: #fef2f2; border: 1.5px solid #fecaca; color: #991b1b; }

/* ------------------------------ Footer -------------------------------- */
.site-footer {
  background: #0c1a15;
  color: #b9cfc6;
  padding: clamp(40px, 5vw, 60px) 0 0;
  margin-top: 10px;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.6fr 1fr 1fr 1fr;
  gap: 30px 26px;
  padding-bottom: 40px;
}

.footer-brand .brand { margin-bottom: 14px; }
.footer-brand .brand-text strong { color: #fff; }
.footer-brand .brand-text strong span { color: #34d399; }
.footer-brand p { font-size: .9rem; color: #9fb8ae; max-width: 340px; }

.footer-badges { list-style: none; padding: 0; display: grid; gap: 8px; margin: 16px 0 0; }
.footer-badges li {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 0;
  font-size: .83rem;
  color: #cfe2da;
}
.footer-badges .icon-sm { color: #34d399; }

.footer-col h3 {
  color: #fff;
  font-size: .82rem;
  text-transform: uppercase;
  letter-spacing: .1em;
  margin-bottom: 14px;
}
.footer-col ul { list-style: none; padding: 0; margin: 0; display: grid; gap: 9px; }
.footer-col li { margin: 0; }
.footer-col a { color: #a9c3b9; font-size: .9rem; }
.footer-col a:hover { color: #fff; }

.footer-bottom {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 8px 24px;
  padding-block: 20px;
  border-top: 1px solid rgba(255, 255, 255, .08);
  font-size: .82rem;
  color: #8aa59b;
}
.footer-bottom p { margin: 0; }
.footer-note { max-width: 560px; }

/* ------------------------------ Toast / top --------------------------- */
.toast {
  position: fixed;
  left: 50%;
  bottom: 26px;
  transform: translate(-50%, 20px);
  z-index: 500;
  padding: 11px 20px;
  border-radius: var(--r-pill);
  background: #0c1a15;
  color: #fff;
  font-size: .88rem;
  font-weight: 600;
  box-shadow: var(--sh-lg);
  opacity: 0;
  pointer-events: none;
  transition: opacity var(--ease), transform var(--ease);
  max-width: min(92vw, 560px);
  text-align: center;
}
.toast.is-visible { opacity: 1; transform: translate(-50%, 0); }

.to-top {
  position: fixed;
  right: 20px;
  bottom: 20px;
  z-index: 90;
  width: 46px; height: 46px;
  display: grid; place-items: center;
  border-radius: 50%;
  border: 1.5px solid var(--line);
  background: var(--surface);
  color: var(--ink-soft);
  box-shadow: var(--sh-md);
  cursor: pointer;
  opacity: 0;
  transform: translateY(10px);
  pointer-events: none;
  transition: opacity var(--ease), transform var(--ease), color var(--ease);
}
.to-top.is-visible { opacity: 1; transform: translateY(0); pointer-events: auto; }
.to-top:hover { color: var(--brand-dark); }
.icon-top { transform: rotate(-90deg); width: 20px; height: 20px; }

/* ------------------------------ Misc pages ---------------------------- */
.page-simple { max-width: 760px; padding: clamp(40px, 6vw, 80px) 20px; text-align: center; }
.page-simple .eyebrow { margin-bottom: 12px; }
.page-simple p { color: var(--ink-soft); }
.page-simple .hero-cta { margin-bottom: 0; }

.empty-state {
  text-align: center;
  padding: 40px 20px;
  background: var(--surface);
  border: 1.5px dashed var(--line-strong);
  border-radius: var(--r-lg);
}
.empty-state p { margin-bottom: 10px; }

/* ------------------------------ Responsive ---------------------------- */
@media (max-width: 1024px) {
  .footer-grid { grid-template-columns: 1.4fr 1fr 1fr; }
  .footer-brand { grid-column: 1 / -1; }
}

@media (max-width: 900px) {
  .header-inner { flex-wrap: wrap; gap: 12px; padding-block: 12px; min-height: 0; }
  .header-search { order: 3; flex-basis: 100%; max-width: none; }
  .main-nav {
    order: 4;
    flex-basis: 100%;
    display: none;
    flex-direction: column;
    align-items: stretch;
    gap: 2px;
    padding-top: 6px;
  }
  .main-nav.open { display: flex; }
  .main-nav a { padding: 11px 14px; border-radius: var(--r-sm); }
  .nav-toggle { display: inline-flex; margin-left: auto; }
  .brand-text em { display: none; }

  .contact-layout { grid-template-columns: 1fr; }
}

@media (max-width: 640px) {
  body { font-size: 16px; }
  .wrap { padding-inline: 16px; }
  .hero { padding-top: 40px; }
  .hero-search { flex-wrap: wrap; border-radius: var(--r-lg); padding: 10px; }
  .hero-search .search-icon { top: 22px; }
  .hero-search input { flex-basis: 100%; }
  .hero-search .btn { width: 100%; }
  .hero-cta .btn { width: 100%; }
  .hero-stats { gap: 14px 26px; }
  .hero-stats li { font-size: .82rem; }

  .card-grid { grid-template-columns: 1fr; }
  .result-grid { grid-template-columns: 1fr; }
  .form-row { grid-template-columns: 1fr; }
  .tool-toolbar .btn { flex: 1 1 calc(50% - 5px); }
  .tool-settings { grid-template-columns: 1fr; }

  .footer-grid { grid-template-columns: 1fr 1fr; }
  .footer-brand { grid-column: 1 / -1; }
  .footer-bottom { flex-direction: column; }
  .section-head-row { flex-direction: column; align-items: flex-start; }

  .to-top { right: 14px; bottom: 14px; }
  .toast { bottom: 76px; }
}

@media (max-width: 420px) {
  .footer-grid { grid-template-columns: 1fr; }
  .brand-mark { width: 38px; height: 38px; }
  .brand-text strong { font-size: 1.06rem; }
}

/* ------------------------------ Motion / print ------------------------ */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: .01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: .01ms !important;
    scroll-behavior: auto !important;
  }
}

@media print {
  .site-header, .site-footer, .tool-toolbar, .tool-settings,
  .to-top, .toast, .breadcrumb { display: none !important; }
  body { background: #fff; }
  .tool-card, .generator-card, .faq { box-shadow: none; border-color: #ddd; }
  .result-chip { border-color: #ddd; background: #fff; }
}
