/*
 * Studio editor. One column, one area at a time.
 * The tab bar picks an area; inside Homepage sections a picker shows one
 * section at a time, with its words first and its background second.
 */
:root {
  color-scheme: dark;
  --accent: #ff2587;
  --accent-strong: #e0106c; /* pink behind white text: passes the 4.5:1 contrast rule */
  --ink: #fff;
  --muted: #a9aab4;
  --line: #ffffff24;
  --field: #08080b;
  --panel: #141419;
  --page: #09090c;
  font-family: Arial, Helvetica, sans-serif;
  background: var(--page);
  color: var(--ink);
}
* { box-sizing: border-box; }
body { margin: 0; }
[hidden] { display: none !important; }
a { color: inherit; text-underline-offset: 4px; }
p { line-height: 1.55; color: #bfc0ca; }
h1, h2 { font-style: italic; font-family: Arial, 'Helvetica Neue', system-ui, sans-serif; }
h1 { font-size: clamp(30px, 4.5vw, 48px); font-weight: 800; letter-spacing: -.05em; margin: 0 0 6px; }
h2 { font-size: 22px; margin: 0 0 12px; }
small { display: block; margin-top: 3px; color: var(--muted); font-size: 12px; font-weight: 400; }
.eyebrow { margin: 0 0 6px; text-transform: uppercase; font-size: 11px; letter-spacing: .15em; color: var(--accent); }
.visually-hidden { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* ---------- Header + tab bar (stays at the top) ---------- */
.admin-header {
  position: sticky;
  top: 0;
  z-index: 20;
  background: rgba(9, 9, 12, .94);
  -webkit-backdrop-filter: blur(12px);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--line);
}
.admin-header-bar { display: flex; align-items: center; gap: 16px; max-width: 900px; margin: 0 auto; padding: 14px 20px; }
.admin-brand { font-weight: 900; letter-spacing: -1px; text-decoration: none; }
.admin-header-label { color: var(--muted); font-size: 13px; }
.admin-open-site { margin-left: auto; }
.admin-header form { margin: 0; }
.admin-header:not(:has(.admin-open-site)) form { margin-left: auto; }
.admin-tabs {
  display: flex;
  gap: 4px;
  max-width: 900px;
  margin: 0 auto;
  padding: 0 14px 10px;
  overflow-x: auto;
  scrollbar-width: none;
}
.admin-tabs::-webkit-scrollbar { display: none; }
.admin-tabs a {
  flex: none;
  padding: 9px 13px;
  border-radius: 999px;
  color: #cfd0d8;
  font-size: 13px;
  font-weight: 600;
  text-decoration: none;
  white-space: nowrap;
}
.admin-tabs a:hover { background: #ffffff12; color: #fff; }
.admin-tabs a[aria-current] { background: var(--accent-strong); color: #fff; }

/* ---------- Page ---------- */
main { max-width: 900px; margin: 0 auto; padding: 28px 20px 120px; }
.area-head { margin-bottom: 22px; }
.area-head p { margin: 0; }
body:not(.is-one-at-a-time) .admin-area { padding-bottom: 60px; margin-bottom: 60px; border-bottom: 1px solid var(--line); }

.notice { padding: 14px 16px; margin: 0 0 20px; background: #163d30; border-radius: 10px; color: #fff; }
.notice.error { background: #18181e; border: 1px solid #ff258780; box-shadow: inset 4px 0 0 #ff2587; }

/* ---------- Fields ---------- */
.field-group {
  margin: 0 0 18px;
  padding: 18px 20px 20px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: var(--panel);
  min-width: 0;
}
fieldset.field-group legend { padding: 0 8px; margin-left: -8px; font-weight: 700; font-size: 13px; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); }
.field-group > h2:first-child { margin-top: 0; }
.field-note { margin: 0 0 12px; font-size: 13px; color: var(--muted); }
.designed-note { margin: 0 0 18px; padding: 14px 16px; border: 1px dashed var(--line); border-radius: 12px; }
.designed-note a { color: var(--accent); }
label { display: block; margin: 14px 0 0; font-size: 14px; font-weight: 600; }
.field-group > label:first-of-type, .field-note + label { margin-top: 4px; }
input:not([type=color]):not([type=checkbox]):not([type=radio]), textarea, select {
  display: block;
  width: 100%;
  margin-top: 8px;
  padding: 12px;
  border: 1px solid #ffffff40;
  border-radius: 8px;
  background: var(--field);
  color: #fff;
  font: 400 16px/1.4 Arial, sans-serif; /* 16px stops iOS zooming into fields */
}
textarea { resize: vertical; min-height: 52px; }
input[type=file] { padding: 10px; font-size: 13px; }
.field-pair { display: grid; grid-template-columns: 1fr 1fr; gap: 0 16px; }
.check-row { display: flex; align-items: center; gap: 10px; min-height: 44px; font-weight: 400; }
.check-row input { width: 20px; height: 20px; margin: 0; accent-color: var(--accent); }
.sub-title { margin: 26px 0 0; font-size: 16px; font-style: normal; color: var(--muted); }
.tag { color: #fff; background: #ff258733; padding: 1px 6px; border-radius: 4px; letter-spacing: .05em; }

/* ---------- Buttons ---------- */
button, .button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  padding: 10px 16px;
  border: 1px solid #ffffff40;
  border-radius: 8px;
  background: transparent;
  color: #fff;
  font: 600 14px Arial, sans-serif;
  cursor: pointer;
  text-decoration: none;
}
.primary { background: var(--accent-strong); border-color: var(--accent-strong); }
button:hover, .button:hover { filter: brightness(1.15); }
button:disabled { opacity: .6; cursor: progress; }
:is(button, a, input, select, textarea):focus-visible { outline: 2px solid #fff; outline-offset: 3px; }
.save-bar { display: flex; flex-wrap: wrap; align-items: center; gap: 12px; margin-top: 20px; }
.save-bar a { font-size: 13px; }
.save-status { font-size: 13px; color: var(--muted); }

/* ---------- Homepage sections ---------- */
.section-picker {
  position: sticky;
  top: calc(var(--header-height, 108px) + 8px);
  z-index: 10;
  display: grid;
  grid-template-columns: 48px 1fr 48px;
  gap: 8px;
  margin: 0 0 20px;
  padding: 8px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: #16161b;
  box-shadow: 0 12px 30px rgba(0,0,0,.4);
}
.section-picker select { margin: 0; height: 48px; font-weight: 700; }
.picker-select { margin: 0; }
.picker-step { padding: 0; height: 48px; font-size: 20px; }
.section-editor-head {
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: end;
  gap: 4px 16px;
  margin-bottom: 16px;
}
.section-editor-head .eyebrow { grid-column: 1 / -1; }
.section-editor-head h2 { margin: 0; font-size: clamp(24px, 3.4vw, 34px); letter-spacing: -.03em; line-height: 1.1; }
.view-link { font-size: 13px; color: var(--muted); white-space: nowrap; }
.is-hidden-section .section-editor-head h2 { opacity: .5; text-decoration: line-through; }
.section-editor .save-bar {
  position: sticky;
  bottom: 0;
  z-index: 5;
  margin: 0 -20px;
  padding: 14px 20px calc(14px + env(safe-area-inset-bottom));
  background: linear-gradient(180deg, rgba(9,9,12,0), var(--page) 30%);
}
body:not(.is-one-at-a-time) .section-editor { margin-bottom: 40px; }

.current-media { display: flex; gap: 14px; align-items: center; margin: 4px 0 8px; }
.current-media :is(video, img) { width: 160px; aspect-ratio: 16 / 9; object-fit: cover; border-radius: 10px; border: 1px solid var(--line); background: #050507; }
.current-media p { margin: 0; display: grid; gap: 4px; color: #fff; font-size: 13px; min-width: 0; }
.current-media span { color: var(--muted); font: 11px monospace; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

/* ---------- Website builds ---------- */
.list-title { margin: 30px 0 14px; font-size: 18px; font-style: normal; color: var(--muted); }
.sitework-list { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; }
.sitework-row { display: grid; grid-template-columns: 96px 1fr; gap: 14px; margin: 0; padding: 12px; border: 1px solid var(--line); border-radius: 14px; background: var(--panel); }
.sitework-row img { width: 96px; aspect-ratio: 3 / 4; object-fit: cover; object-position: top; border-radius: 8px; background: #000; }
.sitework-fields { min-width: 0; }
.sitework-fields label { margin-top: 6px; font-size: 12px; }
.sitework-fields input { padding: 9px 10px; margin-top: 4px; font-size: 14px; }
.sitework-actions { display: flex; gap: 8px; margin-top: 10px; }
.sitework-actions button { min-height: 38px; padding: 6px 12px; font-size: 13px; }

/* ---------- Colours ---------- */
.colour-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 14px; margin-top: 8px; }
.colour-grid label { display: grid; gap: 8px; font-size: 13px; }
.colour-grid input { width: 100%; height: 48px; padding: 0; border: 0; background: none; }
.colour-grid output { font: 12px monospace; color: var(--muted); }
#preview-status { font-size: 13px; color: var(--muted); }
.preview { height: 560px; overflow: hidden; border: 1px solid #ffffff30; border-radius: 16px; background: #050507; }
.preview iframe { width: 100%; height: 100%; border: 0; }

/* ---------- Movement, logo, projects ---------- */
.navigation-options { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.navigation-option { display: flex; align-items: flex-start; gap: 12px; margin: 0; padding: 16px; border: 1px solid #ffffff30; border-radius: 12px; cursor: pointer; }
.navigation-option:has(input:checked) { border-color: var(--accent); background: #ff25870d; }
.navigation-option input { margin: 3px 0 0; accent-color: var(--accent); }
.navigation-option strong, .navigation-option small { display: block; }
.navigation-option small { margin-top: 6px; font-size: 13px; }
.current-logo img { max-height: 60px; max-width: 240px; }
.project-edit { padding: 16px 0; border-top: 1px solid var(--line); }
.project-edit:first-of-type { border-top: 0; padding-top: 0; }

/* ---------- Visitors ---------- */
.analytics-date-form { display: flex; align-items: flex-end; gap: 10px; margin-bottom: 14px; }
.analytics-date-form label { flex: 1 1 auto; min-width: 0; margin: 0; }
.analytics-date-form button { flex: none; }
.analytics-empty { color: #9999a2; }
.analytics-total { font-size: 15px; margin: 0 0 14px; }
.analytics-total strong { font-size: 22px; color: var(--accent); }
.analytics-subhead { font-size: 12px; letter-spacing: .08em; text-transform: uppercase; color: #9999a2; margin: 18px 0 8px; }
.analytics-pages { display: grid; gap: 6px; }
.analytics-row { display: grid; grid-template-columns: minmax(90px,1fr) minmax(60px,2fr) 30px; align-items: center; gap: 8px; font-size: 13px; }
.analytics-row-label { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.analytics-row-bar { height: 10px; border-radius: 6px; background: #1c1c21; overflow: hidden; }
.analytics-row-bar i { display: block; height: 100%; background: var(--accent); border-radius: 6px; }
.analytics-row-count { text-align: right; color: #cfcfd6; }
.analytics-hour-grid { display: grid; grid-template-columns: repeat(24, 1fr); align-items: end; gap: 2px; height: 70px; background: #101014; border-radius: 8px; padding: 6px 4px; }
.analytics-hour { display: flex; align-items: flex-end; height: 100%; }
.analytics-hour i { display: block; width: 100%; min-height: 2px; background: var(--accent); border-radius: 2px 2px 0 0; opacity: .85; }
.analytics-note { margin-top: 14px; font-size: 12px; color: var(--muted); }

/* ---------- Sign in ---------- */
.login { max-width: 460px; margin: 8vh auto; }
.login button { width: 100%; margin-top: 16px; }

/* ---------- Phones ---------- */
@media (max-width: 700px) {
  .admin-header-bar { padding: 10px 16px; gap: 10px; }
  .admin-header-label { display: none; }
  .admin-open-site, .admin-header button { min-height: 38px; padding: 6px 12px; font-size: 13px; }
  main { padding: 20px 14px 120px; }
  .field-group { padding: 16px 14px 18px; }
  .section-editor .save-bar { margin: 0 -14px; padding-inline: 14px; }
  .section-picker { grid-template-columns: 44px 1fr 44px; }
  .field-pair, .navigation-options, .sitework-list { grid-template-columns: 1fr; }
  .colour-grid { grid-template-columns: 1fr 1fr; }
  .section-editor-head { grid-template-columns: 1fr; }
  .current-media :is(video, img) { width: 120px; }
  .preview { height: 480px; }
}
@media (prefers-reduced-motion: reduce) {
  * { scroll-behavior: auto !important; }
}

/* Build folders found in /websites/ that still need a screenshot. */
.sitework-row.is-auto { border-style: dashed; border-color: #ff258766; }
.sitework-missing { display: flex; align-items: center; justify-content: center; width: 96px; aspect-ratio: 3 / 4; padding: 8px; border-radius: 8px; background: #08080b; color: var(--muted); font-size: 11px; text-align: center; }
.field-note code, .area-head code { color: #fff; }
.area-head a { color: var(--accent); }
.sitework-actions { flex-wrap: wrap; }
.hidden-folders { display: grid; gap: 8px; }
.hidden-folder { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 10px 14px; border: 1px dashed var(--line); border-radius: 10px; font: 13px monospace; color: var(--muted); }
.hidden-folder button { min-height: 36px; font-size: 13px; }
.sitework-row.is-pinned { border: 1px solid var(--accent); box-shadow: 0 0 0 1px var(--accent) inset; }

/* =====================================================================
   Studio editor v2 — grouped menu, dashboard and the new areas.
   Phones and tablets: a "Menu" button opens the area list as a sheet.
   Wide screens (1100px+): the same list sits as a sidebar.
   ===================================================================== */

/* ---------- Header ---------- */
.admin-header-bar { max-width: none; }
.admin-menu-button {
  display: inline-flex; gap: 10px; min-width: 0; max-width: 46vw;
  padding: 8px 14px; border-radius: 999px; background: #ffffff10;
}
.admin-menu-button [data-current-area] { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.admin-menu-icon { display: grid; gap: 3px; flex: none; width: 16px; }
.admin-menu-icon i { display: block; height: 2px; border-radius: 2px; background: currentColor; }
.admin-open-site { margin-left: auto; }
.narrow-only { display: none; }

/* ---------- The area list (sheet on small screens) ---------- */
.admin-tabs {
  position: fixed; inset: 0 0 0 auto; z-index: 40;
  display: block; width: min(380px, 100%); max-width: none; margin: 0;
  padding: 0 0 calc(24px + env(safe-area-inset-bottom));
  overflow-y: auto; overscroll-behavior: contain;
  background: #0d0d11; border-left: 1px solid var(--line);
  transform: translateX(102%); visibility: hidden;
  transition: transform .32s cubic-bezier(.2,.8,.2,1), visibility 0s linear .32s;
}
.admin-tabs.is-open { transform: none; visibility: visible; transition: transform .32s cubic-bezier(.2,.8,.2,1); }
.admin-nav-backdrop { position: fixed; inset: 0; z-index: 35; background: rgba(0,0,0,.6); }
.admin-nav-head {
  position: sticky; top: 0; z-index: 1; display: flex; align-items: center; justify-content: space-between;
  padding: 14px 16px 14px 20px; background: #0d0d11; border-bottom: 1px solid var(--line);
}
.admin-nav-close { min-height: 44px; width: 44px; padding: 0; font-size: 26px; line-height: 1; border-radius: 50%; }
.admin-nav-group { padding: 14px 12px 4px; }
.admin-nav-title { margin: 0 8px 6px; font-size: 11px; letter-spacing: .14em; text-transform: uppercase; color: var(--accent); }
.admin-tabs a {
  display: grid; gap: 2px; padding: 11px 12px; border-radius: 12px;
  color: #fff; font-size: 15px; white-space: normal; text-decoration: none;
}
.admin-tabs a small { margin: 0; font-size: 12px; color: var(--muted); }
.admin-tabs a:hover { background: #ffffff0f; }
.admin-tabs a[aria-current] { background: #ff258722; box-shadow: inset 3px 0 0 var(--accent); color: #fff; }
.admin-tabs a[aria-current] small { color: #e7c3d4; }
.admin-nav-signout { padding: 16px 20px 0; }
.admin-nav-signout button { width: 100%; }
body.menu-open { overflow: hidden; }

@media (min-width: 1100px) {
  .admin-menu-button, .admin-nav-head, .admin-nav-backdrop, .admin-nav-signout { display: none !important; }
  .admin-tabs {
    top: var(--header-height, 64px); inset-inline: 0 auto; width: 270px;
    transform: none; visibility: visible; transition: none;
    border-left: 0; border-right: 1px solid var(--line); background: var(--page);
  }
  body.is-signed-in main { padding-left: 290px; }
  body.is-signed-in main { max-width: calc(900px + 290px); margin: 0; }
}

/* ---------- Phones ---------- */
@media (max-width: 700px) {
  .admin-header-bar { gap: 8px; padding: 10px 12px; }
  .admin-brand { font-size: 15px; }
  .admin-signout { display: none; }
  .wide-only { display: none; }
  .narrow-only { display: inline; }
  .admin-menu-button { order: 3; }
  .admin-open-site { order: 2; margin-left: auto; }
  .admin-menu-button, .admin-open-site { min-height: 40px; }
  h1 { font-size: 30px; }
  .area-head p { font-size: 15px; }
  /* Every save button stays in reach of a thumb. */
  form[data-save-form] > .save-bar, .seo-form > .save-bar {
    position: sticky; bottom: 0; z-index: 5; margin: 18px -14px -18px; padding: 12px 14px calc(12px + env(safe-area-inset-bottom));
    background: linear-gradient(180deg, rgba(20,20,25,0), #141419 28%); border-radius: 0 0 14px 14px;
  }
  form[data-save-form] > .save-bar .primary { flex: 1 1 auto; }
  .sitework-row { grid-template-columns: 72px 1fr; gap: 12px; }
  .sitework-row img, .sitework-missing { width: 72px; }
  .analytics-date-form { flex-wrap: wrap; }
  .analytics-date-form button { width: 100%; }
}
@media (prefers-reduced-motion: reduce) { .admin-tabs { transition: none !important; } }

/* ---------- Dashboard ---------- */
.dash-stats { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 10px; margin-bottom: 18px; }
.dash-stat {
  display: grid; gap: 4px; padding: 16px; border: 1px solid var(--line); border-radius: 14px;
  background: var(--panel); text-decoration: none;
}
.dash-stat strong { font-size: 30px; line-height: 1; letter-spacing: -.03em; color: #fff; }
.dash-stat span { font-size: 13px; color: var(--muted); }
.dash-stat:hover { border-color: var(--accent); }
.dash-bars { display: grid; grid-template-columns: repeat(7, 1fr); gap: 8px; height: 150px; align-items: end; }
.dash-bar { display: grid; grid-template-rows: auto 1fr auto; height: 100%; text-align: center; font-size: 12px; color: var(--muted); }
.dash-bar i { align-self: end; display: block; width: 100%; min-height: 0; background: var(--accent); border-radius: 6px 6px 2px 2px; }
.dash-bar-count { color: #fff; font-weight: 700; margin-bottom: 4px; }
.dash-bar-day { margin-top: 6px; }
.dash-actions { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 10px; margin-bottom: 18px; }
.dash-actions a {
  display: grid; gap: 4px; padding: 16px; min-height: 84px; border-radius: 14px; text-decoration: none;
  background: var(--panel); border: 1px solid var(--line); border-left: 3px solid var(--accent);
}
.dash-actions strong { color: #fff; font-size: 15px; }
.dash-actions span { color: var(--muted); font-size: 13px; }
.dash-actions a:hover { background: #1a1a20; }
.dash-latest h2 { margin-bottom: 4px; }
@media (max-width: 700px) {
  .dash-stats { grid-template-columns: 1fr 1fr; }
  .dash-actions { grid-template-columns: 1fr 1fr; }
  .dash-stat strong { font-size: 26px; }
  .dash-bars { height: 120px; gap: 5px; }
}

/* ---------- Health list ---------- */
.health-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.health-list li {
  display: grid; gap: 2px; padding: 12px 14px 12px 40px; position: relative;
  border-radius: 10px; background: #0f0f13; border: 1px solid var(--line);
}
.health-list li::before {
  content: ''; position: absolute; left: 14px; top: 16px; width: 12px; height: 12px; border-radius: 50%;
}
.health-list .is-ok::before { background: #2fbf71; }
.health-list .is-warn::before { background: #f5a524; }
.health-list .is-bad::before { background: #ff4d4f; }
.health-list .is-bad { border-color: #ff4d4f66; }
.health-list strong { color: #fff; font-size: 14px; }
.health-list span { color: var(--muted); font-size: 13px; line-height: 1.45; }
.server-facts { display: grid; gap: 8px; margin: 0; }
.server-facts div { display: flex; justify-content: space-between; gap: 12px; padding: 8px 0; border-bottom: 1px solid var(--line); font-size: 14px; }
.server-facts dt { color: var(--muted); }
.server-facts dd { margin: 0; text-align: right; }

/* ---------- FAQ editor ---------- */
.faq-rows { list-style: none; margin: 0; padding: 0; display: grid; gap: 12px; }
.faq-row { padding: 14px; border: 1px solid var(--line); border-radius: 12px; background: #0f0f13; }
.faq-row.is-page-only { border-style: dashed; }
.faq-row[data-faq-blank] { border-color: #ff258766; border-style: dashed; }
.faq-row label:first-of-type { margin-top: 8px; }
.faq-row-head { display: flex; align-items: center; gap: 10px; }
.faq-row-number { font: 700 12px monospace; color: var(--accent); }
.faq-row-where { font-size: 12px; color: var(--muted); }
.faq-row-move { display: flex; gap: 6px; margin-left: auto; }
.faq-row-move button { min-height: 36px; width: 40px; padding: 0; font-size: 16px; }
[data-count-for] { display: inline; margin-left: 6px; }
[data-count-for].is-over { color: #f5a524; }

/* ---------- Pages & SEO ---------- */
.seo-filter { margin-bottom: 12px; }
.seo-page { border: 1px solid var(--line); border-radius: 12px; background: #0f0f13; margin-top: 8px; }
.seo-page summary {
  display: flex; align-items: baseline; justify-content: space-between; gap: 10px;
  padding: 14px; min-height: 48px; cursor: pointer; list-style: none; font-weight: 700;
}
.seo-page summary::-webkit-details-marker { display: none; }
.seo-page summary small { margin: 0; font-weight: 400; text-align: right; }
.seo-page[data-edited] summary small { color: var(--accent); }
.seo-page[open] { border-color: #ffffff40; }
.seo-page > :not(summary) { margin-inline: 14px; }
.seo-page > .view-link { display: inline-block; margin: 12px 14px 16px; }
.serp { display: grid; gap: 3px; padding: 14px; border-radius: 10px; background: #fff; font-family: Arial, sans-serif; }
.serp-url { color: #202124; font-size: 12px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.serp-title { color: #1a0dab; font-size: 18px; line-height: 1.3; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.serp-desc { color: #4d5156; font-size: 13px; line-height: 1.5; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.seo-page input::placeholder, .seo-page textarea::placeholder { color: #6e6e78; }

/* ---------- Redirects ---------- */
.count-pill { display: inline-block; min-width: 26px; padding: 2px 8px; border-radius: 999px; background: var(--accent-strong); color: #fff; font: 700 13px Arial, sans-serif; font-style: normal; text-align: center; vertical-align: 3px; }
.missing-list, .redirect-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.missing-item { display: grid; gap: 10px; padding: 14px; border: 1px solid var(--line); border-radius: 12px; background: #0f0f13; }
.missing-info { display: grid; gap: 4px; min-width: 0; }
.missing-info code, .redirect-path code { color: #fff; font-size: 14px; overflow-wrap: anywhere; }
.missing-info span { color: var(--muted); font-size: 12px; }
.missing-fix input { margin-top: 0; }
.missing-buttons { display: flex; gap: 8px; margin-top: 8px; }
.missing-buttons .primary { flex: 1 1 auto; }
.redirect-list li { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 12px 14px; border: 1px solid var(--line); border-radius: 12px; background: #0f0f13; }
.redirect-path { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; min-width: 0; }
.redirect-path i { color: var(--accent); font-style: normal; }
.redirect-list form { margin: 0; flex: none; }
@media (min-width: 701px) {
  .missing-item { grid-template-columns: minmax(0, 1fr) minmax(0, 1.2fr); align-items: center; }
}

/* ---------- Homepage cache switch (always in the header) ---------- */
.admin-header .admin-cache-toggle { margin: 0 0 0 auto; }
.admin-cache-toggle + .admin-open-site { margin-left: 0; }
.cache-pill { gap: 8px; border-radius: 999px; white-space: nowrap; }
.cache-pill i { width: 10px; height: 10px; border-radius: 50%; background: #6e6e78; box-shadow: 0 0 0 3px #6e6e7833; }
.cache-pill.is-on { border-color: #2fbf71; background: #2fbf711f; }
.cache-pill.is-on i { background: #2fbf71; box-shadow: 0 0 0 3px #2fbf7140; }
@media (max-width: 700px) {
  .admin-cache-toggle { order: 2; }
  .admin-open-site { order: 2; margin-left: 0; }
  .cache-pill { min-height: 40px; padding: 6px 11px; font-size: 13px; }
  .admin-brand { max-width: 28vw; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
}
@media (max-width: 380px) {
  .admin-open-site { display: none; }
}

/* ---------- Undo list and sign-ins ---------- */
.version-list, .signin-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.version-list li { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 10px 12px 10px 14px; border: 1px solid var(--line); border-radius: 12px; background: #0f0f13; }
.version-list li > span { display: grid; gap: 2px; min-width: 0; }
.version-list strong { font-size: 14px; color: #fff; }
.version-list small { margin: 0; }
.version-list form { margin: 0; flex: none; }
.version-list button { min-height: 40px; }
.signin-list li { display: grid; gap: 2px; padding: 10px 14px 10px 36px; position: relative; border-radius: 10px; background: #0f0f13; border: 1px solid var(--line); }
.signin-list li::before { content: ''; position: absolute; left: 14px; top: 15px; width: 10px; height: 10px; border-radius: 50%; }
.signin-list .is-ok::before { background: #2fbf71; }
.signin-list .is-bad::before { background: #ff4d4f; }
.signin-list strong { font-size: 14px; color: #fff; }
.signin-list span { font-size: 12px; color: var(--muted); }

/* ---------- Gallery manager ---------- */
.gallery-manage-tools { display: grid; grid-template-columns: 2fr 1fr; gap: 0 12px; margin-bottom: 14px; }
.gallery-manage-grid { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 10px; }
.gallery-piece { display: grid; gap: 4px; align-content: start; padding: 8px; border: 1px solid var(--line); border-radius: 12px; background: #0f0f13; min-width: 0; }
.gallery-piece.is-hidden { border-style: dashed; }
.gallery-piece.is-hidden .gallery-piece-thumb img { opacity: .35; }
.gallery-piece-thumb { position: relative; display: grid; place-items: center; aspect-ratio: 4 / 3; overflow: hidden; border-radius: 8px; background: #050507; color: var(--muted); font-size: 12px; }
.gallery-piece-thumb img { width: 100%; height: 100%; object-fit: cover; }
.gallery-piece-thumb em, .gallery-piece-thumb b { position: absolute; top: 6px; padding: 2px 7px; border-radius: 999px; font: 700 10px Arial, sans-serif; font-style: normal; letter-spacing: .05em; text-transform: uppercase; }
.gallery-piece-thumb em { left: 6px; background: #000000b0; color: #fff; }
.gallery-piece-thumb b { right: 6px; background: var(--accent-strong); color: #fff; }
.gallery-piece-name { font-size: 13px; font-weight: 700; color: #fff; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.gallery-piece-cat { font-size: 11px; color: var(--muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.gallery-piece-actions { display: grid; grid-template-columns: 1fr 1fr; gap: 6px; margin-top: 4px; }
.gallery-piece-actions button { min-height: 38px; padding: 6px; font-size: 13px; }
.is-danger { border-color: #ff4d4f80; color: #ffb3b4; }
.is-danger:hover { background: #ff4d4f22; }
@media (max-width: 700px) {
  .gallery-manage-grid { grid-template-columns: 1fr 1fr; gap: 8px; }
  .gallery-manage-tools { grid-template-columns: 1fr; }
}

/* ---------- Website builds: save all ---------- */
.builds-save-all {
  position: sticky; top: calc(var(--header-height, 64px) + 8px); z-index: 8;
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  margin: 0 0 14px; padding: 10px 10px 10px 16px; border: 1px solid var(--accent); border-radius: 14px;
  background: #1b0d14; box-shadow: 0 12px 30px rgba(0,0,0,.45);
}
.builds-save-all span { font-size: 14px; color: #fff; }
.sitework-row.is-dirty { border-color: #ff258799; }
@media (max-width: 700px) {
  .builds-save-all { position: fixed; top: auto; bottom: calc(10px + env(safe-area-inset-bottom)); left: 10px; right: 10px; margin: 0; }
}

/* ---------- Upload progress ---------- */
.upload-progress { display: grid; gap: 6px; flex: 1 1 100%; width: 100%; }
.upload-progress-track { height: 8px; border-radius: 999px; background: #ffffff1a; overflow: hidden; }
.upload-progress-track i { display: block; width: 0; height: 100%; border-radius: 999px; background: var(--accent); transition: width .2s ease; }
.upload-progress span { font-size: 13px; color: #fff; }

/* ---------- Speed check ---------- */
.speed-results { margin-top: 16px; }
.speed-scores { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 8px; }
.speed-score { display: grid; justify-items: center; gap: 6px; padding: 14px 6px; border-radius: 12px; background: #0f0f13; border: 1px solid var(--line); text-align: center; }
.speed-score strong { display: grid; place-items: center; width: 56px; height: 56px; border-radius: 50%; border: 4px solid currentColor; font-size: 20px; }
.speed-score span { font-size: 12px; color: var(--muted); }
.speed-metrics { display: grid; gap: 6px; margin: 12px 0; }
.speed-metric { display: grid; grid-template-columns: 1fr auto; gap: 0 12px; padding: 10px 14px; border-radius: 10px; background: #0f0f13; border-left: 3px solid currentColor; }
.speed-metric span { color: #fff; font-size: 14px; }
.speed-metric strong { font-size: 15px; }
.speed-metric small { grid-column: 1 / -1; margin: 0; }
.is-good { color: #2fbf71; }
.is-ok { color: #f5a524; }
.is-poor { color: #ff4d4f; }
.speed-key { margin-top: 14px; }
.speed-key summary { cursor: pointer; font-size: 13px; color: var(--muted); min-height: 44px; display: flex; align-items: center; }
@media (max-width: 700px) { .speed-scores { grid-template-columns: 1fr 1fr; } }
/* Phone header: name, cache switch and menu only — "Open website" and "Sign out" live in the menu. */
.admin-nav-signout { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.admin-nav-signout form { margin: 0; }
.admin-nav-signout .button, .admin-nav-signout button { width: 100%; }
@media (max-width: 700px) {
  .admin-header .admin-open-site { display: none; }
  .admin-brand { max-width: none; }
  .admin-menu-button { max-width: 42vw; }
}
@media (max-width: 360px) {
  .admin-brand { font-size: 13px; }
  .cache-pill { padding-inline: 9px; }
}

/* =====================================================================
   Homepage sections — list of every section, then one editor at a time
   ===================================================================== */
.section-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.section-card {
  display: grid; grid-template-columns: 76px minmax(0, 1fr) 20px; align-items: center; gap: 14px;
  padding: 10px 14px 10px 10px; border: 1px solid var(--line); border-radius: 14px;
  background: var(--panel); text-decoration: none; min-height: 72px;
}
.section-card:hover, .section-card:focus-visible { border-color: var(--accent); }
.section-card.is-hidden-section { opacity: .6; }
.section-card-thumb { display: grid; place-items: center; width: 76px; aspect-ratio: 16 / 10; overflow: hidden; border-radius: 9px; background: #050507; border: 1px solid var(--line); }
.section-card-thumb img { width: 100%; height: 100%; object-fit: cover; }
.section-card-thumb b { color: var(--accent); font: 700 15px monospace; }
.section-card-text { display: grid; gap: 3px; min-width: 0; }
.section-card-text small { margin: 0; font-size: 11px; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); }
.section-card-text strong { color: #fff; font-size: 15px; line-height: 1.3; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.section-card-chips { display: flex; flex-wrap: wrap; gap: 4px; }
.section-card-chips i { padding: 1px 7px; border-radius: 999px; background: #ffffff14; color: #d6d6dc; font: 600 10px Arial, sans-serif; font-style: normal; letter-spacing: .04em; }
.section-card-chips .is-hidden-chip { background: #ff258733; color: #fff; }
.section-card-arrow { color: var(--muted); font-size: 26px; line-height: 1; }

.section-editor-nav {
  position: sticky; top: calc(var(--header-height, 64px) + 6px); z-index: 9;
  display: flex; justify-content: space-between; gap: 8px; margin: 0 0 16px; padding: 6px;
  border: 1px solid var(--line); border-radius: 14px; background: #16161bf2;
  -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px);
}
.section-editor-nav span { display: flex; gap: 6px; }
.section-editor-nav .button { min-height: 42px; padding: 8px 14px; }

.editor-panel { padding: 0; }
.editor-panel > summary {
  display: flex; align-items: center; justify-content: space-between; min-height: 52px; padding: 0 18px;
  cursor: pointer; list-style: none; font-weight: 700; font-size: 13px; letter-spacing: .08em; text-transform: uppercase; color: var(--muted);
}
.editor-panel > summary::-webkit-details-marker { display: none; }
.editor-panel > summary::after { content: '+'; font-size: 22px; font-weight: 400; color: var(--accent); }
.editor-panel[open] > summary::after { content: '−'; }
.editor-panel[open] > summary { border-bottom: 1px solid var(--line); margin-bottom: 4px; }
.editor-panel > :not(summary) { margin-left: 18px; margin-right: 18px; }
.editor-panel > :last-child { margin-bottom: 18px; }

.segmented { display: grid; grid-auto-flow: column; grid-auto-columns: 1fr; gap: 4px; margin: 14px 18px 4px; padding: 4px; border: 1px solid var(--line); border-radius: 12px; background: var(--field); }
.segmented label { margin: 0; }
.segmented input { position: absolute; opacity: 0; pointer-events: none; }
.segmented span { display: grid; place-items: center; min-height: 40px; border-radius: 9px; font-size: 14px; font-weight: 700; color: var(--muted); cursor: pointer; }
.segmented input:checked + span { background: var(--accent-strong); color: #fff; }
.segmented input:focus-visible + span { outline: 2px solid #fff; outline-offset: 2px; }

.upload-pair { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin-top: 14px; }
.upload-pair[hidden] { display: none; }
.upload-button { position: relative; margin: 0; }
.upload-button-wide { grid-column: 1 / -1; }
.upload-button input { position: absolute; inset: 0; width: 100%; height: 100%; opacity: 0; cursor: pointer; margin: 0; }
.upload-button-face {
  display: grid; gap: 3px; align-content: center; min-height: 68px; padding: 10px 12px; text-align: center;
  border: 1px dashed #ffffff55; border-radius: 12px; background: #0f0f13;
}
.upload-button-face b { color: #fff; font-size: 14px; }
.upload-button-face small { margin: 0; font-size: 11px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.upload-button:hover .upload-button-face, .upload-button input:focus-visible + .upload-button-face { border-color: var(--accent); }
.upload-button.has-file .upload-button-face { border-style: solid; border-color: #2fbf71; background: #2fbf7114; }
.upload-button.has-file small { color: #bfeed3; }
.upload-button input:disabled { pointer-events: none; }

.current-media-empty { display: grid; place-items: center; width: 160px; aspect-ratio: 16 / 9; border-radius: 10px; border: 1px dashed var(--line); color: var(--muted); font-size: 12px; flex: none; }
.reset-media { margin-top: 14px; width: auto; }
@media (max-width: 700px) {
  .section-card { grid-template-columns: 64px minmax(0, 1fr) 16px; gap: 12px; }
  .section-card-thumb { width: 64px; }
  .current-media-empty { width: 120px; }
  .editor-panel > :not(summary) { margin-left: 14px; margin-right: 14px; }
  .segmented { margin-left: 14px; margin-right: 14px; }
  .editor-panel > summary { padding: 0 14px; }
}

/* Section list: move arrows beside each card, save-order bar, add-section form */
.section-list li { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 6px; align-items: stretch; }
.section-list li.is-moved .section-card { border-color: var(--accent); }
.section-move { display: grid; grid-template-rows: 1fr 1fr; gap: 4px; }
.section-move button { min-height: 0; height: 100%; width: 44px; padding: 0; font-size: 17px; border-radius: 10px; }
.section-move-fixed { display: grid; place-items: center; width: 44px; border: 1px dashed var(--line); border-radius: 10px; font-size: 10px; letter-spacing: .06em; text-transform: uppercase; color: var(--muted); }
.section-order-bar {
  position: sticky; top: calc(var(--header-height, 64px) + 8px); z-index: 8;
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  margin: 0 0 12px; padding: 10px 10px 10px 16px; border: 1px solid var(--accent); border-radius: 14px; background: #1b0d14;
  box-shadow: 0 12px 30px rgba(0,0,0,.45);
}
.section-order-bar span { color: #fff; font-size: 14px; }
.add-section { margin-top: 18px; }
.add-section .segmented { margin: 8px 0 4px; }
@media (max-width: 700px) {
  .section-order-bar { position: fixed; top: auto; bottom: calc(10px + env(safe-area-inset-bottom)); left: 10px; right: 10px; margin: 0; }
  .section-move button, .section-move-fixed { width: 40px; }
}
@media (max-width: 700px) {
  .admin-header-bar { gap: 6px; }
  .admin-brand { font-size: 14px; letter-spacing: -.5px; flex: none; }
  .cache-pill { padding-inline: 10px; gap: 6px; }
  .admin-menu-button { flex: 1 1 auto; max-width: none; min-width: 0; justify-content: flex-start; }
}

/* ---------- Phone preview (Homepage sections) ---------- */
.phone-preview { display: grid; justify-items: center; gap: 10px; padding-top: 14px; }
.phone-preview .field-note { text-align: center; margin: 0; }
.phone-mock { width: 214px; height: 463px; padding: 8px; border-radius: 34px; background: #000; border: 1px solid #ffffff2e; box-shadow: 0 18px 40px rgba(0,0,0,.5); }
.phone-mock-screen { position: relative; width: 390px; height: 844px; transform: scale(.508); transform-origin: 0 0; overflow: hidden; border-radius: 52px; background: #080809; font-family: Arial, Helvetica, sans-serif; }
.mock-bg { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.mock-shade { position: absolute; inset: 0; background: #000; }
.mock-copy { position: absolute; left: 0; right: 0; padding: 0 20px; display: grid; gap: 10px; }
[data-kind="film"] .mock-copy { bottom: 0; padding-top: 70px; padding-bottom: 86px; background: linear-gradient(transparent, rgba(0,0,0,.75) 40%); }
[data-kind="designed"] .mock-copy { top: 82px; }
.mock-label { margin: 0; color: #ff1684; font: 400 9px/1.4 "Courier New", monospace; letter-spacing: .1em; text-transform: uppercase; }
.mock-heading { margin: 0; font: 900 33.5px/1.02 Arial, sans-serif; letter-spacing: -1.68px; font-style: normal; color: #fff; overflow-wrap: anywhere; }
[data-kind="designed"] .mock-heading { color: var(--accent); }
.mock-sentence { margin: 0; color: #d4d4d8; font-size: 13.5px; line-height: 1.45; }
.mock-button { justify-self: start; margin-top: 6px; padding: 9px 16px; border-radius: 30px; background: #e0006e; background: color-mix(in srgb, #ff1684 86%, #000); /* same deeper fill the website uses behind white text */ color: #fff; font: 700 13px/1.4 Arial, sans-serif; }
@media (min-width: 1100px) {
  /* Wide screens: fields on the left, the phone preview stays in view on the right. */
  .section-editor form { display: grid; grid-template-columns: minmax(0, 1fr) 270px; column-gap: 20px; align-items: start; }
  .section-editor form > * { grid-column: 1; }
  .section-editor form > .phone-preview-panel { grid-column: 2; grid-row: 1 / span 20; position: sticky; top: calc(var(--header-height, 64px) + 76px); }
}

/* Sliders and phone version */
.slider-row { margin-top: 16px; }
.slider-row label { margin: 0; }
.slider-row label small { display: inline; margin-left: 6px; color: var(--accent); font-weight: 700; }
input[type=range] { width: 100%; margin: 12px 0 4px; accent-color: var(--accent); height: 28px; }
.slider-ends { display: flex; justify-content: space-between; font-size: 11px; color: var(--muted); }
.phone-version { margin-top: 16px; padding: 12px 14px; border: 1px dashed var(--line); border-radius: 12px; }
.phone-version > summary { cursor: pointer; font-weight: 700; font-size: 14px; list-style: none; display: grid; gap: 2px; }
.phone-version > summary::-webkit-details-marker { display: none; }
.phone-version > summary small { margin: 0; font-weight: 400; }
.reset-words { margin-top: 16px; }
@media (max-width: 700px) {
  /* Smaller phone preview on phones, so the heading field fits on screen with it. */
  .phone-mock { width: 176px; height: 378px; padding: 7px; border-radius: 28px; }
  .phone-mock-screen { transform: scale(.415); border-radius: 56px; }
  .phone-preview { padding-top: 10px; }
}

/* Drag handle in the section list */
.section-list li { grid-template-columns: minmax(0, 1fr) 34px auto; }
.drag-handle {
  display: grid; align-content: center; justify-items: center; gap: 4px; width: 34px; min-height: 0; padding: 0;
  border: 1px solid var(--line); border-radius: 10px; background: #0f0f13; cursor: grab; touch-action: none;
}
.drag-handle i { display: block; width: 14px; height: 2px; border-radius: 2px; background: var(--muted); }
.drag-handle-fixed { border-style: dashed; cursor: default; background: none; }
.section-list li.is-dragging { opacity: .85; }
.section-list li.is-dragging .section-card { border-color: var(--accent); box-shadow: 0 14px 30px rgba(0,0,0,.55); transform: scale(1.02); }
.section-list li.is-dragging .drag-handle { cursor: grabbing; border-color: var(--accent); }
.duplicate-section { margin-top: 12px; }
@media (max-width: 700px) {
  .section-list li { grid-template-columns: minmax(0, 1fr) 30px auto; gap: 5px; }
  .drag-handle { width: 30px; }
  .section-card { grid-template-columns: 56px minmax(0, 1fr) 12px; gap: 10px; padding-right: 10px; }
  .section-card-thumb { width: 56px; }
}

/* Quick preview: second button, heading size and position */
.mock-buttons { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 6px; }
.mock-buttons .mock-button { margin-top: 0; }
.mock-button.is-secondary { background: transparent; box-shadow: inset 0 0 0 1.5px #ffffffb3; }
[data-size="small"] .mock-heading { font-size: 25px; line-height: 1.05; }
[data-size="large"] .mock-heading { font-size: 47px; line-height: .95; }
[data-kind="film"][data-position="top"] .mock-copy { top: 0; bottom: auto; padding-top: 96px; padding-bottom: 60px; background: linear-gradient(rgba(0,0,0,.75) 55%, transparent); }
[data-kind="film"][data-position="middle"] .mock-copy { top: 50%; bottom: auto; transform: translateY(-50%); padding: 40px 20px; background: linear-gradient(transparent, rgba(0,0,0,.6) 25%, rgba(0,0,0,.6) 75%, transparent); }
[data-kind="designed"][data-position="middle"] .mock-copy { top: 50%; transform: translateY(-50%); }
[data-kind="designed"][data-position="bottom"] .mock-copy { top: auto; bottom: 76px; }
[data-heading-warning].is-over { color: #f5a524; }

/* Real page preview sits exactly where the quick one does */
.phone-mock { position: relative; }
.real-preview { position: absolute; left: 8px; top: 8px; width: 390px; height: 844px; border: 0; border-radius: 52px; transform: scale(.508); transform-origin: 0 0; background: #080809; z-index: 1; pointer-events: none; }
.phone-preview.is-real .phone-mock-screen { visibility: hidden; }
.preview-mode { margin: 14px 18px 0 !important; }
@media (max-width: 700px) {
  .real-preview { left: 7px; top: 7px; transform: scale(.415); border-radius: 56px; }
}

/* Section editor: labelled segmented choices, template picker, logos */
.segmented-labelled { position: relative; margin: 26px 0 0 !important; }
.segmented-labelled legend { position: absolute; top: -22px; left: 0; padding: 0; font-size: 13px; font-weight: 700; color: #fff; }
.template-picker { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; margin: 10px 0 0; padding: 0; border: 0; }
.template-picker label { margin: 0; }
.template-picker input { position: absolute; opacity: 0; pointer-events: none; }
.template-picker span { display: grid; gap: 4px; height: 100%; padding: 12px; border: 1px solid var(--line); border-radius: 12px; background: #0f0f13; cursor: pointer; }
.template-picker b { font-size: 14px; color: #fff; }
.template-picker small { margin: 0; font-size: 11px; line-height: 1.35; }
.template-picker input:checked + span { border-color: var(--accent); background: #ff258714; box-shadow: inset 0 0 0 1px var(--accent); }
.template-picker input:focus-visible + span { outline: 2px solid #fff; outline-offset: 2px; }
@media (max-width: 700px) { .template-picker { grid-template-columns: 1fr 1fr; } }
.logo-manage { list-style: none; margin: 14px 0 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(110px, 1fr)); gap: 8px; }
.logo-manage li { display: grid; gap: 6px; padding: 10px; border: 1px solid var(--line); border-radius: 10px; background: #0f0f13; }
.logo-manage img { width: 100%; height: 48px; object-fit: contain; background: #2a2a30; border-radius: 6px; }
.logo-manage .check-row { min-height: 32px; font-size: 13px; }
.segmented-labelled { margin: 30px 18px 0 !important; }
.editor-panel > .segmented-labelled:last-child { margin-bottom: 18px !important; }
.version-list button { white-space: nowrap; }
@media (max-width: 700px) { .segmented-labelled { margin: 30px 14px 0 !important; } }

/* ===== Friendlier editor ===== */
/* Messages: text, optional Undo, dismiss */
.notice { display: flex; align-items: center; gap: 10px; }
.notice > p { margin: 0; flex: 1 1 auto; color: #fff; }
.notice-undo { margin: 0; flex: none; }
.notice-undo button { min-height: 38px; padding: 6px 14px; background: #ffffff1f; border-color: #ffffff59; }
.notice-close { flex: none; width: 36px; min-height: 36px; padding: 0; border: 0; background: transparent; font-size: 22px; line-height: 1; opacity: .75; }
.notice-close:hover { opacity: 1; }

/* Panel headings say what's inside without opening them */
.editor-panel > summary { gap: 12px; }
.editor-panel > summary .panel-summary { margin: 0 0 0 auto; padding-right: 4px; font-size: 12px; font-weight: 400; letter-spacing: 0; text-transform: none; color: #8f909a; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; max-width: 60%; }
.editor-panel[open] > summary .panel-summary { visibility: hidden; }

/* Optional fields tucked away until wanted */
.optional-field { margin-top: 14px; }
.optional-field > summary { display: inline-flex; align-items: center; gap: 8px; min-height: 40px; cursor: pointer; list-style: none; color: var(--accent); font-size: 14px; font-weight: 700; }
.optional-field > summary::-webkit-details-marker { display: none; }
.optional-field > summary::before { content: '+'; display: grid; place-items: center; width: 22px; height: 22px; border-radius: 50%; border: 1.5px solid currentColor; font-size: 15px; line-height: 1; }
.optional-field[open] > summary::before { content: '−'; }
.optional-field > label:first-of-type { margin-top: 4px; }

/* Section list: clean until Reorder is pressed */
.section-list-tools { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin: 0 0 10px; }
.section-list-tools .field-note { margin: 0; }
.section-list:not(.is-reordering) li { grid-template-columns: minmax(0, 1fr); }
.section-list:not(.is-reordering) :is(.drag-handle, .section-move) { display: none; }
.section-list.is-reordering .section-card-arrow { visibility: hidden; }
.section-list.is-reordering .section-card { cursor: default; }

/* Menu search */
.admin-nav-search { display: block; margin: 12px 16px 0; }
.admin-nav-search input { margin: 0; padding: 11px 14px; border-radius: 12px; background: #16161b; }
.admin-nav-empty { margin: 14px 20px; font-size: 14px; }
@media (min-width: 1100px) { .admin-nav-search { margin-top: 14px; } }

/* Show password */
.password-wrap { position: relative; display: block; }
.password-wrap input { padding-right: 74px !important; }
.show-password { position: absolute; right: 6px; top: 50%; transform: translateY(calc(-50% + 4px)); min-height: 36px; padding: 4px 12px; font-size: 13px; border-radius: 8px; }
.login .show-password, .password-wrap .show-password { width: auto; margin-top: 0; }

/* ===== iPhone and iPad: bigger targets for fingers, no hover-only cues ===== */
@media (pointer: coarse) {
  button, .button, .admin-tabs a, .seo-page summary, .editor-panel > summary { min-height: 48px; }
  .section-move { gap: 6px; }
  .section-move button { min-height: 44px; width: 46px; }
  .drag-handle { width: 40px; }
  .section-list li { grid-template-columns: minmax(0, 1fr) 40px auto; }
  .section-list:not(.is-reordering) li { grid-template-columns: minmax(0, 1fr); }
  .notice-close { width: 44px; min-height: 44px; }
  .show-password { min-height: 40px; }
  .faq-row-move button { min-height: 44px; width: 46px; }
  .gallery-piece-actions button { min-height: 44px; }
  .version-list button { min-height: 44px; }
  .optional-field > summary { min-height: 44px; }
  input[type=range] { height: 36px; }
  /* Taps shouldn't flash grey on iOS */
  a, button, summary, label { -webkit-tap-highlight-color: transparent; }
}
/* iPad portrait and landscape: use the width for two columns of section cards */
@media (min-width: 760px) and (max-width: 1099px) {
  .section-list:not(.is-reordering) { grid-template-columns: 1fr 1fr; }
  .section-editor .phone-mock { width: 214px; height: 463px; }
}
/* Jumping to an area (#sections etc.) lands with its heading visible under the header. */
.admin-area { scroll-margin-top: calc(var(--header-height, 64px) + 24px); }

/* iPad (portrait and smaller landscape): tidy header, editor in two columns */
@media (min-width: 701px) and (max-width: 1099px) {
  .admin-header-label, .admin-header .admin-signout { display: none; }
  .admin-header .admin-open-site .wide-only { display: none; }
  .admin-header .admin-open-site .narrow-only { display: inline; }
  .admin-menu-button { max-width: 40vw; }
}
@media (min-width: 760px) {
  .section-editor form { display: grid; grid-template-columns: minmax(0, 1fr) 250px; column-gap: 18px; align-items: start; }
  .section-editor form > * { grid-column: 1; }
  .section-editor form > .phone-preview-panel { grid-column: 2; grid-row: 1 / span 20; position: sticky; top: calc(var(--header-height, 64px) + 76px); }
  .section-editor .phone-preview-panel .phone-mock { width: 214px; height: 463px; }
  .section-editor .phone-preview-panel .preview-mode { margin: 12px 12px 0 !important; }
  .section-editor .phone-preview-panel .phone-preview { padding: 12px 8px 14px; }
}
@media (min-width: 1100px) {
  .section-editor form { grid-template-columns: minmax(0, 1fr) 270px; }
}

/* Sign in: keep signed in + Face ID */
.remember-row { margin-top: 14px; }
.passkey-login { margin-top: 18px; }
.passkey-or { display: flex; align-items: center; gap: 12px; margin: 0 0 14px; color: var(--muted); font-size: 13px; }
.passkey-or::before, .passkey-or::after { content: ''; flex: 1; height: 1px; background: var(--line); }
.passkey-button { width: 100%; min-height: 54px; gap: 10px; font-size: 16px; background: #fff; color: #0a0a0c; border-color: #fff; }
.passkey-icon { width: 22px; height: 22px; border: 2px solid currentColor; border-radius: 6px; position: relative; }
.passkey-icon::before { content: ''; position: absolute; left: 4px; right: 4px; bottom: 4px; height: 5px; border: 2px solid currentColor; border-top: 0; border-radius: 0 0 6px 6px; }
.passkey-status { text-align: center; min-height: 1.4em; margin-top: 10px; }
.passkey-list { margin-bottom: 14px; }

/* =====================================================================
   Studio app (Home Screen), enquiries inbox and alerts
   ===================================================================== */

/* Full-screen app: keep clear of the notch, status bar and home bar. */
.admin-header { padding-top: env(safe-area-inset-top); }
.admin-header-bar { padding-left: max(16px, env(safe-area-inset-left)); padding-right: max(16px, env(safe-area-inset-right)); }
main { padding-left: max(16px, env(safe-area-inset-left)); padding-right: max(16px, env(safe-area-inset-right)); padding-bottom: calc(120px + env(safe-area-inset-bottom)); }
.admin-tabs { padding-top: env(safe-area-inset-top); }
.is-app body { -webkit-user-select: none; user-select: none; }
.is-app :is(input, textarea, p, dd, .enquiry-message) { -webkit-user-select: text; user-select: text; }
.admin-refresh { min-height: 38px; width: 38px; padding: 0; border-radius: 50%; font-size: 20px; line-height: 1; flex: none; }

/* New-enquiry counts */
.admin-menu-button { position: relative; }
.menu-dot { position: absolute; top: 4px; right: 4px; width: 10px; height: 10px; border-radius: 50%; background: var(--accent); box-shadow: 0 0 0 2px var(--page); }
.nav-count { display: inline-grid; place-items: center; min-width: 22px; height: 22px; padding: 0 6px; margin-left: 6px; border-radius: 11px; background: #fff; color: #09090c; font-size: 12px; vertical-align: 1px; }
.admin-tabs a[aria-current] .nav-count { background: #09090c; color: #fff; }
.dash-enquiries {
  display: grid; gap: 2px; margin: 0 0 14px; padding: 16px 18px; border-radius: 14px; text-decoration: none;
  background: var(--accent-strong); color: #fff;
}
.dash-enquiries strong { font-size: 20px; letter-spacing: -.02em; }
.dash-enquiries span { font-size: 13px; color: #fff; }

/* "Put Studio on your Home Screen" */
.app-install { border-color: var(--accent); }
.app-steps { margin: 0 0 12px; padding-left: 22px; display: grid; gap: 8px; color: #e6e6ec; line-height: 1.45; }
.share-glyph { display: inline-block; width: 14px; height: 17px; vertical-align: -3px; margin: 0 2px; }

/* Alerts panel */
.push-on-line { display: flex; align-items: center; gap: 10px; margin: 0; color: #fff; font-weight: 600; }
.push-on-line i { width: 10px; height: 10px; border-radius: 50%; background: #3ddc84; flex: none; }
.push-panel [data-push-on] .save-bar, .push-panel [data-push-off] .save-bar { margin-top: 14px; }
.push-status:empty { display: none; }
.push-status { margin: 12px 0 0; }
.push-devices { margin-top: 16px; }
.push-devices summary { cursor: pointer; min-height: 44px; display: flex; align-items: center; color: var(--muted); font-size: 14px; }
.push-devices .version-list { margin-top: 6px; }

/* Inbox */
.inbox-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin: 26px 0 12px; }
.inbox-head .list-title { margin: 0; }
.inbox-head form { margin: 0; }
.inbox-list { display: grid; gap: 10px; margin-bottom: 14px; }
.enquiry { border: 1px solid var(--line); border-radius: 14px; background: var(--panel); overflow: hidden; }
.enquiry.is-new { border-left: 3px solid var(--accent); }
.enquiry summary { list-style: none; display: grid; gap: 4px; padding: 14px 16px; cursor: pointer; min-height: 64px; }
.enquiry summary::-webkit-details-marker { display: none; }
.enquiry-who { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; }
.enquiry-who strong { color: #fff; font-size: 16px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.enquiry.is-new .enquiry-who strong::before { content: ''; display: inline-block; width: 8px; height: 8px; margin-right: 8px; border-radius: 50%; background: var(--accent); vertical-align: 2px; }
.enquiry-who time { flex: none; font-size: 12px; color: var(--muted); }
.enquiry-preview { font-size: 14px; color: var(--muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.enquiry[open] .enquiry-preview { display: none; }
.enquiry[open] summary { border-bottom: 1px solid var(--line); }
.enquiry-body { padding: 14px 16px 16px; }
.enquiry-contact { display: grid; grid-template-columns: repeat(auto-fit, minmax(96px, 1fr)); gap: 8px; }
.enquiry-contact .button { min-height: 48px; }
.enquiry-message { margin: 16px 0; color: #fff; font-size: 16px; line-height: 1.55; white-space: normal; overflow-wrap: anywhere; }
.enquiry-details { margin: 0; display: grid; gap: 6px; font-size: 14px; }
.enquiry-details div { display: grid; grid-template-columns: 64px 1fr; gap: 10px; }
.enquiry-details dt { color: var(--muted); }
.enquiry-details dd { margin: 0; overflow-wrap: anywhere; }
.enquiry-actions { margin-top: 16px; }
.enquiry-actions form { margin: 0; }


/* Without JavaScript the menu can't open as a sheet, so it shows as a plain
   list at the top of the editor (with Sign out), and every area stacks below. */
html:not(.js) .admin-tabs { position: static; transform: none; visibility: visible; width: auto; max-width: 900px; margin: 0 auto; border: 0; background: none; padding-bottom: 0; }
html:not(.js) .admin-menu-button, html:not(.js) .admin-nav-close, html:not(.js) .admin-nav-search, html:not(.js) .admin-nav-backdrop { display: none !important; }
html:not(.js) body.is-signed-in main { padding-left: max(16px, env(safe-area-inset-left)); max-width: 900px; margin: 0 auto; }

/* ---------- Media & storage ---------- */
.storage-bars { list-style: none; margin: 0 0 16px; padding: 0; display: grid; gap: 10px; }
.storage-bars li { display: grid; grid-template-columns: minmax(0, 11em) minmax(0, 1fr) auto; align-items: center; gap: 10px; font-size: 14px; }
.storage-bars b { display: block; height: 10px; border-radius: 5px; background: var(--accent); }
.storage-bars small { margin: 0; }
.storage-clean { margin-top: 12px; padding-top: 12px; border-top: 1px solid var(--line); }
.storage-clean details summary { cursor: pointer; min-height: 44px; display: flex; align-items: center; color: var(--muted); font-size: 14px; }
.storage-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 4px; max-height: 260px; overflow: auto; }
.storage-list li { display: flex; justify-content: space-between; gap: 10px; font-size: 13px; padding: 6px 0; border-bottom: 1px solid var(--line); }
.storage-list span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.storage-list small { margin: 0; flex: none; }
.library-grid { list-style: none; margin: 12px 0 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); gap: 10px; }
.library-item, .library-choice { display: grid; gap: 4px; align-content: start; padding: 8px; border: 1px solid var(--line); border-radius: 12px; background: #0f0f13; min-width: 0; text-align: left; }
.library-item.is-unused { border-style: dashed; opacity: .75; }
.library-thumb { position: relative; display: grid; place-items: center; aspect-ratio: 4 / 3; overflow: hidden; border-radius: 8px; background: #050507; color: var(--muted); font-size: 12px; }
.library-thumb img { width: 100%; height: 100%; object-fit: cover; }
.library-thumb b { position: absolute; right: 6px; bottom: 6px; padding: 2px 7px; border-radius: 999px; background: rgba(0,0,0,.7); color: #fff; font-size: 11px; }
.library-name { font-size: 12px; color: #fff; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.library-item small, .library-choice small { margin: 0; font-size: 11px; }
.library-choice { width: 100%; min-height: 0; font-weight: 400; }
.library-choice:hover { border-color: var(--accent); }
@media (max-width: 700px) { .library-grid { grid-template-columns: 1fr 1fr; gap: 8px; } .storage-bars li { grid-template-columns: 1fr auto; } .storage-bars b { grid-column: 1 / -1; grid-row: 2; } }

/* Library button on each upload tile, and the picker sheet */
.upload-slot { position: relative; min-width: 0; }
.upload-slot .upload-button-face { padding-bottom: 30px; }
.library-button { position: absolute; right: 8px; bottom: 6px; z-index: 2; min-height: 30px; padding: 4px 12px; border-radius: 999px; font-size: 12px; background: #1c1c22; }
.library-picker { position: fixed; inset: 0; z-index: 60; display: grid; align-items: end; background: rgba(0,0,0,.6); }
.library-picker[hidden] { display: none; }
.library-picker-sheet { max-height: 86vh; overflow: auto; overscroll-behavior: contain; padding: 0 16px calc(20px + env(safe-area-inset-bottom)); background: #0d0d11; border-radius: 18px 18px 0 0; border-top: 1px solid var(--line); }
.library-picker-head { position: sticky; top: 0; z-index: 1; display: flex; justify-content: space-between; align-items: center; padding: 12px 0; background: #0d0d11; }
.library-picker-find input { margin-top: 0; }
body.has-picker { overflow: hidden; }
@media (min-width: 900px) { .library-picker { align-items: center; justify-items: center; } .library-picker-sheet { width: min(760px, 92vw); border-radius: 18px; border: 1px solid var(--line); } }

.backup-list { margin-top: 16px; }
.backup-actions { display: flex; gap: 6px; }

/* Enquiry tracking */
.enquiry-status { justify-self: start; padding: 2px 10px; border-radius: 999px; font-size: 12px; font-weight: 700; background: #ffffff18; color: #fff; }
.enquiry-status.is-won { background: #1f6b43; }
.enquiry-status.is-quoted { background: #6b4b1f; }
.enquiry-status.is-lost { background: #3a3a42; color: #c9c9cf; }
.enquiry-track { margin-top: 16px; padding-top: 14px; border-top: 1px solid var(--line); }
.enquiry-status-pick { grid-auto-flow: row; grid-template-columns: repeat(5, minmax(0, 1fr)); margin: 0 0 4px; }
.enquiry-status-pick span { font-size: 13px; min-height: 44px; }
.inbox-filter { display: flex; align-items: center; gap: 10px; margin: 0 0 12px; font-size: 14px; }
.inbox-filter select { margin: 0; width: auto; }
.dash-month { display: grid; gap: 2px; margin: 0 0 14px; padding: 16px 18px; border: 1px solid var(--line); border-radius: 14px; background: var(--panel); text-decoration: none; }
.dash-month span { font-size: 12px; text-transform: uppercase; letter-spacing: .12em; color: var(--accent); }
.dash-month strong { font-size: 22px; color: #fff; }
.dash-month small { margin: 0; font-size: 13px; }
@media (max-width: 420px) { .enquiry-status-pick { grid-template-columns: repeat(3, minmax(0, 1fr)); } }

/* Other pages */
.page-words { padding: 0; }
.page-words > summary { list-style: none; cursor: pointer; display: flex; align-items: center; justify-content: space-between; min-height: 64px; padding: 14px 18px; }
.page-words > summary::-webkit-details-marker { display: none; }
.page-words > summary::after { content: '›'; font-size: 22px; color: var(--muted); transition: transform .2s; }
.page-words[open] > summary::after { transform: rotate(90deg); }
.page-words > summary span { display: grid; gap: 2px; }
.page-words > summary strong { color: #fff; font-size: 16px; }
.page-words > summary small { margin: 0; }
.page-words[data-changed] > summary strong::after { content: ' •'; color: var(--accent); }
.page-words > form { padding: 0 18px 18px; border-top: 1px solid var(--line); }
.page-words-group { margin: 16px 0 0; padding: 0; border: 0; min-width: 0; }
.page-words-group legend { font-size: 12px; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: var(--accent); padding: 0; }
.page-words-item { padding: 10px 0; border-bottom: 1px solid var(--line); }
@media (max-width: 700px) { .page-words > form { padding: 0 14px 16px; } .page-words > summary { padding: 14px; } }

/* Drafts */
.draft-banner { margin: 0 0 16px; padding: 12px 14px; border: 1px solid #c9a227; border-radius: 12px; background: #c9a2271a; }
.draft-banner p { margin: 0 0 10px; color: #fff; font-size: 14px; }
.draft-actions { display: flex; flex-wrap: wrap; gap: 8px; }
.section-card .draft-pill { margin-left: 6px; padding: 1px 8px; border-radius: 999px; background: #c9a227; color: #111; font-size: 11px; font-weight: 700; }
.section-card-chips i.is-draft-chip { background: #c9a227; color: #111; }

/* Crop sheet */
.crop-shapes { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 12px; }
.crop-shapes button { min-height: 38px; padding: 6px 12px; border-radius: 999px; font-size: 13px; }
.crop-shapes button[aria-pressed="true"] { background: var(--accent-strong); border-color: var(--accent-strong); }
.crop-stage { display: grid; place-items: center; padding: 8px 0; background: #050507; border-radius: 12px; }
.crop-frame { position: relative; overflow: hidden; touch-action: none; cursor: grab; outline: 2px solid #fff; box-shadow: 0 0 0 9999px rgba(0,0,0,.55); }
.crop-frame img { position: absolute; left: 0; top: 0; max-width: none; user-select: none; -webkit-user-select: none; pointer-events: none; }
.crop-zoom { display: flex; align-items: center; gap: 12px; }
.crop-zoom input { flex: 1; margin: 0; accent-color: var(--accent); }
.crop-sheet .crop-stage { overflow: hidden; }

/* Finger-sized targets everywhere (Apple's guideline is 44 px). */
.admin-brand { display: inline-flex; align-items: center; min-height: 44px; }
main summary { min-height: 44px; display: flex; align-items: center; cursor: pointer; }
main input[type=range] { min-height: 44px; }
.library-button { min-height: 40px; padding: 6px 14px; bottom: 4px; }
.upload-slot .upload-button-face { padding-bottom: 44px; }

.health-passed { margin-top: 10px; }
.health-passed summary { color: var(--muted); font-size: 14px; }
.health-passed .health-list { margin-top: 6px; }
.backup-file h3 { margin: 16px 0 6px; font-size: 15px; color: #fff; }
.backup-file form + form { margin-top: 18px; padding-top: 4px; border-top: 1px solid var(--line); }
.fold-card > summary { list-style: none; display: flex; justify-content: space-between; align-items: center; }
.fold-card > summary::-webkit-details-marker { display: none; }
.fold-card > summary h2 { margin: 0; }
.fold-card > summary::after { content: '+'; font-size: 24px; color: var(--accent); }
.fold-card[open] > summary::after { content: '−'; }
.fold-card[open] > summary { margin-bottom: 8px; }

/* Plain file pickers turned into tiles (label text stays above the tile) */
label.upload-tile { display: grid; gap: 8px; }
label.upload-tile > input[type=file] { position: absolute; inset: 0; width: 100%; height: 100%; opacity: 0; cursor: pointer; margin: 0; z-index: 1; }
label.upload-tile .upload-button-face { min-height: 64px; }

/* Before you publish */
.publish-check { border-color: #c9a227; }
.publish-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.publish-list a { display: grid; gap: 4px; padding: 12px 14px; border: 1px solid var(--line); border-radius: 12px; background: #0f0f13; text-decoration: none; min-height: 44px; }
.publish-list strong { color: #fff; font-size: 14px; }
.publish-list span, .publish-issues li { font-size: 13px; color: #e8d9a6; line-height: 1.45; }
.publish-list span.is-info, .publish-issues li.is-info { color: var(--muted); }
.publish-issues { margin: 4px 0 8px; padding-left: 20px; display: grid; gap: 10px; }
.publish-issues li { font-size: 15px; }

/* =====================================================================
   Design refinement (6 October 2026)
   - One brand moment per screen: the heavy italic title at the top.
     Card headings are upright and calm.
   - Pink means "act on this" or "needs attention": buttons, new
     enquiries, selected options. Labels and decoration are neutral.
   - Labels in sentence case, not spaced-out capitals.
   - Items inside a card are separated by lines, not more boxes.
   ===================================================================== */
h2 { font-style: normal; font-size: 19px; font-weight: 700; letter-spacing: -.01em; line-height: 1.25; }
.section-editor-head h2, .login h1 { font-style: italic; font-weight: 800; letter-spacing: -.04em; }
.eyebrow { text-transform: none; letter-spacing: 0; font-size: 13px; font-weight: 600; color: var(--muted); }
.area-head .eyebrow { color: #c9c9cf; }
.admin-nav-title { text-transform: none; letter-spacing: 0; font-size: 13px; font-weight: 700; color: var(--muted); }
fieldset.field-group legend, .page-words-group legend { text-transform: none; letter-spacing: 0; font-size: 16px; font-weight: 700; color: #fff; }
.editor-panel > summary { text-transform: none; letter-spacing: 0; font-size: 16px; color: #fff; }
.editor-panel > summary::after, .fold-card > summary::after { color: var(--muted); }
.section-card-text small { text-transform: none; letter-spacing: 0; font-size: 12px; }
.analytics-subhead { text-transform: none; letter-spacing: 0; font-size: 13px; font-weight: 700; color: #c9c9cf; }
.dash-month span { text-transform: none; letter-spacing: 0; font-size: 13px; font-weight: 600; color: var(--muted); }
.dash-actions a { border-left: 1px solid var(--line); }
.dash-actions a:hover { border-color: #ffffff40; }
.app-install { border-color: var(--line); }
.storage-bars b { background: #ffffffb3; }
.faq-row-number { font: 700 13px Arial, sans-serif; color: var(--muted); }
.section-card-thumb b { font: 800 15px Arial, sans-serif; color: #fff; }
/* Rows inside a card: dividers instead of boxes within boxes. */
.faq-row { border: 0; border-bottom: 1px solid var(--line); border-radius: 0; background: none; padding: 18px 0; }
.faq-rows { gap: 0; }
.faq-row:first-child { padding-top: 4px; }
.faq-row.is-page-only { border-style: solid; }
.faq-row[data-faq-blank] { border: 1px dashed #ffffff33; border-radius: 12px; padding: 14px; margin-top: 14px; }

/* Site updates */
.release-ready { border-color: #c9a227; }
.release-counts { list-style: none; margin: 0 0 12px; padding: 0; display: grid; gap: 6px; font-size: 14px; color: #d9d9de; }
.release-counts strong { color: #fff; font-size: 16px; margin-right: 4px; }
.release-files summary { color: var(--muted); font-size: 14px; }
.release-files ul { margin: 4px 0 10px; padding-left: 18px; max-height: 240px; overflow: auto; font: 13px/1.6 Arial, sans-serif; color: #c9c9cf; overflow-wrap: anywhere; }
.release-list { list-style: none; margin: 0; padding: 0; display: grid; }
.release-list li { display: grid; gap: 4px; padding: 14px 0; border-bottom: 1px solid var(--line); }
.release-list li:last-child { border-bottom: 0; }
.release-head { display: flex; justify-content: space-between; align-items: baseline; gap: 10px; }
.release-head strong { color: #fff; overflow-wrap: anywhere; }
.release-status { flex: none; font-size: 12px; font-weight: 700; padding: 2px 10px; border-radius: 999px; background: #ffffff14; color: #c9c9cf; }
.release-list li.is-applied .release-status { background: #1f6b43; color: #fff; }
.release-list small { margin: 0; }
.release-actions { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 6px; }

/* ---------- Mike, the website assistant ---------- */
.mike-status { list-style: none; margin: 0 0 18px; padding: 0; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
.mike-status li { padding: 12px 14px; border: 1px solid var(--line); border-radius: 14px; background: var(--panel); min-width: 0; }
.mike-status strong { display: block; font-size: 15px; }
.mike-status small { overflow-wrap: anywhere; }
.mike-status li.is-good strong::before { content: ''; display: inline-block; width: 8px; height: 8px; margin-right: 7px; border-radius: 50%; background: #3ddc84; vertical-align: 2px; }
.mike-status li.is-off strong { color: var(--muted); }
@media (min-width: 900px) { .mike-status { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
.mike-count { display: inline; margin: 0 0 0 4px; }
.mike-transcript { list-style: none; margin: 0 0 14px; padding: 0; display: grid; gap: 8px; }
.mike-transcript li { max-width: 88%; padding: 9px 12px; border-radius: 14px 14px 14px 4px; background: #ffffff10; }
.mike-transcript li.is-visitor { justify-self: end; border-radius: 14px 14px 4px 14px; background: #e0106c2e; border: 1px solid #ff258740; }
.mike-transcript p { margin: 0; font-size: 15px; line-height: 1.45; overflow-wrap: anywhere; }
.mike-transcript small { margin-top: 4px; font-size: 12px; }
.mike-problem { color: #ffb4b4 !important; }
.mike-clear summary, .mike-knows summary { cursor: pointer; font-weight: 700; min-height: 44px; display: flex; align-items: center; }
.mike-try-form { display: flex; gap: 8px; }
.mike-try-form input { flex: 1; min-width: 0; }
.mike-try-quick { display: flex; flex-wrap: wrap; gap: 6px; margin: 10px 0 0; }
.mike-try-quick button { min-height: 44px; padding: 4px 12px; font-size: 13px; border-radius: 999px; }
.mike-try-result { margin-top: 12px; padding: 12px 14px; border-radius: 14px 14px 14px 4px; background: #ffffff10; }
.mike-try-result p { margin: 0 0 6px; line-height: 1.5; }
.mike-try-result.is-waiting { color: var(--muted); }
.mike-try-result.is-error { color: #ffb4b4; }
.mike-fieldset { border: 0; margin: 4px 0; padding: 0; display: grid; gap: 2px; }
.mike-fieldset legend { padding: 0; margin-bottom: 4px; font-weight: 700; font-size: 15px; }
.mike-limits { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.mike-intent { border-top: 1px solid var(--line); padding: 4px 0; }
.mike-intent summary { display: flex; justify-content: space-between; gap: 10px; align-items: center; min-height: 48px; cursor: pointer; }
.mike-intent summary span { color: var(--muted); font-size: 13px; text-align: right; }
.mike-intent[open] { padding-bottom: 12px; }
.mike-reset { margin: -6px 0 18px; text-align: right; }
.mike-knows pre { max-height: 320px; overflow: auto; white-space: pre-wrap; font: 12px/1.55 ui-monospace, Menlo, monospace; color: #c9c9cf; background: var(--field); padding: 12px; border-radius: 10px; }
.mike-chat .enquiry-contact { margin-bottom: 14px; }
.dash-mike { margin-top: 8px; background: #2a1020; border-color: #ff258755; }
.mike-asked { margin: 0 0 14px; padding-left: 22px; display: grid; gap: 8px; }
.mike-asked li { padding-left: 4px; }
.mike-asked span { display: block; overflow-wrap: anywhere; }
.mike-asked small { margin: 2px 0 0; }
.mike-missed { border-top: 1px solid var(--line); }
.mike-missed summary { display: flex; justify-content: space-between; gap: 10px; align-items: center; min-height: 48px; cursor: pointer; }
.mike-missed summary span { overflow-wrap: anywhere; }
.mike-missed summary small { flex: none; margin: 0; }
.mike-missed[open] { padding-bottom: 12px; }
.mike-try-pics { display: flex; gap: 6px; overflow-x: auto; margin: 8px 0 4px; }
.mike-try-pics img { width: 64px; height: 64px; object-fit: cover; border-radius: 8px; flex: none; background: #ffffff10; }

/* ---------- Mailing list & Email sending ---------- */
.list-prompt { border-top: 1px solid var(--line); }
.list-prompt summary { display: flex; align-items: center; gap: 12px; min-height: 60px; cursor: pointer; }
.list-prompt summary img, .list-prompt-blank { width: 72px; height: 44px; flex: none; object-fit: cover; border-radius: 8px; background: #ffffff12; }
.list-prompt-blank { display: grid; place-items: center; font-size: 22px; color: var(--muted); }
.list-prompt[open] { padding-bottom: 14px; }
.list-people li span, .mail-log li span { min-width: 0; overflow-wrap: anywhere; }
.email-state.is-good h2::before { content: ''; display: inline-block; width: 9px; height: 9px; margin-right: 8px; border-radius: 50%; background: #3ddc84; vertical-align: 2px; }
.email-state.is-warn { border-color: #c9a227; }
.email-help ol { margin: 8px 0 4px; padding-left: 20px; display: grid; gap: 6px; line-height: 1.5; }
.email-help summary, .email-advanced summary { cursor: pointer; min-height: 44px; display: flex; align-items: center; font-weight: 700; }
.mail-log li.is-failed small { color: #ffb4b4; }
.list-tools { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 8px; margin: 0 0 10px; }
.list-tools input, .list-tools select { width: 100%; min-height: 44px; }
.list-people a { color: inherit; text-decoration: none; }
.list-chip { display: inline-block; margin-right: 4px; padding: 1px 8px; border-radius: 999px; font-size: 11px; font-weight: 700; background: #1f6b43; color: #fff; }
.list-chip.is-pending { background: #6b4b1f; }
.dash-list { background: #141a2a; border-color: #5a7cff55; }

/* ---------- Google Analytics ---------- */
.ga-report-head { display: flex; justify-content: space-between; align-items: center; gap: 10px; flex-wrap: wrap; }
.ga-report-head h2 { margin: 0; }
.ga-now { display: inline-flex; align-items: center; gap: 7px; font-size: 13px; color: var(--muted); }
.ga-now i { width: 8px; height: 8px; border-radius: 50%; background: #3ddc84; box-shadow: 0 0 0 4px #3ddc8433; animation: ga-pulse 1.8s ease-in-out infinite; }
@keyframes ga-pulse { 50% { box-shadow: 0 0 0 7px #3ddc8411; } }
.ga-big { list-style: none; margin: 14px 0; padding: 0; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
@media (min-width: 900px) { .ga-big { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
.ga-big li { padding: 12px 14px; border: 1px solid var(--line); border-radius: 14px; background: var(--field); min-width: 0; }
.ga-big strong { display: block; font-size: 26px; letter-spacing: -.02em; }
.ga-big span { display: block; font-size: 13px; color: var(--muted); }
.ga-up { color: #6fe3a3 !important; } .ga-down { color: #ffb4b4 !important; }
.ga-days { display: flex; align-items: flex-end; gap: 3px; height: 90px; margin: 6px 0 16px; padding: 8px; border-radius: 12px; background: var(--field); }
.ga-days span { flex: 1; height: max(3px, var(--h)); border-radius: 3px 3px 0 0; background: var(--accent-strong); }
.ga-lists { display: grid; grid-template-columns: minmax(0, 1fr); gap: 16px; }
@media (min-width: 900px) { .ga-lists { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.ga-lists h3 { margin: 0 0 6px; font-size: 15px; }
.ga-lists ol { list-style: none; margin: 0; padding: 0; }
.ga-lists li { display: flex; justify-content: space-between; gap: 10px; padding: 7px 0; border-bottom: 1px solid var(--line); font-size: 14px; }
.ga-lists li span { min-width: 0; overflow-wrap: anywhere; color: #d9d9de; }

/* ---------- Design pass (9 Oct): consistent details on the newer screens ---------- */
/* Tick boxes keep their size when the words wrap */
.check-row input[type=checkbox], .check-row input[type=radio] { flex: none; }
/* Status cards: white headings, colour only in the dot */
.mike-status strong, .email-state h2 { color: #fff; }
.mike-status li.is-off strong { color: var(--muted); }
/* Fold-outs inside a card: same +/− as "Change password" */
.email-help > summary, .email-advanced > summary { list-style: none; display: flex; justify-content: space-between; align-items: center; gap: 12px; min-height: 48px; font-weight: 700; cursor: pointer; }
.email-help > summary::-webkit-details-marker, .email-advanced > summary::-webkit-details-marker,
.mike-intent > summary::-webkit-details-marker, .mike-missed > summary::-webkit-details-marker, .list-prompt > summary::-webkit-details-marker { display: none; }
.mike-intent > summary, .mike-missed > summary, .list-prompt > summary { list-style: none; }
.email-help > summary::after, .email-advanced > summary::after, .mike-intent > summary::after, .mike-missed > summary::after, .list-prompt > summary::after { content: '+'; flex: none; font-size: 22px; font-weight: 400; line-height: 1; color: var(--muted); }
.email-help[open] > summary::after, .email-advanced[open] > summary::after, .mike-intent[open] > summary::after, .mike-missed[open] > summary::after, .list-prompt[open] > summary::after { content: '−'; }
.list-prompt > summary strong { flex: 1; min-width: 0; }
.mike-intent summary span { margin-left: auto; }
.email-help ol li, .email-help ol strong { overflow-wrap: anywhere; }
.email-help { border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); margin: 4px 0 10px; }
.email-help[open] { padding-bottom: 10px; }
.email-advanced { border-top: 1px solid var(--line); margin-top: 6px; }
/* Mike's chat list: the question count gets its own quiet line */
.mike-chat .mike-count { display: block; margin: 2px 0 0; font-size: 12px; color: var(--muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.inbox-head { flex-wrap: wrap; row-gap: 8px; }
.inbox-head-actions { display: flex; flex-wrap: wrap; gap: 8px; }
/* Dashboard cards for Mike and the mailing list: calm, like the rest */
.dash-mike, .dash-list { background: var(--panel); border: 1px solid var(--line); color: #fff; }
.dash-mike strong, .dash-list strong { color: #fff; }
.dash-mike span, .dash-list span { color: var(--muted); }
.dash-mike { border-left: 3px solid var(--accent-strong); }
/* Small iPhones: a slightly smaller name so the screen name fits */
@media (max-width: 400px) {
  .admin-brand { font-size: 13px; letter-spacing: -.3px; }
  .admin-header-bar { gap: 6px; padding-inline: 12px; }
  .admin-menu-button { padding-inline: 10px; gap: 8px; }
}
.dash-list { border-left: 1px solid var(--line); }
/* Section 09 Music: current track */
.music-now { display: grid; gap: 8px; margin: 4px 0 12px; padding: 12px; border-radius: 12px; background: var(--field); border: 1px solid var(--line); }
.music-now audio { width: 100%; height: 40px; }
.music-now p { margin: 0; display: grid; gap: 2px; font-size: 14px; }
.music-now span { color: var(--muted); font-size: 12px; overflow-wrap: anywhere; }

/* ---------- Business details: Google checklist ---------- */
.gb-steps { margin: 6px 0 12px; padding: 0; list-style: none; counter-reset: gb; display: grid; gap: 12px; }
.gb-steps li { position: relative; padding: 2px 0 0 44px; line-height: 1.55; color: #c9cad3; counter-increment: gb; }
.gb-steps li::before { content: counter(gb); position: absolute; left: 0; top: 0; width: 30px; height: 30px; display: grid; place-items: center; border-radius: 50%; background: #ffffff14; color: #fff; font-weight: 800; font-size: 14px; }
.gb-steps li.is-done::before { content: '✓'; background: #163d30; color: #9ff0c8; }
.gb-steps strong { color: #fff; }
.gb-steps em { font-style: normal; color: #fff; word-break: break-all; }
.gb-steps a { color: #ff8cc0; }

/* ---------- First sign-in: choose your own password (nothing else on screen) ---------- */
.first-password { max-width: 520px; margin: clamp(24px, 8vh, 72px) auto 0; }
.first-password h1 { margin-bottom: 10px; }
.first-password > p { margin: 0 0 18px; }
.first-password .field-group { margin-top: 6px; }
.first-password .save-bar .primary { flex: 1 1 auto; }
.first-password-error { margin: 0 0 14px; padding: 12px 14px; border-radius: 10px; background: #18181e; border: 1px solid #ff258780; box-shadow: inset 4px 0 0 #ff2587; color: #fff; }
body.is-locked .admin-header .admin-signout.admin-signout-locked { display: block; margin-left: auto; }
[data-password-hint].is-good { color: #9ff0c8; }
[data-password-hint].is-bad { color: #ff9ab8; }
.link-card { display: flex; justify-content: space-between; align-items: center; gap: 12px; text-decoration: none; }
.link-card span { color: var(--muted); }
.link-card:hover { border-color: #ffffff4d; }

}

/* Gallery: folder overview */
.gallery-totals { margin: 4px 0 12px; color: var(--muted); font-size: 14px; }
.gallery-totals b { color: #fff; }
.gallery-folders { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 10px; margin: 0 0 18px; }
.gallery-folder { display: grid; gap: 4px; align-content: start; padding: 8px; border: 1px solid var(--line); border-radius: 12px; background: #121217; color: inherit; text-align: left; font: inherit; cursor: pointer; filter: none; }
.gallery-folder:hover { border-color: #ffffff55; filter: none; }
.gallery-folder.is-active { border-color: var(--accent-strong); box-shadow: inset 0 0 0 1px var(--accent-strong); }
.gallery-folder-thumb { position: relative; display: block; aspect-ratio: 4 / 3; overflow: hidden; border-radius: 8px; background: #050507; }
.gallery-folder-thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }
.gallery-folder-thumb b { position: absolute; right: 6px; bottom: 6px; min-width: 26px; padding: 2px 8px; border-radius: 999px; background: #000000c0; color: #fff; font: 700 13px Arial, sans-serif; text-align: center; }
.gallery-folder-name { color: #fff; font-weight: 700; font-size: 14px; text-transform: capitalize; overflow-wrap: anywhere; }
.gallery-folder-count { color: var(--muted); font-size: 12.5px; }
.gallery-folder[data-gallery-folder=""] { align-content: center; min-height: 80px; }
@media (max-width: 560px) { .gallery-folders { grid-template-columns: 1fr 1fr; gap: 8px; } }

/* Site health: space between the sitemap blocks */
.field-group .save-bar + h2 { margin-top: 1.8rem; }

/* The Website Builder tab: deliberately a different colour from everything else. */
.admin-builder-tab { display: inline-flex; align-items: center; gap: .35rem; min-height: 40px; padding: .45rem .95rem; border-radius: 12px;
  background: linear-gradient(90deg, #22d3ee, #a3e635); color: #04121a !important; font-weight: 800; font-size: .9rem; text-decoration: none; white-space: nowrap;
  box-shadow: 0 0 0 1px #22d3ee55, 0 6px 22px -8px #22d3ee; }
.admin-builder-tab:hover, .admin-builder-tab:focus-visible { filter: brightness(1.08); }
@media (max-width: 520px) { .admin-builder-tab { padding: .4rem .65rem; font-size: .8rem; } }

/* iPhone/iPad: no zooming in when you tap a box (they zoom on anything under 16px). */
@media (pointer: coarse) { input:not([type=checkbox]):not([type=radio]):not([type=file]), select, textarea { font-size: 16px !important; } }
