:root {
  --orange: #ff4d2e;
  --orange-soft: #ff8b5c;
  --orange-tint: #fff3ee;
  --ink: #0f0f10;
  --ink-2: #2a2a2c;
  --muted: #6b6b70;
  --line: #e9e9ec;
  --bg: #ffffff;
  --bg-alt: #f7f7f8;
  --radius: 14px;
  --radius-lg: 22px;
  --shadow-sm: 0 1px 2px rgba(15, 15, 16, 0.04), 0 2px 8px rgba(15, 15, 16, 0.04);
  --shadow-md: 0 6px 24px rgba(15, 15, 16, 0.08);
  --container: 1200px;
  --ease: cubic-bezier(0.2, 0.7, 0.2, 1);
}

* {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
}

section[id] {
  scroll-margin-top: 88px;
}

:focus-visible {
  outline: 2px solid var(--orange);
  outline-offset: 3px;
  border-radius: 4px;
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
}

body {
  font-family: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, Helvetica, Arial,
    sans-serif;
  color: var(--ink);
  background: var(--bg);
  font-size: 16px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

a {
  color: inherit;
  text-decoration: none;
}

img,
svg {
  display: block;
  max-width: 100%;
}

h1,
h2,
h3 {
  font-weight: 800;
  letter-spacing: -0.02em;
  line-height: 1.08;
  margin: 0 0 0.4em;
  color: var(--ink);
}

h1 {
  font-size: clamp(2.4rem, 5.2vw, 4.4rem);
}

h2 {
  font-size: clamp(1.8rem, 3.2vw, 2.6rem);
}

h3 {
  font-size: 1.25rem;
  letter-spacing: -0.01em;
}

p {
  margin: 0 0 1em;
  color: var(--ink-2);
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  text-transform: uppercase;
  letter-spacing: 0.18em;
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--orange);
  margin: 0 0 1rem;
}

.eyebrow::before {
  content: "";
  width: 28px;
  height: 1px;
  background: currentColor;
  opacity: 0.8;
}

.section-head .eyebrow {
  justify-content: center;
}

/* Reveal-on-scroll */
.reveal {
  opacity: 0;
  transform: translateY(22px);
  transition: opacity 0.7s var(--ease), transform 0.7s var(--ease);
  will-change: opacity, transform;
}

.reveal.is-visible {
  opacity: 1;
  transform: none;
}

.concept-grid .reveal:nth-child(2) {
  transition-delay: 0.08s;
}
.concept-grid .reveal:nth-child(3) {
  transition-delay: 0.16s;
}
.roadmap-grid .reveal:nth-child(2) {
  transition-delay: 0.08s;
}
.roadmap-grid .reveal:nth-child(3) {
  transition-delay: 0.16s;
}

@media (prefers-reduced-motion: reduce) {
  .reveal {
    opacity: 1;
    transform: none;
    transition: none;
  }
}

.accent {
  color: var(--orange);
}

/* ---------- Nav ---------- */
.nav {
  position: sticky;
  top: 0;
  z-index: 50;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 18px clamp(20px, 5vw, 56px);
  background: rgba(255, 255, 255, 0.7);
  backdrop-filter: saturate(140%) blur(14px);
  -webkit-backdrop-filter: saturate(140%) blur(14px);
  border-bottom: 1px solid transparent;
  transition: border-color 0.3s var(--ease), background 0.3s var(--ease),
    box-shadow 0.3s var(--ease);
}

.nav.is-scrolled {
  background: rgba(255, 255, 255, 0.92);
  border-bottom-color: var(--line);
  box-shadow: 0 6px 24px rgba(15, 15, 16, 0.05);
}

.brand {
  display: inline-flex;
  align-items: center;
  font-weight: 800;
  font-size: 1.15rem;
  letter-spacing: -0.01em;
  line-height: 1;
}

.brand-mark {
  display: inline-block;
  padding: 6px 10px;
  border-radius: 7px;
  background: var(--orange);
  color: #fff;
  font-weight: 800;
}

.nav-links {
  display: flex;
  gap: 28px;
}

.nav-links a {
  font-size: 0.95rem;
  color: var(--ink-2);
  font-weight: 500;
  transition: color 0.2s var(--ease);
}

.nav-links a:hover {
  color: var(--orange);
}

.nav-cta {
  display: inline-flex;
  align-items: center;
  padding: 10px 16px;
  border-radius: 999px;
  background: var(--ink);
  color: #fff;
  font-size: 0.9rem;
  font-weight: 600;
  transition: transform 0.2s var(--ease), background 0.2s var(--ease);
}

.nav-cta:hover {
  background: var(--orange);
  transform: translateY(-1px);
}

.nav-actions {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-shrink: 0;
}

.nav-auth {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 40px;
  padding: 9px 14px;
  border: 1px solid var(--line);
  border-radius: 999px;
  color: var(--ink);
  font-size: 0.9rem;
  font-weight: 700;
  background: rgba(255, 255, 255, 0.72);
  transition: border-color 0.2s var(--ease), color 0.2s var(--ease),
    transform 0.2s var(--ease), background 0.2s var(--ease);
}

.nav-auth:hover {
  color: var(--orange);
  border-color: rgba(255, 77, 46, 0.45);
  background: #fff;
  transform: translateY(-1px);
}

@media (max-width: 760px) {
  .nav-links {
    display: none;
  }
  .nav {
    gap: 14px;
  }
  .nav-actions {
    gap: 8px;
  }
  .nav-cta {
    display: none;
  }
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 14px 22px;
  border-radius: 999px;
  font-weight: 600;
  font-size: 0.95rem;
  transition: transform 0.2s var(--ease), background 0.2s var(--ease),
    color 0.2s var(--ease), border-color 0.2s var(--ease);
  border: 1px solid transparent;
  white-space: nowrap;
}

.btn-primary {
  background: var(--orange);
  color: #fff;
  box-shadow: 0 8px 24px rgba(255, 77, 46, 0.25);
}

