:root {
  --muted: #5F6472;
  --line: #E4E6EE;
  --soft: #F4F6FF;
  --fg: #121317;
  --accent: #1B2EE7;
  --accent-dark: #1220A8;
  --accent-soft: #EEF0FE;
}

* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
html { -webkit-text-size-adjust: 100%; }
body {
  background: #fff;
  color: var(--fg);
  font-family: "Plus Jakarta Sans", system-ui, -apple-system, Segoe UI, Roboto, sans-serif;
  -webkit-font-smoothing: antialiased;
  line-height: 1.5;
  overflow-x: hidden;    /* catch any accidental wide child */
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition: none !important; animation: none !important; }
}
a { color: var(--accent); text-decoration: none; -webkit-tap-highlight-color: transparent; }
a:hover { color: var(--accent-dark); }
button { font: inherit; -webkit-tap-highlight-color: transparent; }
input::placeholder { color: #8A8F9C; }
.card { -webkit-tap-highlight-color: transparent; transition: transform .12s ease; }
.card:active { transform: scale(.98); }
.format-card { transition: transform .12s ease; }
.format-card:active { transform: scale(.98); }
.promo { transition: transform .12s ease; }
.promo:active { transform: scale(.99); }
*:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
summary::-webkit-details-marker { display: none; }
.hs::-webkit-scrollbar { display: none; }

/* App shell */
.app { min-height: 100vh; display: flex; background: #fff; }
.app__main { flex: 1; min-width: 0; display: flex; flex-direction: column; }

/* Sidebar */
.sidebar {
  width: 80px; flex: none; position: sticky; top: 0; height: 100vh;
  background: #fff; border-right: 1px solid var(--line);
  display: flex; flex-direction: column; align-items: center;
  padding: 14px 0; gap: 6px; z-index: 50;
}
.sidebar__brand {
  width: 40px; height: 40px; border-radius: 12px;
  background: var(--accent); color: #fff;
  display: flex; align-items: center; justify-content: center;
  font-weight: 800; font-size: 18px; margin-bottom: 12px;
}
.sidebar__item {
  width: 64px; border: 0; background: none; cursor: pointer;
  display: flex; flex-direction: column; align-items: center; gap: 6px;
  color: var(--fg); font-size: 11.5px; font-weight: 600;
  padding: 8px 0; margin-bottom: 2px; border-radius: 12px;
}
.sidebar__item:hover { background: #F1F2F6; }
.sidebar__item.is-active { color: var(--accent); background: var(--accent-soft); }
.sidebar__icon {
  width: 44px; height: 44px; border-radius: 14px;
  display: flex; align-items: center; justify-content: center;
  color: currentColor;
}
.search__clear svg { width: 16px; height: 16px; }
.editor-mock__rail-item svg { width: 19px; height: 19px; }
.chip { display: inline-flex; align-items: center; gap: 6px; padding: 7px 10px 7px 14px; border-radius: 999px; background: #EEF0FE; color: #1220A8; font-size: 14px; font-weight: 600; }
.chip button { font: inherit; border: 0; background: transparent; color: inherit; cursor: pointer; display: inline-flex; align-items: center; padding: 2px; }
.chip button:hover { color: #000; }
.card__badge { position: absolute; top: 10px; left: 10px; background: rgba(18,19,23,.85); color: #fff; font-size: 11.5px; font-weight: 700; padding: 4px 9px; border-radius: 999px; }
.card--blank { text-decoration: none; color: inherit; }
.card--blank .card__thumb { color: var(--muted); }
.card--blank:hover .card__thumb { color: var(--accent); border-color: var(--accent); background: var(--accent-soft); }
.sidebar__icon--primary {
  background: var(--accent); color: #fff;
  box-shadow: 0 6px 16px rgba(27,46,231,.35);
}

/* Topbar */
.topbar {
  position: sticky; top: 0; z-index: 40;
  background: rgba(255,255,255,.94); backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line);
}
.topbar__inner { height: 60px; padding: 0 28px; display: flex; align-items: center; gap: 20px; }
.topbar__brand { font-weight: 800; font-size: 18px; letter-spacing: -0.03em; color: var(--fg); }
.topbar__urlbar {
  flex: 1; min-width: 0; display: flex; align-items: center; gap: 8px;
  height: 34px; padding: 0 12px; background: #F6F7FA; border-radius: 10px;
  font-size: 12px; font-family: ui-monospace, Menlo, monospace;
  overflow: hidden; max-width: 620px;
}
.topbar__urlbar-host { color: #8A8F9C; }
.topbar__urlbar-sep  { color: #B7BAC5; }
.topbar__urlbar-slug { color: var(--accent); font-weight: 700; }
.topbar__urlbar-type {
  margin-left: auto; font-size: 11px; font-weight: 700;
  color: var(--accent); background: var(--accent-soft);
  padding: 2px 8px; border-radius: 999px; white-space: nowrap;
}
.topbar__cta { margin-left: auto; display: flex; gap: 10px; align-items: center; }

/* Mobile section label — shown only on mobile where the sidebar is hidden. */
.topbar__section {
  display: none;
  position: relative;
  padding-left: 12px;
  font-size: 14px; font-weight: 600; color: var(--fg);
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
  min-width: 0;
}
.topbar__section::before {
  content: ""; position: absolute; left: 0; top: 50%;
  transform: translateY(-50%);
  width: 1px; height: 16px; background: var(--line);
}

/* Mobile hamburger button — hidden on desktop. */
.topbar__menu {
  display: none;
  margin-left: auto;
  width: 40px; height: 40px; border-radius: 10px;
  background: #F6F7FA; border: 1px solid var(--line); color: var(--fg);
  align-items: center; justify-content: center; cursor: pointer;
  transition: background .15s, border-color .15s, color .15s;
  flex: none;
}
.topbar__menu:hover { background: #EEF0FE; border-color: var(--accent-soft); color: var(--accent-dark); }
.topbar__menu[aria-expanded="true"] { background: var(--fg); border-color: var(--fg); color: #fff; }

/* Mobile slide-down menu panel. */
.topbar__sheet {
  position: absolute; top: 100%; left: 0; right: 0;
  background: #fff;
  border-bottom: 1px solid var(--line);
  box-shadow: 0 12px 32px rgba(16, 24, 40, 0.08);
  padding: 8px;
  display: flex; flex-direction: column; gap: 2px;
  z-index: 45;
  animation: topbarSheetIn .18s ease-out;
}
/* `display:flex` above overrides the browser's default `display:none` for the
   [hidden] attribute. Restore it explicitly so the sheet stays closed on load. */
.topbar__sheet[hidden] { display: none !important; }
/* Belt-and-braces: never show the sheet on desktop (the sidebar handles nav). */
@media (min-width: 821px) {
  .topbar__sheet { display: none !important; }
}
@keyframes topbarSheetIn {
  from { opacity: 0; transform: translateY(-8px); }
  to   { opacity: 1; transform: translateY(0); }
}
.topbar__sheet-link {
  display: flex; align-items: center; gap: 12px;
  padding: 12px 14px; border-radius: 10px;
  color: var(--fg); text-decoration: none;
  font-size: 15px; font-weight: 600;
  transition: background .15s, color .15s;
}
.topbar__sheet-link:hover { background: #F6F7FA; color: var(--accent); }
.topbar__sheet-link.is-active {
  background: var(--accent-soft); color: var(--accent-dark);
}
.topbar__sheet-link svg { flex: none; opacity: 0.75; }
.topbar__sheet-link.is-active svg { opacity: 1; }
body.topbar-sheet-open { overflow: hidden; }

/* Buttons */
.btn { font-size: 14px; font-weight: 700; height: 40px; padding: 0 16px; border-radius: 999px; cursor: pointer; display: inline-flex; align-items: center; gap: 8px; border: 0; }
.btn--primary { background: var(--accent); color: #fff; }
.btn--primary:hover { background: #1524C4; }
.btn--ghost   { background: #fff; color: var(--fg); border: 1px solid var(--line); }
.btn--ghost:hover { background: #F6F7FA; }
.btn--link    { background: none; color: var(--fg); font-weight: 600; }
.btn--pro svg { color: #F59F00; }
.btn--big { height: 52px; padding: 0 26px; font-size: 15.5px; }

.content { flex: 1; }

/* Hero */
.hero { padding: 12px 16px 0; }
.hero__inner {
  background: var(--soft); border-radius: 28px;
  display: flex; flex-direction: column; align-items: center; text-align: center;
  position: relative;
  padding: 52px 32px 34px;
}
.hero--sm .hero__inner { padding: 36px 32px 30px; }
.hero__crumbs { display: flex; gap: 6px; align-items: center; font-size: 13px; font-weight: 600; flex-wrap: wrap; justify-content: center; margin-bottom: 18px; }
.hero__crumbs a { color: #5F6472; }
.hero__crumbs .is-active { color: var(--accent); }
.hero__title {
  font-size: clamp(34px, 4.4vw, 56px);
  line-height: 1.05; letter-spacing: -0.04em; font-weight: 800;
  margin: 0; color: var(--accent); max-width: 980px;
  text-wrap: balance;
}
.hero--sm .hero__title { font-size: clamp(30px, 3.6vw, 48px); color: var(--fg); }
.hero__text { margin: 14px 0 0; font-size: 17px; line-height: 1.55; max-width: 640px; color: var(--muted); text-wrap: pretty; }
.hero__tabs { display: flex; gap: 8px; margin-top: 22px; }
.hero__search {
  width: 100%; max-width: 780px; margin-top: 24px;
  display: flex; align-items: center; gap: 12px;
  background: #fff; border: 1.5px solid var(--line);
  border-radius: 16px; padding: 0 10px 0 20px; height: 60px;
  box-shadow: 0 8px 24px rgba(18,19,23,.06);
}
.hero__search:focus-within { border-color: var(--accent); }
.hero__search input { flex: 1; min-width: 0; border: 0; outline: 0; height: 100%; font: inherit; font-size: 16.5px; color: var(--fg); background: transparent; }
.hero__search-clear { width: 36px; height: 36px; border-radius: 50%; border: 0; background: #F1F2F6; cursor: pointer; display: flex; align-items: center; justify-content: center; }
.hero__filters { display: flex; gap: 8px; flex-wrap: wrap; justify-content: center; margin-top: 18px; }
.hero__shortcuts { width: 100%; display: flex; gap: 6px; overflow-x: auto; margin-top: 34px; padding: 4px 0; justify-content: safe center; scrollbar-width: none; -webkit-overflow-scrolling: touch; overscroll-behavior-x: contain; }
.hero__shortcuts::-webkit-scrollbar { display: none; }
.shortcut { flex: none; width: 96px; display: flex; flex-direction: column; align-items: center; gap: 10px; color: var(--fg); font-size: 13.5px; font-weight: 600; }
.shortcut__icon { width: 60px; height: 60px; border-radius: 50%; display: flex; align-items: center; justify-content: center; color: #fff; transition: transform .15s; }
.shortcut:hover .shortcut__icon { transform: translateY(-3px); }

/* Pill */
.pill { font-size: 15px; font-weight: 600; height: 42px; padding: 0 16px; border-radius: 999px; border: 1.5px solid var(--line); background: #fff; color: var(--fg); cursor: pointer; display: inline-flex; align-items: center; gap: 8px; }
.pill:hover { background: #F6F7FA; }
.pill.is-active { border-color: var(--accent); background: var(--accent); color: #fff; }
.pill--ghost { border-color: #DADDE8; background: #fff; }
.pill--ghost.is-active { background: var(--accent-soft); color: var(--accent-dark); border-color: var(--accent); }

/* Role pills (resume maker: browse-by-profession navigation) */
.role-pills {
  display: flex; gap: 8px; flex-wrap: wrap;
  justify-content: center; margin-top: 16px;
  width: 100%;              /* fill hero__inner so overflow-x works on mobile */
  max-width: 100%;
  box-sizing: border-box;
}
.role-pill { display: inline-flex; align-items: center; gap: 6px; padding: 7px 14px; font-size: 14px; font-weight: 500; color: var(--fg); background: #F6F7FA; border: 1px solid var(--line); border-radius: 999px; text-decoration: none; white-space: nowrap; transition: background .15s, border-color .15s, color .15s, transform .15s; }
.role-pill:hover { background: #EEF0FE; border-color: var(--accent-soft); color: var(--accent-dark); transform: translateY(-1px); }
.role-pill.is-active { background: var(--fg); color: #fff; border-color: var(--fg); font-weight: 600; }
.role-pill__icon { font-size: 15px; line-height: 1; }

/* Tablet/phone: convert from wrap-grid into a horizontal scroller.
   The hero__inner parent is flex-column + align-items:center, which naturally
   shrink-wraps children; width:100% + align-self:stretch forces the pills
   container to occupy the full width so overflow-x can activate. */
@media (max-width: 820px) {
  .role-pills {
    gap: 6px; margin-top: 12px;
    justify-content: flex-start;
    overflow-x: auto;
    flex-wrap: nowrap;
    padding: 2px 0 8px;
    -webkit-overflow-scrolling: touch;
    align-self: stretch;
    scroll-snap-type: x proximity;
    scroll-padding-left: 4px;
    /* Fade the right edge so it's obvious there's more to scroll. */
    -webkit-mask-image: linear-gradient(to right, #000 calc(100% - 32px), transparent 100%);
            mask-image: linear-gradient(to right, #000 calc(100% - 32px), transparent 100%);
  }
  .role-pills::-webkit-scrollbar { display: none; }
  .role-pill {
    font-size: 13px; padding: 6px 12px;
    flex-shrink: 0;
    scroll-snap-align: start;
  }
  /* Drop the fade when the user has scrolled near the end — nice-to-have polish. */
  .role-pills.at-end {
    -webkit-mask-image: none;
            mask-image: none;
  }
}

/* Section */
.section { padding: 44px 44px 0; }
.section__head { display: flex; align-items: center; gap: 12px; margin-bottom: 18px; }
.section__head--end { align-items: flex-end; flex-wrap: wrap; }
.section__title { font-size: 26px; letter-spacing: -0.03em; margin: 0; font-weight: 800; margin-right: auto; }
.section__sub   { color: var(--muted); font-size: 14.5px; margin: 0; }
.section__count { font-size: 13px; font-weight: 700; color: var(--accent); background: var(--accent-soft); padding: 4px 10px; border-radius: 999px; }
.section__link  { font-size: 14.5px; font-weight: 700; border: 0; background: none; color: var(--accent); cursor: pointer; }
.nav-btn { width: 40px; height: 40px; border-radius: 50%; border: 1px solid var(--line); background: #fff; cursor: pointer; display: flex; align-items: center; justify-content: center; color: var(--fg); flex: none; transition: background .15s, box-shadow .15s; }
.nav-btn:hover { background: #F6F7FA; }
.nav-btn--primary { box-shadow: 0 4px 12px rgba(18,19,23,.08); }
.nav-btn:disabled { opacity: .35; cursor: default; }

/* Format cards (pastel row) */
.formats {
  display: grid; grid-auto-flow: column; grid-template-rows: repeat(2, 124px);
  grid-auto-columns: 300px; gap: 16px;
  overflow-x: auto; scroll-snap-type: x mandatory; scrollbar-width: none;
  padding-bottom: 4px;
  -webkit-overflow-scrolling: touch;
  scroll-padding-left: 4px;
  overscroll-behavior-x: contain;
}
.formats::-webkit-scrollbar { display: none; }
.formats--related { display: grid; grid-auto-flow: initial; grid-template-rows: initial; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 14px; }
.format-card {
  scroll-snap-align: start; position: relative;
  border-radius: 20px; overflow: hidden; display: flex; align-items: center;
  padding: 0 22px; color: var(--fg); min-height: 110px;
}
.formats--related .format-card { height: 118px; }
.format-card:hover { box-shadow: 0 10px 28px rgba(18,19,23,.12); }
.format-card__meta { display: flex; flex-direction: column; gap: 4px; max-width: 48%; position: relative; z-index: 2; }
.format-card__label { font-size: 17px; font-weight: 700; line-height: 1.25; letter-spacing: -0.01em; }
.format-card__sub   { font-size: 12.5px; color: var(--muted); }
.format-card__back  { position: absolute; width: 100px; height: 76px; border-radius: 8px; transform: rotate(-6deg); right: 70px; bottom: -8px; }
.format-card__front { position: absolute; right: 18px; bottom: -16px; width: 100px; height: 76px; border-radius: 8px; overflow: hidden; box-shadow: 0 8px 20px rgba(18,19,23,.18); transform: rotate(3deg); }

/* Promo cards row */
.promos { display: grid; grid-auto-flow: column; grid-auto-columns: minmax(360px, 1fr); gap: 18px; overflow-x: auto; scroll-snap-type: x mandatory; scrollbar-width: none; -webkit-overflow-scrolling: touch; overscroll-behavior-x: contain; }
.promos::-webkit-scrollbar { display: none; }
.promo {
  scroll-snap-align: start; height: 250px; border-radius: 22px;
  position: relative; overflow: hidden; padding: 26px 28px;
  display: flex; flex-direction: column; gap: 6px;
}
.promo:hover { box-shadow: 0 14px 34px rgba(18,19,23,.16); }
.promo__title { font-size: 21px; font-weight: 700; line-height: 1.25; letter-spacing: -0.02em; max-width: 300px; display: flex; align-items: center; gap: 6px; }
.promo__path  { font-size: 12px; font-family: ui-monospace, Menlo, monospace; opacity: .9; }
.promo__thumbs { position: absolute; left: 28px; right: -20px; bottom: -24px; display: flex; gap: 12px; align-items: flex-end; }

/* Template thumb mock (CSS-only placeholder for TemplateThumb design) */
.tt { position: relative; width: 100%; height: 100%; overflow: hidden; container-type: size; }
.tt--poster span.tt__corner { position: absolute; right: -16cqmin; top: -16cqmin; width: 60cqmin; height: 60cqmin; border-radius: 50%; }
.tt--poster .tt__body { position: absolute; inset: 8cqmin; display: flex; flex-direction: column; justify-content: space-between; }
.tt--poster .tt__kicker { font-size: 3.8cqmin; font-weight: 700; letter-spacing: .14em; text-transform: uppercase; }
.tt--poster .tt__group { display: flex; flex-direction: column; gap: 3cqmin; max-width: 74%; }
.tt--poster .tt__sub { font-size: 3.6cqmin; opacity: .85; }
.tt--poster .tt__bar { width: 22cqmin; height: 1.6cqmin; }
.tt--poster .tt__badge { position: absolute; right: 7cqmin; bottom: 7cqmin; width: 21cqmin; height: 21cqmin; border-radius: 50%; display: flex; align-items: center; justify-content: center; text-align: center; font-weight: 800; font-size: 4.4cqmin; line-height: 1; transform: rotate(-12deg); }
.tt--split .tt__block { position: absolute; left: 0; top: 0; width: 42%; height: 100%; background-image: repeating-linear-gradient(135deg,rgba(255,255,255,.16) 0 2cqmin,transparent 2cqmin 5cqmin); display: flex; align-items: center; justify-content: center; }
.tt--split .tt__block::before { content: ''; width: 30cqmin; height: 30cqmin; border-radius: 50%; box-shadow: 0 0 0 2.4cqmin rgba(255,255,255,.35); display: block; }
.tt--split .tt__body { position: absolute; left: 47%; top: 8cqmin; right: 8cqmin; bottom: 8cqmin; display: flex; flex-direction: column; justify-content: flex-end; gap: 2.4cqmin; }
.tt--frame .tt__body { position: absolute; inset: 5cqmin; border: 0.9cqmin solid currentColor; display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; gap: 3cqmin; padding: 6cqmin; }
.tt--shapes .tt__body { position: absolute; left: 8cqmin; top: 9cqmin; right: 12cqmin; display: flex; flex-direction: column; gap: 3cqmin; }
.tt--shapes .tt__shape1 { position: absolute; left: -10cqmin; bottom: -12cqmin; width: 42cqmin; height: 42cqmin; transform: rotate(14deg); border-radius: 4cqmin; }
.tt--shapes .tt__shape2 { position: absolute; right: -6cqmin; bottom: 12cqmin; width: 34cqmin; height: 34cqmin; border-radius: 50%; }
.tt--list .tt__body { position: absolute; inset: 8cqmin; display: flex; flex-direction: column; gap: 3.5cqmin; }
.tt--list .tt__chip { align-self: flex-start; font-size: 3.4cqmin; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; padding: 1.4cqmin 3cqmin; border-radius: 5cqmin; }
.tt__headline { line-height: .92; }

/* Templates masonry grid */
.cards { columns: 220px; column-gap: 20px; }
.card { break-inside: avoid; margin-bottom: 24px; display: flex; flex-direction: column; gap: 9px; cursor: pointer; }
.card[hidden] { display: none !important; }
.card__thumb {
  position: relative; border-radius: 12px; overflow: hidden;
  box-shadow: 0 0 0 1px rgba(18,19,23,.06);
}
.card__thumb::after {
  content: 'Customize'; position: absolute; inset: 0; display: flex; align-items: flex-end; padding: 12px;
  background: rgba(18,19,23,.38); opacity: 0; transition: opacity .16s;
  color: #fff; font-size: 13px; font-weight: 700;
}
.card__thumb:hover::after { opacity: 1; }
.card__pro { position: absolute; top: 10px; right: 10px; width: 26px; height: 26px; border-radius: 50%; background: #fff; display: flex; align-items: center; justify-content: center; box-shadow: 0 2px 6px rgba(0,0,0,.18); color: #F59F00; }
.card__row  { display: flex; justify-content: space-between; gap: 8px; font-size: 13.5px; line-height: 1.3; }
.card__name { font-weight: 600; }
.card__meta { color: #8A8F9C; white-space: nowrap; }

.load-more { display: flex; justify-content: center; margin-top: 16px; }
.load-more button { font: inherit; font-size: 15px; font-weight: 700; height: 48px; padding: 0 26px; border-radius: 999px; border: 1px solid var(--line); background: #fff; color: var(--fg); cursor: pointer; }

.empty { background: var(--soft); border-radius: 22px; padding: 56px 32px; display: flex; flex-direction: column; gap: 12px; align-items: center; text-align: center; }
.empty__title { font-size: 20px; font-weight: 800; }
.empty__sub   { color: var(--muted); }

/* Editor preview block */
.editor-block { padding: 0 16px; margin-top: 64px; }
.editor-block__inner { background: var(--soft); border-radius: 28px; padding: 56px 44px; display: flex; flex-wrap: wrap; gap: 48px; align-items: center; }
.editor-mock { flex: 1.2 1 460px; min-width: 0; background: #fff; border-radius: 20px; overflow: hidden; box-shadow: 0 24px 60px rgba(18,19,23,.12); cursor: pointer; }
.editor-mock__bar { height: 48px; background: var(--accent); display: flex; align-items: center; gap: 10px; padding: 0 14px; color: #fff; font-size: 13px; font-weight: 600; }
.editor-mock__dl { background: #fff; color: var(--accent); padding: 6px 12px; border-radius: 999px; font-weight: 700; font-size: 12px; }
.editor-mock__canvas { display: flex; height: 340px; }
.editor-mock__rail { width: 62px; border-right: 1px solid var(--line); display: flex; flex-direction: column; align-items: center; gap: 6px; padding-top: 12px; }
.editor-mock__rail-item { width: 40px; height: 40px; border-radius: 10px; display: flex; align-items: center; justify-content: center; }
.editor-mock__page { flex: 1; min-width: 0; display: flex; align-items: center; justify-content: center; padding: 28px; background: #ECEEF3; }
.editor-mock__thumb { position: relative; max-width: 100%; max-height: 100%; box-shadow: 0 10px 26px rgba(18,19,23,.18), 0 0 0 2px var(--accent); }
.editor-copy { flex: 1 1 360px; display: flex; flex-direction: column; gap: 18px; }
.editor-copy__kicker { align-self: flex-start; font-size: 13px; font-weight: 700; color: var(--accent); background: #fff; padding: 6px 12px; border-radius: 999px; }
.editor-copy__title { font-size: 34px; line-height: 1.1; letter-spacing: -0.035em; margin: 0; font-weight: 800; text-wrap: balance; }
.editor-copy__list { display: flex; flex-direction: column; gap: 12px; }
.editor-copy__list span { display: flex; gap: 12px; align-items: flex-start; font-size: 15.5px; line-height: 1.5; }
.editor-copy__check { width: 24px; height: 24px; flex: none; border-radius: 50%; background: var(--accent); display: flex; align-items: center; justify-content: center; margin-top: 1px; color: #fff; }

/* Features grid */
.features { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 14px; }
.feature { border: 1px solid var(--line); border-radius: 20px; padding: 24px; display: flex; flex-direction: column; gap: 10px; }
.feature__icon { width: 46px; height: 46px; border-radius: 14px; display: flex; align-items: center; justify-content: center; }
.feature__title { font-size: 17.5px; margin: 6px 0 0; font-weight: 700; }
.feature__text  { margin: 0; color: var(--muted); line-height: 1.6; font-size: 15px; text-wrap: pretty; }

.specs { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 14px; }
.spec  { flex: 1 1 160px; padding: 16px 18px; background: #F6F7FA; border-radius: 16px; display: flex; flex-direction: column; gap: 3px; }
.spec__k { font-size: 12.5px; font-weight: 600; color: var(--muted); }
.spec__v { font-weight: 700; font-size: 16px; }

/* How-to */
.how { display: grid; grid-template-columns: repeat(auto-fit, minmax(230px, 1fr)); gap: 28px; }
.how__step { display: flex; flex-direction: column; gap: 10px; padding-top: 18px; border-top: 2px solid var(--accent); }
.how__step-n { font-size: 13px; font-weight: 800; color: var(--accent); }
.how__step-t { font-size: 18px; margin: 0; font-weight: 700; }
.how__step-x { margin: 0; color: var(--muted); line-height: 1.6; font-size: 15px; }

/* SEO tips (category) */
.tips { flex: 1 1 420px; display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 12px; }
.tip  { background: #F6F7FA; border-radius: 18px; padding: 20px; display: flex; flex-direction: column; gap: 8px; }
.tip__n { width: 30px; height: 30px; border-radius: 50%; background: var(--accent); color: #fff; font-size: 13px; font-weight: 800; display: flex; align-items: center; justify-content: center; }
.tip__t { font-size: 16px; font-weight: 700; }
.tip__x { font-size: 14px; line-height: 1.55; color: var(--muted); }

.seo-split { display: flex; flex-wrap: wrap; gap: 40px; align-items: flex-start; }
.seo-copy  { flex: 1 1 380px; display: flex; flex-direction: column; gap: 14px; }
.seo-kicker{ align-self: flex-start; font-size: 13px; font-weight: 700; color: var(--accent); background: var(--accent-soft); padding: 6px 12px; border-radius: 999px; }
.seo-title { font-size: 32px; line-height: 1.12; letter-spacing: -0.03em; margin: 0; font-weight: 800; text-wrap: balance; }
.seo-text  { margin: 0; font-size: 16.5px; line-height: 1.7; color: var(--muted); text-wrap: pretty; }

/* Directory */
.directory { display: grid; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); gap: 28px 32px; }
.dir-group { display: flex; flex-direction: column; gap: 14px; }
.dir-group__label { font-size: 12px; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; color: var(--accent); }
.dir-tool  { display: flex; flex-direction: column; gap: 3px; }
.dir-tool__name { font-size: 15px; font-weight: 700; color: var(--fg); }
.dir-tool__name:hover { color: var(--accent); }
.dir-tool__cats { display: flex; flex-wrap: wrap; gap: 4px 10px; }
.dir-tool__cats a { font-size: 13px; color: var(--muted); }
.dir-tool__cats a:hover { color: var(--accent); }

/* FAQ */
.faq-wrap { display: flex; flex-wrap: wrap; gap: 40px; padding: 64px 44px; }
.faq-wrap h2 { flex: 1 1 280px; font-size: 30px; letter-spacing: -0.03em; margin: 0; font-weight: 800; }
.faqs { flex: 2 1 520px; display: flex; flex-direction: column; gap: 10px; }
.faq { background: #F6F7FA; border-radius: 16px; padding: 0 22px; }
.faq summary { list-style: none; cursor: pointer; padding: 19px 0; font-size: 16px; font-weight: 700; display: flex; justify-content: space-between; gap: 16px; }
.faq summary svg { color: var(--accent); transition: transform .15s; }
.faq[open] summary svg { transform: rotate(180deg); }
.faq p { margin: 0 0 20px; max-width: 680px; color: var(--muted); line-height: 1.65; }

/* Footer */
.footer { border-top: 1px solid var(--line); padding: 44px 44px 28px; display: flex; flex-direction: column; gap: 28px; }
.footer__grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: 28px; }
.footer__col  { display: flex; flex-direction: column; gap: 9px; }
.footer__col-label { font-size: 14px; font-weight: 800; margin-bottom: 4px; }
.footer__col a { color: var(--muted); font-size: 13.5px; }
.footer__col a:hover { color: var(--accent); }
.footer__meta { display: flex; justify-content: space-between; font-size: 13px; color: var(--muted); border-top: 1px solid var(--line); padding-top: 20px; }

img { max-width: 100%; height: auto; display: block; }
select, input { font-size: 16px; }  /* prevent iOS zoom on focus */

/* ===== Responsive ===== */

/* Tablets */
@media (max-width: 1024px) {
  .section, .faq-wrap, .footer { padding-left: 24px; padding-right: 24px; }
  .section { padding-top: 36px; }
  .editor-block { padding: 0 12px; margin-top: 48px; }
  .editor-block__inner { padding: 36px 28px; gap: 32px; }
  .seo-title { font-size: 28px; }
  .editor-copy__title { font-size: 28px; }
  .section__title { font-size: 24px; }
}

/* Phones + small tablets: sidebar becomes bottom nav */
@media (max-width: 820px) {
  .sidebar { display: none; }

  /* Topbar */
  .topbar { position: sticky; }
  .topbar__inner { height: 56px; padding: 0 12px; gap: 10px; }
  .topbar__urlbar { display: none; }
  .topbar__cta .btn--pro, .topbar__cta .btn--link { display: none; }
  .topbar__brand { font-size: 16px; flex: none; }
  .topbar__cta { gap: 8px; }

  /* Reveal mobile-only chrome */
  .topbar__section { display: inline-block; min-width: 0; flex: 1; margin-left: 2px; }
  .topbar__menu { display: inline-flex; }
  /* Narrower hamburger on very small phones */
}
@media (max-width: 400px) {
  .topbar__inner { padding: 0 10px; gap: 6px; }
  .topbar__brand { font-size: 15px; }
  .topbar__section { font-size: 12.5px; }
  .topbar__menu { width: 36px; height: 36px; }

  /* Hero */
  .hero { padding: 8px 12px 0; }
  .hero__inner { padding: 36px 20px 24px; border-radius: 20px; }
  .hero--sm .hero__inner { padding: 24px 20px 20px; }
  .hero__crumbs { font-size: 12.5px; margin-bottom: 14px; }
  .hero__text { font-size: 15.5px; margin-top: 10px; }
  .hero__search {
    height: 52px; padding: 0 8px 0 14px; border-radius: 14px; gap: 8px;
    margin-top: 20px;
  }
  .hero__search input { font-size: 16px; }
  .hero__search > svg { width: 20px; height: 20px; }
  .hero__filters { gap: 6px; margin-top: 14px; }
  .hero__filters .pill { font-size: 14px; height: 40px; padding: 0 12px; }
  .hero__shortcuts { margin-top: 24px; gap: 10px; padding: 4px 2px; }
  .shortcut { width: 76px; font-size: 12.5px; }
  .shortcut__icon { width: 54px; height: 54px; }
  .shortcut__icon svg { width: 22px; height: 22px; }

  /* Section */
  .section { padding-left: 16px; padding-right: 16px; padding-top: 36px;  padding-bottom: 36px;}
  .section__title { font-size: 22px; }
  .section__head { margin-bottom: 14px; }

  /* Format cards: STACK vertically on mobile so all cards are instantly
     visible, no horizontal scrolling, and the row has consistent gaps. */
  .formats {
    display: grid !important;
    grid-auto-flow: initial;
    grid-template-rows: initial;
    grid-auto-columns: initial;
    grid-template-columns: 1fr;
    overflow-x: visible;
    scroll-snap-type: none;
    padding-bottom: 0;
    gap: 12px;
  }
  .formats--related { grid-template-columns: repeat(auto-fill, minmax(180px, 1fr)); gap: 12px; }
  .formats--related .format-card { height: 100px; }
  .format-card { padding: 0 18px; min-height: 104px; border-radius: 16px; width: 100%; }
  .format-card__meta { max-width: 55%; }
  .format-card__label { font-size: 15.5px; }
  .format-card__sub { font-size: 12px; }
  .format-card__back  { width: 76px; height: 60px; right: 56px; bottom: -8px; }
  .format-card__front { width: 76px; height: 60px; bottom: -14px; right: 16px; }

  /* Promos */
  .promos { grid-auto-columns: minmax(260px, 85%); gap: 12px; }
  .promo { height: 210px; padding: 20px 22px; border-radius: 18px; }
  .promo__title { font-size: 18px; max-width: 220px; }
  .promo__thumbs { left: 22px; right: -16px; bottom: -20px; gap: 8px; }

  /* Templates grid: switch from CSS columns (masonry) to CSS grid */
  .cards { columns: initial; column-gap: initial; display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 14px; }
  .card { margin-bottom: 0; }
  .card__row { font-size: 12.5px; }
  .card__thumb::after { content: none; } /* hover-only overlay is irrelevant on touch */

  /* Editor mock */
  .editor-block { padding: 0 12px; margin-top: 36px; }
  .editor-block__inner { padding: 24px 20px; gap: 24px; border-radius: 20px; }
  .editor-mock { flex-basis: 100%; }
  .editor-mock__canvas { height: 240px; }
  .editor-mock__rail { width: 48px; }
  .editor-mock__rail-item { width: 36px; height: 36px; }
  .editor-mock__bar { height: 42px; font-size: 12px; padding: 0 12px; }
  .editor-copy { flex-basis: 100%; }
  .editor-copy__title { font-size: 24px; }
  .editor-copy__list span { font-size: 14.5px; }

  /* Features / specs */
  .features { grid-template-columns: 1fr; gap: 10px; }
  .feature { padding: 18px; border-radius: 16px; }
  .feature__title { font-size: 16px; }
  .specs { gap: 8px; }
  .spec { padding: 12px 14px; flex: 1 1 calc(50% - 4px); border-radius: 12px; }

  /* How-to */
  .how { grid-template-columns: 1fr; gap: 16px; }
  .how__step { padding-top: 14px; }

  /* SEO split */
  .seo-split { gap: 20px; }
  .seo-title { font-size: 24px; }
  .seo-text { font-size: 15px; }

  /* Directory */
  .directory { grid-template-columns: 1fr; gap: 24px; }

  /* Tips */
  .tips { grid-template-columns: 1fr 1fr; }
  .tip  { padding: 16px; }

  /* FAQ */
  .faq-wrap { padding: 40px 16px; gap: 16px; }
  .faq-wrap h2 { flex-basis: 100%; font-size: 22px; }
  .faqs { flex-basis: 100%; }
  .faq { padding: 0 16px; border-radius: 14px; }
  .faq summary { font-size: 15px; padding: 16px 0; }

  /* Footer */
  .footer { padding: 32px 16px 32px; gap: 24px; }
  .footer__grid { gap: 20px; grid-template-columns: 1fr 1fr; }
  .footer__meta { flex-direction: column; gap: 6px; text-align: center; align-items: center; }

  /* Chip (smaller on mobile) */
  .chip { font-size: 13px; padding: 6px 8px 6px 12px; }
}

/* Small phones */
@media (max-width: 480px) {
  .hero { padding: 8px 10px 0; }
  .hero__inner { padding: 28px 16px 20px; }
  .hero__title { font-size: 28px; }
  .hero--sm .hero__title { font-size: 24px; }
  .hero__text { font-size: 14.5px; }

  .section { padding-left: 12px; padding-right: 12px; padding-top: 30px; }
  .section__title { font-size: 20px; }

  .cards { grid-template-columns: repeat(2, 1fr); gap: 10px; }
  /* .formats stays stacked (see 820px rule) — don't re-override to a horizontal scroll row. */
  .format-card { min-height: 96px; padding: 0 16px; }
  .format-card__label { font-size: 15px; }
  .formats--related { grid-template-columns: 1fr 1fr; }
  .promos { grid-auto-columns: 85%; }

  .footer { padding: 28px 12px 28px; }
  .footer__grid { grid-template-columns: 1fr; }
  .faq-wrap { padding: 32px 12px; }

  .btn { font-size: 13px; padding: 0 14px; height: 38px; }
  .btn--big { height: 46px; padding: 0 20px; font-size: 14.5px; }

  .topbar__inner { padding: 0 12px; gap: 8px; }
  .topbar__cta .btn--primary { padding: 0 12px; height: 36px; font-size: 13px; }
}

/* ───────────────── Rating section (ported from appscms-tools-theme) ───────────────── */
.create-rating-section { padding: 48px 24px 24px; }
.create-rating-section .container { max-width: 1180px; margin: 0 auto; }
.create-rating-section .row { display: flex; justify-content: center; }
.create-rating-section .col-md-9 { width: 100%; max-width: 820px; text-align: center; }

.create-rating-section .rating-tool {
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  background: #fcfcfc; box-shadow: 0 3px 14px rgba(16, 24, 40, 0.08);
  border-radius: 24px; padding: 36px 28px; margin: 20px 0;
}
.create-rating-section .rating-header { text-align: center; margin-bottom: 12px; }
.create-rating-section .rating-text {
  font-family: 'DM Serif Display', serif;
  font-size: 28px; font-weight: 400; color: #212121; margin: 0 0 6px;
}
.create-rating-section .rating-description { font-size: 14.5px; color: var(--muted); margin: 0; }
.create-rating-section .rating-stars {
  display: flex; align-items: center; justify-content: center; gap: 8px; margin: 20px 0 12px;
}
.create-rating-section .rating-star { cursor: pointer; transition: fill .15s, transform .12s; }
.create-rating-section .rating-star:hover { transform: scale(1.1); }
.create-rating-section .rating-value {
  font-size: 15px; color: #212121; margin-top: 4px;
}
.create-rating-section .rating-value .rating { font-size: 18px; font-weight: 600; }
.create-rating-section .rating-value .total-ratings { font-weight: 600; }

.create-rating-section .feedback-btn {
  background: var(--accent); color: #fff; border: 0; cursor: pointer;
  padding: 12px 28px; border-radius: 10px; font-size: 15px; font-weight: 600;
  margin-top: 20px; transition: background .15s, transform .12s;
}
.create-rating-section .feedback-btn:hover { background: var(--accent-dark); transform: translateY(-1px); }

/* Modal + form */
.create-rating-section .modal-overlay {
  position: fixed; inset: 0; background: rgba(0,0,0,0.5); backdrop-filter: blur(5px);
  display: none; align-items: center; justify-content: center; z-index: 1000;
}
.create-rating-section .feedbackModal {
  background: #fff; border-radius: 14px; width: 90%; max-width: 500px;
  box-shadow: 0 25px 60px rgba(0,0,0,0.25); overflow: hidden; animation: cr-slideIn 0.25s ease-out;
}
@keyframes cr-slideIn { from { opacity: 0; transform: translateY(-24px);} to { opacity: 1; transform: translateY(0);} }
.create-rating-section .modal-header {
  padding: 18px 24px; border-bottom: 1px solid var(--line);
  display: flex; justify-content: space-between; align-items: center;
}
.create-rating-section .modal-title { font-size: 18px; font-weight: 600; margin: 0; color: var(--fg); }
.create-rating-section .close-button {
  width: 32px; height: 32px; border-radius: 50%; border: 0; background: transparent;
  font-size: 22px; cursor: pointer; display: flex; align-items: center; justify-content: center;
  color: var(--muted);
}
.create-rating-section .close-button:hover { background: #F1F2F6; color: var(--fg); }
.create-rating-section .modal-body { padding: 22px 24px; }
.create-rating-section .form-group { margin-bottom: 16px; text-align: left; }
.create-rating-section .form-label {
  display: block; margin-bottom: 6px; font-weight: 500; color: #2d3748; font-size: 14px;
}
.create-rating-section .form-input {
  width: 100%; padding: 11px 14px; border: 1px solid #E2E8F0; border-radius: 8px;
  font-size: 14.5px; color: #2d3748; box-sizing: border-box; font-family: inherit;
  transition: border-color .15s, box-shadow .15s;
}
.create-rating-section .form-input:focus {
  outline: none; border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(27, 46, 231, 0.18);
}
.create-rating-section .modal-footer {
  padding: 14px 24px 20px; text-align: right; display: flex; gap: 10px; justify-content: flex-end;
}
.create-rating-section .btn-primary,
.create-rating-section .btn-secondary {
  padding: 9px 18px; border-radius: 8px; border: 0; cursor: pointer;
  font-size: 14px; font-weight: 600;
}
.create-rating-section .btn-primary { background: var(--accent); color: #fff; }
.create-rating-section .btn-primary:hover { background: var(--accent-dark); }
.create-rating-section .btn-secondary { background: #F1F2F6; color: var(--fg); }
.create-rating-section .btn-secondary:hover { background: #E4E6EE; }

.create-rating-section .thank-you {
  display: none; text-align: center; padding: 36px 24px; background: #fff; border-radius: 14px;
  width: 90%; max-width: 500px; animation: cr-slideIn 0.25s ease-out;
}
.create-rating-section .thank-you-icon {
  width: 56px; height: 56px; border-radius: 50%; background: #48BB78; color: #fff;
  display: flex; align-items: center; justify-content: center; font-size: 28px;
  margin: 0 auto 16px;
}
.create-rating-section .thank-you-title { font-weight: 600; font-size: 20px; margin: 0 0 6px; color: var(--fg); }
.create-rating-section .thank-you-message { color: var(--muted); font-size: 14.5px; margin: 0 0 20px; }

@media (max-width: 820px) {
  .create-rating-section { padding: 32px 16px 16px; }
  .create-rating-section .rating-tool { padding: 28px 20px; border-radius: 20px; }
  .create-rating-section .rating-text { font-size: 24px; }
  .create-rating-section .rating-star { width: 32px; height: 32px; }
}

/* ───────────────── Trustpilot section ───────────────── */
.tp-wrap { padding: 64px 44px 32px; }
.tp-inner { max-width: 1180px; margin: 0 auto; text-align: center; }

/* Compact green badge: TrustScore word + stars + numeric rating + count */
.tp-badge {
  display: inline-flex; align-items: center; gap: 12px;
  padding: 10px 18px; border-radius: 999px;
  background: #F0FBF6; border: 1px solid #CDEBD9; color: #1F2937;
  font-size: 14px; font-weight: 500; flex-wrap: wrap;
  justify-content: center;
}
.tp-word { color: #00B67A; font-weight: 700; letter-spacing: 0.01em; }
.tp-stars { display: inline-flex; gap: 2px; }
.tp-star { display: block; }
.tp-score { color: #5F6472; }
.tp-score strong { color: #121317; font-weight: 700; }

.tp-title {
  font-family: 'DM Serif Display', serif;
  font-size: clamp(28px, 3.4vw, 40px); letter-spacing: -0.015em;
  color: var(--fg); margin: 20px auto 10px; max-width: 760px; text-wrap: balance;
  line-height: 1.15;
}
.tp-desc { color: var(--muted); font-size: 15.5px; line-height: 1.55; max-width: 640px; margin: 0 auto 32px; text-wrap: pretty; }

.tp-grid {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 20px; margin: 28px 0 36px; text-align: left;
}
.tp-card {
  display: block; padding: 24px; border: 1px solid var(--line); border-radius: 20px;
  background: #fff; text-decoration: none; color: inherit;
  transition: transform .15s ease, border-color .15s ease, box-shadow .15s ease;
}
.tp-card:hover { transform: translateY(-3px); border-color: #CDEBD9; box-shadow: 0 10px 28px rgba(0, 182, 122, 0.08); color: inherit; }
.tp-card__stars { display: flex; align-items: center; gap: 2px; margin-bottom: 14px; }
.tp-verified {
  display: inline-flex; align-items: center; gap: 4px;
  margin-left: auto; font-size: 12px; font-weight: 600; color: #00B67A;
}
.tp-card__title { font-weight: 700; font-size: 16px; color: var(--fg); margin-bottom: 8px; }
.tp-card__text { font-size: 14.5px; color: var(--muted); line-height: 1.6; margin: 0 0 14px; }
.tp-card__meta { display: flex; gap: 6px; font-size: 13px; color: #8A8E99; }
.tp-card__name { font-weight: 600; color: #5F6472; }

.tp-cta {
  display: inline-flex; align-items: center; gap: 10px;
  padding: 12px 22px; border-radius: 999px;
  background: #121317; color: #fff;
  font-size: 15px; font-weight: 600; text-decoration: none;
  box-shadow: 0 6px 20px rgba(0, 182, 122, 0.15);
  transition: transform .15s, background .15s;
}
.tp-cta:hover { transform: translateY(-1px); background: #000; color: #fff; }
.tp-cta__text { opacity: 0.9; }
.tp-cta__logo path:first-child { fill: #fff; }
.tp-cta__arrow { display: inline-flex; opacity: 0.9; }

@media (max-width: 820px) {
  .tp-wrap { padding: 44px 20px 20px; }
  .tp-badge { padding: 8px 14px; gap: 8px; font-size: 13px; }
  .tp-star { width: 18px; height: 18px; }
  .tp-grid { gap: 14px; margin: 22px 0 28px; }
  .tp-card { padding: 20px; border-radius: 16px; }
  .section__head--end .create-rating { display: none; }
}

/* ───────────────── Template-card chips (resume maker) ───────────────── */
.card__chips {
  display: flex; flex-wrap: wrap; gap: 4px;
  padding: 0 12px 12px;
}
.card__chip {
  display: inline-flex; align-items: center; gap: 4px;
  padding: 2px 8px; border-radius: 999px;
  font-size: 10.5px; font-weight: 600; letter-spacing: 0.01em;
  background: #F6F7FA; color: #475569;
  border: 1px solid var(--line);
  white-space: nowrap;
  line-height: 1.6;
}
.card__chip--style { background: #EEF0FE; color: var(--accent-dark); border-color: #D6DAFF; }
.card__chip--ats   { background: #DCF6EA; color: #0F7A3F;          border-color: #AEE9CE; }
.card__chip--color { background: #FFFFFF; color: #334155;          padding-left: 6px; }
.card__chip-dot {
  width: 10px; height: 10px; border-radius: 50%;
  border: 1px solid rgba(15, 23, 42, 0.12);
  flex: none;
}
/* Chip dot colour map — mirrors the color-filter buckets. */
.card__chip--color[data-color="Black"]  .card__chip-dot { background: #111827; }
.card__chip--color[data-color="Blue"]   .card__chip-dot { background: #2563EB; }
.card__chip--color[data-color="Navy"]   .card__chip-dot { background: #1E293B; }
.card__chip--color[data-color="Sky"]    .card__chip-dot { background: #0EA5E9; }
.card__chip--color[data-color="Mint"]   .card__chip-dot { background: #86EFAC; }
.card__chip--color[data-color="Coral"]  .card__chip-dot { background: #FB7185; }
.card__chip--color[data-color="Yellow"] .card__chip-dot { background: #FACC15; }
.card__chip--color[data-color="Cream"]  .card__chip-dot { background: #FEF3C7; }
.card__chip--color[data-color="White"]  .card__chip-dot { background: #F8FAFC; }

@media (max-width: 480px) {
  .card__chips { gap: 3px; padding: 0 10px 10px; }
  .card__chip  { font-size: 10px; padding: 2px 7px; }
  /* On very small screens, hide the color chip and keep style + ATS for signal. */
  .card__chip--color { display: none; }
}
