:root {
  --bg-canvas: #F8F8F7;
  --bg-card: #FFFFFF;
  --bg-subtle: #F1F0EC;
  --ink-primary: #141413;
  --ink-secondary: #4B4A46;
  --ink-muted: #6E6C66;
  --border-soft: #E5E3DC;
  --border-hover: #CFCBC0;
  --accent: #141413;
  --accent-blue: #1D4ED8;
  --emerald-bg: #ECFDF5;
  --emerald-ink: #065F46;
  --emerald-border: #A7F3D0;
  --emerald-dot: #10B981;
  --amber-bg: #FFFBEB;
  --amber-ink: #92400E;
  --amber-border: #FDE68A;
  --amber-dot: #F59E0B;
  --font-sans: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
}

*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  background: var(--bg-canvas);
  color: var(--ink-primary);
  font-family: var(--font-sans);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

body {
  background: var(--bg-canvas);
  color: var(--ink-primary);
  min-height: 100vh;
}

body.drawer-locked {
  overflow: hidden;
}

body.subdomain-mode #studioShell {
  display: none;
}

.skip-link {
  position: absolute;
  left: -9999px;
  top: 12px;
  background: var(--ink-primary);
  color: #FFFFFF;
  padding: 8px 14px;
  border-radius: 8px;
  font-size: 13px;
  font-weight: 600;
  z-index: 500;
  text-decoration: none;
}

.skip-link:focus {
  left: 16px;
}

:focus-visible {
  outline: 2px solid var(--accent-blue);
  outline-offset: 2px;
}

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

.page-shell,
.subdomain-landing {
  max-width: 1160px;
  margin: 0 auto;
  padding: 0 28px;
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

.subdomain-landing[hidden] {
  display: none;
}

/* Header / Navbar */
.masthead {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 20px 0;
  gap: 16px;
}

.brand-lockup {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  color: var(--ink-primary);
}

.brand-mark {
  width: 24px;
  height: 24px;
  border-radius: 6px;
  border: 1.5px solid var(--ink-primary);
  overflow: hidden;
  display: grid;
  grid-template-columns: 1fr 1fr;
  grid-template-rows: 1fr 1fr;
  flex-shrink: 0;
}

.brand-mark span:nth-child(1) {
  background: var(--ink-primary);
  border-right: 1px solid var(--ink-primary);
  border-bottom: 1px solid var(--ink-primary);
}

.brand-mark span:nth-child(2) {
  border-bottom: 1px solid var(--ink-primary);
}

.brand-mark span:nth-child(3) {
  border-right: 1px solid var(--ink-primary);
}

.brand-name {
  font-size: 16px;
  font-weight: 700;
  letter-spacing: -0.02em;
}

.brand-domain {
  font-size: 13px;
  font-weight: 500;
  color: var(--ink-muted);
  padding-left: 10px;
  border-left: 1px solid var(--border-soft);
}

.masthead-nav,
.masthead-right {
  display: flex;
  align-items: center;
  gap: 20px;
}

.nav-link {
  font-size: 14px;
  font-weight: 500;
  color: var(--ink-secondary);
  text-decoration: none;
  transition: color 0.15s ease;
}

.nav-link:hover {
  color: var(--ink-primary);
}

.email-cta {
  font-size: 13.5px;
  font-weight: 600;
  color: var(--ink-primary);
  background: var(--bg-card);
  border: 1px solid var(--border-soft);
  padding: 7px 14px;
  border-radius: 999px;
  text-decoration: none;
  transition: border-color 0.15s ease, background-color 0.15s ease;
}

.email-cta:hover {
  border-color: var(--border-hover);
  background: var(--bg-subtle);
}

/* Hero */
.hero {
  padding: 36px 0 32px;
  max-width: 760px;
}

.hero-kicker {
  font-size: 13px;
  font-weight: 600;
  color: var(--ink-muted);
  margin-bottom: 12px;
}

.hero-headline {
  font-size: clamp(32px, 4.4vw, 48px);
  font-weight: 800;
  line-height: 1.1;
  letter-spacing: -0.03em;
  color: var(--ink-primary);
  margin-bottom: 16px;
}

.hero-lead {
  font-size: 17px;
  line-height: 1.6;
  color: var(--ink-secondary);
  max-width: 650px;
}

/* Filter Strip */
.toolbar-strip {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  margin-bottom: 20px;
  flex-wrap: wrap;
}

.filter-tabs {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 4px;
  background: var(--bg-subtle);
  border-radius: 999px;
}

.filter-tab {
  appearance: none;
  background: transparent;
  border: none;
  padding: 7px 14px;
  border-radius: 999px;
  font-family: var(--font-sans);
  font-size: 13.5px;
  font-weight: 600;
  color: var(--ink-secondary);
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  transition: background-color 0.15s ease, color 0.15s ease, box-shadow 0.15s ease;
}

.filter-tab:hover {
  color: var(--ink-primary);
}

.filter-tab[aria-selected="true"] {
  background: var(--bg-card);
  color: var(--ink-primary);
  box-shadow: 0 1px 3px rgba(20, 20, 19, 0.08);
}

.filter-count {
  font-size: 12px;
  font-weight: 600;
  color: var(--ink-muted);
}

.toolbar-note {
  font-size: 13px;
  color: var(--ink-muted);
}

/* 2x2 Product Bento Grid */
.product-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 20px;
  margin-bottom: 40px;
}