.btn-primary:hover {
  background: #ef3f1f;
  transform: translateY(-1px);
}

.btn-ghost {
  background: transparent;
  color: var(--ink);
  border-color: var(--line);
}

.btn-ghost:hover {
  border-color: var(--ink);
  background: var(--ink);
  color: #fff;
}

/* ---------- Section base ---------- */
section {
  padding: clamp(64px, 9vw, 120px) clamp(20px, 5vw, 56px);
}

.section-head {
  max-width: 720px;
  margin: 0 auto clamp(36px, 5vw, 56px);
  text-align: center;
}

.section-lede {
  font-size: 1.05rem;
  color: var(--muted);
}

/* ---------- Hero ---------- */
.hero {
  position: relative;
  overflow: hidden;
  background:
    radial-gradient(1100px 600px at 85% 10%, rgba(255, 139, 92, 0.18), transparent 60%),
    radial-gradient(900px 600px at 10% 90%, rgba(255, 77, 46, 0.1), transparent 65%),
    linear-gradient(180deg, #fff 0%, var(--orange-tint) 100%);
}

.hero-scroll {
  position: absolute;
  bottom: 28px;
  left: 50%;
  transform: translateX(-50%);
  display: inline-flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  color: var(--muted);
  font-size: 0.7rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  font-weight: 600;
  text-decoration: none;
  opacity: 0.75;
  transition: opacity 0.2s var(--ease), color 0.2s var(--ease);
  z-index: 3;
}

.hero-scroll:hover {
  opacity: 1;
  color: var(--orange);
}

.hero-scroll svg {
  width: 18px;
  height: 18px;
  animation: hero-bob 2.2s ease-in-out infinite;
}

@keyframes hero-bob {
  0%, 100% { transform: translateY(0); opacity: 0.7; }
  50% { transform: translateY(6px); opacity: 1; }
}

@media (max-width: 900px) {
  .hero-scroll { display: none; }
}

@media (prefers-reduced-motion: reduce) {
  .hero-scroll svg { animation: none; }
}

.hero-grid {
  max-width: var(--container);
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1.1fr 1fr;
  gap: clamp(32px, 6vw, 80px);
  align-items: center;
}

.hero-copy h1 {
  margin-bottom: 22px;
}

.lede {
  font-size: 1.15rem;
  color: var(--ink-2);
  max-width: 540px;
  margin-bottom: 32px;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-bottom: 48px;
}

.hero-stats {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
  max-width: 520px;
}

.hero-stats li {
  border-left: 2px solid var(--orange);
  padding: 4px 0 4px 14px;
}

.hero-stats strong {
  display: block;
  font-size: 1.9rem;
  font-weight: 800;
  letter-spacing: -0.03em;
  line-height: 1;
  background: linear-gradient(135deg, var(--orange) 0%, #ff7141 60%, #ffa37a 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.hero-stats span {
  font-size: 0.85rem;
  color: var(--muted);
}

.hero-visual {
  position: relative;
  aspect-ratio: 1;
  width: 100%;
}

.hero-shape {
  width: 100%;
  height: 100%;
  position: relative;
  z-index: 2;
  animation: spin 38s linear infinite;
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

.orb {
  position: absolute;
  border-radius: 50%;
  filter: blur(40px);
  opacity: 0.55;
}

.orb-a {
  width: 260px;
  height: 260px;
  background: var(--orange);
  top: 6%;
  left: 8%;
}

.orb-b {
  width: 200px;
  height: 200px;
  background: var(--orange-soft);
  bottom: 8%;
  right: 6%;
  opacity: 0.4;
}

.orb-c {
  width: 140px;
  height: 140px;
  background: #ffd0bf;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  opacity: 0.35;
}

@media (max-width: 900px) {
  .hero-grid {
    grid-template-columns: 1fr;
  }
  .hero-visual {
    max-width: 420px;
    margin: 0 auto;
  }
}

/* ---------- Concept ---------- */
.concept {
  background: var(--bg);
}

.concept-grid {
  max-width: var(--container);
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 20px;
}

.concept-card {
  position: relative;
  padding: 36px 28px;
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  background: var(--bg);
  overflow: hidden;
  transition: transform 0.3s var(--ease), border-color 0.3s var(--ease),
    box-shadow 0.3s var(--ease);
}

.concept-card::before {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at 0% 0%, rgba(255, 77, 46, 0.08), transparent 60%);
  opacity: 0;
  transition: opacity 0.35s var(--ease);
  pointer-events: none;
}

.concept-card:hover {
  transform: translateY(-6px);
  border-color: rgba(255, 77, 46, 0.35);
  box-shadow: 0 16px 40px rgba(255, 77, 46, 0.12), 0 2px 6px rgba(15, 15, 16, 0.04);
}

.concept-card:hover::before {
  opacity: 1;
}

.concept-num {
  position: absolute;
  top: 18px;
  right: 22px;
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  color: var(--orange);
  opacity: 0.5;
  font-feature-settings: "tnum" 1;
}

.concept-badge {
  display: inline-block;
  padding: 6px 12px;
  margin-bottom: 18px;
  border-radius: 999px;
  background: var(--orange-tint);
  color: var(--orange);
  font-weight: 700;
  font-size: 0.85rem;
  letter-spacing: -0.01em;
}

.concept-card p {
  color: var(--muted);
  margin: 0;
}

@media (max-width: 820px) {
  .concept-grid {
    grid-template-columns: 1fr;
  }
}

/* ---------- Products ---------- */
.products {
  background: var(--bg-alt);
}

.product-card {
  max-width: var(--container);
  margin: 0 auto;
  background: var(--bg);
  border-radius: var(--radius-lg);
  overflow: hidden;
  border: 1px solid var(--line);
  display: grid;
  grid-template-columns: 1fr 1fr;
  box-shadow: var(--shadow-sm);
  transition: transform 0.35s var(--ease), box-shadow 0.35s var(--ease);
}

.product-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 22px 60px rgba(15, 15, 16, 0.08), 0 4px 12px rgba(255, 77, 46, 0.08);
}

.product-card + .product-card {
  margin-top: 28px;
}

.product-card.reverse .product-copy {
  order: 2;
}

.product-card.reverse .product-visual {
  order: 1;
}

.product-copy {
  padding: clamp(32px, 4vw, 56px);
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.product-tag {
  display: inline-block;
  align-self: flex-start;
  padding: 5px 10px;
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  border-radius: 999px;
  background: rgba(255, 77, 46, 0.1);
  color: var(--orange);
  margin-bottom: 16px;
}

.product-card h3 {
  font-size: clamp(1.8rem, 2.6vw, 2.2rem);
  margin-bottom: 12px;
  display: flex;
  align-items: baseline;
  flex-wrap: wrap;
  gap: 12px;
}

.product-parent {
  font-size: 0.78rem;
  font-weight: 500;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted);
  padding: 4px 10px;
  border: 1px solid var(--line);
  border-radius: 999px;
  white-space: nowrap;
}

.product-lede {
  font-size: 1.05rem;
  color: var(--ink-2);
  margin-bottom: 20px;
}

.product-features {
  list-style: none;
  margin: 0 0 28px;
  padding: 0;
  display: grid;
  gap: 10px;
}

.product-features li {
  position: relative;
  padding-left: 24px;
  color: var(--ink-2);
  font-size: 0.97rem;
}

.product-features li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.55em;
  width: 12px;
  height: 12px;
  border-radius: 3px;
  background: var(--orange);
  transform: rotate(45deg);
}

