/* BMEHQ palette
   --navy      header / major branding
   --blue      buttons / links / accents
   --me-green  Brand ME logo accent only (do not flood the UI)
   --paper     page background
   --card      cards / creator workspace
   --ink       main text
   --muted     secondary text
*/
:root {
  --navy: #0a3d73;
  --navy-2: #1256a0;
  --blue: #1a6fb5;
  --blue-2: #2b86d1;
  --me-green: #1aa34a;
  --sky: #e7f2fb;
  --paper: #f4f8fc;
  --card: #ffffff;
  --ink: #123a5c;
  --muted: #5b7390;
  --line: rgba(10, 61, 115, 0.14);
  --white: #ffffff;
  --serif: Georgia, "Times New Roman", serif;
  --sans: "Segoe UI", Tahoma, sans-serif;
}

* { box-sizing: border-box; }
html, body { margin: 0; min-height: 100%; }
body {
  background: var(--paper);
  color: var(--ink);
  font-family: var(--sans);
  line-height: 1.5;
}
a { color: var(--blue); text-decoration: none; }
a:hover { color: var(--navy-2); }
img { max-width: 100%; display: block; }

.wrap { width: min(1120px, calc(100% - 32px)); margin: 0 auto; }
.narrow { width: min(520px, calc(100% - 32px)); }
.bar { display: flex; align-items: center; justify-content: space-between; gap: 16px; }
.site-header {
  position: sticky; top: 0; z-index: 4;
  background: var(--navy);
  padding: 10px 0;
}
.site-header .bar { flex-wrap: wrap; }
.site-footer {
  margin-top: 64px; padding: 28px 0 48px;
  border-top: 1px solid var(--line);
  color: var(--muted);
}
.brand { display: flex; align-items: center; }
.brand img { height: 100px; width: auto; display: block; }
.footer-brand img { height: 44px; width: auto; display: block; }
.nav { display: flex; align-items: center; gap: 18px; }
.nav a { color: var(--white); }
.nav a:hover { color: #cfe6f8; }
.nav-cta, .gold-btn, button.gold-btn {
  display: inline-flex; align-items: center; justify-content: center;
  background: var(--blue); color: var(--white); border: 0; min-height: 42px; padding: 0 18px;
  font: 600 14px var(--sans); cursor: pointer;
}
.nav-cta:hover, .gold-btn:hover, button.gold-btn:hover { background: var(--blue-2); color: var(--white); }
.ghost-btn {
  display: inline-flex; align-items: center; min-height: 42px; padding: 0 18px;
  border: 1px solid var(--line); color: var(--navy);
}
.actions { display: flex; gap: 12px; flex-wrap: wrap; }
.text-btn, .inline { display: inline; background: none; border: 0; color: inherit; font: inherit; cursor: pointer; padding: 0; }
.nav .text-btn { color: #cfe6f8; }
.kicker { text-transform: uppercase; letter-spacing: 0.22em; font-size: 11px; color: var(--blue); }
h1, h2, h3 { font-family: var(--serif); font-weight: 400; line-height: 1.1; margin: 8px 0 16px; color: var(--navy); }
h1 { font-size: clamp(40px, 7vw, 84px); }
h2 { font-size: 32px; }
.lede { font-size: 20px; max-width: 38rem; color: var(--muted); }
.hero {
  background: linear-gradient(165deg, #0a3d73 0%, #1565a8 72%, #1a6fb5 100%);
  color: var(--white);
  padding: 72px 0 64px;
}
.hero h1 { color: var(--white); }
.hero .lede { color: #d7e9f8; }
.hero .kicker { color: #9fd0f5; }
.hero .ghost-btn { color: var(--white); border-color: rgba(255,255,255,.35); }
.hero .gold-btn { background: var(--white); color: var(--navy); }
.hero .gold-btn:hover { background: var(--sky); color: var(--navy); }
.page { padding: 48px 0 24px; }
.examples { padding: 56px 0 8px; }
.examples h2 { font-size: clamp(32px, 5vw, 56px); margin-bottom: 8px; }
.example-gallery {
  display: grid;
  grid-template-columns: 230px minmax(0, 1.35fr) minmax(0, 1fr) 168px;
  gap: 20px;
  align-items: start;
  margin-top: 28px;
}
.example-card {
  background: var(--card);
  border: 1px solid var(--line);
  padding: 14px;
  margin: 0;
  min-width: 0;
}
.example-card.is-splash { grid-column: 1; grid-row: 1 / span 2; }
.example-card.is-wide { grid-column: 2 / span 2; }
.example-card.is-mid { grid-column: 2; }
.example-card.is-box { grid-column: 3; }
.example-card.is-sky { grid-column: 4; grid-row: 1 / span 2; }
.example-card.is-strip { grid-column: 2 / span 2; }
.example-frame {
  background: #d7e6f4;
  padding: 10px;
  display: grid;
  place-items: center;
}
.example-frame .stage {
  width: 100%;
  max-width: none;
  box-shadow: 0 10px 28px rgba(10, 61, 115, 0.16);
}
.example-card.is-splash .example-frame .stage {
  width: min(100%, 210px);
}
.example-card figcaption {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
  margin-top: 12px;
  font-size: 13px;
  color: var(--muted);
}
.example-card.is-splash figcaption,
.example-card.is-sky figcaption {
  flex-direction: column;
  align-items: flex-start;
  gap: 2px;
}
.example-card figcaption strong { color: var(--navy); font-weight: 600; }
.example-cta { margin-top: 28px; }
.example-gallery.is-live {
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
}
.example-gallery.is-live .example-card {
  grid-column: auto;
  grid-row: auto;
}
.example-gallery.is-live .example-card.is-splash { max-width: 260px; }
.example-gallery.is-live .example-card.is-sky { max-width: 180px; }
.example-gallery.is-live .example-card.is-wide,
.example-gallery.is-live .example-card.is-strip { grid-column: 1 / -1; }
.quotes { padding: 24px 0 8px; }
.quotes h2 { font-size: clamp(28px, 4vw, 44px); }
.quote-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 20px;
  margin-top: 24px;
}
.quote-card {
  margin: 0;
  background: var(--card);
  border: 1px solid var(--line);
  padding: 24px;
}
.quote-card blockquote {
  margin: 0 0 16px;
  font-family: var(--serif);
  font-size: 20px;
  line-height: 1.35;
  color: var(--navy);
}
.quote-card figcaption { color: var(--muted); font-size: 14px; }
.check {
  display: flex;
  flex-direction: row;
  align-items: flex-start;
  gap: 8px;
  color: var(--ink);
}
.check input { width: auto; margin-top: 3px; }
.plain { padding-left: 18px; color: var(--muted); }
.plain em { color: var(--ink); font-style: italic; }
.split { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 20px; margin: 40px 0; }
.panel, .plan, .row-card { background: var(--card); border: 1px solid var(--line); padding: 24px; }
.plan-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 20px; }
.plan ul { padding-left: 18px; color: var(--muted); }
.price { font-family: var(--serif); font-size: 48px; margin: 0; color: var(--navy); }
.price span { font-size: 16px; color: var(--muted); }
.plan.is-gold { border-color: var(--blue); box-shadow: 0 10px 30px rgba(26, 111, 181, 0.12); }
.stack { display: grid; gap: 12px; }
label { display: grid; gap: 6px; font-size: 13px; color: var(--muted); }
input, select, textarea, button {
  font: inherit; color: var(--ink); background: var(--card); border: 1px solid var(--line); padding: 10px 12px;
}
textarea { min-height: 72px; }
.error, .flash { color: var(--navy-2); }
.muted, .fine { color: var(--muted); }
.row-card { display: flex; justify-content: space-between; gap: 12px; align-items: center; margin-bottom: 10px; }
.row-actions { display: flex; gap: 12px; align-items: center; }
.list-block { margin-top: 36px; }
.studio-body { background: var(--paper); color: var(--ink); }
.studio-body .site-header,
.studio-body .site-footer { display: none; }
.studio-body .flash { margin: 0; padding: 10px 20px; }
.studio-top { display: flex; gap: 16px; align-items: center; padding: 16px 20px; border-bottom: 1px solid var(--line); background: var(--white); }
.studio-grid { display: grid; grid-template-columns: minmax(0, 1fr) 340px; height: calc(100vh - 88px); }
.canvas-well { background: #d7e6f4; display: grid; place-items: center; padding: 16px; overflow: auto; }
.inspector { border-left: 1px solid var(--line); padding: 16px; overflow: auto; height: 100%; background: var(--white); }
.stage {
  container-type: inline-size;
  width: min(100%, 900px);
  position: relative;
  overflow: hidden;
  box-shadow: 0 24px 60px rgba(10, 61, 115, .18);
}
.splash-body { background: var(--navy); }
.splash-shell { min-height: 100vh; display: grid; place-items: center; padding: 0; }
.splash-shell .stage { width: min(100vw, calc(100vh * var(--cw) / var(--ch))); max-height: 100vh; }
.el { position: absolute; overflow: hidden; }
.el img, .el-shape, .el-btn, .el-text { width: 100%; height: 100%; }
.el img { max-width: none; object-fit: fill; pointer-events: none; }
.resize {
  position: absolute; width: 10px; height: 10px; background: var(--blue);
  border: 1px solid #fff; z-index: 3; box-sizing: border-box;
}
.resize.nw { left: -5px; top: -5px; cursor: nwse-resize; }
.resize.ne { right: -5px; top: -5px; cursor: nesw-resize; }
.resize.sw { left: -5px; bottom: -5px; cursor: nesw-resize; }
.resize.se { right: -5px; bottom: -5px; cursor: nwse-resize; }
.el-text { white-space: pre-wrap; line-height: 1.15; }
.el-btn { display: grid; place-items: center; font-family: var(--sans); font-weight: 600; color: inherit; }
.is-ellipse { border-radius: 50%; }
.el-fields { border: 1px solid var(--line); margin: 0 0 12px; padding: 10px; }
.xy { display: grid; grid-template-columns: 1fr 1fr 1fr 1fr; gap: 6px; }
.tool-row, .nudge { display: flex; flex-wrap: wrap; gap: 8px; margin: 12px 0; }
.noscript-note { margin: 0; padding: 10px 20px; color: var(--muted); font-size: 13px; border-bottom: 1px solid var(--line); background: var(--sky); }
.live-link { word-break: break-all; }
.is-editable { cursor: move; outline: 1px dashed transparent; }
.is-editable:hover, .is-editable.is-on { outline-color: var(--blue); }

@media (max-width: 1000px) {
  .example-gallery {
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  }
  .example-card.is-splash,
  .example-card.is-wide,
  .example-card.is-mid,
  .example-card.is-box,
  .example-card.is-sky,
  .example-card.is-strip {
    grid-column: auto;
    grid-row: auto;
  }
  .example-card.is-splash,
  .example-card.is-sky { justify-self: center; width: min(100%, 230px); }
}
@media (max-width: 800px) {
  .studio-grid { grid-template-columns: 1fr; height: auto; }
  .canvas-well { height: 46vh; }
  .inspector { height: auto; border-left: 0; border-top: 1px solid var(--line); }
  .nav { gap: 10px; font-size: 14px; }
  .brand img { height: 72px; }
  .example-gallery { grid-template-columns: minmax(0, 1fr); }
}