.product-card {
  background: var(--bg-card);
  border: 1px solid var(--border-soft);
  border-radius: 18px;
  padding: 26px 28px;
  display: flex;
  flex-direction: column;
  gap: 14px;
  cursor: pointer;
  transition: border-color 0.18s ease, box-shadow 0.18s ease, transform 0.18s ease;
}

.product-card[hidden] {
  display: none;
}

.product-card:hover {
  border-color: var(--border-hover);
  box-shadow: 0 10px 28px rgba(20, 20, 19, 0.06);
  transform: translateY(-1px);
}

.card-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
}

.category-label {
  font-size: 12.5px;
  font-weight: 600;
  color: var(--ink-muted);
}

.dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  display: inline-block;
  flex-shrink: 0;
}

.dot-emerald { background: var(--emerald-dot); }
.dot-amber { background: var(--amber-dot); }

.pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 10px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 600;
  white-space: nowrap;
}

.pill-live {
  background: var(--emerald-bg);
  color: var(--emerald-ink);
  border: 1px solid var(--emerald-border);
}

.pill-upcoming {
  background: var(--amber-bg);
  color: var(--amber-ink);
  border: 1px solid var(--amber-border);
}

.card-header {
  display: flex;
  flex-direction: column;
  gap: 3px;
}

.card-title-btn {
  appearance: none;
  background: none;
  border: none;
  padding: 0;
  text-align: left;
  font-family: var(--font-sans);
  font-size: 24px;
  font-weight: 700;
  line-height: 1.2;
  letter-spacing: -0.02em;
  color: var(--ink-primary);
  cursor: pointer;
}

.card-domain {
  font-size: 13px;
  font-weight: 500;
  color: var(--ink-muted);
}

.card-desc {
  font-size: 14.5px;
  line-height: 1.6;
  color: var(--ink-secondary);
}

.feature-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: auto;
  padding-top: 4px;
}

.feature-chip {
  font-size: 12px;
  font-weight: 500;
  color: var(--ink-secondary);
  background: var(--bg-subtle);
  padding: 5px 10px;
  border-radius: 8px;
}

.card-actions {
  display: flex;
  align-items: center;
  gap: 10px;
  padding-top: 8px;
  border-top: 1px solid var(--border-soft);
  flex-wrap: wrap;
}

.btn-card-primary,
.btn-primary {
  appearance: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  background: var(--ink-primary);
  color: #FFFFFF;
  border: 1px solid var(--ink-primary);
  padding: 9px 16px;
  border-radius: 10px;
  font-family: var(--font-sans);
  font-size: 13.5px;
  font-weight: 600;
  text-decoration: none;
  cursor: pointer;
  transition: opacity 0.15s ease;
}