.product-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.product-visual {
  position: relative;
  background: linear-gradient(135deg, #1a1a1c 0%, #2a2a2c 100%);
  min-height: 360px;
  overflow: hidden;
}

.map-mock {
  position: absolute;
  inset: 0;
}

.map-grid {
  position: absolute;
  inset: 0;
  background-image: linear-gradient(rgba(255, 255, 255, 0.06) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.06) 1px, transparent 1px);
  background-size: 36px 36px;
}

.map-grid::after {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(
    circle at 60% 50%,
    rgba(255, 77, 46, 0.2),
    transparent 60%
  );
}

.pin {
  position: absolute;
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: var(--orange);
  box-shadow: 0 0 0 4px rgba(255, 77, 46, 0.25), 0 0 24px rgba(255, 77, 46, 0.6);
}

.pin::after {
  content: "";
  position: absolute;
  inset: -8px;
  border-radius: 50%;
  border: 1px solid rgba(255, 77, 46, 0.5);
  animation: ping 2.4s var(--ease) infinite;
}

.pin-1 {
  top: 28%;
  left: 22%;
}
.pin-2 {
  top: 48%;
  left: 58%;
}
.pin-3 {
  top: 64%;
  left: 32%;
  animation-delay: 0.6s;
}
.pin-4 {
  top: 32%;
  left: 72%;
}

.pin-3::after {
  animation-delay: 0.4s;
}
.pin-4::after {
  animation-delay: 0.9s;
}

@keyframes ping {
  0% {
    transform: scale(0.6);
    opacity: 0.9;
  }
  100% {
    transform: scale(2.6);
    opacity: 0;
  }
}

.map-route {
  position: absolute;
  top: 30%;
  left: 24%;
  width: 50%;
  height: 36%;
  border-top: 2px dashed rgba(255, 139, 92, 0.7);
  border-right: 2px dashed rgba(255, 139, 92, 0.7);
  border-top-right-radius: 80px;
  opacity: 0.8;
}

.map-label {
  position: absolute;
  bottom: 18px;
  right: 20px;
  font-size: 0.78rem;
  letter-spacing: 0.06em;
  color: rgba(255, 255, 255, 0.65);
  font-weight: 500;
  font-family: ui-monospace, "SF Mono", Menlo, monospace;
}

/* ---------- Eatavenue visual ---------- */
.venue-visual {
  background: linear-gradient(160deg, #16161a 0%, #221f24 60%, #2a2024 100%);
}

.venue-mock {
  position: absolute;
  inset: 0;
  padding: 28px;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  gap: 14px;
}

.venue-skyline {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 38%;
  background:
    linear-gradient(180deg, transparent 0%, rgba(255, 77, 46, 0.05) 100%),
    linear-gradient(to top,
      #0e0d10 0,
      #0e0d10 28%,
      transparent 28%);
  -webkit-mask-image: linear-gradient(180deg, transparent 0, black 35%);
  mask-image: linear-gradient(180deg, transparent 0, black 35%);
}

.venue-skyline::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(90deg, #1a181d 12px, transparent 12px 22px, #1a181d 22px 44px, transparent 44px 60px, #1a181d 60px 96px, transparent 96px 114px, #1a181d 114px 138px, transparent 138px 152px, #1a181d 152px 188px, transparent 188px 208px, #1a181d 208px 234px, transparent 234px 254px, #1a181d 254px 290px, transparent 290px 312px, #1a181d 312px 340px, transparent 340px 360px, #1a181d 360px 396px);
  background-repeat: no-repeat;
  background-position: 0 100%;
  background-size: 100% 80%;
  mask-image: linear-gradient(to top,
    black 0,
    black 30%,
    rgba(0, 0, 0, 0.85) 55%,
    rgba(0, 0, 0, 0.55) 75%,
    transparent 100%);
  -webkit-mask-image: linear-gradient(to top,
    black 0,
    black 30%,
    rgba(0, 0, 0, 0.85) 55%,
    rgba(0, 0, 0, 0.55) 75%,
    transparent 100%);
}

.venue-heat {
  position: relative;
  z-index: 2;
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: 6px;
  width: min(78%, 360px);
  margin-top: 6px;
}

.venue-heat .cell {
  aspect-ratio: 1.4 / 1;
  border-radius: 4px;
  background: rgba(255, 255, 255, 0.05);
  transition: transform 0.3s var(--ease);
}

.venue-heat .cell.h1 {
  background: rgba(255, 139, 92, 0.18);
}
.venue-heat .cell.h2 {
  background: rgba(255, 139, 92, 0.4);
}
.venue-heat .cell.h3 {
  background: rgba(255, 77, 46, 0.6);
}
.venue-heat .cell.h4 {
  background: var(--orange);
  box-shadow: 0 0 18px rgba(255, 77, 46, 0.55);
}

.venue-arc {
  position: absolute;
  top: 8%;
  left: 6%;
  right: 6%;
  height: 56%;
  z-index: 1;
}

.venue-tag {
  position: absolute;
  z-index: 3;
  padding: 4px 10px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 139, 92, 0.5);
  color: #fff;
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
}

.tag-hk {
  top: calc(8% + 30%);
  left: 3%;
}

.tag-gba {
  top: 14%;
  right: 4%;
}

@media (max-width: 900px) {
  .product-card {
    grid-template-columns: 1fr;
  }
  .product-visual {
    min-height: 280px;
    order: -1;
  }
  .product-card.reverse .product-copy {
    order: 2;
  }
  .product-card.reverse .product-visual {
    order: 1;
  }
}

/* ---------- Roadmap ---------- */
.roadmap {
  position: relative;
  background: var(--ink);
  color: #fff;
  overflow: hidden;
}

.roadmap::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image: radial-gradient(circle, rgba(255, 255, 255, 0.05) 1px, transparent 1px);
  background-size: 26px 26px;
  mask-image: radial-gradient(ellipse at center, #000 30%, transparent 75%);
  -webkit-mask-image: radial-gradient(ellipse at center, #000 30%, transparent 75%);
  pointer-events: none;
}

.roadmap::after {
  content: "";
  position: absolute;
  top: -120px;
  left: 50%;
  width: 600px;
  height: 600px;
  transform: translateX(-50%);
  background: radial-gradient(circle, rgba(255, 77, 46, 0.18), transparent 65%);
  pointer-events: none;
  filter: blur(20px);
}

.roadmap > * {
  position: relative;
  z-index: 1;
}

.roadmap .section-head h2,
.roadmap .section-head .section-lede {
  color: #fff;
}

.roadmap .eyebrow {
  color: var(--orange-soft);
}

.roadmap-grid {
  max-width: var(--container);
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 20px;
}

.roadmap-card {
  padding: 32px 28px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: var(--radius-lg);
  background: rgba(255, 255, 255, 0.03);
  transition: transform 0.25s var(--ease), border-color 0.25s var(--ease),
    background 0.25s var(--ease);
}

.roadmap-card:hover {
  transform: translateY(-4px);
  border-color: rgba(255, 77, 46, 0.5);
  background: rgba(255, 77, 46, 0.06);
}

.roadmap-status {
  display: inline-block;
  padding: 4px 10px;
  margin-bottom: 16px;
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  border-radius: 999px;
  background: rgba(255, 139, 92, 0.15);
  color: var(--orange-soft);
}

.roadmap-card h3 {
  color: #fff;
  margin-bottom: 8px;
}

.roadmap-card p {
  color: rgba(255, 255, 255, 0.7);
  margin: 0;
  font-size: 0.97rem;
}

@media (max-width: 820px) {
  .roadmap-grid {
    grid-template-columns: 1fr;
  }
}

/* ---------- CTA ---------- */
.cta {
  background: var(--bg);
}

.cta-inner {
  max-width: 980px;
  margin: 0 auto;
  text-align: center;
  padding: clamp(48px, 6vw, 80px) clamp(28px, 5vw, 56px);
  background: linear-gradient(135deg, var(--orange) 0%, #ff7141 100%);
  color: #fff;
  border-radius: var(--radius-lg);
  box-shadow: 0 30px 80px rgba(255, 77, 46, 0.25);
}

.cta-inner h2 {
  color: #fff;
}

.cta-inner p {
  color: rgba(255, 255, 255, 0.92);
  font-size: 1.05rem;
  margin: 0 auto 28px;
  max-width: 540px;
}

.cta-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  justify-content: center;
}

.cta .btn-primary {
  background: #fff;
  color: var(--orange);
  box-shadow: none;
}

.cta .btn-primary:hover {
  background: var(--ink);
  color: #fff;
}

.cta .btn-ghost {
  border-color: rgba(255, 255, 255, 0.5);
  color: #fff;
}

.cta .btn-ghost:hover {
  background: #fff;
  color: var(--orange);
  border-color: #fff;
}

.auth-shell {
  max-width: 720px;
  margin: 0 auto;
  padding: 12px;
  border: 1px solid rgba(255, 255, 255, 0.36);
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.16);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.18);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
}

.auth-tabs {
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(0, 1fr) minmax(0, 1.35fr);
  gap: 6px;
  padding: 4px;
  border-radius: 8px;
  background: rgba(15, 15, 16, 0.14);
}

.auth-tab,
.dashboard-tab {
  min-height: 42px;
  border: 0;
  border-radius: 7px;
  font: inherit;
  padding: 0 10px;
  font-weight: 800;
  color: rgba(255, 255, 255, 0.78);
  background: transparent;
  cursor: pointer;
  white-space: nowrap;
  transition: background 0.2s var(--ease), color 0.2s var(--ease),
    transform 0.2s var(--ease);
}

.auth-tab:hover,
.dashboard-tab:hover {
  color: #fff;
}

.auth-tab.is-active {
  color: var(--orange);
  background: #fff;
  box-shadow: 0 10px 24px rgba(15, 15, 16, 0.12);
}

.auth-panels {
  padding: 18px 4px 4px;
}

.auth-panel {
  display: none;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
  align-items: start;
}

.auth-panel.is-active {
  display: grid;
}

.auth-panel label {
  display: grid;
  gap: 7px;
  color: #fff;
  font-size: 0.85rem;
  font-weight: 800;
  text-align: left;
}