.btn-primary.rink {
  background: var(--accent-blue);
  border-color: var(--accent-blue);
}

.btn-card-primary:hover,
.btn-primary:hover {
  opacity: 0.88;
}

.btn-card-secondary,
.btn-secondary {
  appearance: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  background: var(--bg-card);
  color: var(--ink-primary);
  border: 1px solid var(--border-soft);
  padding: 9px 15px;
  border-radius: 10px;
  font-family: var(--font-sans);
  font-size: 13.5px;
  font-weight: 600;
  text-decoration: none;
  cursor: pointer;
  transition: background-color 0.15s ease, border-color 0.15s ease;
}

.btn-card-secondary:hover,
.btn-secondary:hover {
  background: var(--bg-subtle);
  border-color: var(--border-hover);
}

/* Footer */
.colophon {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 20px 0 28px;
  border-top: 1px solid var(--border-soft);
  font-size: 13px;
  color: var(--ink-muted);
  margin-top: auto;
  gap: 16px;
  flex-wrap: wrap;
}

.subdomain-map {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.subdomain-link {
  appearance: none;
  background: none;
  border: none;
  padding: 0;
  font-family: var(--font-sans);
  font-size: 13px;
  font-weight: 500;
  color: var(--ink-secondary);
  text-decoration: none;
  cursor: pointer;
}

.subdomain-link:hover {
  color: var(--ink-primary);
  text-decoration: underline;
}

/* Drawer / Slide-Over */
.drawer-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(20, 20, 19, 0.4);
  backdrop-filter: blur(4px);
  display: flex;
  justify-content: flex-end;
  z-index: 200;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition: opacity 0.2s ease, visibility 0s linear 0.2s;
}

.drawer-backdrop.is-open {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
  transition: opacity 0.2s ease, visibility 0s linear 0s;
}

.slide-over {
  width: 620px;
  max-width: 100vw;
  height: 100vh;
  background: var(--bg-card);
  border-left: 1px solid var(--border-soft);
  padding: 20px 28px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 14px;
  box-shadow: -20px 0 50px rgba(20, 20, 19, 0.12);
  overflow-y: auto;
  transform: translateX(24px);
  transition: transform 0.22s ease;
}

.drawer-backdrop.is-open .slide-over {
  transform: translateX(0);
}

#drawerContent {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 16px;
  min-height: 100%;
}

.sheet-top-bar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--border-soft);
  margin-bottom: 14px;
}

.close-btn {
  appearance: none;
  background: var(--bg-subtle);
  border: 1px solid transparent;
  padding: 6px 13px;
  border-radius: 999px;
  font-family: var(--font-sans);
  font-size: 13px;
  font-weight: 600;
  color: var(--ink-primary);
  cursor: pointer;
}

.close-btn:hover {
  border-color: var(--border-hover);
}

.sheet-hero {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-bottom: 14px;
}

.sheet-title {
  font-size: 26px;
  font-weight: 800;
  line-height: 1.18;
  letter-spacing: -0.025em;
  color: var(--ink-primary);
}

.sheet-title span,
.subdomain-headline span {
  color: var(--accent-blue);
}

.sheet-summary {
  font-size: 15px;
  line-height: 1.6;
  color: var(--ink-secondary);
}

.flow-strip {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
  margin-top: 6px;
}