.auth-panel input {
  width: 100%;
  min-height: 48px;
  padding: 12px 13px;
  border: 1px solid rgba(255, 255, 255, 0.5);
  border-radius: 8px;
  color: var(--ink);
  background: rgba(255, 255, 255, 0.95);
  font: inherit;
  outline: none;
  transition: border-color 0.2s var(--ease), box-shadow 0.2s var(--ease);
}

.auth-panel input:focus {
  border-color: #fff;
  box-shadow: 0 0 0 3px rgba(255, 255, 255, 0.24);
}

.field-hint {
  color: rgba(255, 255, 255, 0.78);
  font-size: 0.74rem;
  font-weight: 600;
  line-height: 1.35;
}

.auth-panel .btn-primary {
  grid-column: 1 / -1;
  align-self: start;
  min-height: 48px;
  background: var(--ink);
  color: #fff;
  border-color: var(--ink);
  box-shadow: none;
}

.auth-panel .btn-primary:hover {
  background: #fff;
  color: var(--orange);
  border-color: #fff;
}

.auth-panel[data-auth-panel="register"] {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  align-items: start;
}

.auth-panel[data-auth-panel="forgot"] label {
  grid-column: 1 / -1;
}

.auth-panel[data-auth-panel="register"] .btn {
  grid-column: span 2;
}

.auth-state {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  margin-top: 14px;
  padding: 12px 4px 0;
  color: rgba(255, 255, 255, 0.88);
  font-size: 0.92rem;
  font-weight: 600;
  text-align: left;
}

.auth-state > div {
  display: inline-flex;
  align-items: center;
  gap: 9px;
}

.status-dot {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: #fff;
  box-shadow: 0 0 0 4px rgba(255, 255, 255, 0.16);
  flex: 0 0 auto;
}

.dashboard-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 36px;
  padding: 8px 12px;
  border-radius: 999px;
  color: var(--orange);
  background: #fff;
  font-weight: 800;
  white-space: nowrap;
}

.dashboard-link[hidden] {
  display: none;
}

@media (max-width: 680px) {
  .auth-tabs {
    grid-template-columns: 1fr;
  }
  .auth-tab {
    justify-content: center;
    width: 100%;
  }
  .auth-panel,
  .auth-panel[data-auth-panel="register"] {
    grid-template-columns: 1fr;
  }
  .auth-panel[data-auth-panel="register"] .btn {
    grid-column: auto;
  }
  .auth-state {
    align-items: stretch;
    flex-direction: column;
  }
  .dashboard-link {
    width: 100%;
  }
}

/* ---------- Dashboard ---------- */
.dashboard {
  background: #f4f6f8;
  padding: clamp(64px, 8vw, 104px) clamp(20px, 5vw, 56px);
}

.dashboard[hidden] {
  display: none;
}

.dashboard-inner {
  max-width: var(--container);
  margin: 0 auto;
}

.dashboard-head {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 24px;
  margin-bottom: 24px;
}

.dashboard-head .section-lede {
  text-align: left;
  margin: 0;
}

.dashboard-logout {
  color: var(--ink);
  border-color: var(--line);
  background: #fff;
}

.dashboard-logout:hover {
  color: #fff;
  background: var(--ink);
  border-color: var(--ink);
}

.dashboard-tabs {
  display: inline-grid;
  grid-template-columns: repeat(2, minmax(160px, 1fr));
  gap: 6px;
  padding: 5px;
  margin-bottom: 24px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  box-shadow: var(--shadow-sm);
}

.dashboard-tab {
  color: var(--muted);
}

.dashboard-tab.is-active {
  color: #fff;
  background: var(--ink);
}

.dashboard-panel {
  display: none;
}

.dashboard-panel.is-active {
  display: block;
}

.dashboard-grid,
.admin-layout {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 16px;
}

.app-card,
.admin-card {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  min-height: 250px;
  padding: 22px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  box-shadow: var(--shadow-sm);
}

.app-card h3,
.admin-card h3 {
  margin-bottom: 10px;
}

.app-card p,
.admin-card p {
  color: var(--muted);
  font-size: 0.95rem;
  margin-bottom: 20px;
}

.app-card .btn {
  margin-top: auto;
  min-height: 42px;
  padding: 11px 16px;
}