.flow-step {
  background: var(--bg-canvas);
  border: 1px solid var(--border-soft);
  border-radius: 12px;
  padding: 12px;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.flow-step-num {
  font-size: 11.5px;
  font-weight: 700;
  color: var(--ink-muted);
}

.flow-step strong {
  font-size: 13.5px;
  color: var(--ink-primary);
}

.flow-step span {
  font-size: 12.5px;
  line-height: 1.45;
  color: var(--ink-secondary);
}

.capability-stack {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-bottom: 14px;
}

.cap-item {
  background: var(--bg-canvas);
  border: 1px solid var(--border-soft);
  border-radius: 14px;
  padding: 13px 16px;
  display: flex;
  flex-direction: column;
  gap: 5px;
}

.cap-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.cap-title {
  font-size: 15px;
  font-weight: 700;
  color: var(--ink-primary);
}

.cap-badge {
  font-size: 11.5px;
  font-weight: 600;
  color: var(--ink-secondary);
  background: var(--bg-card);
  border: 1px solid var(--border-soft);
  padding: 2px 8px;
  border-radius: 999px;
}

.cap-copy {
  font-size: 13.5px;
  line-height: 1.55;
  color: var(--ink-secondary);
}

.excerpt-box {
  background: var(--bg-card);
  border: 1px solid var(--border-soft);
  border-radius: 14px;
  overflow: hidden;
}

.excerpt-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 11px 16px;
  background: var(--bg-subtle);
  border-bottom: 1px solid var(--border-soft);
  font-size: 12.5px;
  font-weight: 600;
  color: var(--ink-secondary);
}

.excerpt-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  padding: 12px 16px;
  border-bottom: 1px solid var(--border-soft);
  font-size: 13.5px;
}

.excerpt-row:last-child {
  border-bottom: none;
}

.excerpt-sub {
  font-size: 12.5px;
  color: var(--ink-muted);
  margin-top: 2px;
}

.spot-chip {
  display: inline-flex;
  align-items: center;
  padding: 5px 10px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 600;
  background: var(--emerald-bg);
  color: var(--emerald-ink);
  border: 1px solid var(--emerald-border);
  text-decoration: none;
  white-space: nowrap;
}

.spot-chip.watch,
.spot-chip.amber {
  background: var(--amber-bg);
  color: var(--amber-ink);
  border-color: var(--amber-border);
}

.sheet-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  padding-top: 16px;
  border-top: 1px solid var(--border-soft);
  flex-wrap: wrap;
}

.sheet-footer-meta {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.sheet-footer-meta strong {
  font-size: 14px;
  color: var(--ink-primary);
}

.sheet-footer-meta span {
  font-size: 12.5px;
  color: var(--ink-muted);
}

.sheet-footer-btns {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

/* Subdomain Standalone Landing */
.subdomain-grid {
  display: grid;
  grid-template-columns: 1.08fr 0.92fr;
  gap: 32px;
  padding: 28px 0 40px;
  align-items: start;
  flex: 1;
}

.subdomain-left {
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.subdomain-badge {
  margin-bottom: 12px;
}

.subdomain-headline {
  font-size: clamp(28px, 3.6vw, 40px);
  font-weight: 800;
  line-height: 1.14;
  letter-spacing: -0.025em;
  color: var(--ink-primary);
}

.subdomain-lead {
  font-size: 16px;
  line-height: 1.6;
  color: var(--ink-secondary);
}

.subdomain-right {
  background: var(--bg-card);
  border: 1px solid var(--border-soft);
  border-radius: 18px;
  padding: 24px;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.subdomain-right-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--border-soft);
  font-size: 13px;
  font-weight: 700;
  color: var(--ink-secondary);
}

.subdomain-right .capability-stack {
  margin-bottom: 0;
}

.subdomain-spec-foot {
  font-size: 12.5px;
  color: var(--ink-muted);
  padding-top: 8px;
  border-top: 1px solid var(--border-soft);
}

/* 404 Page */
.not-found-main {
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 16px;
  max-width: 600px;
  padding: 48px 0;
}

.not-found-title {
  margin-bottom: 0;
}

/* Responsive */
@media (max-width: 860px) {
  .product-grid,
  .subdomain-grid,
  .flow-strip {
    grid-template-columns: 1fr;
  }

  .page-shell,
  .subdomain-landing {
    padding: 0 18px;
  }

  .slide-over {
    padding: 22px 20px;
  }
}