.app-status,
.admin-kicker {
  display: inline-flex;
  align-items: center;
  min-height: 26px;
  padding: 4px 9px;
  margin-bottom: 14px;
  border-radius: 999px;
  color: var(--orange);
  background: var(--orange-tint);
  font-size: 0.74rem;
  font-weight: 800;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.admin-layout {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.admin-card {
  min-height: 220px;
  background: #111214;
  border-color: #24262b;
}

.admin-card h3 {
  color: #fff;
}

.admin-card p {
  color: rgba(255, 255, 255, 0.72);
}

@media (max-width: 1040px) {
  .dashboard-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .admin-layout {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 700px) {
  .dashboard-head {
    align-items: stretch;
    flex-direction: column;
  }
  .dashboard-tabs {
    display: grid;
    grid-template-columns: 1fr;
    width: 100%;
  }
  .dashboard-grid {
    grid-template-columns: 1fr;
  }
}

/* ---------- Dashboard Page ---------- */
.dashboard-page {
  min-height: 100vh;
  background: #f5f6f8;
}

.dash-topbar {
  position: sticky;
  top: 0;
  z-index: 20;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  min-height: 72px;
  padding: 0 clamp(20px, 4vw, 44px);
  border-bottom: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: blur(16px);
}

.dash-nav {
  display: flex;
  align-items: center;
  gap: 18px;
  color: var(--muted);
  font-size: 0.94rem;
  font-weight: 700;
}

.dash-nav a:hover,
.dash-link-button:hover {
  color: var(--ink);
}

.dash-link-button {
  border: 0;
  padding: 0;
  color: inherit;
  background: transparent;
  font: inherit;
  cursor: pointer;
}

.dash-main {
  width: 100%;
  margin: 0;
  padding: clamp(16px, 2.4vw, 28px) clamp(14px, 2vw, 28px) 56px;
}

.dash-auth {
  display: grid;
  place-items: center;
  min-height: calc(100vh - 160px);
}

.dash-auth[hidden],
.dash-shell[hidden],
.dash-nav [hidden] {
  display: none;
}

.dash-shell {
  padding: 0;
}

.dash-auth-panel {
  width: min(560px, 100%);
  padding: clamp(24px, 4vw, 40px);
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  box-shadow: var(--shadow-sm);
}

.dash-copy {
  max-width: 760px;
  color: var(--muted);
  font-size: 1rem;
}

.dash-login-form,
.admin-action {
  display: grid;
  gap: 14px;
}

.dash-login-form {
  margin-top: 24px;
}

.dash-login-form label,
.admin-action label {
  display: grid;
  gap: 8px;
  color: var(--ink);
  font-size: 0.92rem;
  font-weight: 800;
}

.dash-login-form input,
.admin-action input,
.admin-action select {
  width: 100%;
  min-height: 48px;
  padding: 0 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  color: var(--ink);
  background: #fff;
  font: inherit;
  font-weight: 650;
}

.dash-auth-actions {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-top: 16px;
  color: var(--muted);
  font-weight: 750;
}

.dash-auth-actions button {
  border: 0;
  padding: 0;
  color: inherit;
  background: transparent;
  font: inherit;
  cursor: pointer;
}

.dash-message {
  margin: 16px 0 0;
  color: var(--muted);
  font-size: 0.92rem;
  font-weight: 700;
}

.dash-hero {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 24px;
  padding: clamp(16px, 2.4vw, 24px);
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  box-shadow: var(--shadow-sm);
}

.dash-hero .eyebrow {
  margin-bottom: 0.55rem;
}

.dash-hero h1 {
  font-size: clamp(1.65rem, 2.4vw, 2.25rem);
  letter-spacing: 0;
}

.dash-hero .dash-copy {
  margin-bottom: 0;
  font-size: 0.96rem;
}

.dash-status {
  display: inline-flex;
  align-items: center;
  min-height: 34px;
  padding: 6px 12px;
  border-radius: 999px;
  color: #17653a;
  background: #e8f7ee;
  font-size: 0.82rem;
  font-weight: 850;
  text-transform: uppercase;
}

.dash-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 14px 0 18px;
}

.dash-tab {
  min-height: 42px;
  padding: 0 16px;
  border: 1px solid var(--line);
  border-radius: 8px;
  color: var(--muted);
  background: #fff;
  font: inherit;
  font-weight: 800;
  cursor: pointer;
}

.dash-tab.is-active {
  color: #fff;
  background: var(--ink);
  border-color: var(--ink);
}

.dash-panel {
  display: none;
}

.dash-panel.is-active {
  display: block;
}

.dash-section-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  margin-bottom: 16px;
}

.dash-section-head h2 {
  font-size: 1.35rem;
}

.dash-tools {
  display: flex;
  align-items: end;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 10px;
}

.dash-tool {
  display: grid;
  gap: 5px;
  color: var(--muted);
  font-size: 0.74rem;
  font-weight: 850;
  text-transform: uppercase;
}

.dash-tool input,
.dash-tool select {
  min-height: 38px;
  min-width: 180px;
  padding: 0 11px;
  border: 1px solid var(--line);
  border-radius: 8px;
  color: var(--ink);
  background: #fff;
  font: inherit;
  font-size: 0.9rem;
  font-weight: 700;
  text-transform: none;
}

.compact {
  min-height: 38px;
  padding: 9px 13px;
  border-radius: 8px;
  font-size: 0.9rem;
}

.dash-app-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
}

.dash-app-card,
.dash-data-block,
.admin-workbench {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  box-shadow: var(--shadow-sm);
}

.dash-app-card {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  min-height: 218px;
  padding: 20px;
}

.dash-app-card h3 {
  margin-top: 14px;
}

.dash-app-card p {
  color: var(--muted);
  font-size: 0.94rem;
}

.dash-app-meta {
  margin: 0 0 16px;
  color: var(--muted);
  font-size: 0.78rem;
  font-weight: 800;
}

.dash-app-card .btn {
  margin-top: auto;
}

.dash-card-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  width: 100%;
}

.dash-pill,
.dash-state {
  display: inline-flex;
  align-items: center;
  min-height: 26px;
  padding: 4px 9px;
  border-radius: 999px;
  font-size: 0.72rem;
  font-weight: 850;
  text-transform: uppercase;
}

.dash-pill {
  color: var(--orange);
  background: var(--orange-tint);
}

.dash-state,
.status-badge {
  color: #37506a;
  background: #e9f0f7;
}

.status-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 26px;
  padding: 4px 9px;
  border-radius: 999px;
  font-size: 0.72rem;
  font-weight: 900;
  line-height: 1;
  text-transform: uppercase;
  white-space: nowrap;
}

.status-badge.is-green {
  color: #0f6b3a;
  background: #e6f7ee;
}

.status-badge.is-amber {
  color: #8a4e00;
  background: #fff2d8;
}

.status-badge.is-red {
  color: #9f1b1b;
  background: #ffe6e6;
}

.status-badge.is-blue {
  color: #1d4f8f;
  background: #e7f0ff;
}

.status-badge.is-purple {
  color: #5b2b90;
  background: #f0e8ff;
}

.status-badge.is-gray {
  color: #4b5563;
  background: #eceff3;
}

.dash-data-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

.dash-data-grid.admin-data {
  grid-template-columns: repeat(auto-fit, minmax(340px, 1fr));
  margin-top: 14px;
}

.user-workbench {
  display: grid;
  grid-template-columns: minmax(280px, 0.8fr) minmax(0, 1.7fr);
  gap: 14px;
}

.user-list-block,
.user-detail-block {
  min-height: 520px;
}

.user-result {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 12px;
  width: 100%;
  min-height: 58px;
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  color: var(--ink);
  background: #fafafa;
  font: inherit;
  text-align: left;
  cursor: pointer;
}

.user-result:hover {
  border-color: #d4d8de;
  background: #fff;
}

.user-result.is-selected {
  border-color: rgba(255, 77, 50, 0.55);
  background: #fff4f1;
  box-shadow: inset 3px 0 0 var(--accent);
}

.user-result small,
.user-detail-head p,
.user-permission-card p,
.usage-empty {
  color: var(--muted);
}

.username-label {
  display: inline-block;
  width: fit-content;
  margin-top: 3px;
  color: #374151;
  font-size: 0.75rem;
  font-weight: 900;
}

.user-detail-empty {
  padding: 24px;
  border: 1px dashed #d9dce0;
  border-radius: 8px;
  color: var(--muted);
  background: #fbfbfc;
  font-weight: 700;
}

.user-detail-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 14px;
}

.user-detail-actions {
  display: inline-flex;
  align-items: center;
  justify-content: flex-end;
  flex-wrap: wrap;
  gap: 8px;
}

.user-detail-actions button,
.audit-user-link {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  color: var(--ink);
  font: inherit;
  font-weight: 850;
  cursor: pointer;
}

.user-detail-actions button {
  min-height: 34px;
  padding: 0 10px;
}

.user-permission-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.user-permission-card {
  display: grid;
  gap: 12px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fafafa;
}

.platform-permission-card {
  border-color: rgba(255, 77, 46, 0.22);
  background: #fffafa;
}

.user-permission-card h4 {
  margin: 0 0 4px;
  font-size: 1rem;
}

.permission-controls {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 8px;
}

.permission-controls select,
.permission-controls button {
  min-height: 38px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  font: inherit;
  font-weight: 800;
}

.permission-controls select {
  padding: 0 10px;
}

.permission-controls button {
  padding: 0 12px;
  cursor: pointer;
}

.permission-meta {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 6px;
}

.permission-note {
  color: var(--muted);
  font-size: 0.78rem;
  font-weight: 750;
}

.usage-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
}

.usage-cell {
  min-height: 58px;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}

.usage-cell strong {
  display: block;
  font-size: 1.05rem;
}

.usage-cell span {
  display: block;
  color: var(--muted);
  font-size: 0.75rem;
  font-weight: 800;
}

.usage-cell small {
  display: block;
  margin-top: 4px;
  color: var(--muted);
  font-size: 0.72rem;
  font-weight: 800;
}

.usage-cell.usage-warn {
  border-color: rgba(196, 132, 0, 0.42);
  background: #fffaf0;
}

.usage-cell.usage-over {
  border-color: rgba(202, 51, 30, 0.45);
  background: #fff3f0;
}

.usage-meter {
  height: 5px;
  margin-top: 7px;
  overflow: hidden;
  border-radius: 999px;
  background: #eef0f3;
}

.usage-meter span {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: #15803d;
}

.usage-meter.is-warn span {
  background: #b87500;
}

.usage-meter.is-over span {
  background: #c7371e;
}

.usage-meter.is-unlimited span {
  background: repeating-linear-gradient(90deg, #cbd1d9 0 6px, #e7eaee 6px 12px);
}

.audit-table {
  max-height: 66vh;
}

.audit-row {
  grid-template-columns: minmax(0, 1fr) max-content;
}

.audit-user-link {
  display: inline-block;
  max-width: 100%;
  padding: 0;
  overflow-wrap: anywhere;
  border: 0;
  background: transparent;
  text-align: left;
}

.audit-user-link:hover {
  color: var(--accent);
}

.batch-action {
  grid-template-columns: 1.2fr 1fr 1fr 1fr 1fr 1.15fr auto auto;
}

.batch-preview-block {
  margin-top: 14px;
}

.batch-select-row {
  cursor: pointer;
}

.batch-select-user {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  align-items: center;
  gap: 10px;
  min-width: 0;
}

.batch-select-user input {
  width: 16px;
  height: 16px;
  margin: 0;
}

.batch-preview-badges {
  display: inline-flex;
  align-items: center;
  justify-content: flex-end;
  flex-wrap: wrap;
  gap: 6px;
  min-width: 0;
}

.dash-data-block {
  min-height: 220px;
  padding: 18px;
}

.dash-data-block h3 {
  margin-bottom: 14px;
  font-size: 1rem;
}

.dash-table {
  display: grid;
  gap: 8px;
  max-height: 58vh;
  overflow: auto;
  padding-right: 2px;
}

.dash-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 12px;
  min-height: 44px;
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  color: var(--muted);
  background: #fafafa;
  font-size: 0.9rem;
}

.dash-row strong {
  color: var(--ink);
  font-size: 0.82rem;
  text-transform: uppercase;
}

.dash-row small {
  display: block;
  margin-top: 2px;
  color: var(--muted);
}

.dash-row > span:first-child {
  min-width: 0;
  overflow-wrap: anywhere;
}

.dash-row.action-row {
  grid-template-columns: minmax(180px, 1fr) max-content max-content;
}

.row-badges {
  display: inline-flex;
  align-items: center;
  justify-content: flex-end;
  flex-wrap: wrap;
  gap: 6px;
}

.row-actions {
  display: inline-flex;
  align-items: center;
  justify-content: flex-end;
  flex-wrap: wrap;
  gap: 6px;
}

.dash-row button {
  min-height: 30px;
  padding: 5px 9px;
  border: 1px solid var(--line);
  border-radius: 8px;
  color: var(--ink);
  background: #fff;
  font: inherit;
  font-size: 0.78rem;
  font-weight: 850;
  cursor: pointer;
}

.admin-action button:disabled,
.permission-controls button:disabled,
.dash-row button:disabled {
  cursor: not-allowed;
  opacity: 0.55;
}

.dash-empty {
  padding: 22px;
  border: 1px dashed #d9dce0;
  border-radius: 8px;
  color: var(--muted);
  background: #fbfbfc;
  font-weight: 700;
}

.admin-workbench {
  padding: 18px;
}

.schema-status {
  display: grid;
  gap: 4px;
  margin-bottom: 14px;
  padding: 12px 14px;
  border: 1px solid #d8eadf;
  border-radius: 8px;
  color: #17653a;
  background: #f0fbf4;
  font-size: 0.9rem;
  font-weight: 750;
}

.schema-status-global {
  margin: -4px 0 18px;
}

.schema-status strong {
  color: inherit;
}

.schema-status span,
.schema-status small {
  color: var(--muted);
}

.schema-status.is-warning {
  border-color: #ffd2d2;
  color: #9f1b1b;
  background: #fff4f4;
}

.schema-explainer {
  display: grid;
  gap: 16px;
}

.schema-summary,
.schema-diagram,
.schema-note-grid article {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  box-shadow: var(--shadow-sm);
}

.schema-summary {
  display: grid;
  grid-template-columns: minmax(240px, 0.72fr) 1fr;
  gap: 18px;
  align-items: end;
  padding: 18px;
}

.schema-summary h3 {
  margin: 0;
  font-size: 1.08rem;
  line-height: 1.25;
}

.schema-summary p {
  margin: 0;
  color: var(--muted);
  font-size: 0.95rem;
  font-weight: 650;
}

.schema-diagram {
  padding: 18px;
  background:
    linear-gradient(90deg, rgba(255, 77, 46, 0.08), transparent 36%),
    linear-gradient(180deg, #fff, #fbfbfc);
}

.schema-lane,
.schema-lane-wide,
.schema-table-grid,
.schema-app-row {
  display: grid;
  gap: 12px;
}

.schema-lane {
  grid-template-columns: minmax(260px, 420px);
  justify-content: center;
}

.schema-lane-wide {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.schema-table-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.schema-app-row {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.schema-flow {
  display: grid;
  place-items: center;
  min-height: 28px;
  color: #69727d;
  font-size: 1.15rem;
  font-weight: 900;
}

.schema-node {
  min-height: 118px;
  padding: 14px;
  border: 1px solid #dfe3e8;
  border-left: 4px solid #ff4d2e;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.92);
}

.schema-node span {
  display: block;
  color: #69727d;
  font-size: 0.72rem;
  font-weight: 900;
  letter-spacing: 0;
  text-transform: uppercase;
}

.schema-node strong {
  display: block;
  margin-top: 8px;
  color: var(--ink);
  font-size: 1rem;
  line-height: 1.18;
  overflow-wrap: anywhere;
}

.schema-node small {
  display: block;
  margin-top: 8px;
  color: var(--muted);
  font-size: 0.82rem;
  line-height: 1.35;
  overflow-wrap: anywhere;
}

.schema-node-identity {
  border-left-color: #17653a;
}

.schema-node-table {
  border-left-color: #274f8f;
}

.schema-node-app {
  border-left-color: #9f6b15;
}

.schema-note-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
}

.schema-note-grid article {
  padding: 16px;
}

.schema-note-grid h3 {
  margin: 0 0 8px;
  font-size: 0.98rem;
}

.schema-note-grid p {
  margin: 0;
  color: var(--muted);
  font-size: 0.9rem;
  font-weight: 650;
  line-height: 1.5;
}

.schema-note-grid code {
  font-size: 0.88em;
  overflow-wrap: anywhere;
}

.admin-action {
  grid-template-columns: 1fr 1.15fr 1.35fr 1fr 1.15fr auto;
  align-items: end;
}

.admin-action [hidden] {
  display: none;
}

.confirm-admin-change {
  display: flex;
  align-items: center;
  min-height: 48px;
  padding: 10px 12px;
  border: 1px solid #ffd2d2;
  border-radius: 8px;
  color: #9f1b1b;
  background: #fff4f4;
}

.confirm-admin-change input {
  width: 16px;
  min-height: 16px;
  margin: 0 8px 0 0;
}

@media (max-width: 1100px) {
  .dash-app-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
  .dash-data-grid.admin-data {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .user-workbench,
  .user-permission-list {
    grid-template-columns: 1fr;
  }
  .schema-note-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .admin-action {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 760px) {
  .dash-topbar,
  .dash-hero,
  .dash-section-head {
    align-items: flex-start;
    flex-direction: column;
  }
  .dash-main {
    width: 100%;
    padding-inline: 14px;
  }
  .dash-app-grid,
  .dash-data-grid,
  .dash-data-grid.admin-data,
  .admin-action,
  .batch-action,
  .schema-summary,
  .schema-lane-wide,
  .schema-table-grid,
  .schema-app-row,
  .schema-note-grid,
  .usage-grid {
    grid-template-columns: 1fr;
  }
  .dash-row,
  .dash-row.action-row {
    grid-template-columns: 1fr;
  }
  .schema-lane {
    grid-template-columns: 1fr;
  }
  .row-badges {
    justify-content: flex-start;
  }
  .row-actions {
    justify-content: flex-start;
  }
}

/* ---------- Footer ---------- */
.footer {
  background: var(--bg-alt);
  border-top: 1px solid var(--line);
  padding: 40px clamp(20px, 5vw, 56px);
}

.footer-inner {
  max-width: var(--container);
  margin: 0 auto;
  display: grid;
  grid-template-columns: auto 1fr auto;
  gap: 24px;
  align-items: center;
}

.footer-brand {
  display: inline-flex;
  align-items: center;
  font-weight: 800;
  font-size: 1.15rem;
  letter-spacing: -0.01em;
  line-height: 1;
}

.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 22px;
  justify-content: center;
}

.footer-links a {
  font-size: 0.92rem;
  color: var(--muted);
  transition: color 0.2s var(--ease);
}

.footer-links a:hover {
  color: var(--orange);
}

.footer-fine {
  font-size: 0.85rem;
  color: var(--muted);
  margin: 0;
  text-align: right;
}

@media (max-width: 720px) {
  .footer-inner {
    grid-template-columns: 1fr;
    text-align: center;
  }
  .footer-links {
    justify-content: center;
  }
  .footer-fine {
    text-align: center;
  }
}

@media (prefers-reduced-motion: reduce) {
  .hero-shape,
  .pin::after {
    animation: none;
  }
}
