*, *::before, *::after {
  box-sizing: border-box;
}
html {
  color-scheme: light;
  font-size: clamp(14px, 0.25vw + 13.2px, 16px);
}
:root {
  --bg: var(--sm-paper);
  --bg-soft: var(--sm-panel);
  --bg-elevated: rgba(255, 255, 255, 0.84);
  --bg-card: rgba(255, 255, 255, 0.92);
  --bg-input: rgba(255, 255, 255, 0.92);
  --surface: var(--sm-surface);
  --surface-strong: var(--sm-surface);
  --border: var(--sm-line);
  --border-strong: rgba(20, 60, 35, 0.22);
  --text: var(--sm-ink);
  --text-soft: var(--sm-ink-2);
  --text-muted: var(--sm-muted);
  --brand: var(--sm-accent);
  --brand-deep: var(--sm-accent-ink);
  --brand-soft: var(--sm-mint-soft);
  --accent: var(--sm-accent);
  --danger: #a82020;
  --warning: #a86a00;
  --play-yellow: #ffd86b;
  --play-coral: #ff8f7d;
  --play-sky: #84d7f5;
  --shadow-sm: 0 1px 2px rgba(10, 40, 20, 0.04), 0 2px 6px rgba(10, 40, 20, 0.03);
  --shadow: 0 2px 4px rgba(10, 40, 20, 0.05), 0 8px 24px rgba(10, 40, 20, 0.07);
  --shadow-lg: 0 4px 8px rgba(10, 40, 20, 0.06), 0 16px 48px rgba(10, 40, 20, 0.10);
  --shadow-soft: var(--shadow-sm);
  --shadow-glow: 0 0 0 1px rgba(20, 92, 50, 0.08), 0 4px 16px rgba(20, 92, 50, 0.12);
  --brand-gradient: linear-gradient(135deg, #145c32 0%, #175f35 100%);
  --bg-mesh: none;
  --radius-xl: 20px;
  --radius-lg: 16px;
  --radius-md: 12px;
  --radius-sm: 8px;
  --radius-pill: 999px;
  --font-body: "Space Grotesk", system-ui, -apple-system, "Segoe UI", sans-serif;
  --font-heading: "Space Grotesk", system-ui, -apple-system, "Segoe UI", sans-serif;
  --font-head: var(--font-heading);
  --ease-out: cubic-bezier(0.22, 1, 0.36, 1);
  --ease-spring: cubic-bezier(0.34, 1.56, 0.64, 1);
  --sm-paper: #faf8f3;
  --sm-panel: #f1ede4;
  --sm-surface: #fff;
  --sm-ink: #111512;
  --sm-ink-2: #4a524c;
  --sm-muted: #5f6f64;
  --sm-line: #e7e4dc;
  --sm-accent: #145c32;
  --sm-accent-ink: #0e3d1f;
  --sm-forest: #0f3d22;
  --sm-mint: #b6f0c8;
  --sm-mint-soft: #e6f3e9;
  --sm-gold: #d9a441;
  --sm-crayon-1: #ef4444;
  --sm-crayon-2: #f59e0b;
  --sm-crayon-3: #facc15;
  --sm-crayon-4: #22c55e;
  --sm-crayon-5: #3b82f6;
  --sm-crayon-6: #a855f7;
  --sm-r-card: 16px;
  --sm-r-input: 12px;
  --sm-r-pill: 999px;
  --sm-shadow-card: 0 1px 2px rgba(0, 0, 0, .04), 0 12px 32px rgba(0, 0, 0, .06);
  --sm-font-display: "Space Grotesk", system-ui, -apple-system, "Segoe UI", sans-serif;
  --sm-font-body: system-ui, -apple-system, "Segoe UI", sans-serif;
  --sm-font-mono: "Space Mono", ui-monospace, monospace;
  --sm-on-accent: #fff;
  --sm-on-forest: #fff;
  --sm-on-gold: #111512;
  --sm-danger: #b42318;
  --sm-danger-soft: #fdecea;
  --sm-r-book: 14px;
  --sm-shadow-pop: 0 4px 12px rgba(17, 21, 18, .08), 0 24px 48px rgba(17, 21, 18, .12);
  --sm-scrim: rgba(17, 21, 18, .45);
  --sm-glass: rgba(250, 248, 243, .85);
  --sm-shadow-xs: 0 1px 2px rgba(17, 21, 18, .06);
  --sm-shadow-sm: 0 1px 2px rgba(17, 21, 18, .05), 0 2px 8px -2px rgba(17, 21, 18, .06);
  --sm-shadow-md: 0 1px 2px rgba(17, 21, 18, .04), 0 4px 12px -2px rgba(17, 21, 18, .06), 0 16px 32px -12px rgba(17, 21, 18, .10);
  --sm-shadow-lg: 0 2px 4px rgba(17, 21, 18, .04), 0 12px 24px -6px rgba(17, 21, 18, .08), 0 32px 64px -16px rgba(17, 21, 18, .14);
  --sm-shadow-lift: 0 2px 4px rgba(17, 21, 18, .04), 0 12px 24px -8px rgba(17, 21, 18, .12), 0 28px 48px -18px rgba(20, 92, 50, .22);
  --sm-shadow-btn: 0 1px 2px rgba(17, 21, 18, .14), inset 0 1px 0 rgba(255, 255, 255, .14);
  --sm-highlight: inset 0 1px 0 rgba(255, 255, 255, .7);
  --sm-ring: 0 0 0 4px color-mix(in srgb, var(--sm-accent) 18%, transparent);
  --sm-line-strong: color-mix(in srgb, var(--sm-ink) 14%, var(--sm-line));
  --sm-hover: color-mix(in srgb, var(--sm-ink) 5%, transparent);
  --sm-tint: color-mix(in srgb, var(--sm-accent) 4%, var(--sm-surface));
  --sm-rail-bg: color-mix(in srgb, var(--sm-panel) 38%, var(--sm-paper));
  --sm-glow-ring: linear-gradient(135deg, color-mix(in srgb, var(--sm-accent) 60%, transparent), color-mix(in srgb, var(--sm-mint) 90%, transparent) 34%, color-mix(in srgb, var(--sm-line) 80%, transparent) 58%, color-mix(in srgb, var(--sm-gold) 55%, transparent));
  --sm-glow: 0 0 0 5px color-mix(in srgb, var(--sm-mint) 26%, transparent), 0 30px 80px -28px color-mix(in srgb, var(--sm-accent) 55%, transparent), 0 12px 36px -18px color-mix(in srgb, var(--sm-gold) 45%, transparent);
  --sm-r-xs: 6px;
  --sm-r-sm: 8px;
  --sm-r-md: 10px;
  --sm-r-lg: 14px;
  --sm-r-xl: 20px;
  --sm-r-2xl: 24px;
  --sm-r-tag: 6px;
  --sm-r-chip: 8px;
  --sm-ease: cubic-bezier(.2, .8, .2, 1);
  --sm-dur-fast: .12s;
  --sm-dur: .2s;
  --sm-fs-xs: 12px;
  --sm-fs-sm: 13px;
  --sm-fs-base: 15px;
  --sm-fs-md: 17px;
  --sm-fs-lg: 20px;
  --sm-fs-xl: 24px;
  --sm-fs-2xl: 32px;
  --sm-track-tight: -.015em;
  --sm-track-tighter: -.028em;
  --sm-track-display: -.04em;
}
html[data-theme="dark"] {
  color-scheme: dark;
  --bg: var(--sm-paper);
  --bg-soft: var(--sm-panel);
  --bg-elevated: rgba(14, 24, 17, 0.92);
  --bg-card: rgba(12, 22, 15, 0.95);
  --bg-input: rgba(8, 16, 10, 0.96);
  --surface: var(--sm-surface);
  --surface-strong: var(--sm-surface);
  --border: var(--sm-line);
  --border-strong: rgba(100, 180, 130, 0.22);
  --text: var(--sm-ink);
  --text-soft: var(--sm-ink-2);
  --text-muted: var(--sm-muted);
  --brand: #3aad5e;
  --brand-deep: #5ec97a;
  --brand-soft: rgba(58, 173, 94, 0.14);
  --accent: #3aad5e;
  --danger: #ff7070;
  --warning: #ffc44d;
  --shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.14), 0 2px 8px rgba(0, 0, 0, 0.10);
  --shadow: 0 2px 4px rgba(0, 0, 0, 0.16), 0 8px 24px rgba(0, 0, 0, 0.18);
  --shadow-lg: 0 4px 8px rgba(0, 0, 0, 0.20), 0 16px 48px rgba(0, 0, 0, 0.24);
  --shadow-soft: var(--shadow-sm);
  --shadow-glow: 0 0 0 1px rgba(58, 173, 94, 0.12), 0 4px 16px rgba(58, 173, 94, 0.14);
  --brand-gradient: linear-gradient(135deg, #3aad5e 0%, #5ec97a 50%, #86efac 100%);
  --bg-mesh: none;
  --sm-paper: #0e1310;
  --sm-panel: #151c18;
  --sm-surface: #1b231e;
  --sm-ink: #eef2ee;
  --sm-ink-2: #c5cfc8;
  --sm-muted: #9aab9f;
  --sm-line: #2c3630;
  --sm-accent: #5cc98a;
  --sm-accent-ink: #a6e8bf;
  --sm-forest: #153a25;
  --sm-mint: #1f4a31;
  --sm-mint-soft: #17281e;
  --sm-gold: #d9a441;
  --sm-shadow-card: 0 1px 2px rgba(0, 0, 0, .5), 0 12px 32px rgba(0, 0, 0, .35);
  --sm-on-accent: #07160d;
  --sm-on-forest: #eef2ee;
  --sm-on-gold: #111512;
  --sm-danger: #ff8a80;
  --sm-danger-soft: #3a1714;
  --sm-shadow-pop: 0 4px 12px rgba(0, 0, 0, .5), 0 24px 48px rgba(0, 0, 0, .45);
  --sm-scrim: rgba(0, 0, 0, .6);
  --sm-glass: rgba(14, 19, 16, .82);
  --sm-shadow-xs: 0 1px 2px rgba(0, 0, 0, .4);
  --sm-shadow-sm: 0 1px 2px rgba(0, 0, 0, .4), 0 2px 8px -2px rgba(0, 0, 0, .35);
  --sm-shadow-md: 0 1px 2px rgba(0, 0, 0, .4), 0 4px 12px -2px rgba(0, 0, 0, .35), 0 16px 32px -12px rgba(0, 0, 0, .5);
  --sm-shadow-lg: 0 2px 4px rgba(0, 0, 0, .4), 0 12px 24px -6px rgba(0, 0, 0, .45), 0 32px 64px -16px rgba(0, 0, 0, .6);
  --sm-shadow-lift: 0 2px 4px rgba(0, 0, 0, .4), 0 12px 24px -8px rgba(0, 0, 0, .5), 0 28px 48px -18px rgba(92, 201, 138, .18);
  --sm-shadow-btn: 0 1px 2px rgba(0, 0, 0, .4), inset 0 1px 0 rgba(255, 255, 255, .18);
  --sm-highlight: inset 0 1px 0 rgba(255, 255, 255, .05);
  --sm-ring: 0 0 0 4px color-mix(in srgb, var(--sm-accent) 26%, transparent);
  --sm-hover: color-mix(in srgb, var(--sm-ink) 7%, transparent);
  --sm-tint: color-mix(in srgb, var(--sm-accent) 6%, var(--sm-surface));
  --sm-rail-bg: color-mix(in srgb, var(--sm-panel) 70%, var(--sm-paper));
}
body {
  margin: 0;
  min-height: 100vh;
  font-family: var(--font-body);
  color: var(--text);
  background: var(--bg);
  display: flex;
  flex-direction: column;
  -webkit-font-smoothing: antialiased;
  background-image: var(--bg-mesh);
  background-attachment: fixed;
}
h1, h2, h3, h4, h5, h6 {
  text-wrap: balance;
}
:focus-visible {
  outline: 2px solid var(--brand);
  outline-offset: 2px;
}
button:focus-visible,
a:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible {
  outline: 2px solid var(--brand);
  outline-offset: 2px;
}
[hidden] {
  display: none !important;
}
html[data-theme="dark"] body {
  background: var(--bg);
}
img {
  max-width: 100%;
  display: block;
}
a {
  color: inherit;
}
.shell {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  min-width: 0;
}
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  border: 0;
}
.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  padding: 0.85rem 0;
  -webkit-backdrop-filter: blur(16px) saturate(1.4);
  backdrop-filter: blur(16px) saturate(1.4);
  background: var(--sm-glass);
  border-bottom: 1px solid var(--sm-line);
  transition: box-shadow 0.3s ease;
}
.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  flex-wrap: nowrap;
}
.header-inner > * {
  min-width: 0;
}
.logo-area {
  display: flex;
  align-items: center;
  gap: 0.8rem;
  text-decoration: none;
  flex-shrink: 0;
}
.logo-mark {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2.7rem;
  height: 2.7rem;
  border-radius: 1rem;
  font-size: 1.5rem;
  line-height: 1;
  background: linear-gradient(145deg, #fff7c8, #d9f5df);
  border: 1px solid rgba(20, 92, 50, 0.12);
  box-shadow: 0 7px 18px rgba(20, 92, 50, 0.1);
  transform: rotate(-3deg);
}
.logo-mark svg {
  transform: rotate(3deg);
}
.logo-copy {
  display: flex;
  flex-direction: column;
}
.logo-text {
  font-family: var(--font-heading);
  font-size: 1.15rem;
  font-weight: 700;
  line-height: 1;
}
.logo-sub {
  display: none;
}
.nav-links,
.header-right,
.user-area,
.footer-links,
.preview-actions,
.toolbar-group,
.theme-pills,
.chat-actions,
.stack-actions,
.suggestion-chips,
.billing-toggle {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}
.nav-toggle {
  display: none;
  background: none;
  border: 1.5px solid var(--border);
  border-radius: 10px;
  padding: 0.45rem 0.55rem;
  cursor: pointer;
  color: var(--text);
  line-height: 0;
}
.nav-toggle svg { display: block; }
.nav-toggle:focus-visible,
.nav-link:focus-visible {
  outline: 3px solid rgba(42, 135, 75, 0.42);
  outline-offset: 3px;
}
.page-breadcrumb {
  box-sizing: border-box;
  color: var(--text-muted);
  font-size: 0.82rem;
  padding-top: 0.7rem;
}
.page-breadcrumb ol {
  align-items: center;
  display: flex;
  flex-wrap: wrap;
  gap: 0;
  list-style: none;
  margin: 0;
  padding: 0;
}
.page-breadcrumb-item {
  align-items: center;
  display: inline-flex;
  min-width: 0;
}
.page-breadcrumb-item + .page-breadcrumb-item::before {
  color: color-mix(in srgb, var(--text-muted) 62%, transparent);
  content: "›";
  font-size: 1.05em;
  margin: 0 0.58rem;
}
.page-breadcrumb a {
  color: inherit;
  text-decoration: none;
}
.page-breadcrumb a:hover {
  color: var(--accent);
  text-decoration: underline;
  text-underline-offset: 0.18em;
}
.page-breadcrumb-item[aria-current="page"] {
  color: var(--text);
  font-weight: 750;
}
.nav-links {
  flex: 1 1 auto;
  flex-wrap: nowrap;
  justify-content: flex-start;
  gap: 0.15rem;
  overflow-x: auto;
  scrollbar-width: none;
  -webkit-overflow-scrolling: touch;
  padding-bottom: 2px;
  align-items: center;
}
.user-area {
  gap: 0.55rem;
  flex-wrap: wrap;
  justify-content: flex-end;
  max-width: 100%;
  position: relative;
}
.header-right {
  flex: 0 0 auto;
  flex-wrap: nowrap;
  justify-content: flex-end;
  margin-left: auto;
  min-width: 0;
}
.user-email {
  font-size: 0.82rem;
  color: var(--text-secondary);
  max-width: 14rem;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.btn-sm {
  min-height: 2.1rem;
  font-size: 0.76rem;
  padding: 0.22rem 0.62rem;
  border-radius: 10px;
}
.usage-badge,
.tier-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--sm-r-tag);
  padding: 0.45rem 0.8rem;
  font-size: 0.82rem;
  font-weight: 700;
}
.usage-badge {
  background: rgba(20, 92, 50, 0.08);
  color: var(--brand-deep);
  border: 1px solid rgba(20, 92, 50, 0.12);
}
.tier-badge {
  background: rgba(255, 255, 255, 0.72);
  color: var(--text);
  border: 1px solid var(--border);
}
html[data-theme="dark"] .tier-badge {
  background: rgba(255, 255, 255, 0.04);
}
.tier-badge.plus {
  color: var(--brand-deep);
}
.tier-badge.max {
  color: #aa7b1c;
}
.nav-link {
  font-size: clamp(0.85rem, 1.2vw, 0.92rem);
  font-weight: 500;
  text-decoration: none;
  color: var(--text-soft);
  padding: 0.4rem 0.65rem;
  border-radius: var(--radius-pill);
  white-space: nowrap;
  flex-shrink: 0;
  transition: all 0.2s ease;
}
.nav-link:hover,
.nav-link.active {
  background: rgba(20, 92, 50, 0.08);
  color: var(--text);
}
.nav-link:hover,
.nav-link.active {
  color: var(--text);
  background: rgba(20, 92, 50, 0.08);
}
.nav-external {
  color: var(--text-muted);
}
.btn-primary,
.btn-secondary,
.btn-ghost,
.text-action,
.billing-pill,
.chip-btn,
.theme-pill {
  font: inherit;
}
.btn-primary,
.btn-secondary,
.btn-ghost,
.btn-inline {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
  min-height: 2.65rem;
  border-radius: 14px;
  cursor: pointer;
  white-space: nowrap;
  transition: transform 0.18s ease, box-shadow 0.18s ease, background 0.18s ease;
}
.btn-primary {
  border: none;
  color: var(--sm-on-accent);
  background: var(--sm-accent);
  padding: 0.6rem 1.05rem;
  min-height: 2.5rem;
  border-radius: 10px;
  font-weight: 650;
  box-shadow: 0 1px 2px rgba(17, 21, 18, 0.12);
}
.btn-primary:hover,
.btn-secondary:hover,
.btn-ghost:hover,
.chip-btn:hover,
.theme-pill:hover {
  transform: translateY(-1px);
  box-shadow: var(--shadow-glow);
}
.btn-primary:hover {
  background: var(--sm-accent-ink);
  box-shadow: 0 1px 2px rgba(17, 21, 18, 0.12), 0 6px 16px rgba(17, 21, 18, 0.08);
  transform: none;
}
.btn-primary:disabled {
  opacity: 0.7;
  cursor: wait;
  transform: none;
}
.btn-secondary {
  border: 1px solid var(--border-strong);
  color: var(--text);
  background: rgba(255, 255, 255, 0.6);
  backdrop-filter: blur(8px);
  padding: 0.72rem 1rem;
}
html[data-theme="dark"] .btn-secondary {
  background: rgba(255, 255, 255, 0.02);
}
.btn-ghost {
  border: 1px solid rgba(20, 92, 50, 0.18);
  background: rgba(255, 255, 255, 0.72);
  color: var(--brand-deep);
  padding: 0.66rem 0.92rem;
}
html[data-theme="dark"] .btn-ghost {
  border-color: var(--sm-line-strong);
  background: var(--sm-surface);
  color: var(--sm-ink);
}
.sm-guest-actions {
  display: flex;
  align-items: center;
  gap: 0.55rem;
}
.sm-auth-button {
  gap: 0.45rem;
  font-weight: 750;
  letter-spacing: -0.01em;
}
.sm-auth-button svg {
  width: 17px;
  height: 17px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.9;
  stroke-linecap: round;
  stroke-linejoin: round;
  flex: 0 0 auto;
}
.current-label {
  width: 100%;
}
.btn-inline {
  padding: 0.72rem 1.1rem;
  font-size: clamp(0.8rem, 1.5vw, 0.95rem);
}
.btn-launch {
  min-width: 9.75rem;
  white-space: nowrap;
  background: var(--brand-gradient);
  box-shadow: var(--shadow-sm);
  transition: transform 0.15s ease, box-shadow 0.2s ease, background 0.15s ease;
}
.btn-launch:hover {
  background: var(--brand-gradient);
  filter: brightness(1.08);
  box-shadow: var(--shadow-glow);
}
.btn-launch:active {
  transform: translateY(0) scale(0.97);
}
html[data-theme="dark"] .btn-launch {
  background: var(--brand-gradient);
  box-shadow: var(--shadow-sm);
}
html[data-theme="dark"] .btn-launch:hover {
  background: var(--brand-gradient);
  filter: brightness(1.1);
  box-shadow: var(--shadow-glow);
}
.text-action {
  border: none;
  background: none;
  color: var(--brand-deep);
  padding: 0;
  cursor: pointer;
  font-weight: 600;
}
.hero,
.page-hero {
  text-align: center;
}
.home-main,
.pricing-main,
.account-main,
.settings-main {
  padding: 2rem 0 3rem;
}
.workspace-main {
  padding: 0.85rem;
  flex: 1;
  display: flex;
  flex-direction: column;
  width: min(1480px, calc(100% - 1rem));
}
.hero-home {
  padding-top: 2.5rem;
  max-width: 52rem;
  margin: 0 auto 2rem;
}
.hero-home h1 {
  color: var(--text);
}
html[data-theme="dark"] .hero-home h1 {
  color: var(--text);
}
.hero-badge,
.status-chip,
.editor-model-pill,
.billing-pill,
.mini-plan-note {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--radius-pill);
  background: rgba(255, 255, 255, 0.7);
  border: 1px solid rgba(20, 92, 50, 0.16);
  color: var(--brand-deep);
  font-size: 0.86rem;
  padding: 0.45rem 0.9rem;
}
html[data-theme="dark"] .hero-badge,
html[data-theme="dark"] .status-chip,
html[data-theme="dark"] .editor-model-pill,
html[data-theme="dark"] .billing-pill,
html[data-theme="dark"] .mini-plan-note {
  background: rgba(255, 255, 255, 0.04);
}
.account-menu-button {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  min-height: 2.65rem;
  padding: 0.3rem 0.7rem 0.3rem 0.35rem;
  color: var(--text);
  background: rgba(255, 255, 255, 0.54);
  border: 1px solid var(--border);
  border-radius: 999px;
  font: inherit;
  font-size: 0.86rem;
  font-weight: 650;
  cursor: pointer;
  transition: border-color 0.18s ease, background 0.18s ease, box-shadow 0.18s ease;
}
.account-menu-button:hover,
.account-menu-button[aria-expanded="true"] {
  border-color: rgba(20, 92, 50, 0.3);
  background: var(--surface-strong);
  box-shadow: 0 6px 20px rgba(16, 52, 31, 0.1);
}
.account-menu-button:focus-visible,
.account-menu a:focus-visible,
.account-menu-signout:focus-visible {
  outline: 3px solid rgba(53, 145, 84, 0.26);
  outline-offset: 2px;
}
.account-avatar {
  width: 2rem;
  height: 2rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 auto;
  overflow: hidden;
  border-radius: 50%;
  background: linear-gradient(145deg, #d9f4df, #a8ddb8);
  color: var(--brand-deep);
  border: 1px solid rgba(20, 92, 50, 0.16);
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.02em;
}
.account-avatar-image {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
}
.account-avatar-fallback {
  line-height: 1;
}
.account-menu-chevron {
  color: var(--text-muted);
  transition: transform 0.18s ease;
}
.account-menu-button[aria-expanded="true"] .account-menu-chevron {
  transform: rotate(180deg);
}
.account-menu {
  position: absolute;
  z-index: 80;
  top: calc(100% + 0.6rem);
  right: 0;
  width: min(20rem, calc(100vw - 1.5rem));
  overflow: hidden;
  color: var(--text);
  background: var(--surface-strong);
  border: 1px solid var(--border);
  border-radius: 18px;
  box-shadow: 0 18px 48px rgba(14, 42, 25, 0.18);
}
.account-menu[hidden] {
  display: none;
}
.account-menu-identity {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: 0.7rem;
  padding: 1rem;
  background: rgba(20, 92, 50, 0.055);
  border-bottom: 1px solid var(--border);
}
.account-avatar-large {
  width: 2.6rem;
  height: 2.6rem;
  font-size: 0.84rem;
}
.account-menu-person {
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 0.12rem;
}
.account-menu-person strong,
.account-menu-person small {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.account-menu-person strong {
  font-size: 0.88rem;
}
.account-menu-person small {
  color: var(--text-muted);
  font-size: 0.72rem;
}
.account-menu-tier {
  padding: 0.25rem 0.48rem;
  color: var(--brand-deep);
  background: rgba(20, 92, 50, 0.09);
  border-radius: var(--sm-r-tag);
  font-size: 0.68rem;
  font-weight: 750;
}
.account-menu-links {
  display: grid;
  gap: 0.15rem;
  padding: 0.45rem;
}
.account-menu-links a,
.account-menu-signout {
  width: 100%;
  display: flex;
  align-items: center;
  gap: 0.7rem;
  padding: 0.72rem 0.75rem;
  color: var(--text);
  background: transparent;
  border: 0;
  border-radius: 10px;
  font: inherit;
  font-size: 0.84rem;
  text-align: left;
  text-decoration: none;
  cursor: pointer;
}
.account-menu-links a:hover,
.account-menu-signout:hover {
  background: rgba(20, 92, 50, 0.07);
}
.account-menu-links a span,
.account-menu-signout span {
  width: 1.15rem;
  color: var(--text-muted);
  text-align: center;
}
.account-menu-signout {
  border-top: 1px solid var(--border);
  border-radius: 0;
  color: #a43b35;
  padding: 0.82rem 1.2rem;
}
html[data-theme="dark"] .account-menu-button {
  background: rgba(255, 255, 255, 0.04);
}
.pricing-view-panel[hidden] {
  display: none !important;
}
.pricing-main .billing-toggle {
  align-items: stretch;
  justify-content: center;
  margin-top: 1.35rem;
}
.pricing-main .billing-pill {
  min-width: 154px;
  min-height: 54px;
  border-radius: 10px;
  padding: 0.85rem 1.25rem;
  cursor: pointer;
  font-size: 0.95rem;
  font-weight: 800;
  letter-spacing: 0;
  box-shadow: var(--shadow-sm), inset 0 1px 0 rgba(255, 255, 255, 0.62);
  transition: transform 0.18s ease, box-shadow 0.18s ease, background 0.18s ease, border-color 0.18s ease;
}
.pricing-main .billing-pill:hover {
  transform: translateY(-1px);
  border-color: rgba(20, 92, 50, 0.36);
  box-shadow: var(--shadow-md);
}
.pricing-main .billing-pill.active {
  background: var(--brand);
  border-color: var(--brand);
  color: #fff;
  box-shadow: 0 16px 34px rgba(20, 92, 50, 0.22);
}
html[data-theme="dark"] .pricing-main .billing-pill.active {
  background: #78d48f;
  border-color: #78d48f;
  color: #06140b;
}
.status-chip.danger {
  color: var(--danger);
  border-color: rgba(200, 68, 68, 0.18);
}
.hero h1,
.page-hero h1,
.progress-card h1,
.status-card h1,
.error-card h1 {
  margin: 0.75rem 0 0.8rem;
  font-family: var(--font-heading);
  font-size: clamp(2rem, 4vw, 3.2rem);
  line-height: 1.08;
  letter-spacing: -0.04em;
}
.page-hero h1,
.progress-card h1,
.status-card h1,
.error-card h1 {
  font-size: clamp(2rem, 4vw, 3.2rem);
}
.hero-sub,
.progress-copy,
.block-copy,
.workspace-note,
.mini-plan-note,
.helper-note {
  color: var(--text-soft);
  font-size: 1.02rem;
  line-height: 1.7;
}
.page-hero {
  max-width: 50rem;
  margin: 0 auto 2rem;
}
.card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow-sm);
  backdrop-filter: blur(12px);
}
.composer-card,
.discount-card,
.settings-confirm {
  padding: 1.5rem;
}
.composer-card {
  border: 1px solid var(--border);
  box-shadow: var(--shadow-sm), inset 0 1px 0 rgba(255, 255, 255, 0.5);
  backdrop-filter: blur(12px);
}
.composer-card:hover {
  transform: none;
  border-color: rgba(20, 92, 50, 0.2);
  box-shadow: var(--shadow), inset 0 1px 0 rgba(255, 255, 255, 0.5);
}
html[data-theme="dark"] .composer-card {
  border-color: var(--border);
  box-shadow: var(--shadow-sm), inset 0 1px 0 rgba(255, 255, 255, 0.04);
}
html[data-theme="dark"] .composer-card:hover {
  transform: none;
  border-color: var(--border-strong);
  box-shadow: var(--shadow), inset 0 1px 0 rgba(255, 255, 255, 0.04);
}
.composer-topline,
.workspace-panel-head,
.preview-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1rem;
}
.price-card-top {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}
.eyebrow,
.price-tier,
.message-role {
  margin: 0 0 0.45rem;
  font-size: 0.78rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--brand-deep);
}
.composer-card .eyebrow {
  color: var(--brand);
}
html[data-theme="dark"] .composer-card .eyebrow {
  color: var(--accent);
}
.composer-topline h2,
.workspace-panel-head h2,
.settings-card h2,
.price-card h2,
.account-block h2,
.discount-card h2,
.signed-out-card h2 {
  margin: 0;
  font-family: var(--font-heading);
  font-size: clamp(1.5rem, 2.2vw, 2rem);
  letter-spacing: -0.04em;
}
.prompt-form {
  margin-top: 1.5rem;
}
.prompt-stage {
  position: relative;
  padding: 1.2rem 1.2rem 0.6rem;
  border-radius: 14px;
  background: var(--surface);
  border: 1px solid var(--border);
  box-shadow: none;
  transition: border-color 0.2s ease;
}
.prompt-stage:focus-within {
  border-color: var(--brand);
  box-shadow: 0 0 0 3px rgba(20, 92, 50, 0.08);
}
html[data-theme="dark"] .prompt-stage {
  background: var(--surface);
  border-color: var(--border);
}
html[data-theme="dark"] .prompt-stage:focus-within {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(58, 173, 94, 0.1);
}
.prompt-stage textarea {
  border: none;
  background: transparent;
  padding: 0;
  min-height: 7rem;
  line-height: 1.65;
  font-size: 1.05rem;
  resize: none;
}
.prompt-stage textarea:focus {
  outline: none;
  border: none;
  box-shadow: none;
}
.creator-draft-note {
  margin: .15rem 0 .35rem;
  color: var(--accent);
  font-size: .78rem;
  line-height: 1.4;
}
html[data-theme="dark"] .creator-draft-note {
  color: #8ce3a5;
}
textarea,
input[type="text"],
select {
  width: 100%;
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  background: var(--bg-input);
  color: var(--text);
  padding: 1rem 1.1rem;
  font: inherit;
  resize: vertical;
  transition: border-color 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}
textarea {
  min-height: 8.5rem;
  line-height: 1.6;
}
textarea:focus,
input[type="text"]:focus,
select:focus {
  outline: none;
  border-color: var(--brand);
  box-shadow: 0 0 0 3px rgba(20, 92, 50, 0.1);
}
.composer-toolbar {
  margin-top: 0.6rem;
  padding-top: 0.6rem;
  border-top: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.6rem;
  flex-wrap: wrap;
}
html[data-theme="dark"] .composer-toolbar {
  border-top-color: var(--border);
}
.inline-select {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.3rem 0.5rem 0.3rem 0.55rem;
  border-radius: var(--radius-sm);
  background: var(--bg-soft);
  border: 1px solid var(--border);
  transition: border-color 0.15s;
  cursor: pointer;
}
.inline-select:hover {
  border-color: var(--brand);
}
html[data-theme="dark"] .inline-select {
  background: var(--surface);
  border-color: var(--border);
}
html[data-theme="dark"] .inline-select:hover {
  border-color: var(--accent);
}
.inline-select .model-icon {
  color: var(--text-muted);
  flex-shrink: 0;
  opacity: 0.7;
}
.inline-select span {
  font-family: "Inter", "Space Grotesk", sans-serif;
  font-size: 0.78rem;
  font-weight: 500;
  color: var(--text-soft);
  white-space: nowrap;
  letter-spacing: -0.01em;
}
.inline-select select {
  min-width: 0;
  width: 100%;
  border: none;
  background: transparent;
  padding: 0.3rem 1.6rem 0.3rem 0;
  box-shadow: none;
  font-family: "Inter", "Space Grotesk", sans-serif;
  font-size: 0.82rem;
  font-weight: 500;
  color: var(--text);
  letter-spacing: -0.01em;
  cursor: pointer;
  -webkit-appearance: none;
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg width='10' height='6' viewBox='0 0 10 6' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M1 1l4 4 4-4' stroke='%23888' stroke-width='1.5' fill='none' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 0.3rem center;
  background-size: 10px 6px;
}
.inline-select select:focus {
  outline: none;
}
.form-meta-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  margin-top: 0.9rem;
}
.char-count {
  color: var(--text-muted);
  font-size: 0.88rem;
}
.beta-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.12rem 0.45rem;
  border-radius: var(--sm-r-tag);
  font-size: 0.65rem;
  font-weight: 700;
  font-family: var(--font-head);
  text-transform: uppercase;
  letter-spacing: 0.06em;
  background: linear-gradient(135deg, #f59e0b, #d97706);
  color: var(--sm-on-gold, #111512);
  vertical-align: middle;
  white-space: nowrap;
}
.page-count-row {
  display: flex;
  align-items: center;
  gap: 0.8rem;
  margin-top: 0.8rem;
  padding: 0.65rem 1rem;
  border-radius: var(--radius-md);
  background: rgba(20, 92, 50, 0.04);
  border: 1px solid rgba(20, 92, 50, 0.1);
}
html[data-theme="dark"] .page-count-row {
  background: rgba(255,255,255, 0.02);
  border-color: rgba(255,255,255,0.06);
}
.page-count-label {
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--text-muted);
  white-space: nowrap;
}
.page-count-slider {
  flex: 1;
  accent-color: var(--brand);
  height: 6px;
  cursor: pointer;
}
.page-count-value {
  font-size: 1rem;
  font-weight: 700;
  color: var(--brand);
  min-width: 2.2ch;
  text-align: center;
}
.page-count-hint {
  font-size: 0.78rem;
  color: var(--text-muted);
  margin-left: auto;
  text-align: right;
}
.advanced-panel {
  margin-top: 1rem;
  padding: 1.2rem;
  border-radius: var(--radius-lg);
  background: rgba(255, 255, 255, 0.55);
  border: 1px solid var(--border);
}
html[data-theme="dark"] .advanced-panel {
  background: rgba(255, 255, 255, 0.02);
}
.options-grid,
.settings-grid,
.account-grid-page,
.feature-strip {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1rem;
}
.options-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}
.field {
  display: flex;
  flex-direction: column;
  gap: 0.45rem;
}
.field.full {
  grid-column: 1 / -1;
}
label {
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--text-soft);
}
.style-picker {
  display: flex;
  flex-wrap: wrap;
  gap: 0.7rem;
}
.style-chip,
.chip-btn,
.theme-pill {
  border: 1px solid var(--border);
  background: rgba(255, 255, 255, 0.7);
  color: var(--text);
  border-radius: var(--sm-r-chip);
  padding: 0.75rem 1rem;
  cursor: pointer;
}
html[data-theme="dark"] .style-chip,
html[data-theme="dark"] .chip-btn,
html[data-theme="dark"] .theme-pill {
  background: rgba(255, 255, 255, 0.03);
}
.style-chip input {
  display: none;
}
.style-chip.selected,
.theme-pill.active,
.billing-pill.active {
  background: var(--brand-soft);
  border-color: var(--brand);
}
html[data-theme="dark"] .style-chip.selected,
html[data-theme="dark"] .theme-pill.active,
html[data-theme="dark"] .billing-pill.active {
  background: rgba(120, 212, 143, 0.14);
}
.suggestions-block {
  margin: 2rem auto 0;
  text-align: center;
  background: transparent;
  border: none;
  border-radius: 0;
  padding: 0 0 1rem;
  box-shadow: none;
}
html[data-theme="dark"] .suggestions-block {
  border-color: transparent;
  box-shadow: none;
}
.suggestions-title {
  color: var(--brand-deep);
  font-weight: 800;
  font-size: 0.84rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  margin-bottom: 1rem;
}
.chip-btn {
  box-shadow: var(--shadow-soft);
}
.feature-strip {
  margin-top: 2rem;
}
.feature-card,
.settings-card,
.account-block,
.signed-out-card,
.price-card,
.workspace-chat,
.workspace-preview,
.progress-card,
.status-card,
.error-card {
  padding: 1.5rem;
}
.feature-card {
  border-radius: var(--radius-lg);
  background: rgba(255, 255, 255, 0.78);
  border: 1px solid var(--border);
  box-shadow: var(--shadow-sm), inset 0 1px 0 rgba(255, 255, 255, 0.6);
  backdrop-filter: blur(8px);
}
html[data-theme="dark"] .feature-card {
  background: rgba(255, 255, 255, 0.03);
}
.feature-card h3 {
  margin: 0 0 0.65rem;
  font-family: var(--font-heading);
  font-size: 1.15rem;
}
.feature-card p,
.price-copy {
  margin: 0;
  color: var(--text-soft);
  line-height: 1.65;
}
.billing-pill[disabled] {
  opacity: 0.55;
  cursor: not-allowed;
}
.pricing-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 1rem;
}
.pricing-grid-wide {
  margin-top: 1.5rem;
}
.section-heading {
  margin: 1.7rem 0 1rem;
}
.section-heading h2 {
  margin: 0;
  font-family: var(--font-heading);
  font-size: clamp(1.7rem, 2.4vw, 2.35rem);
  letter-spacing: -0.04em;
}
.section-heading p:not(.eyebrow) {
  max-width: 760px;
  margin: 0.45rem 0 0;
  color: var(--text-muted);
  line-height: 1.7;
}
.credit-pricing {
  margin-top: 1.5rem;
}
.credit-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 1rem;
}
.credit-card {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  min-height: 100%;
  padding: 1.35rem;
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  background: var(--bg-card);
  box-shadow: var(--shadow-sm), inset 0 1px 0 rgba(255, 255, 255, 0.5);
}
.credit-card.universal {
  border-color: rgba(20, 92, 50, 0.35);
  box-shadow: var(--shadow-glow), inset 0 1px 0 rgba(255, 255, 255, 0.5);
}
html[data-theme="dark"] .credit-card.universal {
  border-color: rgba(120, 212, 143, 0.36);
}
.credit-card h3 {
  margin: 0 0 0.35rem;
  font-family: var(--font-heading);
  font-size: 1.35rem;
  letter-spacing: -0.03em;
}
.credit-price {
  margin-top: auto;
  font-family: var(--font-heading);
  font-size: clamp(2rem, 3vw, 2.7rem);
  letter-spacing: -0.05em;
}
.price-card {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow-sm), inset 0 1px 0 rgba(255, 255, 255, 0.5);
  backdrop-filter: blur(18px);
  padding: 1.5rem;
  transition: transform 0.28s var(--ease-out), box-shadow 0.28s var(--ease-out), border-color 0.2s ease;
}
.price-card.featured {
  background: var(--bg-card);
  border-color: var(--brand);
  border-width: 2px;
  box-shadow: var(--shadow-glow), inset 0 1px 0 rgba(255, 255, 255, 0.5);
  transform: scale(1.02);
}
html[data-theme="dark"] .price-card.featured {
  background: var(--bg-card);
  border-color: var(--accent);
}
.price-amount {
  font-family: var(--font-heading);
  font-size: clamp(2.5rem, 3.4vw, 3.3rem);
  letter-spacing: -0.06em;
}
.price-period {
  font-size: 1rem;
  color: var(--text-muted);
  margin-left: 0.35rem;
}
.price-features {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
  padding: 0;
  margin: 0;
  color: var(--text-soft);
}
.price-features li {
  display: flex;
  align-items: flex-start;
  gap: 0.6rem;
}
.price-features li::before {
  content: "";
  flex-shrink: 0;
  width: 1.1em;
  height: 1.1em;
  margin-top: 0.15em;
  background: var(--brand-deep);
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M20 6 9 17l-5-5'/%3E%3C/svg%3E") center/contain no-repeat;
  mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M20 6 9 17l-5-5'/%3E%3C/svg%3E") center/contain no-repeat;
}
.price-features li.muted {
  color: var(--text-muted);
}
.price-features li.muted::before {
  background: var(--text-muted);
  -webkit-mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='2.5' stroke-linecap='round'%3E%3Cpath d='M5 12h14'/%3E%3C/svg%3E");
  mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='2.5' stroke-linecap='round'%3E%3Cpath d='M5 12h14'/%3E%3C/svg%3E");
}
.price-action {
  margin-top: auto;
}
body[data-page="pricing"] {
  background-color: #fbfaf5;
  background-image:
    radial-gradient(ellipse 70% 34% at 50% 5%, rgba(182, 240, 200, 0.2), transparent 72%),
    linear-gradient(90deg, rgba(20, 92, 50, 0.025) 1px, transparent 1px);
  background-size: auto, 34px 34px;
}
html[data-theme="dark"] body[data-page="pricing"] {
  background-color: var(--bg);
  background-image: var(--bg-mesh);
}
.pricing-main {
  --pricing-serif: Georgia, "Times New Roman", serif;
  width: min(1280px, calc(100% - 2rem));
  padding-bottom: 1rem;
}
.pricing-main .page-hero {
  max-width: 1120px;
  padding: clamp(3.75rem, 7vw, 6.5rem) 0 1.5rem;
  margin-inline: auto;
  text-align: center;
}
.pricing-main .page-hero h1 {
  max-width: none;
  margin: 0;
  color: var(--brand-deep);
  font-family: var(--pricing-serif);
  font-size: clamp(2.8rem, 5.2vw, 4.7rem);
  font-weight: 700;
  line-height: 0.98;
  letter-spacing: -0.055em;
}
.pricing-main .page-hero h1::after {
  content: "";
  display: block;
  width: min(360px, 48vw);
  height: 3px;
  margin: 0.45rem auto 0;
  border-radius: 999px;
  background: linear-gradient(90deg, transparent, #8ad4a0 20%, #8ad4a0 80%, transparent);
}
.pricing-main .hero-sub {
  max-width: 680px;
  margin: 1rem auto 0;
  color: var(--text-soft);
  font-size: clamp(1rem, 1.6vw, 1.22rem);
  line-height: 1.6;
}
.pricing-main .billing-toggle {
  width: min(570px, 100%);
  gap: 0;
  padding: 4px;
  margin: 1.75rem auto 0;
  border: 1px solid rgba(20, 92, 50, 0.2);
  border-radius: var(--radius-pill);
  background: rgba(255, 255, 255, 0.55);
  box-shadow: none;
}
.pricing-main .billing-pill {
  flex: 1;
  min-width: 0;
  min-height: 48px;
  border: 0;
  border-radius: 10px;
  background: transparent;
  box-shadow: none;
}
.pricing-main .billing-pill:hover {
  transform: none;
  border-color: transparent;
  box-shadow: none;
  background: rgba(20, 92, 50, 0.06);
}
.pricing-main .billing-pill.active,
html[data-theme="dark"] .pricing-main .billing-pill.active {
  background: var(--brand-deep);
  color: #fff;
  box-shadow: 0 8px 22px rgba(14, 61, 31, 0.18);
}
.pricing-currency-note {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.45rem;
  min-height: 1.5rem;
  margin: 0.75rem 0 0;
  color: var(--text-muted);
  font-size: 0.9rem;
}
.pricing-choice-helper {
  max-width: 680px;
  margin: 0.8rem auto 0;
  color: var(--text-muted);
  font-size: 0.86rem;
  line-height: 1.5;
  text-align: center;
}
.pricing-choice-helper strong {
  color: var(--text);
}
.pricing-upgrade-context {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: center;
  gap: 0.45rem;
  max-width: 760px;
  margin: 0 auto 1.5rem;
  border: 1px solid rgba(20, 92, 50, 0.2);
  border-radius: 12px;
  padding: 0.8rem 1rem;
  color: var(--text);
  background: rgba(217, 246, 225, 0.6);
  font-size: 0.88rem;
  line-height: 1.45;
  text-align: center;
}
.pricing-upgrade-context strong {
  color: var(--brand-deep);
}
.credit-card.credit-card-contextual {
  border-color: var(--brand);
  box-shadow: 0 0 0 3px rgba(20, 92, 50, 0.1), 0 14px 30px rgba(20, 92, 50, 0.11);
}
.pricing-currency-note svg {
  width: 18px;
  height: 18px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.7;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.credit-pricing {
  position: relative;
  margin-top: 1rem;
}
.credit-pricing::before,
.credit-pricing::after {
  content: "";
  position: absolute;
  top: 0;
  bottom: 11rem;
  z-index: -1;
  width: 38px;
  border: 1px solid rgba(20, 92, 50, 0.12);
  opacity: 0.75;
}
.credit-pricing::before {
  left: -18px;
  border-right: 0;
  border-radius: 50% 0 0 50%;
}
.credit-pricing::after {
  right: -18px;
  border-left: 0;
  border-radius: 0 50% 50% 0;
}
.credit-grid {
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 0;
  align-items: stretch;
  padding: 1rem 0;
}
.credit-card {
  position: relative;
  justify-content: flex-start;
  gap: 0;
  min-width: 0;
  min-height: 450px;
  padding: 2rem clamp(1.2rem, 2vw, 2rem) 1.6rem;
  border: 0;
  border-right: 1px solid rgba(20, 92, 50, 0.16);
  border-radius: 0;
  background: transparent;
  box-shadow: none;
  backdrop-filter: none;
}
.credit-card:last-child {
  border-right: 0;
}
.credit-card-featured {
  z-index: 1;
  min-height: 480px;
  margin-block: -0.95rem;
  padding-top: 2.7rem;
  border: 3px solid #8ad4a0;
  border-radius: 24px;
  color: #f6fff8;
  background: linear-gradient(155deg, #0e4c29, #07361c);
  box-shadow: 0 20px 45px rgba(14, 61, 31, 0.24), inset 0 0 0 1px rgba(255, 255, 255, 0.1);
}
.credit-card-featured + .credit-card {
  border-left: 0;
}
.credit-card-featured .price-tier,
.credit-card-featured .price-copy,
.credit-card-featured .credit-currency {
  color: rgba(246, 255, 248, 0.76);
}
.credit-card-featured h3,
.credit-card-featured .credit-price {
  color: #fff;
}
.credit-card-featured .credit-icon {
  color: #b6f0c8;
}
.credit-card-featured .btn-primary {
  color: #07361c;
  background: #b6f0c8;
  box-shadow: none;
}
.credit-card-featured .btn-primary:hover {
  background: #ccf6d7;
}
.credit-value-label {
  position: absolute;
  top: -1rem;
  left: 50%;
  min-width: 130px;
  padding: 0.42rem 0.85rem;
  border-radius: 9px;
  color: #0b3f22;
  background: #9cddb0;
  font-size: 0.82rem;
  font-weight: 800;
  text-align: center;
  transform: translateX(-50%);
}
.credit-icon {
  display: grid;
  width: 70px;
  height: 70px;
  margin: 0 auto 0.75rem;
  place-items: center;
  color: var(--brand-deep);
}
.credit-icon svg {
  width: 58px;
  height: 58px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.7;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.credit-card-copy {
  text-align: center;
}
.credit-card .price-tier {
  margin-bottom: 0.5rem;
  font-size: 0.76rem;
  letter-spacing: 0.12em;
}
.credit-card h3 {
  min-height: 3.2rem;
  margin: 0;
  font-family: var(--pricing-serif);
  font-size: clamp(1.4rem, 2vw, 1.75rem);
  line-height: 1.1;
}
.credit-card .price-copy {
  min-height: 3.4rem;
  margin-top: 0.75rem;
  font-size: 0.92rem;
  line-height: 1.5;
}
.credit-price {
  display: flex;
  align-items: baseline;
  justify-content: center;
  gap: 0.45rem;
  margin: auto 0 1rem;
  font-family: var(--pricing-serif);
  letter-spacing: -0.055em;
}
.credit-price-number {
  font-size: clamp(2.75rem, 4.2vw, 4rem);
  line-height: 1;
}
.credit-currency {
  color: var(--text-muted);
  font-family: var(--font-body);
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.04em;
}
.credit-card .btn-primary,
.credit-card .btn-secondary {
  width: 100%;
  min-height: 48px;
  margin-top: 0;
  padding-inline: 0.8rem;
  border-radius: 10px;
  font-weight: 800;
}
.comic-match-note {
  min-height: 1.2rem;
  margin: -0.55rem 0 0.75rem;
  color: var(--brand-deep);
  font-size: 0.76rem;
  font-weight: 700;
  text-align: center;
  line-height: 1.4;
}
.credit-assurance {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0;
  margin: 1rem auto 0;
  padding: 1.15rem 1rem;
  border: 1px solid rgba(20, 92, 50, 0.16);
  border-radius: 14px;
  background: rgba(182, 240, 200, 0.28);
  color: var(--text-soft);
  text-align: center;
}
.credit-assurance span + span {
  border-left: 1px solid rgba(20, 92, 50, 0.16);
}
.credit-assurance strong {
  margin-right: 0.4rem;
  color: var(--brand);
}
.credit-how {
  padding: 3.5rem 0 2rem;
}
.credit-how h2 {
  margin: 0 0 2rem;
  color: var(--brand-deep);
  font-family: var(--pricing-serif);
  font-size: clamp(2rem, 4vw, 3rem);
  text-align: center;
}
.credit-how ol {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 0;
  padding: 0;
  margin: 0;
  list-style: none;
}
.credit-how li {
  display: flex;
  align-items: flex-start;
  gap: 0.85rem;
  padding: 0 1.25rem;
  border-right: 1px solid var(--border);
}
.credit-how li:last-child {
  border-right: 0;
}
.credit-how li > span {
  display: grid;
  flex: 0 0 38px;
  width: 38px;
  height: 38px;
  border: 1px solid var(--brand);
  border-radius: 50%;
  color: var(--brand-deep);
  font-family: var(--pricing-serif);
  font-size: 1.25rem;
  place-items: center;
}
.credit-how strong,
.credit-how small {
  display: block;
}
.credit-how small {
  margin-top: 0.25rem;
  color: var(--text-muted);
  line-height: 1.45;
}
.pricing-main .section-heading {
  margin: 1rem 0 1.5rem;
  text-align: center;
}
.pricing-main .section-heading h2 {
  color: var(--brand-deep);
  font-family: var(--pricing-serif);
  font-size: clamp(2rem, 4vw, 3rem);
}
.pricing-main .section-heading p:not(.eyebrow) {
  margin-inline: auto;
}
.pricing-main .pricing-grid-wide {
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 0;
  align-items: stretch;
  overflow: visible;
  padding-top: 1.1rem;
}
.pricing-main .price-card {
  position: relative;
  min-width: 0;
  padding: 1.8rem 1.45rem;
  border-radius: 0;
  box-shadow: none;
  backdrop-filter: none;
}
.pricing-main .price-card:first-child {
  border-radius: 20px 0 0 20px;
}
.pricing-main .price-card:last-child {
  border-radius: 0 20px 20px 0;
}
.pricing-main .price-card + .price-card {
  border-left: 0;
}
.pricing-main .price-card.featured {
  z-index: 1;
  margin-block: -0.8rem;
  padding-top: 2.6rem;
  border: 2px solid var(--brand-deep);
  border-radius: 18px;
  background: linear-gradient(180deg, rgba(182, 240, 200, 0.26), var(--bg-card) 34%);
  box-shadow: 0 16px 38px rgba(14, 61, 31, 0.14);
  transform: none;
}
.plan-recommended {
  position: absolute;
  top: 0;
  left: -2px;
  right: -2px;
  padding: 0.48rem;
  border-radius: 16px 16px 0 0;
  color: #fff;
  background: var(--brand-deep);
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.11em;
  text-align: center;
  text-transform: uppercase;
}
.pricing-main .price-card-top h2 {
  min-height: 3.15rem;
  font-family: var(--pricing-serif);
  font-size: 1.55rem;
  line-height: 1.1;
}
.pricing-main .price-amount {
  display: flex;
  align-items: flex-end;
  gap: 0.45rem;
  font-family: var(--pricing-serif);
  letter-spacing: -0.055em;
}
.plan-price-number {
  font-size: clamp(2.25rem, 3.3vw, 3.35rem);
  line-height: 0.95;
}
.plan-price-meta {
  padding-bottom: 0.15rem;
  color: var(--text-muted);
  font-family: var(--font-body);
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0;
  line-height: 1.25;
  white-space: nowrap;
}
.pricing-main .price-features {
  padding-top: 1rem;
  border-top: 1px solid var(--border);
  font-size: 0.9rem;
}
.pricing-main .price-action .btn-primary,
.pricing-main .price-action .btn-ghost {
  width: 100%;
  min-height: 46px;
  text-align: center;
}
@media (max-width: 980px) {
  .credit-grid,
  .pricing-main .pricing-grid-wide {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 1rem;
  }
  .credit-card,
  .pricing-main .price-card,
  .pricing-main .price-card:first-child,
  .pricing-main .price-card:last-child {
    min-height: 420px;
    border: 1px solid var(--border);
    border-radius: 18px;
  }
  .credit-card-featured,
  .pricing-main .price-card.featured {
    margin: 0;
  }
  .credit-how ol {
    grid-template-columns: repeat(2, 1fr);
    row-gap: 1.5rem;
  }
  .credit-how li:nth-child(2) {
    border-right: 0;
  }
}
@media (max-width: 640px) {
  .pricing-main {
    width: calc(100% - 32px);
  }
  .pricing-main .page-hero {
    padding-top: 2.7rem;
  }
  .pricing-main .page-hero h1 {
    font-size: clamp(2.45rem, 13vw, 3.35rem);
  }
  .pricing-main .billing-toggle {
    flex-wrap: nowrap;
  }
  .pricing-main .billing-pill {
    min-height: 44px;
    padding: 0.7rem 0.55rem;
    font-size: 0.88rem;
  }
  .credit-pricing::before,
  .credit-pricing::after {
    display: none;
  }
  .credit-grid,
  .pricing-main .pricing-grid-wide,
  .credit-how ol,
  .credit-assurance {
    grid-template-columns: 1fr;
  }
  .credit-card,
  .credit-card-featured,
  .pricing-main .price-card,
  .pricing-main .price-card:first-child,
  .pricing-main .price-card:last-child,
  .pricing-main .price-card.featured {
    min-height: 0;
    margin: 0;
    border-radius: 18px;
  }
  .credit-card h3,
  .credit-card .price-copy {
    min-height: 0;
  }
  .credit-price {
    margin-top: 1.75rem;
  }
  .credit-assurance {
    text-align: left;
  }
  .credit-assurance span {
    padding: 0.45rem 0.6rem;
  }
  .credit-assurance span + span {
    border-top: 1px solid rgba(20, 92, 50, 0.16);
    border-left: 0;
  }
  .credit-how li,
  .credit-how li:nth-child(2) {
    padding: 0.7rem 0.5rem;
    border-right: 0;
    border-bottom: 1px solid var(--border);
  }
  .credit-how li:last-child {
    border-bottom: 0;
  }
}
.current-badge {
  background: var(--accent);
  color: #fff;
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  padding: 0.25rem 0.75rem;
  border-radius: var(--radius-md) var(--radius-md) 0 0;
  text-align: center;
  margin: -1.5rem -1.5rem 1rem;
}
.current-label {
  opacity: 0.6;
  cursor: default;
}
#checkout-overlay {
  position: fixed;
  inset: 0;
  z-index: 9999;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(0, 0, 0, 0.55);
  backdrop-filter: blur(4px);
}
#checkout-overlay[hidden] { display: none; }
.checkout-overlay-inner {
  text-align: center;
  color: #fff;
  font-size: 1.1rem;
}
.checkout-overlay-inner .spinner {
  width: 2.5rem;
  height: 2.5rem;
  border: 3px solid rgba(255,255,255,0.3);
  border-top-color: #fff;
  border-radius: 50%;
  margin: 0 auto 1rem;
  animation: co-spin 0.7s linear infinite;
}
@keyframes co-spin { to { transform: rotate(360deg); } }
.discount-card {
  margin-top: 1.5rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  flex-wrap: wrap;
}
.discount-form {
  display: flex;
  gap: 0.8rem;
  align-items: center;
  flex-wrap: wrap;
}
.discount-form input {
  min-width: 16rem;
}
.discount-msg,
.inline-message {
  margin-top: 1rem;
  border-radius: var(--radius-md);
  padding: 0.85rem 1rem;
  font-size: 0.94rem;
}
.discount-msg.success,
.inline-message.success {
  color: var(--brand-deep);
  background: rgba(20, 92, 50, 0.08);
  border: 1px solid rgba(20, 92, 50, 0.14);
}
.discount-msg.error,
.inline-message.error {
  color: var(--danger);
  background: rgba(200, 68, 68, 0.08);
  border: 1px solid rgba(200, 68, 68, 0.14);
}
.account-grid-page,
.settings-grid {
  margin-top: 1.5rem;
}
.settings-grid-modern {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}
.settings-card-wide {
  grid-column: span 2;
}
.settings-rows {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1rem;
  margin: 1rem 0;
}
.account-plan-label {
  font-family: var(--font-heading);
  font-size: clamp(1.4rem, 3vw, 2.2rem);
  margin: 0.3rem 0 0.8rem;
}
.usage-bar-wrap {
  width: 100%;
  height: 0.7rem;
  border-radius: var(--radius-pill);
  background: rgba(20, 92, 50, 0.12);
  overflow: hidden;
}
.usage-bar {
  height: 100%;
  width: 0;
  background: linear-gradient(135deg, #145c32, #22874a);
  border-radius: var(--radius-pill);
}
.usage-bar.warn {
  background: linear-gradient(135deg, #d9a33e, #f2d474);
}
.usage-bar.full {
  background: linear-gradient(135deg, #d15a5a, #ff9d9d);
}
.account-usage-text,
.account-reset-text {
  color: var(--text-soft);
}
.stack-actions {
  margin-top: 1rem;
  flex-wrap: wrap;
}
.signed-out-card {
  max-width: 40rem;
  margin: 0 auto;
  text-align: center;
}
.account-main {
  width: min(1080px, calc(100% - 2rem));
  padding-top: 2.8rem;
}
.account-page-intro {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 2rem;
  margin-bottom: 2rem;
}
.account-page-intro h1 {
  margin: 0;
  max-width: 42rem;
  font-family: var(--font-heading);
  font-size: clamp(2.25rem, 5vw, 4rem);
  line-height: 1;
  letter-spacing: -0.055em;
}
.account-page-intro p {
  max-width: 42rem;
  margin: 0.9rem 0 0;
  color: var(--text-soft);
  font-size: 1.05rem;
  line-height: 1.6;
}
.account-create-link {
  flex: 0 0 auto;
  margin-bottom: 0.2rem;
}
.account-dashboard {
  display: grid;
  gap: 1.2rem;
}
.account-plan-overview {
  position: relative;
  isolation: isolate;
  display: grid;
  grid-template-columns: minmax(0, 1.25fr) minmax(18rem, 0.75fr);
  gap: 2.5rem;
  overflow: hidden;
  padding: clamp(1.5rem, 4vw, 2.5rem);
  color: #fff;
  background: linear-gradient(135deg, #0b3d20 0%, #145c32 58%, #1d7540 100%);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 24px;
  box-shadow: 0 18px 48px rgba(12, 61, 32, 0.2);
}
.account-plan-overview::after {
  content: "";
  position: absolute;
  z-index: -1;
  right: -7rem;
  bottom: -9rem;
  width: 22rem;
  height: 22rem;
  border: 1px solid rgba(255, 255, 255, 0.11);
  border-radius: 50%;
  box-shadow: 0 0 0 3.6rem rgba(255, 255, 255, 0.035), 0 0 0 7rem rgba(255, 255, 255, 0.025);
  pointer-events: none;
}
.account-plan-overview .eyebrow {
  color: rgba(255, 255, 255, 0.7);
}
.account-plan-title-row {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.8rem;
}
.account-plan-overview .account-plan-label {
  margin: 0;
  color: #fff;
  font-size: clamp(2.2rem, 5vw, 3.35rem);
  line-height: 1;
  letter-spacing: -0.055em;
}
.account-active-state {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  padding: 0.36rem 0.68rem;
  color: #eaffef;
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: var(--radius-pill);
  font-size: 0.78rem;
  font-weight: 700;
}
.account-active-state span {
  width: 0.45rem;
  height: 0.45rem;
  background: #8ee6a7;
  border-radius: 50%;
  box-shadow: 0 0 0 3px rgba(142, 230, 167, 0.16);
}
.account-plan-description {
  max-width: 35rem;
  margin: 1rem 0 0;
  color: rgba(255, 255, 255, 0.78);
  font-size: 0.96rem;
  line-height: 1.65;
}
.account-plan-actions {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.7rem;
  margin-top: 1.5rem;
}
.account-plan-overview .btn-primary {
  color: #0b3d20;
  background: #fff;
  box-shadow: 0 8px 22px rgba(0, 0, 0, 0.15);
}
.account-plan-overview .btn-primary:hover {
  color: #0b3d20;
  background: #f3fff6;
}
.account-plan-overview .btn-secondary {
  color: #fff;
  background: transparent;
  border-color: rgba(255, 255, 255, 0.32);
}
.account-plan-overview .btn-secondary:hover {
  color: #fff;
  background: rgba(255, 255, 255, 0.09);
  border-color: rgba(255, 255, 255, 0.55);
}
.account-text-action {
  padding: 0.45rem 0.2rem;
  color: rgba(255, 255, 255, 0.72);
  background: none;
  border: 0;
  font: inherit;
  font-size: 0.84rem;
  font-weight: 600;
  cursor: pointer;
  text-decoration: underline;
  text-underline-offset: 0.2rem;
}
.account-text-action:hover {
  color: #fff;
}
.account-sync-link {
  margin: 0.9rem 0 0;
  font-size: 0.82rem;
}
.account-sync-link a {
  color: rgba(255, 255, 255, 0.72);
  text-underline-offset: 0.2rem;
}
.account-sync-link a:hover {
  color: #fff;
}
.account-usage-panel {
  align-self: stretch;
  display: flex;
  flex-direction: column;
  justify-content: center;
  min-height: 13rem;
  padding: 1.5rem;
  background: rgba(255, 255, 255, 0.09);
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 18px;
  backdrop-filter: blur(8px);
}
.account-usage-heading {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1rem;
}
.account-usage-icon {
  display: grid;
  place-items: center;
  width: 2.7rem;
  height: 2.7rem;
  flex: 0 0 auto;
  color: #d9f7e1;
  background: rgba(255, 255, 255, 0.1);
  border-radius: 12px;
}
.account-plan-overview .account-usage-text {
  margin: 0.25rem 0 0;
  color: #fff;
  font-family: var(--font-heading);
  font-size: 1.35rem;
  font-weight: 700;
  letter-spacing: -0.035em;
}
.account-plan-overview .usage-bar-wrap {
  height: 0.55rem;
  margin-top: 1.5rem;
  background: rgba(255, 255, 255, 0.18);
}
.account-plan-overview .usage-bar {
  background: #b6f0c8;
}
.account-plan-overview .usage-bar.warn {
  background: #f9d778;
}
.account-plan-overview .usage-bar.full {
  background: #ffaaa5;
}
.account-plan-overview .account-reset-text {
  min-height: 1.2em;
  margin: 0.75rem 0 0;
  color: rgba(255, 255, 255, 0.68);
  font-size: 0.82rem;
}
.account-content-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.28fr) minmax(18rem, 0.72fr);
  gap: 1.2rem;
  align-items: stretch;
}
.account-panel {
  padding: clamp(1.35rem, 3vw, 2rem);
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 20px;
  box-shadow: var(--shadow-sm);
}
.account-panel-heading {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 2rem;
  margin-bottom: 1.5rem;
}
.account-panel-heading-stacked {
  display: block;
}
.account-panel-heading h2,
.account-realms-panel h2 {
  margin: 0;
  font-family: var(--font-heading);
  font-size: 1.55rem;
  line-height: 1.15;
  letter-spacing: -0.04em;
}
.account-panel-heading > p,
.account-panel-heading-stacked > p {
  max-width: 18rem;
  margin: 0;
  color: var(--text-muted);
  font-size: 0.86rem;
  line-height: 1.55;
}
.account-panel-heading-stacked > p {
  max-width: 25rem;
  margin-top: 0.75rem;
}
.profile-form {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1rem;
}
.profile-form label {
  color: var(--text-soft);
  font-size: 0.82rem;
  font-weight: 700;
}
.profile-form input,
.profile-form textarea {
  width: 100%;
  padding: 0.8rem 0.9rem;
  color: var(--text);
  background: var(--bg-input);
  border: 1px solid var(--border);
  border-radius: 11px;
  font: inherit;
  font-size: 0.92rem;
  line-height: 1.45;
  transition: border-color 0.18s ease, box-shadow 0.18s ease;
}
.profile-form input:focus,
.profile-form textarea:focus {
  outline: none;
  border-color: var(--brand);
  box-shadow: 0 0 0 3px rgba(20, 92, 50, 0.1);
}
.profile-form textarea {
  min-height: 7.5rem;
  resize: vertical;
}
.profile-bio-field,
.profile-form-footer {
  grid-column: 1 / -1;
}
.profile-form-footer {
  display: flex;
  align-items: center;
  gap: 1rem;
  margin-top: 0.15rem;
}
.account-inline-status {
  margin: 0;
  color: var(--text-muted);
  font-size: 0.84rem;
  line-height: 1.4;
}
.account-access-row {
  display: flex;
  align-items: center;
  gap: 0.8rem;
  padding: 0.9rem;
  background: rgba(20, 92, 50, 0.055);
  border: 1px solid rgba(20, 92, 50, 0.1);
  border-radius: 13px;
}
.account-access-icon {
  display: grid;
  place-items: center;
  width: 2.55rem;
  height: 2.55rem;
  flex: 0 0 auto;
  color: var(--brand);
  background: var(--brand-soft);
  border-radius: 10px;
}
.account-access-row strong,
.account-access-row span {
  display: block;
}
.account-access-row strong {
  font-size: 0.9rem;
}
.account-access-row div span {
  max-width: 17rem;
  margin-top: 0.15rem;
  overflow: hidden;
  color: var(--text-muted);
  font-size: 0.8rem;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.account-access-button {
  margin-top: 0.85rem;
}
.account-danger-zone {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  margin-top: 1.6rem;
  padding-top: 1.25rem;
  border-top: 1px solid var(--border);
}
.account-danger-zone h3 {
  margin: 0;
  font-size: 0.9rem;
}
.account-danger-zone p {
  margin: 0.25rem 0 0;
  color: var(--text-muted);
  font-size: 0.78rem;
  line-height: 1.45;
}
.account-danger-button {
  flex: 0 0 auto;
  padding: 0.55rem 0.75rem;
  color: var(--danger);
  background: transparent;
  border: 1px solid color-mix(in srgb, var(--danger) 35%, transparent);
  border-radius: 9px;
  font: inherit;
  font-size: 0.78rem;
  font-weight: 700;
  cursor: pointer;
}
.account-danger-button:hover {
  background: color-mix(in srgb, var(--danger) 8%, transparent);
  border-color: var(--danger);
}
.account-realms-panel {
  margin-top: 0;
}
.signed-out-card {
  padding: clamp(2rem, 5vw, 3.25rem);
  border-radius: 22px;
}
.signed-out-card p {
  max-width: 29rem;
  margin: 0.8rem auto 1.4rem;
  color: var(--text-soft);
  line-height: 1.65;
}
.signed-out-icon {
  display: grid;
  place-items: center;
  width: 3.5rem;
  height: 3.5rem;
  margin: 0 auto 1.25rem;
  color: var(--brand);
  background: var(--brand-soft);
  border-radius: 16px;
}
html[data-theme="dark"] .account-access-row {
  background: rgba(58, 173, 94, 0.07);
  border-color: rgba(58, 173, 94, 0.14);
}
@media (max-width: 900px) {
  .account-page-intro {
    align-items: flex-start;
    flex-direction: column;
    gap: 1.25rem;
  }
  .account-plan-overview,
  .account-content-grid {
    grid-template-columns: 1fr;
  }
  .account-plan-overview {
    gap: 1.5rem;
  }
  .account-usage-panel {
    min-height: 0;
  }
}
@media (max-width: 620px) {
  .account-main {
    width: min(100% - 1.2rem, 1080px);
    padding-top: 1.5rem;
  }
  .account-page-intro {
    margin-bottom: 1.4rem;
  }
  .account-page-intro h1 {
    font-size: clamp(2rem, 11vw, 2.7rem);
  }
  .account-plan-overview,
  .account-panel,
  .signed-out-card {
    border-radius: 17px;
  }
  .account-plan-actions,
  .profile-form,
  .profile-form-footer {
    grid-template-columns: 1fr;
  }
  .profile-form {
    display: grid;
  }
  .profile-form-footer {
    display: flex;
    align-items: stretch;
    flex-direction: column;
  }
  .account-panel-heading {
    display: block;
  }
  .account-panel-heading > p {
    margin-top: 0.75rem;
  }
  .account-danger-zone {
    align-items: flex-start;
    flex-direction: column;
  }
  .account-danger-button {
    width: 100%;
  }
}
.toggle-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  margin: 1rem 0;
  padding: 0.9rem 1rem;
  border-radius: var(--radius-md);
  background: rgba(255, 255, 255, 0.62);
  border: 1px solid var(--border);
}
html[data-theme="dark"] .toggle-row {
  background: rgba(255, 255, 255, 0.03);
}
.toggle-row input[type="checkbox"] {
  width: 1.15rem;
  height: 1.15rem;
  accent-color: var(--brand);
}
.settings-stack {
  display: flex;
  flex-direction: column;
  gap: 0.8rem;
  margin-top: 1rem;
}
.toggle-label {
  display: flex;
  align-items: center;
  gap: 0.7rem;
  padding: 0.85rem 1rem;
  border-radius: var(--radius-md);
  background: rgba(255, 255, 255, 0.62);
  border: 1px solid var(--border);
}
html[data-theme="dark"] .toggle-label {
  background: rgba(255, 255, 255, 0.03);
}
.toggle-label input[type="radio"] {
  accent-color: var(--brand);
}
.workspace-shell {
  display: grid;
  grid-template-columns: minmax(300px, 0.64fr) minmax(0, 1.36fr);
  gap: 1rem;
  --workspace-panel-height: calc(100vh - 8.25rem);
  flex: 1;
  min-height: calc(100vh - 5.5rem);
  align-items: stretch;
  animation: fadeIn 0.3s ease;
}
@keyframes fadeIn {
  from { opacity: 0; transform: translateY(8px); }
  to   { opacity: 1; transform: translateY(0); }
}
@keyframes sm-spin {
  to { transform: rotate(360deg); }
}
@keyframes sm-pulse {
  0%, 100% { transform: scale(1); opacity: 1; }
  50% { transform: scale(0.82); opacity: 0.72; }
}
.sm-reveal {
  transition: opacity 0.2s var(--ease-out);
}
html.sm-anim .sm-reveal:not(.sm-visible) {
  opacity: 0;
}
.sm-reveal.sm-visible {
  opacity: 1;
}
.sm-stagger > .sm-reveal:nth-child(1) { transition-delay: 0ms; }
.sm-stagger > .sm-reveal:nth-child(2) { transition-delay: 30ms; }
.sm-stagger > .sm-reveal:nth-child(3) { transition-delay: 60ms; }
.sm-stagger > .sm-reveal:nth-child(4) { transition-delay: 90ms; }
.sm-stagger > .sm-reveal:nth-child(5) { transition-delay: 120ms; }
.sm-stagger > .sm-reveal:nth-child(6) { transition-delay: 150ms; }
.sm-stagger > .sm-reveal:nth-child(7) { transition-delay: 180ms; }
.sm-stagger > .sm-reveal:nth-child(8) { transition-delay: 210ms; }
.sm-reveal-scale {
  transition: opacity 0.2s cubic-bezier(0.22, 1, 0.36, 1),
              transform 0.2s cubic-bezier(0.22, 1, 0.36, 1);
}
html.sm-anim .sm-reveal-scale:not(.sm-visible) {
  opacity: 0;
  transform: scale(0.98);
}
.sm-reveal-scale.sm-visible {
  opacity: 1;
  transform: scale(1);
}
@media (prefers-reduced-motion: reduce) {
  html.sm-anim .sm-reveal:not(.sm-visible), html.sm-anim .sm-reveal-scale:not(.sm-visible) { opacity: 1; transform: none; }
  .sm-reveal, .sm-reveal-scale { transition: none; }
}
@media (prefers-reduced-motion: no-preference) {
  html body .mk-hero :is(.mk-h1, .mk-lead, .mk-prompt, .mk-actions, .mk-hero-media) { animation: sm-hero-settle .3s cubic-bezier(.2, .7, .2, 1) both; }
  html body .mk-hero :is(.mk-lead, .mk-prompt, .mk-actions, .mk-hero-media) { animation-delay: 0s; }
}
@keyframes sm-hero-settle { from { transform: translateY(6px); } to { transform: none; } }
html .mk-close--signoff .mk-lead { margin-inline: auto; }
.sm-pointer-card {
  position: relative;
}
.sm-pointer-card > * {
  position: relative;
  z-index: 1;
}
@keyframes heroSlideUp {
  from { opacity: 0; transform: translateY(32px); }
  to   { opacity: 1; transform: translateY(0); }
}
@keyframes heroBadgePop {
  0%   { opacity: 0; transform: scale(0.8) translateY(12px); }
  60%  { transform: scale(1.04) translateY(0); }
  100% { opacity: 1; transform: scale(1) translateY(0); }
}
.mkt-step,
.mkt-why-card,
.mkt-plan,
.composer-card,
.feature-card,
.price-card,
.page-card,
.workspace-chat,
.workspace-preview,
.progress-card,
.mkt-demo-card {
  transition: transform 0.28s var(--ease-out),
              box-shadow 0.28s var(--ease-out),
              border-color 0.28s ease;
}
.mkt-step:hover,
.mkt-why-card:hover,
.mkt-plan:hover,
.feature-card:hover,
.price-card:hover,
.page-card:hover,
.workspace-chat:hover,
.progress-card:hover,
.mkt-demo-card:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-lg);
}
.sm-ripple-host {
  position: relative;
  overflow: hidden;
}
.sm-ripple {
  position: absolute;
  border-radius: 50%;
  pointer-events: none;
  transform: translate(-50%, -50%) scale(0);
  background: rgba(255, 255, 255, 0.28);
  animation: smRipple 0.6s cubic-bezier(0.22, 1, 0.36, 1) forwards;
}
@keyframes smRipple {
  to {
    transform: translate(-50%, -50%) scale(1);
    opacity: 0;
  }
}
.btn-primary:active,
.btn-secondary:active,
.btn-ghost:active,
.mkt-cta-primary:active,
.mkt-cta-secondary:active {
  transform: scale(0.97);
  transition-duration: 0.08s;
}
@keyframes shimmer {
  0%   { background-position: -200% 0; }
  100% { background-position: 200% 0; }
}
.skeleton {
  background: linear-gradient(90deg, var(--bg-soft) 25%, var(--surface) 37%, var(--bg-soft) 63%);
  background-size: 200% 100%;
  animation: shimmer 1.4s ease-in-out infinite;
  border-radius: var(--radius-md);
}
.chip-btn,
.style-chip,
.mkt-badge,
.status-chip,
.tier-badge {
  transition: transform 0.2s ease, border-color 0.2s ease, background 0.2s ease;
}
.chip-btn:hover,
.style-chip:hover {
  transform: scale(1.04);
}
@keyframes progressPulse {
  0%, 100% { opacity: 0.4; }
  50%      { opacity: 1; }
}
@keyframes progressSweep {
  from { background-position: 0% 50%; }
  to   { background-position: 100% 50%; }
}
.progress-bar {
  background: linear-gradient(90deg, #145c32 0%, #1f7b43 35%, #5fd48a 52%, #1f7b43 70%, #145c32 100%);
  background-size: 220% 100%;
  animation: progressSweep 2.4s linear infinite;
  position: relative;
}
.progress-bar::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  box-shadow: 0 0 18px rgba(20, 92, 50, 0.5);
  animation: progressPulse 2s ease-in-out infinite;
  will-change: opacity;
}
@keyframes stepPing {
  0%   { transform: scale(1); }
  50%  { transform: scale(1.06); }
  100% { transform: scale(1); }
}
.step.active {
  animation: stepPing 1.8s ease-in-out infinite;
  will-change: transform;
}
.step {
  transition: color 0.3s ease, background 0.3s ease, border-color 0.3s ease;
}
@keyframes msgSlideIn {
  from { opacity: 0; transform: translateY(14px) scale(0.97); }
  to   { opacity: 1; transform: translateY(0) scale(1); }
}
.message {
  animation: msgSlideIn 0.35s cubic-bezier(0.22, 1, 0.36, 1) both;
}
@keyframes pageCardIn {
  from { opacity: 0; transform: translateY(20px) scale(0.95); }
  to   { opacity: 1; transform: translateY(0) scale(1); }
}
.page-card {
  animation: pageCardIn 0.45s cubic-bezier(0.22, 1, 0.36, 1) both;
}
.preview-pages .page-card:nth-child(1) { animation-delay: 0ms; }
.preview-pages .page-card:nth-child(2) { animation-delay: 100ms; }
.preview-pages .page-card:nth-child(3) { animation-delay: 200ms; }
.preview-pages .page-card:nth-child(4) { animation-delay: 300ms; }
.preview-pages .page-card:nth-child(5) { animation-delay: 400ms; }
.preview-pages .page-card:nth-child(6) { animation-delay: 500ms; }
.preview-pages .page-card:nth-child(7) { animation-delay: 600ms; }
.preview-pages .page-card:nth-child(8) { animation-delay: 700ms; }
.page-image,
.cover-stage img {
  transition: transform 0.4s cubic-bezier(0.22, 1, 0.36, 1);
}
.page-card:hover .page-image {
  transform: scale(1.04);
}
.cover-stage:hover img {
  transform: scale(1.03);
}
@keyframes modalBackdropIn {
  from { opacity: 0; }
  to   { opacity: 1; }
}
@keyframes modalCardIn {
  from { opacity: 0; transform: scale(0.9) translateY(20px); }
  to   { opacity: 1; transform: scale(1) translateY(0); }
}
.auth-modal-overlay {
  animation: modalBackdropIn 0.25s ease-out both;
}
.auth-modal {
  animation: modalCardIn 0.35s 0.05s cubic-bezier(0.22, 1, 0.36, 1) both;
}
@keyframes float {
  0%, 100% { transform: translateY(0); }
  50%      { transform: translateY(-10px); }
}
.mkt-page-img {
  animation: float 3.5s ease-in-out infinite;
}
.mkt-page:nth-child(2) .mkt-page-img {
  animation-delay: 0.7s;
}
@keyframes slideInLeft {
  from { opacity: 0; transform: translateX(-32px); }
  to   { opacity: 1; transform: translateX(0); }
}
@keyframes slideInRight {
  from { opacity: 0; transform: translateX(32px); }
  to   { opacity: 1; transform: translateX(0); }
}
.logo-mark {
  transition: transform 0.3s cubic-bezier(0.22, 1, 0.36, 1);
}
.logo-area:hover .logo-mark {
  transform: rotate(-8deg) scale(1.1);
}
@keyframes gradientShimmer {
  0%   { background-position: -200% center; }
  100% { background-position: 200% center; }
}
.mkt-hero h1 em {
  background: linear-gradient(90deg, var(--accent), #22874a, #10b981, var(--accent));
  background-size: 200% auto;
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  animation: gradientShimmer 4s linear infinite;
}
html[data-theme="dark"] .mkt-hero h1 em {
  background: linear-gradient(90deg, #3aad5e, #5ec97a, #86efac, #3aad5e);
  background-size: 200% auto;
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}
.mkt-demo-card .mkt-demo-text {
  transition: opacity 0.7s cubic-bezier(0.22, 1, 0.36, 1),
              transform 0.7s cubic-bezier(0.22, 1, 0.36, 1);
}
.mkt-demo-card .mkt-book {
  transition: opacity 0.7s 0.15s cubic-bezier(0.22, 1, 0.36, 1),
              transform 0.7s 0.15s cubic-bezier(0.22, 1, 0.36, 1);
}
html.sm-anim .mkt-demo-card .mkt-demo-text:not(.sm-visible *) {
  opacity: 0;
  transform: translateX(-36px);
}
html.sm-anim .mkt-demo-card .mkt-book:not(.sm-visible *) {
  opacity: 0;
  transform: translateX(36px);
}
.sm-visible .mkt-demo-text,
.sm-visible .mkt-book {
  opacity: 1;
  transform: translateX(0);
}
@keyframes cursorBlink {
  0%, 100% { border-right-color: var(--accent); }
  50%      { border-right-color: transparent; }
}
.mkt-hero-sub.typing {
  display: inline-block;
  border-right: 2px solid var(--accent);
  padding-right: 4px;
  animation: cursorBlink 0.75s step-end infinite;
  white-space: nowrap;
  overflow: hidden;
  max-width: 560px;
}
.mkt-hero-sub.typing-done {
  border-right: none;
  white-space: normal;
  overflow: visible;
}
.sm-divider {
  width: 80px;
  height: 2px;
  background: linear-gradient(90deg, transparent, var(--accent), transparent);
  border-radius: 2px;
  margin: 0 auto 2.5rem;
  transform-origin: center;
  transition: transform 0.6s 0.2s var(--ease-out);
}
html.sm-anim .sm-divider:not(.sm-visible) {
  transform: scaleX(0);
}
.sm-divider.sm-visible {
  transform: scaleX(1);
}
@keyframes stepNumPop {
  0%   { transform: scale(0) rotate(-20deg); opacity: 0; }
  60%  { transform: scale(1.15) rotate(3deg); }
  100% { transform: scale(1) rotate(0); opacity: 1; }
}
.sm-visible .mkt-step-num {
  animation: stepNumPop 0.5s cubic-bezier(0.22, 1, 0.36, 1) both;
}
.sm-stagger .mkt-step:nth-child(1) .mkt-step-num { animation-delay: 0.1s; }
.sm-stagger .mkt-step:nth-child(2) .mkt-step-num { animation-delay: 0.2s; }
.sm-stagger .mkt-step:nth-child(3) .mkt-step-num { animation-delay: 0.3s; }
.sm-stagger .mkt-step:nth-child(4) .mkt-step-num { animation-delay: 0.4s; }
@keyframes iconBounce {
  0%   { transform: translateY(16px) scale(0.5); opacity: 0; }
  50%  { transform: translateY(-4px) scale(1.1); }
  100% { transform: translateY(0) scale(1); opacity: 1; }
}
.sm-visible .mkt-why-icon {
  animation: iconBounce 0.55s cubic-bezier(0.22, 1, 0.36, 1) both;
}
.sm-stagger .mkt-why-card:nth-child(1) .mkt-why-icon { animation-delay: 0.05s; }
.sm-stagger .mkt-why-card:nth-child(2) .mkt-why-icon { animation-delay: 0.12s; }
.sm-stagger .mkt-why-card:nth-child(3) .mkt-why-icon { animation-delay: 0.19s; }
.sm-stagger .mkt-why-card:nth-child(4) .mkt-why-icon { animation-delay: 0.26s; }
.sm-stagger .mkt-why-card:nth-child(5) .mkt-why-icon { animation-delay: 0.33s; }
.sm-stagger .mkt-why-card:nth-child(6) .mkt-why-icon { animation-delay: 0.40s; }
.sm-stagger .mkt-why-card:nth-child(7) .mkt-why-icon { animation-delay: 0.47s; }
.sm-stagger .mkt-why-card:nth-child(8) .mkt-why-icon { animation-delay: 0.54s; }
html.sm-anim .mkt-plan:not(.sm-visible):not(.sm-visible *) {
  opacity: 0;
  transform: translateY(24px) scale(0.95);
}
.mkt-plan {
  transition: opacity 0.5s cubic-bezier(0.22, 1, 0.36, 1),
              transform 0.5s cubic-bezier(0.22, 1, 0.36, 1),
              border-color 0.28s ease,
              box-shadow 0.28s ease;
}
.sm-stagger .mkt-plan:nth-child(1) { transition-delay: 0ms; }
.sm-stagger .mkt-plan:nth-child(2) { transition-delay: 100ms; }
.sm-stagger .mkt-plan:nth-child(3) { transition-delay: 200ms; }
.sm-stagger .mkt-plan:nth-child(4) { transition-delay: 300ms; }
.sm-visible .mkt-plan,
.mkt-plan.sm-visible {
  opacity: 1;
  transform: translateY(0) scale(1);
}
.mkt-plan:hover {
  transform: translateY(-4px) scale(1.02);
  box-shadow: var(--shadow-lg);
}
.mkt-plan.hi:hover {
  box-shadow: var(--shadow-glow), var(--shadow-lg);
}
@keyframes bottomGlow {
  0%, 100% { box-shadow: 0 0 40px rgba(20, 92, 50, 0.06); }
  50%      { box-shadow: 0 0 60px rgba(20, 92, 50, 0.14); }
}
.mkt-bottom {
  animation: bottomGlow 4s ease-in-out infinite;
}
.nav-link {
  position: relative;
}
.nav-link::after {
  content: "";
  position: absolute;
  bottom: 0;
  left: 50%;
  width: 0;
  height: 2px;
  background: var(--accent);
  border-radius: 1px;
  transition: width 0.25s ease, left 0.25s ease;
}
.nav-link:hover::after,
.nav-link.active::after {
  width: 60%;
  left: 20%;
}
.sm-ad-slot {
  display: none;
  width: min(100%, 970px);
  margin: 1.75rem auto;
  padding: 0;
  clear: both;
  contain: layout;
  text-align: center;
}
.sm-ad-state-ready,
.sm-ad-state-pending {
  display: block;
}
.sm-ad-label {
  margin: 0 0 0.4rem;
  color: var(--text-muted);
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  line-height: 1;
  text-transform: uppercase;
}
.sm-ad-frame {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 96px;
  overflow: hidden;
  border: 1px solid var(--border);
  border-radius: 8px;
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.76), rgba(240, 246, 239, 0.7));
}
html[data-theme="dark"] .sm-ad-frame {
  background:
    linear-gradient(135deg, rgba(19, 30, 22, 0.82), rgba(10, 16, 12, 0.7));
}
.sm-ad-slot[data-sm-ad-size="leaderboard"] .sm-ad-frame {
  min-height: 112px;
}
.sm-ad-slot[data-sm-ad-size="in-article"] {
  max-width: 760px;
}
.sm-ad-slot[data-sm-ad-size="in-article"] .sm-ad-frame,
.sm-ad-slot[data-sm-ad-size="feed"] .sm-ad-frame {
  min-height: 160px;
}
.sm-ad-frame .adsbygoogle {
  width: 100%;
  min-height: inherit;
}
body.sm-ads-disabled .sm-ad-slot,
body.sm-ads-paid .sm-ad-slot,
.reader-experience .sm-ad-slot,
.reader-stage-shell .sm-ad-slot,
.imm-reader .sm-ad-slot,
.imm-overlay .sm-ad-slot {
  display: none !important;
}
body[data-page="published"] .sm-ad-slot[data-sm-ad-slot="share-top"] {
  margin-top: 1.25rem;
  margin-bottom: 1.5rem;
}
body[data-page="published"] .sm-ad-slot[data-sm-ad-slot="share-bottom"] {
  margin-top: 1.5rem;
}
@media (max-width: 720px) {
  .sm-ad-slot {
    width: 100%;
    margin: 1.35rem auto;
  }
  .sm-ad-frame,
  .sm-ad-slot[data-sm-ad-size="leaderboard"] .sm-ad-frame {
    min-height: 92px;
  }
  .sm-ad-slot[data-sm-ad-size="in-article"] .sm-ad-frame,
  .sm-ad-slot[data-sm-ad-size="feed"] .sm-ad-frame {
    min-height: 132px;
  }
}
.usage-bar {
  transition: width 0.8s cubic-bezier(0.22, 1, 0.36, 1);
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
  .sm-reveal,
  .sm-reveal-scale,
  .sm-divider,
  .mkt-plan,
  .mkt-demo-card .mkt-demo-text,
  .mkt-demo-card .mkt-book {
    opacity: 1 !important;
    transform: none !important;
  }
  .mkt-hero h1 em {
    -webkit-text-fill-color: var(--accent) !important;
    background: none !important;
  }
}
.workspace-chat {
  display: flex;
  flex-direction: column;
  overflow: hidden;
  height: var(--workspace-panel-height);
  min-height: 0;
  max-height: var(--workspace-panel-height);
}
.workspace-preview {
  display: flex;
  flex-direction: column;
  overflow: hidden;
  height: var(--workspace-panel-height);
  min-height: 0;
  max-height: var(--workspace-panel-height);
}
body[data-page="generate"] .workspace-chat,
body[data-page="generate"] .workspace-preview {
  background: linear-gradient(180deg, #fffef9, #f6fbf7);
  color: var(--text);
}
html[data-theme="dark"] body[data-page="generate"] .workspace-chat,
html[data-theme="dark"] body[data-page="generate"] .workspace-preview {
  background: var(--editor-surface, var(--sm-surface));
  color: var(--editor-ink, var(--sm-ink));
}
.editor-agent-status {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  padding: 0.45rem 0.72rem;
  border-radius: 999px;
  background: rgba(20, 92, 50, 0.08);
  border: 1px solid rgba(20, 92, 50, 0.14);
  color: var(--brand-deep);
  font-size: 0.78rem;
  font-weight: 700;
}
.editor-agent-dot {
  width: 0.52rem;
  height: 0.52rem;
  border-radius: 999px;
  background: #24a55a;
  box-shadow: 0 0 0 4px rgba(36, 165, 90, 0.12);
}
.editor-agent-status[data-state="working"] .editor-agent-dot {
  background: #e6a21a;
  box-shadow: 0 0 0 4px rgba(230, 162, 26, 0.14);
  animation: sm-pulse 1.1s ease-in-out infinite;
}
.editor-agent-status[data-state="error"] .editor-agent-dot {
  background: #dc2626;
  box-shadow: 0 0 0 4px rgba(220, 38, 38, 0.12);
}
.workspace-chat .chat-messages {
  flex: 1;
  min-height: 0;
}
.workspace-preview .preview-pages {
  flex: 1;
  min-height: 0;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  margin-top: 0;
}
.chat-messages {
  margin-top: 1rem;
  display: flex;
  flex-direction: column;
  gap: 0.9rem;
  flex: 1;
  min-height: 0;
  overflow-y: auto;
  overscroll-behavior: contain;
  padding-right: 0.3rem;
  scroll-behavior: smooth;
}
.message {
  border-radius: 1.25rem;
  padding: 0.95rem 1rem;
  line-height: 1.65;
}
.message.assistant {
  background: rgba(255, 255, 255, 0.72);
  border: 1px solid var(--border);
}
.message.user {
  background: rgba(20, 92, 50, 0.1);
  border: 1px solid rgba(20, 92, 50, 0.14);
}
html[data-theme="dark"] .message.assistant {
  background: rgba(255, 255, 255, 0.03);
}
.message p {
  margin: 0;
}
.message-role {
  margin-bottom: 0.35rem;
}
.chat-form {
  margin-top: auto;
  padding-top: 1rem;
  background: linear-gradient(180deg, rgba(245, 251, 244, 0), var(--bg-card) 18%);
}
html[data-theme="dark"] .chat-form {
  background: linear-gradient(180deg, rgba(15, 23, 17, 0), var(--bg-card) 18%);
}
.chat-hint {
  color: var(--text-muted);
  font-size: 0.85rem;
}
.chat-quick-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
  margin: 0.85rem 0 0;
}
.chat-quick-actions button,
.edit-page-btn {
  border: 1px solid rgba(20, 92, 50, 0.16);
  background: rgba(20, 92, 50, 0.08);
  color: var(--brand-deep);
  border-radius: var(--sm-r-chip);
  font: inherit;
  font-size: 0.8rem;
  font-weight: 700;
  cursor: pointer;
  transition: background 0.15s ease, border-color 0.15s ease, transform 0.15s ease;
}
.chat-quick-actions button {
  padding: 0.48rem 0.72rem;
}
.chat-quick-actions button:hover,
.edit-page-btn:hover {
  background: rgba(20, 92, 50, 0.13);
  border-color: rgba(20, 92, 50, 0.28);
  transform: translateY(-1px);
}
.chat-attachment {
  padding: 0.75rem 0.8rem 0;
}
.chat-attachment-chip {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: 0.55rem;
  padding: 0.58rem 0.7rem;
  border-radius: 14px;
  background: rgba(20, 92, 50, 0.08);
  border: 1px solid rgba(20, 92, 50, 0.15);
  color: #17351f;
}
.chat-attachment-chip strong {
  white-space: nowrap;
  color: var(--brand-deep);
}
.chat-attachment-chip span {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  color: var(--text-soft);
  font-size: 0.84rem;
}
.chat-attachment-chip button {
  width: 1.8rem;
  height: 1.8rem;
  border: 0;
  border-radius: 999px;
  background: rgba(20, 92, 50, 0.12);
  color: var(--brand-deep);
  font-size: 1.05rem;
  line-height: 1;
  cursor: pointer;
}
.message.pending {
  opacity: 0.76;
}
.message.working {
  position: relative;
}
.message.working::after {
  content: "";
  display: inline-block;
  width: 1.1rem;
  height: 1.1rem;
  margin-left: 0.25rem;
  border-radius: 999px;
  border: 2px solid rgba(20, 92, 50, 0.18);
  border-top-color: var(--brand);
  vertical-align: -0.25rem;
  animation: sm-spin 0.8s linear infinite;
}
.edit-page-btn {
  position: absolute;
  right: 1rem;
  bottom: 1rem;
  z-index: 3;
  padding: 0.55rem 0.85rem;
  box-shadow: 0 12px 28px rgba(20, 50, 30, 0.12);
}
.spread-page-slider-wrap {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  min-width: min(18rem, 100%);
  color: var(--brand-deep);
  font-size: 0.78rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}
.spread-page-slider {
  width: 100%;
  accent-color: var(--brand);
}
.preview-meta {
  color: var(--text-soft);
  margin-top: 0.3rem;
}
.cover-stage {
  margin-top: 1.4rem;
  border-radius: var(--radius-lg);
  overflow: hidden;
  border: 1px solid var(--border);
  background: var(--surface-strong);
}
.cover-stage img {
  width: 100%;
  aspect-ratio: 1 / 1;
  object-fit: cover;
}
.locked-banner {
  margin-top: 1rem;
  padding: 1rem 1.1rem;
  border-radius: var(--radius-md);
  background: rgba(215, 146, 41, 0.1);
  color: #8a641d;
  border: 1px solid rgba(215, 146, 41, 0.18);
}
html[data-theme="dark"] .locked-banner {
  color: #ffd27c;
}
.preview-pages {
  margin-top: 1.2rem;
  display: flex;
  flex-direction: column;
  gap: 1rem;
  overflow-y: auto;
  padding-right: 0.2rem;
}
.page-card {
  padding: 0.9rem;
  border-radius: var(--radius-lg);
  background: rgba(255, 255, 255, 0.7);
  border: 1px solid var(--border);
  box-shadow: var(--shadow-sm);
  backdrop-filter: blur(6px);
}
html[data-theme="dark"] .page-card {
  background: rgba(255, 255, 255, 0.03);
}
.page-card-locked {
  display: flex;
  flex-direction: column;
  justify-content: center;
  min-height: 13rem;
  background: linear-gradient(135deg, rgba(215, 146, 41, 0.1), rgba(20, 92, 50, 0.08));
}
.comic-page { padding: 0.75rem; }
.comic-panel-grid {
  display: grid;
  gap: 10px;
  width: 100%;
  min-height: clamp(24rem, 72vh, 56rem);
  grid-auto-flow: dense;
}
.comic-panel-grid.comic-canonical-layout {
  display: block;
  position: relative;
  min-height: 0;
  max-height: min(78vh, 58rem);
  margin: 0 auto;
  background: #fff;
}
.comic-canonical-layout .comic-panel {
  position: absolute;
  min-height: 0;
}
.comic-canonical-layout .comic-panel-img,
.comic-canonical-layout .comic-panel-placeholder {
  width: 100%;
  height: 100%;
  aspect-ratio: auto;
}
.comic-layout-2x2 {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  grid-template-rows: repeat(2, minmax(180px, 1fr));
}
.comic-layout-2x3 {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  grid-template-rows: repeat(3, minmax(135px, 1fr));
}
.comic-layout-3x1 {
  grid-template-columns: minmax(0, 1fr);
  grid-template-rows: repeat(3, minmax(140px, 1fr));
}
.comic-layout-1x3 {
  grid-template-columns: repeat(3, minmax(0, 1fr));
  grid-template-rows: minmax(320px, 1fr);
}
.comic-layout-cinematic {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  grid-template-rows: minmax(250px, 1.8fr) minmax(160px, 1fr);
}
.comic-layout-cinematic .comic-panel-1 { grid-column: 1 / -1; }
.comic-layout-splash {
  grid-template-columns: minmax(0, 1fr);
  grid-template-rows: minmax(480px, 1fr);
}
.comic-layout-widescreen {
  grid-template-columns: minmax(0, 1fr);
  grid-template-rows: repeat(2, minmax(220px, 1fr));
}
.comic-layout-focus {
  grid-template-columns: minmax(0, 0.68fr) minmax(0, 1.28fr) minmax(0, 0.68fr);
  grid-template-rows: minmax(360px, 1fr);
}
.comic-layout-diagonal {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  grid-template-rows: repeat(2, minmax(180px, 1fr));
}
.comic-layout-Lshape {
  grid-template-columns: minmax(0, 1.35fr) minmax(0, 0.9fr);
  grid-template-rows: repeat(2, minmax(180px, 1fr));
}
.comic-layout-Lshape .comic-panel-1 { grid-row: 1 / span 2; }
.comic-layout-Tshape {
  grid-template-columns: repeat(3, minmax(0, 1fr));
  grid-template-rows: minmax(220px, 1.1fr) minmax(160px, 1fr);
}
.comic-layout-Tshape .comic-panel-1 { grid-column: 1 / -1; }
.comic-layout-stagger {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  grid-template-rows: repeat(3, minmax(130px, 1fr));
}
.comic-layout-stagger .comic-panel-3 { grid-column: 1 / -1; }
.comic-layout-cross {
  grid-template-columns: minmax(0, 0.72fr) minmax(0, 1.15fr) minmax(0, 0.72fr);
  grid-template-rows: minmax(120px, 0.7fr) minmax(190px, 1.1fr) minmax(120px, 0.7fr);
}
.comic-layout-cross .comic-panel-1 { grid-column: 1; grid-row: 1; }
.comic-layout-cross .comic-panel-2 { grid-column: 3; grid-row: 1; }
.comic-layout-cross .comic-panel-3 { grid-column: 2; grid-row: 2; }
.comic-layout-cross .comic-panel-4 { grid-column: 1; grid-row: 3; }
.comic-layout-cross .comic-panel-5 { grid-column: 3; grid-row: 3; }
.comic-layout-hextrio {
  grid-template-columns: repeat(3, minmax(0, 1fr));
  grid-template-rows: repeat(2, minmax(200px, 1fr));
}
.comic-layout-hextrio .comic-panel-1 { grid-column: 1 / 4; }
.comic-layout-trapezoid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  grid-template-rows: repeat(2, minmax(180px, 1fr));
}
.comic-layout-chevron {
  grid-template-columns: minmax(0, 1fr);
  grid-template-rows: repeat(3, minmax(140px, 1fr));
}
.comic-layout-wedge {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  grid-template-rows: minmax(360px, 1fr);
}
.comic-layout-diamond {
  grid-template-columns: repeat(3, minmax(0, 1fr));
  grid-template-rows: repeat(3, minmax(120px, 1fr));
}
.comic-layout-diamond .comic-panel-1 { grid-column: 2; grid-row: 1 / 4; }
.comic-layout-diamond .comic-panel-2 { grid-column: 1; grid-row: 1; }
.comic-layout-diamond .comic-panel-3 { grid-column: 3; grid-row: 1; }
.comic-layout-diamond .comic-panel-4 { grid-column: 1; grid-row: 3; }
.comic-layout-diamond .comic-panel-5 { grid-column: 3; grid-row: 3; }
.comic-layout-mangatall {
  grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr) minmax(0, 1.6fr);
  grid-template-rows: minmax(360px, 1fr);
}
.comic-layout-mangaaction {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  grid-template-rows: minmax(260px, 1.4fr) minmax(180px, 1fr);
}
.comic-layout-mangaaction .comic-panel-1 { grid-column: 1 / -1; }
.comic-panel-grid.manga-rtl {
  direction: rtl;
}
.comic-panel-grid.manga-rtl .comic-panel {
  direction: ltr;
}
.comic-panel {
  border: 3px solid #18181b;
  border-radius: 10px;
  overflow: hidden;
  background: #fff;
  position: relative;
  min-height: 0;
  display: flex;
  flex-direction: column;
  box-shadow: 0 12px 28px rgba(15, 23, 42, 0.12);
}
html[data-theme="dark"] .comic-panel {
  background: #161616;
  border-color: #52525b;
  box-shadow: 0 14px 30px rgba(0, 0, 0, 0.28);
}
.comic-panel-img,
.comic-panel-placeholder {
  width: 100%;
  flex: 1 1 auto;
  min-height: 0;
  display: block;
  object-fit: cover;
}
.comic-layout-2x2 .comic-panel-img,
.comic-layout-2x2 .comic-panel-placeholder { aspect-ratio: 1 / 1.05; }
.comic-layout-2x3 .comic-panel-img,
.comic-layout-2x3 .comic-panel-placeholder { aspect-ratio: 1 / 1.28; }
.comic-layout-3x1 .comic-panel-img,
.comic-layout-3x1 .comic-panel-placeholder { aspect-ratio: 3.2 / 1; }
.comic-layout-1x3 .comic-panel-img,
.comic-layout-1x3 .comic-panel-placeholder { aspect-ratio: 0.72 / 1; }
.comic-layout-cinematic .comic-panel-img,
.comic-layout-cinematic .comic-panel-placeholder { aspect-ratio: 1.4 / 1; }
.comic-layout-cinematic .comic-panel-1 .comic-panel-img,
.comic-layout-cinematic .comic-panel-1 .comic-panel-placeholder { aspect-ratio: 2.35 / 1; }
.comic-layout-splash .comic-panel-img,
.comic-layout-splash .comic-panel-placeholder { aspect-ratio: 0.82 / 1; }
.comic-layout-widescreen .comic-panel-img,
.comic-layout-widescreen .comic-panel-placeholder { aspect-ratio: 2.4 / 1; }
.comic-layout-focus .comic-panel-img,
.comic-layout-focus .comic-panel-placeholder { aspect-ratio: 0.72 / 1; }
.comic-layout-focus .comic-panel-2 .comic-panel-img,
.comic-layout-focus .comic-panel-2 .comic-panel-placeholder { aspect-ratio: 1 / 1; }
.comic-layout-diagonal .comic-panel-img,
.comic-layout-diagonal .comic-panel-placeholder { aspect-ratio: 1 / 1; }
.comic-layout-Lshape .comic-panel-img,
.comic-layout-Lshape .comic-panel-placeholder { aspect-ratio: 1 / 1; }
.comic-layout-Lshape .comic-panel-1 .comic-panel-img,
.comic-layout-Lshape .comic-panel-1 .comic-panel-placeholder { aspect-ratio: 0.82 / 1; }
.comic-layout-Tshape .comic-panel-img,
.comic-layout-Tshape .comic-panel-placeholder { aspect-ratio: 1 / 1.05; }
.comic-layout-Tshape .comic-panel-1 .comic-panel-img,
.comic-layout-Tshape .comic-panel-1 .comic-panel-placeholder { aspect-ratio: 2.35 / 1; }
.comic-layout-stagger .comic-panel-img,
.comic-layout-stagger .comic-panel-placeholder { aspect-ratio: 1 / 1.1; }
.comic-layout-stagger .comic-panel-3 .comic-panel-img,
.comic-layout-stagger .comic-panel-3 .comic-panel-placeholder { aspect-ratio: 2.1 / 1; }
.comic-layout-cross .comic-panel-img,
.comic-layout-cross .comic-panel-placeholder { aspect-ratio: 1 / 1; }
.comic-layout-cross .comic-panel-3 .comic-panel-img,
.comic-layout-cross .comic-panel-3 .comic-panel-placeholder { aspect-ratio: 1 / 1.05; }
.comic-panel-placeholder {
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, #f0f0f0, #e0e0e0);
  color: #888;
  font-size: 0.8rem;
  font-weight: 600;
}
html[data-theme="dark"] .comic-panel-placeholder { background: linear-gradient(135deg, #2a2a2a, #333); color: #666; }
.comic-layout-diagonal .comic-panel-1 { clip-path: polygon(0 0, 100% 0, 84% 100%, 0 100%); }
.comic-layout-diagonal .comic-panel-2 { clip-path: polygon(16% 0, 100% 0, 100% 100%, 0 100%); }
.comic-layout-diagonal .comic-panel-3 { clip-path: polygon(0 0, 100% 0, 100% 100%, 18% 100%); }
.comic-layout-diagonal .comic-panel-4 { clip-path: polygon(0 0, 82% 0, 100% 100%, 0 100%); }
.comic-dialogue-wrap {
  position: absolute;
  inset: 0;
  padding: 0.55rem;
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
  pointer-events: none;
}
.comic-speech-bubble {
  background: rgba(255, 255, 255, 0.96);
  border: 2px solid #18181b;
  border-radius: 18px 18px 18px 6px;
  padding: 0.38rem 0.72rem;
  font-size: 0.78rem;
  line-height: 1.35;
  position: relative;
  max-width: min(18rem, 76%);
  overflow-wrap: anywhere;
  box-shadow: 0 8px 18px rgba(15, 23, 42, 0.18);
}
.comic-speech-bubble::after {
  content: "";
  position: absolute;
  left: 14px;
  bottom: -10px;
  width: 14px;
  height: 14px;
  background: inherit;
  border-right: 2px solid #18181b;
  border-bottom: 2px solid #18181b;
  transform: rotate(38deg) skewX(8deg);
}
.comic-speech-bubble.pos-top-right,
.comic-speech-bubble.pos-bottom-right { align-self: flex-end; }
.comic-speech-bubble.pos-top-center,
.comic-speech-bubble.pos-bottom-center { align-self: center; }
.comic-speech-bubble.pos-bottom-left,
.comic-speech-bubble.pos-bottom-right,
.comic-speech-bubble.pos-bottom-center { margin-top: auto; }
.comic-speech-bubble.pos-top-right::after,
.comic-speech-bubble.pos-bottom-right::after {
  left: auto;
  right: 14px;
  transform: rotate(52deg) skewX(-8deg);
}
.comic-speech-bubble.pos-top-center::after,
.comic-speech-bubble.pos-bottom-center::after {
  left: calc(50% - 7px);
  right: auto;
}
html[data-theme="dark"] .comic-speech-bubble {
  background: rgba(24, 24, 27, 0.94);
  border-color: #d4d4d8;
  color: #f4f4f5;
}
html[data-theme="dark"] .comic-speech-bubble::after {
  border-right-color: #d4d4d8;
  border-bottom-color: #d4d4d8;
}
.comic-speaker { color: var(--accent); font-size: 0.72rem; }
.comic-narration {
  position: absolute;
  left: 0.55rem;
  right: 0.55rem;
  bottom: 0.55rem;
  background: rgba(255, 248, 220, 0.94);
  border: 1px solid rgba(200, 180, 100, 0.35);
  border-radius: 4px;
  padding: 0.28rem 0.55rem;
  font-size: 0.72rem;
  font-style: italic;
  color: #555;
  line-height: 1.3;
  box-shadow: 0 8px 16px rgba(0, 0, 0, 0.08);
}
html[data-theme="dark"] .comic-narration {
  background: rgba(60, 50, 20, 0.68);
  border-color: rgba(100, 90, 50, 0.35);
  color: #e4e4e7;
}
@media (max-width: 720px) {
  .page-count-row {
    flex-wrap: wrap;
  }
  .page-count-hint {
    width: 100%;
    margin-left: 0;
    text-align: left;
  }
  .comic-panel-grid {
    min-height: 20rem;
    gap: 8px;
  }
  .comic-layout-1x3 {
    grid-template-columns: minmax(0, 1fr);
    grid-template-rows: repeat(3, minmax(180px, 1fr));
  }
  .comic-layout-1x3 .comic-panel-img,
  .comic-layout-1x3 .comic-panel-placeholder { aspect-ratio: 1.25 / 1; }
  .comic-layout-focus,
  .comic-layout-cross {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    grid-template-rows: auto;
  }
  .comic-layout-cross .comic-panel-1,
  .comic-layout-cross .comic-panel-2,
  .comic-layout-cross .comic-panel-3,
  .comic-layout-cross .comic-panel-4,
  .comic-layout-cross .comic-panel-5,
  .comic-layout-focus .comic-panel-1,
  .comic-layout-focus .comic-panel-2,
  .comic-layout-focus .comic-panel-3 {
    grid-column: auto;
    grid-row: auto;
  }
  .comic-layout-focus .comic-panel-2,
  .comic-layout-cross .comic-panel-3 {
    grid-column: 1 / -1;
  }
}
@media (max-width: 560px) {
  .comic-panel-grid,
  .comic-panel-grid.comic-canonical-layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr) !important;
    grid-template-rows: none !important;
    grid-auto-rows: auto;
    gap: 10px;
    min-height: 0;
    max-height: none;
    aspect-ratio: auto !important;
    background: transparent;
  }
  .comic-panel-grid > .comic-panel {
    position: relative !important;
    inset: auto !important;
    width: auto !important;
    height: auto !important;
    grid-column: 1 / -1 !important;
    grid-row: auto !important;
    clip-path: none !important;
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    grid-template-rows: auto auto;
  }
  .comic-panel-grid > .comic-panel > .comic-panel-img,
  .comic-panel-grid > .comic-panel > .comic-panel-placeholder {
    grid-area: 1 / 1;
    width: 100%;
    height: 100%;
    aspect-ratio: auto;
    object-fit: cover;
  }
  .comic-panel-grid > .comic-panel > .comic-panel-placeholder { min-height: 0; aspect-ratio: 4 / 3; }
  .comic-panel-grid > .comic-panel > .comic-dialogue-wrap {
    position: relative;
    inset: auto;
    grid-area: 1 / 1;
    align-self: stretch;
    align-items: flex-start;
    min-width: 0;
  }
  .comic-panel-grid > .comic-panel > .comic-narration {
    position: static;
    grid-area: 2 / 1;
    margin: 0;
    border-width: 1px 0 0;
    border-radius: 0;
    box-shadow: none;
    padding: 0.45rem 0.7rem;
    font-size: 0.78rem;
  }
  .comic-panel-grid > .comic-panel .comic-speech-bubble { max-width: 84%; font-size: 0.76rem; }
}
.book-spread-wrapper {
  perspective: 1800px;
  display: flex;
  flex-direction: column;
  align-items: stretch;
  flex: 1;
  min-height: 0;
  padding: 0;
}
.page-spread {
  display: flex;
  flex-direction: column;
  flex: 1;
  min-height: 0;
  width: 100%;
  max-width: none;
  position: relative;
  transform-style: preserve-3d;
  background: linear-gradient(170deg, #fdfcf8 0%, #f5f2ec 100%);
  border-radius: 4px;
  box-shadow:
    0 2px 4px rgba(0,0,0,0.06),
    0 12px 40px rgba(20,50,30,0.12),
    inset 0 0 60px rgba(0,0,0,0.03);
  overflow: hidden;
  cursor: pointer;
  transition: transform 0.5s cubic-bezier(0.22, 1, 0.36, 1);
}
html[data-theme="dark"] .page-spread {
  background: linear-gradient(170deg, #1c211e 0%, #191e1b 100%);
}
.page-spread::before { display: none; }
.page-spread::after {
  content: "";
  position: absolute;
  bottom: 0;
  right: 0;
  width: 52px;
  height: 52px;
  background: linear-gradient(225deg, rgba(20,92,50,0.1) 0%, transparent 60%);
  pointer-events: none;
  z-index: 3;
  transition: width 0.25s ease, height 0.25s ease;
}
.page-spread:hover::after {
  width: 72px;
  height: 72px;
}
.page-spread .spread-page {
  flex: 1;
  min-height: 0;
  padding: 1.5rem 1.5rem;
  border: none;
  box-shadow: none;
  display: flex;
  flex-direction: column;
  background: linear-gradient(170deg, #fdfcf8, #f5f2ec);
  overflow-y: auto;
}
.page-spread .picture-page {
  display: grid;
  grid-template-rows: auto minmax(0, 1fr) auto;
  gap: 0.9rem;
  overflow: hidden;
}
.page-spread .novel-page {
  display: flex;
  overflow: hidden;
  padding: clamp(1.5rem, 4vw, 3.5rem) clamp(1.25rem, 7vw, 6rem);
  cursor: default;
}
.page-spread .novel-page .novel-chapter-title {
  margin: 0 0 1.2rem;
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(1.55rem, 3vw, 2.4rem);
  line-height: 1.15;
  color: var(--brand-deep);
}
.page-spread .novel-page .novel-chapter-text {
  min-height: 0;
  overflow: hidden;
  white-space: pre-wrap;
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(1rem, 1.25vw, 1.16rem);
  line-height: 1.75;
  padding: clamp(1rem, 2vw, 1.6rem);
}
html[data-theme="dark"] .page-spread .novel-page .novel-chapter-title {
  color: var(--brand-light);
}
html[data-theme="dark"] .page-spread .spread-page {
  background: linear-gradient(170deg, #1c211e, #191e1b);
}
.page-spread .spread-page .page-label {
  font-size: 0.72rem;
  opacity: 0.5;
  margin-bottom: 0.6rem;
}
.page-spread .spread-page .page-image {
  width: 100%;
  flex: 1 1 auto;
  min-height: clamp(18rem, 48vh, 42rem);
  object-fit: contain;
  background: #fff;
  border-radius: 8px;
  margin-bottom: 1rem;
  box-shadow: 0 4px 16px rgba(0,0,0,0.1);
}
.page-spread .spread-page .page-image.image-loading,
.page-spread .spread-page .page-image.image-load-failed,
.spread-cover img.image-loading,
.spread-cover img.image-load-failed,
.comic-panel-img.image-loading,
.comic-panel-img.image-load-failed {
  background:
    linear-gradient(135deg, rgba(20, 92, 50, 0.08), rgba(215, 146, 41, 0.08)),
    #f8faf7;
}
.page-spread .spread-page .page-image.image-load-failed,
.spread-cover img.image-load-failed,
.comic-panel-img.image-load-failed {
  border: 1px dashed rgba(20, 92, 50, 0.28);
}
.page-spread img[data-sm-preview-loading],
.spread-cover img[data-sm-preview-loading],
.comic-panel img[data-sm-preview-loading],
.coloring-stage img[data-sm-preview-loading] {
  content: url("data:image/gif;base64,R0lGODlhAQABAIAAAAAAAP///yH5BAEAAAAALAAAAAABAAEAAAIBRAA7");
  color: transparent;
  background-image: linear-gradient(100deg, rgba(255, 255, 255, 0) 30%, rgba(255, 255, 255, .55) 50%, rgba(255, 255, 255, 0) 70%), linear-gradient(145deg, #eef4ec, #dbe8da);
  background-size: 200% 100%, 100% 100%;
  background-repeat: no-repeat;
  animation: smPreviewImgShimmer 1.4s ease-in-out infinite;
}
body .spread-cover img[data-sm-preview-loading],
body[data-page="generate"] .spread-cover img[data-sm-preview-loading] { width: min(86%, 34rem, 58vh); aspect-ratio: 1 / 1; height: auto; }
@media (min-width: 900px) {
  body[data-page="generate"] .page-spread .picture-page .page-image[data-sm-preview-loading] {
    height: 100%; width: auto; max-width: 100%; aspect-ratio: 1 / 1;
    background-image: linear-gradient(100deg, rgba(255, 255, 255, 0) 30%, rgba(255, 255, 255, .55) 50%, rgba(255, 255, 255, 0) 70%), linear-gradient(145deg, #eef4ec, #dbe8da);
    background-size: 200% 100%, 100% 100%; background-repeat: no-repeat;
  }
}
@keyframes smPreviewImgShimmer {
  from { background-position: 150% 0, 0 0; }
  to { background-position: -50% 0, 0 0; }
}
@media (prefers-reduced-motion: reduce) {
  .page-spread img[data-sm-preview-loading],
  .spread-cover img[data-sm-preview-loading],
  .comic-panel img[data-sm-preview-loading],
  .coloring-stage img[data-sm-preview-loading] { animation: none; background-position: 50% 0, 0 0; }
}
.page-spread .spread-page .page-text {
  flex-shrink: 0;
  margin: 0;
  font-size: clamp(0.94rem, 1.05vw, 1.12rem);
  line-height: 1.55;
  color: var(--text);
  padding: 0.9rem 1rem;
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.74);
  border: 1px solid rgba(20, 92, 50, 0.1);
  box-shadow: 0 10px 24px rgba(20, 50, 30, 0.08);
  overflow-wrap: anywhere;
}
html[data-theme="dark"] .page-spread .spread-page .page-text {
  background: rgba(255, 255, 255, 0.05);
  border-color: rgba(255, 255, 255, 0.08);
}
@media (min-width: 900px) {
  .page-spread .picture-page {
    grid-template-columns: minmax(0, 1.28fr) minmax(15rem, 0.72fr);
    grid-template-rows: auto minmax(0, 1fr);
    align-items: stretch;
  }
  .page-spread .picture-page .page-label {
    grid-column: 1 / -1;
  }
  .page-spread .picture-page .page-image {
    grid-column: 1;
    grid-row: 2;
    height: 100%;
    min-height: 0;
    margin-bottom: 0;
  }
  .page-spread .picture-page .page-text {
    grid-column: 2;
    grid-row: 2;
    display: flex;
    align-items: center;
    min-height: 0;
    padding: clamp(1rem, 1.8vw, 1.45rem);
  }
}
@keyframes pageFlipForward {
  0%   { transform: rotateY(0deg);   opacity: 1; }
  40%  { transform: rotateY(-90deg); opacity: 0.6; }
  60%  { transform: rotateY(-90deg); opacity: 0.6; }
  100% { transform: rotateY(0deg);   opacity: 1; }
}
@keyframes pageFlipBackward {
  0%   { transform: rotateY(0deg);   opacity: 1; }
  40%  { transform: rotateY(90deg);  opacity: 0.6; }
  60%  { transform: rotateY(90deg);  opacity: 0.6; }
  100% { transform: rotateY(0deg);   opacity: 1; }
}
.page-spread.flipping-forward {
  animation: pageFlipForward 0.55s cubic-bezier(0.22, 1, 0.36, 1);
  transform-origin: left center;
}
.page-spread.flipping-backward {
  animation: pageFlipBackward 0.55s cubic-bezier(0.22, 1, 0.36, 1);
  transform-origin: right center;
}
.spread-nav {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 1.2rem;
  padding: 0.6rem 1rem;
  width: 100%;
  max-width: none;
  flex-shrink: 0;
  border-top: 1px solid var(--border);
  background: var(--bg-card);
}
.spread-btn {
  background: var(--surface-strong);
  border: 1px solid var(--border);
  border-radius: var(--radius-pill);
  padding: 0.5rem 1.2rem;
  font-size: 0.92rem;
  cursor: pointer;
  color: var(--text);
  font-weight: 600;
  transition: background 0.2s, color 0.2s, transform 0.15s;
}
.spread-btn:hover {
  background: var(--accent);
  color: #fff;
  transform: scale(1.04);
}
.spread-btn:active { transform: scale(0.97); }
.spread-btn:disabled {
  opacity: 0.4;
  cursor: default;
  transform: none;
}
.spread-download-btn {
  background: linear-gradient(135deg, #145c32, #22874a);
  color: #fff;
  border-color: #145c32;
}
.spread-download-btn:hover {
  background: linear-gradient(135deg, #0e3d1f, #145c32);
  color: #fff;
}
.spread-counter {
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--text-muted);
  min-width: 5rem;
  text-align: center;
}
.spread-page-dots {
  display: flex;
  gap: 0.35rem;
  align-items: center;
}
.spread-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--border);
  transition: background 0.2s, transform 0.2s;
}
.spread-dot.active {
  background: var(--accent);
  transform: scale(1.3);
}
.spread-cover {
  flex: 1;
  min-height: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 2rem;
  background: linear-gradient(135deg, #f0fdf4, #dcfce7);
  text-align: center;
}
html[data-theme="dark"] .spread-cover {
  background: linear-gradient(135deg, rgba(20,60,35,0.3), rgba(30,80,50,0.2));
}
.spread-cover img {
  max-width: min(86%, 34rem);
  max-height: min(58vh, 34rem);
  object-fit: contain;
  background: #fff;
  border-radius: 12px;
  box-shadow: 0 8px 24px rgba(0,0,0,0.15);
  margin-bottom: 1rem;
}
.spread-cover-title {
  font-family: var(--font-heading);
  font-size: 1.6rem;
  font-weight: 800;
  color: var(--text);
  letter-spacing: -0.02em;
}
.spread-cover-author {
  font-size: 1rem;
  font-weight: 500;
  color: var(--brand-deep);
  margin-top: 0.35rem;
  font-style: italic;
}
.spread-cover-meta {
  font-size: 0.88rem;
  color: var(--text-muted);
  margin-top: 0.3rem;
}
.cover-plus-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  background: linear-gradient(135deg, #145c32, #22874a);
  color: #fff;
  border-radius: var(--sm-r-tag);
  padding: 0.3rem 0.8rem;
  font-size: 0.75rem;
  font-weight: 700;
  margin-top: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}
@media (max-width: 640px) {
  .page-spread {
    min-height: 24rem;
  }
  .page-spread .spread-page { min-height: 22rem; }
  .page-spread .spread-page .page-image { min-height: 15rem; }
  .page-spread .spread-page .page-text { font-size: 0.92rem; line-height: 1.45; padding: 0.8rem; }
  .spread-cover img { max-width: 80%; }
}
.gallery-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 1.2rem;
}
.gallery-card {
  display: flex;
  flex-direction: column;
  overflow: hidden;
  border-radius: var(--radius-md);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}
.gallery-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 12px 32px rgba(20, 60, 30, 0.16);
}
.gallery-cover {
  width: 100%;
  aspect-ratio: 4/3;
  object-fit: cover;
  border-radius: var(--radius-md) var(--radius-md) 0 0;
}
.gallery-cover-placeholder {
  width: 100%;
  aspect-ratio: 4/3;
  background: linear-gradient(135deg, var(--bg-soft), var(--brand-soft));
}
.gallery-info {
  padding: 1rem 1rem 0.5rem;
}
.gallery-title {
  margin: 0 0 0.25rem;
  font-size: 1.05rem;
}
.gallery-author {
  margin: 0 0 0.4rem;
  font-size: 0.85rem;
  color: var(--text-muted);
  font-style: italic;
}
.gallery-badge {
  display: inline-block;
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--brand);
  background: var(--brand-soft);
  padding: 0.2rem 0.6rem;
  border-radius: var(--sm-r-tag);
}
.gallery-actions {
  display: flex;
  gap: 0.5rem;
  padding: 0.8rem 1rem 1rem;
  flex-wrap: wrap;
}
.publish-popup-overlay {
  position: fixed;
  inset: 0;
  z-index: 9000;
  background: rgba(0, 0, 0, 0.45);
  backdrop-filter: blur(6px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1rem;
}
.publish-popup-overlay[hidden] { display: none; }
.publish-popup {
  background: var(--surface-strong);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow);
  padding: 2rem 1.8rem;
  max-width: 440px;
  width: 100%;
  position: relative;
}
.publish-popup h3 {
  margin: 0 0 0.5rem;
  font-size: 1.2rem;
}
.publish-popup p {
  color: var(--text-muted);
  margin: 0 0 1.2rem;
  font-size: 0.92rem;
}
.publish-option {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
  padding: 1rem;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  cursor: pointer;
  background: var(--bg-card);
  margin-bottom: 0.8rem;
  transition: border-color 0.2s, background 0.2s;
}
.publish-option:hover {
  border-color: var(--brand);
  background: var(--brand-soft);
}
.publish-option strong { font-size: 1rem; }
.publish-option span { font-size: 0.85rem; color: var(--text-muted); }
.publish-library-option { cursor: default; }
.publish-library-option:hover { background: var(--bg-card); }
.publish-library-option label {
  margin-top: 0.25rem;
  color: var(--text);
  font-size: 0.78rem;
  font-weight: 700;
}
.publish-library-option select {
  width: 100%;
  min-height: 2.55rem;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--surface-strong);
  color: var(--text);
  padding: 0.55rem 0.7rem;
  font: inherit;
  font-size: 0.88rem;
}
.publish-library-option button { align-self: flex-start; margin-top: 0.2rem; }
.publish-amazing-option { cursor: default; border-color: color-mix(in srgb, var(--brand) 36%, var(--border)); background: linear-gradient(135deg, color-mix(in srgb, var(--brand-soft) 78%, #fff), var(--bg-card)); }
.publish-amazing-option:hover { background: linear-gradient(135deg, color-mix(in srgb, var(--brand-soft) 88%, #fff), var(--bg-card)); }
.publish-amazing-option label:not(.publish-amazing-consent),
.publish-amazing-option select {
  font-size: 0.82rem;
}
.publish-amazing-option select {
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--bg-input);
  color: var(--text);
  padding: 0.45rem 0.55rem;
  max-width: 16rem;
}
.publish-amazing-consent {
  align-items: flex-start;
  color: var(--text-muted);
  display: flex;
  font-size: 0.8rem;
  gap: 0.5rem;
  line-height: 1.3;
}
.publish-amazing-consent input { margin-top: 0.13rem; }
.publish-amazing-option button { align-self: flex-start; margin-top: 0.15rem; }
.publish-amazing-status { color: var(--brand-dark, var(--brand)); font-size: 0.82rem; font-weight: 650; line-height: 1.35; }
.publish-amazon-option { cursor: default; border-color: color-mix(in srgb, #b9771e 42%, var(--border)); background: linear-gradient(135deg, color-mix(in srgb, #f6e9d4 72%, #fff), var(--bg-card)); }
.publish-amazon-option:hover { background: linear-gradient(135deg, color-mix(in srgb, #f6e9d4 86%, #fff), var(--bg-card)); }
.publish-amazon-option label:not(.publish-amazing-consent),
.publish-amazon-option select,
.publish-amazon-option input[type="text"] {
  font-size: 0.82rem;
}
.publish-amazon-option select,
.publish-amazon-option input[type="text"] {
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--bg-input);
  color: var(--text);
  padding: 0.45rem 0.55rem;
  max-width: 22rem;
  font: inherit;
  font-size: 0.86rem;
}
.publish-amazon-option select { max-width: 16rem; }
.publish-amazon-plan-badge {
  align-self: flex-start;
  background: linear-gradient(120deg, var(--brand, #145c32), #22874a);
  border-radius: var(--sm-r-tag);
  color: #fff;
  font-size: 0.68rem;
  font-weight: 800;
  letter-spacing: 0.07em;
  padding: 0.22rem 0.6rem;
  text-transform: uppercase;
}
.publish-amazon-status { color: #8a5a12; font-size: 0.82rem; font-weight: 650; line-height: 1.35; }
.publish-amazon-status a { color: inherit; font-weight: 800; }
.publish-popup { max-height: 86vh; overflow-y: auto; width: min(34rem, calc(100vw - 2rem)); }
.publish-popup-sub { color: var(--text-muted); font-size: 0.9rem; margin: 0.2rem 0 1.1rem; }
.publish-option-row {
  align-items: center;
  cursor: pointer;
  display: flex;
  flex-direction: row;
  gap: 0.9rem;
  padding: 1.05rem 1.1rem;
}
.publish-option-row .publish-option-icon {
  align-items: center;
  background: color-mix(in srgb, var(--brand-soft, #e6f0e5) 80%, #fff);
  border: 1px solid rgba(20, 92, 50, 0.14);
  border-radius: 12px;
  display: flex;
  flex: 0 0 2.9rem;
  font-size: 1.25rem;
  height: 2.9rem;
  justify-content: center;
  width: 2.9rem;
}
.publish-option-row .publish-option-copy { display: flex; flex: 1; flex-direction: column; gap: 0.18rem; min-width: 0; }
.publish-option-row .publish-option-chev { color: var(--text-muted); font-size: 1.1rem; transition: transform 0.18s ease, color 0.18s ease; }
.publish-option-row:hover .publish-option-chev { color: var(--brand, #145c32); transform: translateX(3px); }
.publish-amazon-row .publish-option-icon { background: color-mix(in srgb, #f6e9d4 80%, #fff); border-color: rgba(185, 119, 30, 0.25); }
.publish-new-pill {
  background: var(--brand, #145c32);
  border-radius: var(--sm-r-tag);
  color: #fff;
  font-size: 0.62rem;
  font-style: normal;
  font-weight: 800;
  letter-spacing: 0.07em;
  margin-left: 0.4rem;
  padding: 0.14rem 0.5rem;
  text-transform: uppercase;
  vertical-align: 0.12em;
}
.publish-back {
  background: none;
  border: none;
  color: var(--brand, #145c32);
  cursor: pointer;
  font: inherit;
  font-size: 0.86rem;
  font-weight: 700;
  margin-bottom: 0.4rem;
  padding: 0.2rem 0;
}
.publish-back:hover { text-decoration: underline; }
#publish-amazon-view h3 { align-items: center; display: flex; flex-wrap: wrap; gap: 0.6rem; margin-top: 0.1rem; }
#publish-amazon-view label:not(.publish-amazing-consent) { display: block; font-size: 0.8rem; font-weight: 700; margin: 0.85rem 0 0.3rem; }
#publish-amazon-view input[type="text"],
#publish-amazon-view select {
  background: var(--bg-input);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  color: var(--text);
  font: inherit;
  font-size: 0.9rem;
  padding: 0.55rem 0.65rem;
  width: 100%;
}
#publish-amazon-view .publish-amazing-consent { margin: 1rem 0; }
#publish-amazon-view .btn-primary { margin-top: 0.2rem; }
#publish-amazon-view .publish-amazon-status { display: block; margin-top: 0.7rem; }
#publish-amazon-view #publish-amazon-revenue { margin-top: 0.7rem; }
.publish-popup-close {
  position: absolute;
  top: 0.8rem;
  right: 0.8rem;
  background: none;
  border: none;
  font-size: 1.4rem;
  cursor: pointer;
  color: var(--text-muted);
  line-height: 1;
}
.sm-action-modal-overlay {
  position: fixed;
  inset: 0;
  z-index: 9050;
  background: rgba(5, 15, 9, 0.5);
  backdrop-filter: blur(8px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1rem;
}
.sm-action-modal-overlay[hidden] {
  display: none;
}
.sm-action-modal {
  width: min(100%, 30rem);
  background: var(--surface-strong);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow);
  padding: 1.5rem;
  position: relative;
}
.sm-action-close {
  position: absolute;
  top: 0.75rem;
  right: 0.75rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 30px;
  height: 30px;
  padding: 0;
  border: none;
  border-radius: 8px;
  background: transparent;
  color: var(--text-muted);
  font-size: 1.25rem;
  line-height: 1;
  cursor: pointer;
}
.sm-action-close::before { content: ""; position: absolute; inset: -5px; }
.sm-action-close:hover { background: var(--sm-hover, rgba(17, 21, 18, 0.06)); color: var(--text); }
@media (pointer: coarse) {
  .sm-action-close { width: 44px; height: 44px; top: 0.5rem; right: 0.5rem; }
  .sm-action-close::before { inset: 0; }
}
.sm-action-badge {
  display: inline-flex;
  align-items: center;
  padding: 0.32rem 0.7rem;
  border-radius: var(--sm-r-tag);
  background: rgba(20, 92, 50, 0.1);
  color: var(--brand-deep);
  font-size: 0.74rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}
.sm-action-modal h3 {
  margin: 1rem 0 0.45rem;
  font-family: var(--font-heading);
  font-size: 1.35rem;
}
.sm-action-modal p {
  margin: 0;
  color: var(--text-muted);
  line-height: 1.6;
}
.sm-action-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 0.75rem;
  flex-wrap: wrap;
  margin-top: 1.2rem;
}
.sm-action-primary,
.sm-action-secondary {
  min-width: 8.5rem;
  text-align: center;
}
.sm-danger-count { color: var(--sm-danger, #b42318) !important; font-weight: 600; }
.sm-danger-count[hidden] { display: none; }
.sm-danger-confirm { display: flex; flex-direction: column; gap: 6px; min-width: min(100%, 280px); }
.sm-danger-confirm label { color: var(--sm-muted, var(--text-muted)); font-size: 13px; }
.sm-danger-confirm label strong { color: var(--sm-ink, var(--text)); letter-spacing: 0.04em; }
.sm-danger-confirm-row { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.sm-danger-confirm-row .sm-input { flex: 1 1 140px; min-width: 0; width: auto; }
.sm-danger-confirm-row .sm-btn[disabled] { opacity: 0.5; cursor: not-allowed; }
.btn-danger {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 2.5rem;
  padding: 0.6rem 1.05rem;
  border: 1.5px solid var(--sm-danger, #b42318);
  border-radius: 10px;
  background: var(--sm-surface, #fff);
  color: var(--sm-danger, #b42318);
  font: inherit;
  font-weight: 650;
  text-decoration: none;
  white-space: nowrap;
  cursor: pointer;
  transition: background 0.18s ease, color 0.18s ease;
}
.btn-danger:hover {
  background: var(--sm-danger-soft, #fdecea);
  color: var(--sm-danger, #b42318);
}
.btn-danger:focus-visible {
  outline: 3px solid var(--sm-danger, #b42318);
  outline-offset: 2px;
}
.coming-soon-overlay {
  position: fixed;
  inset: 0;
  z-index: 9100;
  background: rgba(5, 15, 9, 0.55);
  backdrop-filter: blur(10px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1rem;
}
.coming-soon-overlay[hidden] { display: none; }
.coming-soon-modal {
  width: min(100%, 28rem);
  background: var(--surface-strong);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow);
  padding: 2rem 1.75rem;
  position: relative;
  text-align: center;
}
.coming-soon-close {
  position: absolute;
  top: 0.75rem;
  right: 0.9rem;
  border: none;
  background: transparent;
  color: var(--text-muted);
  font-size: 1.5rem;
  cursor: pointer;
  line-height: 1;
}
.coming-soon-badge {
  display: inline-flex;
  align-items: center;
  padding: 0.35rem 0.85rem;
  border-radius: var(--sm-r-tag);
  background: linear-gradient(135deg, rgba(20,92,50,0.12), rgba(20,92,50,0.05));
  color: var(--brand);
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}
.coming-soon-modal h3 {
  margin: 1rem 0 0.5rem;
  font-family: var(--font-heading);
  font-size: 1.25rem;
  font-weight: 700;
}
.coming-soon-modal p {
  margin: 0 0 1rem;
  color: var(--text-muted);
  line-height: 1.6;
  font-size: 0.92rem;
}
.coming-soon-form {
  display: flex;
  gap: 0.5rem;
  margin: 1rem 0 0.5rem;
}
.coming-soon-form input[type="email"] {
  flex: 1;
  padding: 0.65rem 0.9rem;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--bg-input);
  color: var(--text);
  font-size: 0.92rem;
  min-width: 0;
}
.coming-soon-form input[type="email"]:focus {
  outline: none;
  border-color: var(--brand);
  box-shadow: 0 0 0 3px rgba(20,92,50,0.12);
}
.coming-soon-form .btn-primary {
  white-space: nowrap;
  padding: 0.65rem 1.2rem;
}
.coming-soon-status {
  font-size: 0.88rem;
  margin: 0.75rem 0 0;
  padding: 0.5rem 0.75rem;
  border-radius: var(--radius-sm);
}
.coming-soon-status.success {
  background: rgba(20,92,50,0.08);
  color: var(--brand);
}
.coming-soon-status.error {
  background: rgba(168,32,32,0.08);
  color: var(--danger);
}
.coming-soon-fine {
  font-size: 0.78rem;
  color: var(--text-muted);
  opacity: 0.7;
  margin: 0.5rem 0 0;
}
.star-rating {
  display: inline-flex;
  gap: 0.15rem;
  font-size: 1.3rem;
  cursor: pointer;
}
.star-rating .star {
  color: var(--border-strong);
  transition: color 0.15s;
  user-select: none;
}
.star-rating .star.filled { color: #f5b831; }
.star-rating .star:hover,
.star-rating .star:hover ~ .star { color: #f5b831; }
.star-rating-display {
  display: inline-flex;
  gap: 0.1rem;
  font-size: 1.1rem;
}
.star-rating-display .star { color: var(--border-strong); }
.star-rating-display .star.filled { color: #f5b831; }
.chip-btn-modern {
  display: inline-flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 0.2rem;
  border: 1px solid var(--border);
  background: var(--bg-card);
  color: var(--text);
  border-radius: var(--radius-md);
  padding: 0.7rem 0.9rem;
  min-width: min(100%, 14rem);
  text-align: left;
  font-size: 0.88rem;
  font-weight: 500;
  font-family: var(--font-body);
  cursor: pointer;
  box-shadow: var(--shadow-soft);
  transition: border-color 0.15s, transform 0.12s, box-shadow 0.15s;
}
.chip-btn-modern:hover {
  border-color: var(--brand);
  transform: translateY(-1px);
  box-shadow: var(--shadow);
}
html[data-theme="dark"] .chip-btn-modern {
  background: var(--surface);
  border-color: var(--border);
  color: var(--text);
}
html[data-theme="dark"] .chip-btn-modern:hover {
  background: var(--surface-strong);
  border-color: var(--accent);
  box-shadow: var(--shadow);
}
.chip-kicker {
  font-size: 0.73rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--accent);
}
.chip-title {
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--text);
}
.page-label {
  font-size: 0.82rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--text-muted);
  margin-bottom: 0.8rem;
}
.page-image {
  width: 100%;
  aspect-ratio: 1 / 1;
  object-fit: cover;
  border-radius: 1rem;
  border: 1px solid var(--border);
  margin-bottom: 0.8rem;
}
.page-text {
  margin: 0;
  color: var(--text);
  line-height: 1.6;
}
.progress-card,
.status-card,
.error-card {
  max-width: 42rem;
  margin: 1rem auto 0;
  text-align: center;
  width: 100%;
}
.progress-section-v2 {
  max-width: 44rem;
  margin: 2rem auto 0;
  padding: 2.5rem 2rem 2rem;
  text-align: center;
}
.progress-hero {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.6rem;
  margin-bottom: 2.4rem;
}
.progress-icon-ring {
  position: relative;
  width: 80px;
  height: 80px;
  display: flex;
  align-items: center;
  justify-content: center;
}
.progress-spinner {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  animation: spinRing 2.2s linear infinite;
}
.progress-spinner circle {
  stroke: var(--brand);
  stroke-dasharray: 90 35;
  stroke-linecap: round;
}
@keyframes spinRing { to { transform: rotate(360deg); } }
.progress-pct-text {
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--brand);
  z-index: 1;
}
.progress-section-v2 h1 {
  font-size: 1.5rem;
  margin: 0;
}
.progress-sub {
  color: var(--text-muted);
  font-size: 0.92rem;
  margin: 0;
  min-height: 1.4em;
}
.progress-eta {
  color: var(--text-muted);
  font-size: 0.82rem;
  margin: 1.2rem 0 0;
}
.timeline-track {
  position: relative;
  max-width: 36rem;
  margin: 0 auto;
}
.timeline-rail {
  position: absolute;
  top: 16px;
  left: 2rem;
  right: 2rem;
  height: 3px;
  background: var(--border);
  border-radius: 2px;
  z-index: 0;
  overflow: hidden;
}
.timeline-fill {
  height: 100%;
  width: 0%;
  background: var(--brand);
  border-radius: 2px;
  transition: width 0.5s ease;
}
.timeline-steps {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  justify-content: space-between;
  position: relative;
  z-index: 1;
}
.tl-step {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.45rem;
  flex: 1;
}
.tl-dot {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: var(--surface-strong);
  border: 2.5px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: border-color 0.3s, background 0.3s, box-shadow 0.3s;
}
.tl-icon {
  font-size: 0.78rem;
  font-weight: 700;
  color: var(--text-muted);
  line-height: 1;
  transition: color 0.3s;
}
.tl-label {
  font-size: 0.72rem;
  font-weight: 600;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.04em;
  transition: color 0.3s;
}
.tl-step.active .tl-dot {
  border-color: var(--brand);
  background: var(--brand-soft);
  box-shadow: 0 0 0 6px rgba(20, 92, 50, 0.1);
  animation: tlPulse 2s ease-in-out infinite;
}
.tl-step.active .tl-icon { color: var(--brand); }
.tl-step.active .tl-label { color: var(--brand); }
@keyframes tlPulse {
  0%, 100% { box-shadow: 0 0 0 4px rgba(20, 92, 50, 0.08); }
  50%      { box-shadow: 0 0 0 10px rgba(20, 92, 50, 0.18); }
}
.tl-step.done .tl-dot {
  border-color: var(--brand);
  background: var(--brand);
}
.tl-step.done .tl-icon { color: #fff; }
.tl-step.done .tl-label { color: var(--brand-deep); }
.tl-step.error .tl-dot {
  border-color: var(--danger);
  background: var(--danger);
}
.tl-step.error .tl-icon { color: #fff; }
.tl-step.error .tl-label { color: var(--danger); }
@media (max-width: 480px) {
  .timeline-steps { gap: 0.2rem; }
  .tl-label { font-size: 0.62rem; }
  .tl-dot { width: 28px; height: 28px; }
  .tl-icon { font-size: 0.68rem; }
  .timeline-rail { top: 13px; }
  .progress-section-v2 { padding: 1.5rem 1rem; }
}
.pricing-main .price-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 12px 28px rgba(14, 61, 31, 0.1);
}
.pricing-main .price-card.featured:hover {
  transform: translateY(-2px);
  box-shadow: 0 18px 42px rgba(14, 61, 31, 0.17);
}
.progress-bar-wrap {
  margin: 1.4rem 0 1.2rem;
  height: 0.8rem;
  border-radius: var(--radius-pill);
  background: rgba(20, 92, 50, 0.12);
  overflow: hidden;
}
.progress-bar {
  height: 100%;
  background: linear-gradient(90deg, #145c32, #22874a);
  border-radius: var(--radius-pill);
  transition: width 0.3s ease;
}
.step-list {
  list-style: none;
  padding: 0;
  margin: 1rem 0 0;
  display: grid;
  gap: 0.75rem;
}
.step {
  display: flex;
  align-items: center;
  gap: 0.8rem;
  justify-content: center;
  padding: 0.9rem 1rem;
  border-radius: var(--radius-md);
  background: rgba(255, 255, 255, 0.62);
  color: var(--text-muted);
}
html[data-theme="dark"] .step {
  background: rgba(255, 255, 255, 0.03);
}
.step.active {
  color: var(--text);
  border: 1px solid rgba(20, 92, 50, 0.2);
}
.step.done {
  color: var(--brand-deep);
}
.step.error {
  color: var(--danger);
}
.site-footer {
  margin-top: auto;
  position: relative;
  overflow: hidden;
  padding: 2.7rem 0 2rem;
  color: var(--text-muted);
  border-top: 1px solid rgba(20, 92, 50, 0.13);
  background:
    radial-gradient(circle at 8% 26%, rgba(255, 216, 107, 0.3) 0 5px, transparent 6px),
    radial-gradient(circle at 92% 18%, rgba(132, 215, 245, 0.28) 0 7px, transparent 8px),
    radial-gradient(circle at 86% 78%, rgba(255, 143, 125, 0.2) 0 5px, transparent 6px),
    linear-gradient(180deg, #f5fbf3 0%, #eaf6e9 100%);
}
.site-footer .shell {
  max-width: 1200px;
  margin: 0 auto;
}
.footer-inner {
  display: grid;
  grid-template-columns: minmax(220px, 0.9fr) minmax(360px, 1.35fr);
  align-items: start;
  gap: 1.45rem 3rem;
}
.footer-brand {
  display: flex;
  align-items: center;
  gap: 0.8rem;
}
.footer-brand-mark {
  width: 3rem;
  height: 3rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 auto;
  border-radius: 17px 13px 18px 12px;
  color: var(--brand);
  background: linear-gradient(145deg, #fff5bd, #cef0d8);
  border: 1px solid rgba(20, 92, 50, 0.12);
  box-shadow: 0 10px 24px rgba(20, 92, 50, 0.1);
  transform: rotate(-4deg);
}
.footer-brand-mark svg {
  width: 25px;
  height: 25px;
  fill: rgba(20, 92, 50, 0.18);
  stroke: currentColor;
  stroke-width: 1.7;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.footer-brand strong,
.footer-brand small {
  display: block;
}
.footer-brand strong {
  font-family: var(--font-heading);
  color: var(--text);
  font-size: 1.08rem;
}
.footer-brand small {
  margin-top: 0.18rem;
  font-size: 0.79rem;
  color: var(--text-muted);
}
.footer-copy {
  grid-column: 1 / -1;
  margin: 0;
  padding-top: 1rem;
  border-top: 1px dashed rgba(20, 92, 50, 0.16);
  font-size: 0.78rem;
}
.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 0.65rem 1.45rem;
  width: 100%;
}
.footer-links a {
  text-decoration: none;
  font-size: 0.95rem;
  color: var(--text-soft);
  font-weight: 650;
  transition: color 0.15s ease, transform 0.15s ease;
}
.footer-links a:hover {
  color: var(--brand);
  transform: translateY(-1px);
}
.footer-legal {
  display: flex;
  flex-wrap: wrap;
  grid-column: 2;
  gap: 0.55rem 1.15rem;
  width: 100%;
  padding-top: 0.9rem;
  border-top: 1px solid rgba(20, 92, 50, 0.12);
}
.footer-legal a {
  text-decoration: none;
  font-size: 0.84rem;
  color: var(--text-muted);
  font-weight: 500;
  transition: color 0.15s ease;
}
.footer-legal a:hover {
  color: var(--brand);
}
.footer-language {
  margin-left: auto;
  color: var(--brand) !important;
  font-weight: 700 !important;
}
html[data-theme="dark"] .site-footer {
  background: linear-gradient(180deg, #101b13 0%, #0b140e 100%);
}
html[data-theme="dark"] .support-email-action {
  color: var(--sm-on-accent);
  background: var(--sm-accent);
}
@media (max-width: 760px) {
  .footer-inner {
    grid-template-columns: 1fr;
    gap: 1.35rem;
  }
  .footer-legal,
  .footer-copy {
    grid-column: 1;
  }
  .footer-language {
    width: 100%;
    margin-left: 0;
    padding-top: 0.35rem;
  }
}
@media (max-width: 1080px) {
  .workspace-shell {
    grid-template-columns: 1fr;
    min-height: auto;
    --workspace-panel-height: min(44rem, calc(100vh - 6rem));
  }
  .workspace-chat,
  .workspace-preview {
    min-height: 0;
  }
  .feature-strip,
  .settings-grid,
  .account-grid-page {
    grid-template-columns: 1fr;
  }
  .settings-card-wide {
    grid-column: span 1;
  }
  .settings-rows {
    grid-template-columns: 1fr;
  }
}
@media (max-width: 920px) {
  .header-inner {
    flex-wrap: wrap;
    justify-content: space-between;
    gap: 0.75rem;
  }
  .pricing-grid,
  .preview-pages,
  .options-grid {
    grid-template-columns: 1fr;
  }
  .composer-toolbar,
  .preview-head,
  .workspace-panel-head,
  .discount-card,
  .composer-topline {
    flex-direction: column;
    align-items: stretch;
    gap: 0.75rem;
  }
  .toolbar-models,
  .preview-actions,
  .discount-form {
    width: 100%;
  }
  .inline-select,
  .btn-launch,
  .discount-form input {
    width: 100%;
  }
  .btn-inline {
    width: auto;
  }
  .inline-select select {
    min-width: 0;
    width: 100%;
  }
  .preview-actions {
    flex-direction: row;
    flex-wrap: wrap;
    gap: 0.5rem;
  }
  .preview-actions .btn-inline {
    flex: 1 1 auto;
    min-width: 0;
    text-align: center;
    padding: 0.6rem 0.8rem;
    font-size: 0.88rem;
  }
}
@media (max-width: 640px) {
  .shell {
    width: calc(100% - 32px);
  }
  .workspace-main {
    padding: 0.5rem;
    width: min(100% - 0.5rem, 100%);
  }
  .hero h1,
  .page-hero h1 {
    font-size: 2rem;
  }
  .hero-home {
    padding-top: 1.5rem;
  }
  html.js .nav-toggle {
    display: block;
  }
  .header-inner {
    flex-wrap: wrap;
  }
  html.js .nav-links {
    display: none;
    flex-basis: 100%;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    order: 1;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 14px;
    padding: 0.5rem;
    margin-top: 0.5rem;
    box-shadow: 0 8px 24px rgba(0,0,0,.08);
  }
  html[data-theme="dark"] .nav-links {
    background: var(--surface-strong);
  }
  html.js .nav-links.open {
    display: flex;
  }
  .nav-link {
    font-size: 0.92rem;
    padding: 0.7rem 0.8rem;
    border-radius: 10px;
    width: 100%;
    text-align: left;
  }
  .nav-link:hover,
  .nav-link.active {
    background: rgba(20, 92, 50, 0.06);
  }
  .nav-external {
    display: none;
  }
  .billing-toggle,
  .chat-actions {
    flex-wrap: wrap;
    justify-content: center;
    gap: 0.5rem;
  }
  .chat-actions {
    align-items: stretch;
  }
  .home-main .btn-primary,
  .home-main .btn-secondary,
  .account-main .btn-primary,
  .account-main .btn-secondary,
  .pricing-main .btn-primary,
  .pricing-main .btn-secondary,
  .auth-modal .btn-primary,
  .auth-modal .btn-secondary,
  .btn-launch {
    width: 100%;
    text-align: center;
  }
  html.js .header-right {
    order: 0;
    width: auto;
    justify-content: flex-end;
  }
  html.js .user-area {
    justify-content: center;
  }
  .page-breadcrumb {
    font-size: 0.76rem;
    padding-top: 0.48rem;
  }
  .page-breadcrumb-item:not(:last-child):not(:nth-last-child(2)) {
    display: none;
  }
  .page-breadcrumb-item + .page-breadcrumb-item::before {
    margin: 0 0.42rem;
  }
  .account-menu {
    right: auto;
    left: 50%;
    transform: translateX(-50%);
  }
  .logo-copy {
    display: none;
  }
  .workspace-chat,
  .workspace-preview {
    height: auto;
    min-height: auto;
    max-height: none;
  }
  .workspace-chat .chat-messages,
  .chat-messages {
    flex: 0 1 auto;
    max-height: min(56vh, 28rem);
  }
  .chat-form textarea {
    min-height: 4rem;
    font-size: 0.9rem;
  }
  .page-card {
    padding: 0.7rem;
  }
  .feature-card,
  .settings-card,
  .price-card {
    padding: 1.2rem;
  }
  .composer-card {
    padding: 1rem;
  }
  .prompt-stage {
    padding: 0.8rem;
  }
  .suggestion-chips {
    flex-wrap: wrap;
    justify-content: center;
  }
  .chip-btn {
    font-size: 0.82rem;
    padding: 0.55rem 0.75rem;
  }
  .chip-btn-modern {
    width: 100%;
    min-width: 0;
  }
  .editor-model-pill {
    font-size: 0.78rem;
    padding: 0.35rem 0.7rem;
  }
  .progress-card h1,
  .error-card h1 {
    font-size: 1.6rem;
  }
  .step {
    font-size: 0.88rem;
    padding: 0.7rem 0.8rem;
  }
}
@media (max-width: 480px) {
  .shell {
    width: calc(100% - 32px);
  }
  .site-header {
    padding: 0.6rem 0;
  }
  .header-inner {
    gap: 0.35rem;
  }
  .account-button-label {
    display: none;
  }
  .account-menu-button {
    gap: 0.25rem;
    padding-right: 0.45rem;
  }
  .hero h1,
  .page-hero h1 {
    font-size: clamp(1.5rem, 8vw, 2rem);
    letter-spacing: -0.04em;
  }
  .hero-sub,
  .progress-copy {
    font-size: 0.92rem;
  }
  .composer-topline h2,
  .workspace-panel-head h2 {
    font-size: 1.2rem;
  }
  .price-amount {
    font-size: 2rem;
  }
  .account-plan-label {
    font-size: 1.4rem;
  }
  .usage-badge,
  .tier-badge {
    display: none;
  }
  .logo-mark {
    width: 2rem;
    height: 2rem;
  }
  .user-email {
    max-width: 9rem;
  }
  .spread-btn {
    padding: 0.4rem 0.7rem;
    font-size: 0.82rem;
  }
  .spread-counter {
    font-size: 0.78rem;
    min-width: 3.5rem;
  }
  .publish-popup {
    padding: 1.4rem 1.2rem;
  }
  .sm-action-actions {
    flex-direction: column-reverse;
    align-items: stretch;
  }
}
.auth-modal-overlay {
  position: fixed;
  inset: 0;
  z-index: 9000;
  background: rgba(0, 0, 0, 0.45);
  backdrop-filter: blur(6px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1rem;
}
.auth-modal-overlay[hidden] {
  display: none;
}
.auth-modal {
  background: var(--surface-strong);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow);
  padding: 2.5rem 2rem;
  max-width: 420px;
  width: 100%;
  text-align: center;
  position: relative;
  animation: fadeIn 0.2s ease-out;
}
.auth-modal-close {
  position: absolute;
  top: 0.75rem;
  right: 0.75rem;
  background: none;
  border: none;
  font-size: 1.5rem;
  cursor: pointer;
  color: var(--text-muted);
  line-height: 1;
  padding: 0.25rem;
}
.auth-modal-icon {
  font-size: 2.5rem;
  display: block;
  margin-bottom: 0.5rem;
}
.auth-modal h2 {
  font-family: var(--font-heading);
  font-size: 1.4rem;
  margin: 0 0 0.5rem;
}
.auth-modal p {
  color: var(--text-soft);
  font-size: 0.92rem;
  margin: 0 0 1.2rem;
  line-height: 1.5;
}
.auth-modal-btn {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0.75rem 1rem;
  border-radius: var(--radius-pill);
  font-size: 0.95rem;
  font-weight: 600;
  cursor: pointer;
  transition: opacity 0.15s;
}
.auth-modal-btn:hover {
  opacity: 0.88;
}
.auth-modal-divider {
  display: flex;
  align-items: center;
  gap: 0.8rem;
  margin: 1rem 0;
  color: var(--text-muted);
  font-size: 0.82rem;
}
.auth-modal-divider::before,
.auth-modal-divider::after {
  content: "";
  flex: 1;
  height: 1px;
  background: var(--border);
}
.auth-modal-note {
  font-size: 0.78rem !important;
  color: var(--text-muted) !important;
  margin-top: 0.5rem !important;
}
.auth-form {
  display: flex;
  flex-direction: column;
  gap: 0.85rem;
  text-align: left;
}
.auth-form .field {
  gap: 0.35rem;
}
.auth-form .field label {
  font-size: 0.82rem;
}
.auth-form input[type="text"],
.auth-form input[type="email"],
.auth-form input[type="password"] {
  width: 100%;
  border: 1px solid var(--border);
  border-radius: 12px;
  background: var(--bg-input);
  color: var(--text);
  padding: 0.82rem 0.95rem;
  font: inherit;
}
.auth-form input[type="text"]:focus,
.auth-form input[type="email"]:focus,
.auth-form input[type="password"]:focus {
  outline: none;
  border-color: rgba(20, 92, 50, 0.36);
  box-shadow: 0 0 0 4px rgba(20, 92, 50, 0.08);
}
.auth-form .btn-primary,
.auth-form .btn-secondary,
.auth-form .auth-google-btn {
  width: 100%;
}
.auth-form-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
}
.auth-helper-text {
  font-size: 0.82rem;
  color: var(--text-muted);
  line-height: 1.45;
}
.auth-helper {
  margin: -0.2rem 0 0.15rem;
  font-size: 0.8rem;
  color: var(--text-muted);
  line-height: 1.45;
}
.devs-main {
  padding-top: 2rem;
  overflow-x: hidden;
}
.api-docs-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(24rem, 100%), 1fr));
  gap: 1.25rem;
  margin-top: 1.5rem;
}
.api-endpoint {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 1.25rem;
  overflow: hidden;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.03);
  transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
}
.api-endpoint:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.08);
  border-color: rgba(20, 92, 50, 0.3);
}
.api-endpoint p {
  color: var(--text-secondary);
  font-size: 0.92rem;
  margin: 0.75rem 0 0;
  line-height: 1.5;
}
.api-method {
  display: inline-block;
  font-family: 'Space Mono', monospace;
  font-size: 0.75rem;
  font-weight: 700;
  padding: 0.25rem 0.6rem;
  border-radius: 6px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  flex-shrink: 0;
  vertical-align: middle;
}
.api-method.get {
  background: #ecfdf5;
  color: #059669;
  border: 1px solid #a7f3d0;
}
.api-method.post {
  background: #eff6ff;
  color: #2563eb;
  border: 1px solid #bfdbfe;
}
html[data-theme="dark"] .api-method.get {
  background: rgba(16, 185, 129, 0.15);
  color: #34d399;
  border-color: rgba(16, 185, 129, 0.3);
}
html[data-theme="dark"] .api-method.post {
  background: rgba(59, 130, 246, 0.15);
  color: #60a5fa;
  border-color: rgba(59, 130, 246, 0.3);
}
.api-path {
  display: inline-block;
  font-family: 'Space Mono', monospace;
  font-size: 0.9rem;
  margin-left: 0.5rem;
  color: var(--text);
  word-break: break-all;
  vertical-align: middle;
  font-weight: 600;
}
.api-code {
  background: #111827;
  color: #e5e7eb;
  border: 1px solid #374151;
  border-radius: 8px;
  padding: 1rem;
  font-family: 'Space Mono', monospace;
  font-size: 0.82rem;
  overflow-x: auto;
  margin-top: 0.75rem;
  max-width: 100%;
  white-space: pre-wrap;
  word-break: break-word;
  box-shadow: inset 0 2px 4px rgba(0,0,0,0.2);
}
.api-endpoint details {
  margin-top: 1rem;
  padding-top: 0.75rem;
  border-top: 1px dashed var(--border);
}
.api-endpoint summary {
  color: var(--text);
  font-size: 0.88rem;
  cursor: pointer;
  font-weight: 600;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  user-select: none;
}
.api-endpoint summary::before {
  content: "?";
  font-size: 0.8rem;
  color: var(--text-muted);
  transition: transform 0.2s ease;
}
.api-endpoint details[open] summary::before {
  transform: rotate(90deg);
}
.api-endpoint summary::-webkit-details-marker {
  display: none;
}
.api-auth-info {
  margin-top: 1.5rem;
  padding: 1.2rem;
}
.api-auth-info h3 {
  margin: 0 0 0.5rem;
  font-size: 1rem;
}
.api-auth-info ul {
  margin: 0.5rem 0;
  padding-left: 1.5rem;
}
.api-auth-info li {
  color: var(--text-soft);
  font-size: 0.88rem;
  margin-bottom: 0.3rem;
}
.api-auth-info code {
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  color: var(--brand-deep);
  font-family: 'Space Mono', monospace;
  padding: 0.15rem 0.4rem;
  border-radius: 4px;
  font-size: 0.82rem;
}
.api-keys-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  flex-wrap: wrap;
  gap: 1rem;
}
.api-create-row {
  display: flex;
  gap: 0.75rem;
  margin-bottom: 1rem;
  flex-wrap: wrap;
}
.api-label-input {
  flex: 1;
  min-width: 14rem;
  padding: 0.6rem 0.8rem;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--bg-input);
  color: var(--text);
  font-size: 0.9rem;
}
.api-keys-error {
  margin: 0 0 1rem;
  padding: 0.65rem 0.85rem;
  border: 1px solid rgba(180, 35, 24, 0.28);
  border-radius: var(--sm-r-tag, 6px);
  background: rgba(180, 35, 24, 0.06);
  color: var(--sm-danger, #b42318);
  font-size: 0.88rem;
  line-height: 1.5;
}
.api-keys-error[hidden] { display: none; }
.dev-plan-actions .btn-upgrade { width: 100%; }
.dev-plan-current {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  flex-wrap: wrap;
}
.dev-plan-current[hidden] { display: none; }
.dev-plan-badge {
  display: inline-flex;
  align-items: center;
  padding: 0.3rem 0.65rem;
  border-radius: var(--sm-r-tag, 6px);
  background: rgba(20, 92, 50, 0.1);
  color: var(--sm-accent-ink, #0f4425);
  font-size: 0.8rem;
  font-weight: 700;
}
.api-new-key-banner {
  background: linear-gradient(to right, rgba(20, 92, 50, 0.08), rgba(20, 92, 50, 0.03));
  border: 1px solid rgba(20, 92, 50, 0.25);
  border-left: 4px solid var(--brand);
  border-radius: 8px;
  padding: 1.25rem;
  margin-bottom: 1.5rem;
  box-shadow: 0 4px 6px rgba(0,0,0,0.02);
}
.api-new-key-banner p {
  margin: 0 0 0.75rem;
  font-size: 0.92rem;
  color: var(--text);
  font-weight: 500;
}
.api-key-display {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  background: #111827;
  color: #10b981;
  border: 1px solid #374151;
  border-radius: 8px;
  padding: 0.75rem 1rem;
  overflow-x: auto;
  box-shadow: inset 0 2px 4px rgba(0,0,0,0.2);
}
.api-key-display code {
  font-family: 'Space Mono', monospace;
  font-size: 0.9rem;
  font-weight: 600;
  word-break: break-all;
  flex: 1;
}
.api-keys-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.88rem;
  display: block;
  overflow-x: auto;
  white-space: nowrap;
  -webkit-overflow-scrolling: touch;
}
.api-keys-table th, .api-keys-table td {
  text-align: left;
  padding: 0.85rem 1rem;
  border-bottom: 1px solid var(--border);
}
.api-keys-table th {
  color: var(--text-soft);
  font-weight: 600;
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}
.api-keys-table code {
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  padding: 0.2rem 0.5rem;
  border-radius: 6px;
  font-size: 0.82rem;
  font-family: 'Space Mono', monospace;
  color: var(--text-secondary);
}
.api-empty {
  color: var(--text-muted);
  text-align: center;
  padding: 2rem 0 !important;
}
.api-status-active {
  color: var(--brand-deep);
  font-weight: 600;
}
.api-status-revoked {
  color: var(--text-muted);
}
@media (max-width: 640px) {
  .api-docs-grid {
    grid-template-columns: 1fr;
  }
  .api-keys-table th:nth-child(4),
  .api-keys-table td:nth-child(4),
  .api-keys-table th:nth-child(3),
  .api-keys-table td:nth-child(3) {
    display: none;
  }
  .api-create-row {
    flex-direction: column;
  }
  .api-label-input {
    min-width: 0;
    width: 100%;
  }
  .api-auth-info {
    padding: 0.8rem;
  }
  .api-keys-header {
    flex-direction: column;
  }
}
@media (max-width: 640px) {
  .sm-action-modal {
    width: calc(100% - 1rem);
    padding: 1.25rem;
  }
  .sm-action-actions {
    flex-direction: column;
    gap: 0.5rem;
  }
  .sm-action-primary,
  .sm-action-secondary {
    width: 100%;
  }
  .auth-modal {
    width: calc(100% - 1rem);
    padding: 1.5rem 1.25rem;
  }
  .auth-card {
    padding: 2rem 1.25rem;
  }
  .price-card {
    margin-bottom: 0.75rem;
  }
  .btn-launch {
    position: sticky;
    bottom: 0.75rem;
    z-index: 5;
  }
}
.sm-modal-overlay{position:fixed;inset:0;z-index:9500;background:rgba(0,0,0,.45);display:flex;align-items:center;justify-content:center;animation:smFadeIn .2s ease}
html[data-theme="dark"] .sm-modal-overlay{background:rgba(0,0,0,.65)}
@keyframes smFadeIn{from{opacity:0}to{opacity:1}}
.sm-modal{position:relative;background:var(--surface);border:1px solid var(--border);border-radius:20px;padding:2rem;max-width:480px;width:90vw;box-shadow:0 16px 48px rgba(0,0,0,.18);animation:smSlideUp .25s ease}
@keyframes smSlideUp{from{transform:translateY(12px);opacity:0}to{transform:translateY(0);opacity:1}}
.sm-modal-close{position:absolute;top:.75rem;right:.75rem;background:none;border:none;font-size:1.5rem;cursor:pointer;color:var(--text-muted);line-height:1}
.sm-modal-close:hover{color:var(--text)}
.org-type-card{flex:1;min-width:180px;display:flex;flex-direction:column;align-items:center;gap:.5rem;padding:1.5rem 1rem;border-radius:16px;border:2px solid var(--border);background:var(--bg);cursor:pointer;transition:border-color .2s,box-shadow .2s,transform .15s}
.org-type-card:hover{border-color:var(--brand);box-shadow:0 4px 16px rgba(20,92,50,.12);transform:translateY(-2px)}
.org-type-icon{font-size:2.5rem}
.org-type-label{font-weight:700;font-size:1.05rem;color:var(--text)}
.org-type-desc{font-size:.82rem;color:var(--text-muted);text-align:center}
.upgrade-toast{background:var(--surface)!important;color:var(--text)!important;border:1px solid var(--border)!important;box-shadow:0 12px 40px rgba(0,0,0,.15)!important}
html[data-theme="dark"] .upgrade-toast{background:var(--surface)!important;border-color:var(--border)!important;box-shadow:0 12px 40px rgba(0,0,0,.4)!important}
.upgrade-toast-text strong{color:var(--text)!important}
.upgrade-toast-text span{color:var(--text-muted)!important}
.upgrade-toast-btn{background:var(--brand)!important;color:#fff!important}
html[data-theme="dark"] .upgrade-toast-btn{background:var(--accent)!important}
body, .shell {
  transition: background-color 0.3s ease, color 0.3s ease;
}
.composer-card {
  border: 1px solid var(--border);
  box-shadow: 0 24px 64px rgba(0,0,0,0.06);
  border-radius: 28px;
  background: var(--surface);
  backdrop-filter: blur(20px);
  padding: 2rem;
  margin: 4rem auto;
  max-width: 800px;
}
html[data-theme="dark"] .composer-card {
  background: var(--surface);
  box-shadow: 0 24px 64px rgba(0,0,0,0.4);
  border-color: var(--border-strong);
}
.prompt-stage {
  border-radius: 20px;
  background: var(--bg-soft);
  border: 1.5px solid transparent;
  box-shadow: 0 8px 32px rgba(0,0,0,0.03) inset;
  transition: all 0.25s ease;
}
html[data-theme="dark"] .prompt-stage {
  box-shadow: 0 8px 32px rgba(0,0,0,0.2) inset;
  background: #0d1410;
}
.prompt-stage:focus-within {
  background: var(--surface);
  border-color: var(--brand);
  box-shadow: 0 0 0 4px var(--brand-soft);
  transform: translateY(-2px);
}
.prompt-stage textarea {
  font-size: 1.15rem;
  padding: 1.5rem;
  font-family: var(--font-body);
  color: var(--text);
}
.prompt-stage textarea::placeholder {
  color: var(--text-muted);
  font-weight: 400;
}
.composer-toolbar {
  background: transparent;
  border-top: 1px solid var(--border);
  padding: 1rem 1.5rem;
}
.toolbar-submit {
  border-radius: 12px;
  padding: 0.6rem 1.4rem;
  font-size: 0.95rem;
  box-shadow: 0 4px 12px rgba(20,92,50,0.2);
}
html[data-theme="dark"] .toolbar-submit {
  box-shadow: 0 4px 12px rgba(58,173,94,0.3);
}
.toolbar-pill {
  border-radius: 10px;
  padding: 0.4rem 0.8rem;
}
.sm-chat-wrapper {
  border-radius: 20px;
  background: var(--surface);
  box-shadow: var(--shadow);
  border: 1px solid var(--border);
  overflow: hidden;
}
.chat-bubble.user {
  background: var(--brand);
  color: #fff;
  border-radius: 18px 18px 4px 18px;
}
.chat-bubble.assistant {
  background: var(--bg-soft);
  border-radius: 18px 18px 18px 4px;
  border: 1px solid var(--border);
}
html[data-theme="dark"] .chat-bubble.assistant {
  background: #111a14;
}
.chat-input-row {
  background: var(--surface);
  border-top: 1px solid var(--border);
  padding: 1rem;
}
.chat-input {
  border-radius: 16px;
  background: var(--bg-soft);
  border: 1px solid transparent;
  padding: 0.8rem 1.2rem;
}
.chat-input:focus {
  background: var(--surface);
  border-color: var(--brand);
  box-shadow: 0 0 0 3px var(--brand-soft);
}
body[data-page="pricing"] {
  background: #f4f7f3;
  background-image: none;
}
.pricing-main {
  --pricing-serif: var(--font-heading);
  width: min(1220px, calc(100% - 2rem));
}
.pricing-main .page-hero {
  max-width: 860px;
  padding: clamp(3.5rem, 6vw, 5.5rem) 0 2.25rem;
}
.pricing-main .page-hero h1 {
  font-family: var(--font-heading);
  font-size: clamp(2.6rem, 5vw, 4.25rem);
  font-weight: 700;
  line-height: 1.06;
  letter-spacing: -0.055em;
}
.pricing-main .page-hero h1::after {
  display: none;
}
.pricing-main .hero-sub {
  max-width: 720px;
  margin-top: 1.15rem;
  font-size: clamp(1rem, 1.45vw, 1.16rem);
}
.pricing-main .billing-toggle {
  width: min(520px, 100%);
  margin-top: 1.6rem;
  border-color: var(--border-strong);
  border-radius: 10px;
  background: #fff;
}
.pricing-main .billing-pill {
  border-radius: 7px;
}
.pricing-main .billing-pill.active,
html[data-theme="dark"] .pricing-main .billing-pill.active {
  background: var(--brand);
  box-shadow: none;
}
.credit-pricing {
  margin-top: 1.25rem;
}
.credit-pricing::before,
.credit-pricing::after {
  display: none;
}
.classic-section-heading {
  max-width: 760px;
  margin: 0 0 1.5rem;
}
.classic-section-heading h2 {
  margin: 0;
  color: var(--text);
  font-family: var(--font-heading);
  font-size: clamp(1.8rem, 3vw, 2.45rem);
  letter-spacing: -0.04em;
}
.classic-section-heading p {
  margin: 0.55rem 0 0;
  color: var(--text-muted);
  line-height: 1.65;
}
.credit-grid {
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 1rem;
  align-items: stretch;
  padding: 0;
}
.credit-card,
.credit-card-featured,
.credit-card.universal {
  min-height: 610px;
  margin: 0;
  padding: 1.65rem;
  border: 1px solid var(--border-strong);
  border-radius: 14px;
  color: var(--text);
  background: #fff;
  box-shadow: 0 2px 10px rgba(10, 40, 20, 0.055);
}
.credit-card-featured {
  border: 2px solid var(--brand);
  box-shadow: 0 8px 24px rgba(20, 92, 50, 0.12);
}
.credit-card-featured .price-tier,
.credit-card-featured .price-copy,
.credit-card-featured .credit-currency {
  color: var(--text-muted);
}
.credit-card-featured h3,
.credit-card-featured .credit-price {
  color: var(--text);
}
.credit-card-featured .btn-primary {
  color: #fff;
  background: var(--brand);
}
.credit-card-featured .btn-primary:hover {
  background: var(--brand-deep);
}
.credit-value-label {
  top: -0.8rem;
  min-width: 120px;
  padding: 0.35rem 0.75rem;
  border-radius: var(--sm-r-tag);
  color: #fff;
  background: var(--brand);
  font-size: 0.75rem;
  letter-spacing: 0.02em;
}
.credit-card-copy {
  text-align: left;
}
.credit-card .price-tier {
  margin: 0 0 0.85rem;
  color: var(--brand-deep);
  font-size: 0.76rem;
  letter-spacing: 0.09em;
}
.credit-card h3 {
  min-height: 3.4rem;
  font-family: var(--font-heading);
  font-size: 1.45rem;
  line-height: 1.15;
}
.credit-card .price-copy {
  min-height: 5.8rem;
  margin-top: 0.7rem;
  font-size: 0.9rem;
  line-height: 1.55;
}
.credit-price {
  justify-content: flex-start;
  margin: 1.25rem 0 1.15rem;
  font-family: var(--font-heading);
}
.credit-price-number {
  font-size: clamp(2.8rem, 3.8vw, 3.55rem);
  font-weight: 700;
}
.credit-features {
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
  padding: 1rem 0 1.35rem;
  margin: 0;
  border-top: 1px solid var(--border);
  color: var(--text-soft);
  font-size: 0.88rem;
  list-style: none;
}
.credit-features li {
  display: flex;
  gap: 0.55rem;
  line-height: 1.35;
}
.credit-features li::before {
  content: "✓";
  flex: 0 0 auto;
  color: var(--brand);
  font-weight: 800;
}
.credit-card .btn-primary,
.credit-card .btn-secondary {
  margin-top: auto;
  border-radius: var(--radius-pill);
  word-spacing: 0.08em;
}
.credit-assurance {
  grid-template-columns: repeat(3, 1fr);
  margin-top: 1.25rem;
  padding: 0;
  border: 1px solid var(--border-strong);
  border-radius: 12px;
  background: #fff;
  text-align: left;
}
.credit-assurance span {
  padding: 1.15rem 1.25rem;
}
.credit-assurance span + span {
  border-left: 1px solid var(--border);
}
.credit-assurance strong,
.credit-assurance small {
  display: block;
}
.credit-assurance strong {
  margin: 0;
  color: var(--text);
  font-size: 0.92rem;
}
.credit-assurance small {
  margin-top: 0.3rem;
  color: var(--text-muted);
  line-height: 1.35;
}
.pricing-main .section-heading {
  margin: 0 0 1.5rem;
  text-align: left;
}
.pricing-main .section-heading h2 {
  color: var(--text);
  font-family: var(--font-heading);
  font-size: clamp(1.8rem, 3vw, 2.45rem);
}
.pricing-main .section-heading p:not(.eyebrow) {
  margin-inline: 0;
}
.pricing-main .pricing-grid-wide {
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 1rem;
  padding-top: 0.5rem;
}
.pricing-main .price-card,
.pricing-main .price-card:first-child,
.pricing-main .price-card:last-child,
.pricing-main .price-card.featured {
  min-height: 760px;
  margin: 0;
  padding: 1.6rem;
  border: 1px solid var(--border-strong);
  border-radius: 14px;
  background: #fff;
  box-shadow: 0 2px 10px rgba(10, 40, 20, 0.055);
}
.pricing-main .price-card.featured {
  padding-top: 2.75rem;
  border: 2px solid var(--brand);
  box-shadow: 0 8px 24px rgba(20, 92, 50, 0.12);
}
.plan-recommended {
  left: -2px;
  right: -2px;
  padding: 0.5rem;
  border-radius: 12px 12px 0 0;
  background: var(--brand);
}
.pricing-main .price-card-top h2 {
  min-height: 3.6rem;
  font-family: var(--font-heading);
  font-size: 1.35rem;
  line-height: 1.15;
}
.pricing-main .price-card .price-copy {
  min-height: 8.4rem;
  font-size: 0.9rem;
  line-height: 1.55;
}
.pricing-main .price-card:hover,
.pricing-main .price-card.featured:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 22px rgba(14, 61, 31, 0.1);
}
.plan-limits {
  margin-top: 1.25rem;
  padding: 1.6rem;
  border-radius: 14px;
  background: #fff;
}
.plan-limits h2 {
  margin: 0.2rem 0 0.45rem;
  font-family: var(--font-heading);
  font-size: 1.55rem;
  letter-spacing: -0.035em;
}
.plan-limits > p:not(.eyebrow) {
  max-width: 820px;
  margin: 0 0 1.25rem;
  color: var(--text-muted);
  line-height: 1.65;
}
.plan-limit-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  border: 1px solid var(--border);
  border-radius: 10px;
  overflow: hidden;
}
.plan-limit-item {
  padding: 1rem;
  background: #fff;
}
.plan-limit-item + .plan-limit-item {
  border-left: 1px solid var(--border);
}
.plan-limit-name {
  color: var(--brand-deep);
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}
.plan-limit-value {
  margin: 0.35rem 0 0.2rem;
  color: var(--text);
  font-size: 1.45rem;
  font-weight: 700;
}
.plan-limit-copy {
  color: var(--text-muted);
  font-size: 0.82rem;
  line-height: 1.4;
}
html[data-theme="dark"] body[data-page="pricing"] {
  background: var(--bg);
}
html[data-theme="dark"] .credit-card,
html[data-theme="dark"] .credit-card-featured,
html[data-theme="dark"] .credit-card.universal,
html[data-theme="dark"] .credit-assurance,
html[data-theme="dark"] .pricing-main .price-card,
html[data-theme="dark"] .pricing-main .price-card.featured {
  background: var(--bg-card);
}
html[data-theme="dark"] .plan-limits,
html[data-theme="dark"] .plan-limit-item {
  background: var(--bg-card);
}
@media (max-width: 980px) {
  .credit-grid,
  .pricing-main .pricing-grid-wide {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .credit-card,
  .credit-card-featured,
  .credit-card.universal,
  .pricing-main .price-card,
  .pricing-main .price-card:first-child,
  .pricing-main .price-card:last-child,
  .pricing-main .price-card.featured {
    min-height: 0;
  }
  .credit-card .price-copy,
  .pricing-main .price-card .price-copy {
    min-height: 0;
  }
}
@media (max-width: 640px) {
  .pricing-main .page-hero {
    padding-top: 2.8rem;
  }
  .pricing-main .page-hero h1 {
    font-size: clamp(2.2rem, 11vw, 3rem);
  }
  .classic-section-heading,
  .pricing-main .section-heading {
    text-align: left;
  }
  .credit-grid,
  .pricing-main .pricing-grid-wide,
  .credit-assurance {
    grid-template-columns: 1fr;
  }
  .credit-assurance span + span {
    border-top: 1px solid var(--border);
    border-left: 0;
  }
  .credit-card,
  .credit-card-featured,
  .credit-card.universal,
  .pricing-main .price-card,
  .pricing-main .price-card:first-child,
  .pricing-main .price-card:last-child,
  .pricing-main .price-card.featured {
    padding: 1.4rem;
  }
  .credit-card-featured,
  .pricing-main .price-card.featured {
    padding-top: 2.6rem;
  }
  .credit-card h3,
  .credit-card .price-copy,
  .pricing-main .price-card-top h2,
  .pricing-main .price-card .price-copy {
    min-height: 0;
  }
  .plan-limit-grid {
    grid-template-columns: 1fr;
  }
  .plan-limit-item + .plan-limit-item {
    border-top: 1px solid var(--border);
    border-left: 0;
  }
}
.account-credits-panel {
  overflow: hidden;
}
.pricing-credit-wallet {
  display: grid;
  grid-template-columns: minmax(12rem, 0.8fr) minmax(28rem, 2fr) auto;
  gap: 1rem;
  align-items: center;
  margin: 0 auto 1.4rem;
  padding: 1rem 1.1rem;
  border: 1px solid color-mix(in srgb, var(--brand) 18%, var(--border));
  border-radius: 16px;
  background: color-mix(in srgb, var(--brand-soft) 42%, var(--bg-card));
}
.pricing-credit-wallet[hidden] { display: none; }
.pricing-credit-wallet h3 { margin: 0.2rem 0 0; font-size: 1rem; }
.pricing-credit-wallet .credit-wallet-grid { gap: 0.5rem; }
.pricing-credit-wallet .credit-wallet-item { padding: 0.75rem; }
.pricing-credit-wallet .credit-wallet-item strong { font-size: 1.35rem; }
.credit-wallet-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 0.75rem;
}
.credit-wallet-item {
  min-width: 0;
  padding: 1rem;
  background: color-mix(in srgb, var(--brand-soft) 58%, var(--bg-card));
  border: 1px solid color-mix(in srgb, var(--brand) 14%, var(--border));
  border-radius: 13px;
}
.credit-wallet-item strong,
.credit-wallet-item span {
  display: block;
}
.credit-wallet-item strong {
  color: var(--brand);
  font-family: var(--font-heading);
  font-size: 1.8rem;
  line-height: 1;
}
.credit-wallet-item span {
  margin-top: 0.4rem;
  color: var(--text-muted);
  font-size: 0.76rem;
  font-weight: 700;
  line-height: 1.35;
}
.gift-credit-form {
  display: grid;
  grid-template-columns: minmax(12rem, 0.9fr) minmax(14rem, 1.35fr) minmax(6rem, 0.35fr) auto;
  gap: 0.8rem;
  align-items: end;
  margin-top: 1.2rem;
  padding-top: 1.2rem;
  border-top: 1px solid var(--border);
}
.gift-credit-field label {
  display: block;
  margin-bottom: 0.4rem;
  color: var(--text-soft);
  font-size: 0.78rem;
  font-weight: 700;
}
.gift-credit-field input,
.gift-credit-field select {
  width: 100%;
  min-height: 2.75rem;
  padding: 0.68rem 0.78rem;
  color: var(--text);
  background: var(--bg-input);
  border: 1px solid var(--border);
  border-radius: 10px;
  font: inherit;
  font-size: 0.86rem;
}
.gift-credit-field input:focus,
.gift-credit-field select:focus {
  outline: none;
  border-color: var(--brand);
  box-shadow: 0 0 0 3px rgba(20, 92, 50, 0.1);
}
.gift-credit-actions {
  display: flex;
  gap: 0.55rem;
}
.gift-credit-actions .btn-primary,
.gift-credit-actions .btn-secondary {
  min-height: 2.75rem;
  white-space: nowrap;
}
.account-credits-panel > .account-inline-status {
  margin-top: 0.85rem;
}
.gift-credit-note {
  margin: 0.7rem 0 0;
  color: var(--text-muted);
  font-size: 0.76rem;
  line-height: 1.5;
}
.nav-dropdown { position: relative; display: inline-flex; align-items: center; }
.nav-dropdown-toggle .nav-caret { font-size: .7em; margin-left: .15rem; opacity: .7; transition: transform .15s ease; }
.nav-dropdown-menu {
  position: absolute; top: calc(100% + .35rem); left: -0.5rem; z-index: 60; display: none;
  min-width: 300px; padding: .45rem; border-radius: 16px; background: var(--surface, #fff);
  border: 1px solid var(--border, rgba(15, 61, 34, .12)); box-shadow: 0 18px 40px rgba(15, 61, 34, .14);
}
.nav-dropdown::after { content: ""; position: absolute; left: 0; right: 0; top: 100%; height: .5rem; }
.nav-dropdown:hover .nav-dropdown-menu, .nav-dropdown:focus-within .nav-dropdown-menu { display: block; }
.nav-dropdown:hover .nav-caret, .nav-dropdown:focus-within .nav-caret { transform: rotate(180deg); }
.nav-dropdown-item { display: block; padding: .6rem .75rem; border-radius: 11px; text-decoration: none; color: inherit; }
.nav-dropdown-item strong { display: block; font-size: .92rem; color: var(--forest, #0f3d22); }
.nav-dropdown-item span { display: block; font-size: .8rem; line-height: 1.35; color: var(--muted, #5b6b61); margin-top: .1rem; }
.nav-dropdown-item:hover, .nav-dropdown-item:focus-visible { background: rgba(20, 92, 50, .07); outline: none; }
html[data-theme="dark"] .nav-dropdown-menu { background: var(--surface-strong, #16241b); }
@media (max-width: 640px) {
  .nav-dropdown { display: block; width: 100%; }
  .nav-dropdown-menu { position: static; display: block; min-width: 0; box-shadow: none; border: 0; padding: 0 0 .25rem .75rem; background: transparent; }
  .nav-dropdown::after, .nav-dropdown-toggle .nav-caret { display: none; }
  .nav-dropdown-item span { display: none; }
}
.nav-links:has(.nav-dropdown) { overflow: visible; }
@media (min-width: 641px) {
  .nav-links:has(.nav-dropdown) .nav-link { padding-left: .55rem; padding-right: .55rem; white-space: nowrap; }
  .header-inner:has(.nav-dropdown) .logo-sub { display: none; }
}
@media (min-width: 641px) and (max-width: 1180px) {
  .nav-links:has(.nav-dropdown) .nav-link { font-size: .86rem; padding-left: .4rem; padding-right: .4rem; }
  .header-inner:has(.nav-dropdown) .mkt-auth-btns .btn-ghost span { display: none; }
}
.sm-skip-link {
  position: absolute; left: 12px; top: -48px; z-index: 100; padding: .55rem .9rem; border-radius: 10px;
  background: var(--sm-accent); color: var(--sm-on-accent); font-weight: 650; text-decoration: none; transition: top .15s ease;
}
.sm-skip-link:focus { top: calc(env(safe-area-inset-top, 0px) + 10px); outline: 3px solid var(--sm-accent-ink); outline-offset: 2px; }
.site-header.sm-public-header {
  padding: 0;
  top: env(safe-area-inset-top, 0px);
  z-index: 60;
  background: var(--sm-glass);
  border-bottom: 1px solid var(--sm-line);
  -webkit-backdrop-filter: blur(14px) saturate(1.3);
  backdrop-filter: blur(14px) saturate(1.3);
}
.sm-public-header .header-inner { min-height: 64px; gap: 1rem; flex-wrap: nowrap; }
.sm-public-header .logo-area { gap: .6rem; }
.sm-public-header .logo-copy { display: flex; }
.sm-public-header .logo-text { font-family: var(--sm-font-display); font-size: 1.14rem; font-weight: 700; letter-spacing: -.01em; color: var(--sm-ink); }
.sm-public-header .logo-mark { width: 2.1rem; height: 2.1rem; border-radius: 10px; box-shadow: none; transform: none; background: var(--sm-mint-soft); border-color: var(--sm-line); }
.sm-public-header .logo-mark svg { transform: none; width: 21px; height: 21px; }
html[data-theme="dark"] .sm-public-header .logo-mark svg path:first-child { fill: var(--sm-accent); }
html[data-theme="dark"] .sm-public-header .logo-mark svg path:nth-child(2) { stroke: var(--sm-accent-ink); }
.sm-public-nav { flex: 1 1 auto; justify-content: center; gap: .1rem; overflow: visible; padding-bottom: 0; }
.sm-public-nav .nav-link,
.sm-public-nav .nav-dropdown-toggle {
  display: inline-flex; align-items: center; gap: .3rem; min-height: 38px; padding: .4rem .7rem; border: 0; border-radius: 10px;
  background: none; cursor: pointer; font: inherit; font-family: var(--sm-font-display); font-size: .95rem; font-weight: 500;
  letter-spacing: -.005em; line-height: 1.2; color: var(--sm-ink-2); white-space: nowrap; text-decoration: none;
  transition: background .15s ease, color .15s ease;
}
.sm-public-nav .nav-link:hover,
.sm-public-nav .nav-dropdown-toggle:hover,
.sm-public-nav .nav-link.active,
.sm-public-nav .nav-dropdown-toggle.active,
.sm-public-nav .nav-dropdown.is-open > .nav-dropdown-toggle,
.sm-public-nav .nav-link[aria-current="page"] { color: var(--sm-ink); background: var(--sm-mint-soft); }
.sm-public-nav .nav-link:focus-visible,
.sm-public-nav .nav-dropdown-toggle:focus-visible { outline: 3px solid var(--sm-accent); outline-offset: 1px; }
.sm-public-nav .nav-link::after { display: none; }
.sm-nav-chevron { flex: 0 0 auto; opacity: .7; transition: transform .15s ease; }
.nav-dropdown.is-open .sm-nav-chevron,
.nav-dropdown-toggle[aria-expanded="true"] .sm-nav-chevron { transform: rotate(180deg); }
.sm-public-nav .sm-nav-feature { color: var(--sm-ink); font-weight: 600; }
.sm-nav-badge {
  display: inline-flex; align-items: center; padding: .1rem .42rem; border-radius: var(--sm-r-tag);
  background: var(--sm-mint); color: var(--sm-accent-ink); font-family: var(--sm-font-body); font-size: .66rem; font-weight: 700; letter-spacing: .02em;
}
.sm-public-header .nav-dropdown { position: relative; display: inline-flex; }
.sm-public-header .nav-dropdown::after { content: ""; position: absolute; left: 0; right: 0; top: 100%; height: .6rem; }
.sm-public-header .nav-dropdown-menu {
  display: none; position: absolute; top: calc(100% + .5rem); left: 50%; z-index: 70; transform: translateX(-50%);
  min-width: 290px; padding: .4rem; border-radius: var(--sm-r-card);
  background: var(--sm-surface); border: 1px solid var(--sm-line); box-shadow: var(--sm-shadow-pop);
}
.sm-public-header .nav-dropdown:hover > .nav-dropdown-menu,
.sm-public-header .nav-dropdown:focus-within > .nav-dropdown-menu { display: block; }
html.sm-nav-js .sm-public-header .nav-dropdown:not(.is-open) > .nav-dropdown-menu { display: none; }
html.sm-nav-js .sm-public-header .nav-dropdown.is-open > .nav-dropdown-menu { display: block; }
.sm-public-header .nav-dropdown-item { display: block; padding: .6rem .75rem; border-radius: 10px; color: var(--sm-ink); text-decoration: none; }
.sm-public-header .nav-dropdown-item strong { display: block; color: var(--sm-ink); font-family: var(--sm-font-display); font-size: .95rem; font-weight: 600; }
.sm-public-header .nav-dropdown-item span { display: block; margin-top: .1rem; color: var(--sm-muted); font-size: .82rem; line-height: 1.35; }
.sm-public-header .nav-dropdown-item:hover,
.sm-public-header .nav-dropdown-item:focus-visible,
.sm-public-header .nav-dropdown-item[aria-current="page"] { background: var(--sm-mint-soft); outline: none; }
.sm-public-header .nav-dropdown-item:focus-visible { box-shadow: inset 0 0 0 2px var(--sm-accent); }
.sm-public-header .header-right { gap: .35rem; flex: 0 0 auto; margin-left: 0; }
.sm-lang-link {
  display: inline-flex; align-items: center; gap: .35rem; min-height: 38px; padding: .4rem .6rem; border-radius: 10px;
  color: var(--sm-ink-2); font-family: var(--sm-font-display); font-size: .92rem; font-weight: 500; text-decoration: none;
}
.sm-lang-link:hover { color: var(--sm-ink); background: var(--sm-mint-soft); }
.sm-lang-link:focus-visible { outline: 3px solid var(--sm-accent); outline-offset: 1px; }
.sm-public-header .btn-ghost.sm-signin-link {
  min-height: 38px; padding: .4rem .75rem; border: 0; border-radius: 10px; background: none; box-shadow: none;
  color: var(--sm-ink); font-family: var(--sm-font-display); font-size: .95rem; font-weight: 600;
}
.sm-public-header .btn-ghost.sm-signin-link:hover { background: var(--sm-mint-soft); transform: none; box-shadow: none; }
.sm-public-header .btn-primary.sm-start-free {
  min-height: 40px; padding: .45rem 1rem; border-radius: 10px; font-family: var(--sm-font-display); font-size: .95rem; font-weight: 600;
  background: var(--sm-accent); color: var(--sm-on-accent); box-shadow: 0 1px 2px rgba(17, 21, 18, .12);
}
.sm-public-header .btn-primary.sm-start-free:hover { background: var(--sm-accent-ink); color: var(--sm-on-accent); transform: none; }
.sm-public-header .btn-primary.sm-start-free:focus-visible { outline: 3px solid var(--sm-accent); outline-offset: 2px; }
.sm-public-header .mkt-auth-btns { display: flex; align-items: center; gap: .25rem; }
.sm-public-header .mkt-auth-btns[hidden] { display: none; }
.sm-public-header .nav-toggle {
  display: none; align-items: center; justify-content: center; width: 40px; height: 40px; padding: 0; margin-left: .15rem;
  border: 1px solid var(--sm-line); border-radius: 10px; background: var(--sm-surface); color: var(--sm-ink); cursor: pointer;
}
.sm-public-header .nav-toggle:focus-visible { outline: 3px solid var(--sm-accent); outline-offset: 2px; }
.sm-public-header .nav-toggle .sm-toggle-close { display: none; }
.sm-public-header .nav-toggle[aria-expanded="true"] .sm-toggle-open { display: none; }
.sm-public-header .nav-toggle[aria-expanded="true"] .sm-toggle-close { display: block; }
.sm-nav-sheet-extra { display: none; }
@media (max-width: 479.98px) {
  .sm-public-header .sm-signin-link { display: none; }
}
@media (min-width: 1100px) and (max-width: 1239px) {
  .sm-public-header .sm-lang-link span { display: none; }
  .sm-public-nav .nav-link, .sm-public-nav .nav-dropdown-toggle { padding-left: .5rem; padding-right: .5rem; }
  html[lang="es"] .sm-nav-badge { display: none; }
}
@media (max-width: 1099px) {
  .sm-public-header .header-inner { min-height: 60px; }
  .sm-public-header .sm-lang-link { display: none; }
  .sm-public-header .header-right { margin-left: auto; }
  html.js .sm-public-header .nav-toggle { display: inline-flex; }
  html.js .sm-public-header .sm-public-nav {
    display: none; position: fixed; left: 0; right: 0; bottom: 0; top: calc(env(safe-area-inset-top, 0px) + 61px); z-index: 59;
    flex-direction: column; align-items: stretch; justify-content: flex-start; gap: .15rem; margin: 0;
    padding: .75rem max(16px, calc((100vw - 720px) / 2)) calc(env(safe-area-inset-bottom, 0px) + 1.5rem);
    overflow-y: auto; overscroll-behavior: contain; background: var(--sm-paper); border: 0; border-top: 1px solid var(--sm-line); border-radius: 0; box-shadow: none;
  }
  html.js .sm-public-header .sm-public-nav.open { display: flex; }
  .site-header.sm-public-header:has(.sm-public-nav.open),
  body.mobile-nav-open .site-header.sm-public-header { -webkit-backdrop-filter: none; backdrop-filter: none; background: var(--sm-paper); }
  html.js body.mobile-nav-open:has(.sm-public-header) { overflow: hidden; }
  .sm-public-nav .nav-link,
  .sm-public-nav .nav-dropdown-toggle { width: 100%; justify-content: space-between; min-height: 52px; padding: .75rem .85rem; font-size: 1.08rem; border-radius: 12px; }
  .sm-public-header .nav-dropdown { display: block; width: 100%; }
  .sm-public-header .nav-dropdown::after { display: none; }
  .sm-public-header .nav-dropdown-menu { position: static; transform: none; min-width: 0; margin: 0 0 .35rem; padding: .1rem 0 .3rem .5rem; border: 0; box-shadow: none; background: transparent; }
  .sm-public-header .nav-dropdown:hover > .nav-dropdown-menu { display: none; }
  html:not(.sm-nav-js) .sm-public-header .nav-dropdown-menu { display: block; }
  .sm-public-header .nav-dropdown-item { padding: .6rem .85rem; }
  .sm-public-nav .sm-nav-feature { justify-content: flex-start; gap: .55rem; }
  .sm-nav-sheet-extra { display: flex; flex-direction: column; gap: .15rem; margin-top: .75rem; padding-top: .75rem; border-top: 1px solid var(--sm-line); }
  .sm-nav-sheet-extra .nav-link { justify-content: flex-start; }
  html:not(.js) .sm-public-header .header-inner { flex-wrap: wrap; padding-block: .5rem; }
  html:not(.js) .sm-public-header .sm-public-nav { order: 3; flex-basis: 100%; flex-wrap: wrap; justify-content: flex-start; }
}
@media (max-width: 380px) {
  .sm-public-header .btn-primary.sm-start-free { padding-inline: .75rem; font-size: .9rem; }
  .sm-public-header .logo-text { font-size: 1.05rem; }
}
.sm-theme-toggle {
  position: relative; display: inline-flex; flex: 0 0 auto; align-items: center; justify-content: center;
  width: 34px; height: 34px; margin: 0; padding: 0; border: 0; border-radius: 10px;
  background: transparent; color: var(--sm-ink-2); cursor: pointer; box-shadow: none;
  transition: background-color .12s ease, color .12s ease;
}
.sm-theme-toggle:hover { background: var(--sm-mint-soft); color: var(--sm-ink); }
.sm-theme-toggle:focus-visible { outline: 3px solid var(--sm-accent); outline-offset: 2px; }
.sm-theme-toggle svg, .sm-theme-row-icon svg { display: block; flex: 0 0 auto; width: 18px; height: 18px; }
html .sm-tt-sun, html[data-theme="dark"] .sm-tt-moon { display: none; }
html[data-theme="dark"] .sm-tt-sun { display: block; }
.sm-theme-row { display: none; }
.sm-theme-row-icon { display: inline-flex; color: var(--sm-ink-2); }
html[data-theme] .sm-theme-row .sm-tt-moon { display: block; }
html[data-theme] .sm-theme-row .sm-tt-sun { display: none; }
.sm-theme-row[aria-pressed="true"] .sm-theme-row-icon { color: var(--sm-accent); }
.sm-theme-row[aria-pressed="true"] .sm-tt-moon { fill: currentColor; }
@media (max-width: 639.98px) {
  .sm-public-header .sm-theme-bar { display: none; }
  .sm-nav-sheet-extra .sm-theme-row {
    display: flex; align-items: center; justify-content: flex-start; gap: .6rem; width: 100%; margin: 0;
    border: 0; background: transparent; box-shadow: none; color: var(--sm-ink); font-family: inherit; font-weight: 500;
    line-height: inherit; text-align: left; cursor: pointer;
  }
  .sm-nav-sheet-extra .sm-theme-row:hover { background: var(--sm-mint-soft); }
  .sm-nav-sheet-extra .sm-theme-row:focus-visible { outline: 3px solid var(--sm-accent); outline-offset: -3px; }
}
@media (pointer: coarse) {
  .sm-theme-toggle::before { content: ""; position: absolute; inset: -5px; }
}
.sm-backend-banner {
  position: fixed; top: env(safe-area-inset-top, 0px); left: 0; right: 0; z-index: 9999;
  display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: .55rem .75rem;
  padding: .6rem 1rem; background: var(--sm-danger-soft); color: var(--sm-danger);
  border-bottom: 1px solid color-mix(in srgb, var(--sm-danger) 25%, transparent);
  font-family: var(--sm-font-body); font-size: .9rem; line-height: 1.4; box-shadow: var(--sm-shadow-card);
}
.sm-backend-banner svg { flex: 0 0 auto; }
.sm-backend-banner-text { color: var(--sm-ink); font-weight: 500; }
.sm-backend-banner-retry {
  min-height: 32px; padding: .3rem .85rem; border: 1px solid var(--sm-line); border-radius: 8px; cursor: pointer;
  background: var(--sm-surface); color: var(--sm-ink); font: inherit; font-weight: 650;
}
.sm-backend-banner-retry:hover { border-color: var(--sm-ink-2); }
.sm-backend-banner-retry:focus-visible { outline: 3px solid var(--sm-accent); outline-offset: 2px; }
@media (max-width: 639.98px) {
  html.sm-backend-banner-on body { padding-top: var(--sm-backend-banner-h, 0px); }
  html.sm-backend-banner-on body .site-header,
  html.sm-backend-banner-on body[data-shell] .app-topbar { top: var(--sm-backend-banner-h, 0px); }
}
.sm-public-footer {
  padding: 3rem 0 1.5rem; color: var(--sm-ink-2); background: var(--sm-panel); border-top: 1px solid var(--sm-line);
}
.sm-footer-inner { display: grid; grid-template-columns: minmax(200px, 1fr) minmax(0, 3fr); gap: 2rem 3rem; align-items: start; }
.sm-footer-logo { display: inline-flex; align-items: center; gap: .6rem; color: var(--sm-ink); text-decoration: none; font-family: var(--sm-font-display); font-size: 1.05rem; }
.sm-public-footer .footer-brand-mark { width: 2.25rem; height: 2.25rem; border-radius: 10px; color: var(--sm-accent); background: var(--sm-mint-soft); border: 1px solid var(--sm-line); box-shadow: none; transform: none; }
.sm-public-footer .footer-brand-mark svg { width: 20px; height: 20px; fill: none; }
.sm-footer-tagline { margin: .6rem 0 0; font-size: .86rem; color: var(--sm-muted); }
.sm-footer-cols { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 1.5rem; }
.sm-footer-title { margin: 0 0 .7rem; font-family: var(--sm-font-body); font-size: .8rem; font-weight: 700; letter-spacing: .04em; text-transform: uppercase; color: var(--sm-ink); }
.sm-footer-col ul { list-style: none; margin: 0; padding: 0; display: grid; gap: .45rem; }
.sm-footer-col a, .sm-footer-langs a { color: var(--sm-ink-2); text-decoration: none; font-size: .9rem; }
.sm-footer-col a:hover, .sm-footer-langs a:hover { color: var(--sm-accent); text-decoration: underline; text-underline-offset: .18em; }
.sm-public-footer .sm-footer-bottom { display: flex; flex-wrap: wrap; justify-content: space-between; gap: .5rem 1.5rem; margin-top: 2.25rem; padding-top: 1.1rem; border-top: 1px solid var(--sm-line); font-size: .84rem; color: var(--sm-muted); }
.sm-footer-bottom p { margin: 0; }
.sm-footer-langs { display: inline-flex; gap: .55rem; align-items: center; }
.sm-footer-langs [aria-current] { color: var(--sm-ink); font-weight: 600; }
.sm-public-footer { padding-bottom: calc(env(safe-area-inset-bottom, 0px) + var(--sm-fab-bottom, 24px) + 52px + 24px); }
@media (max-width: 900px) {
  .sm-footer-inner { grid-template-columns: 1fr; }
  .sm-footer-cols { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
.account-switcher {
  display: inline-flex; align-items: center; gap: .55rem; max-width: 100%; min-height: 2.65rem;
  padding: .3rem .55rem .3rem .35rem; color: var(--sm-ink); background: var(--sm-surface);
  border: 1px solid var(--sm-line); border-radius: var(--sm-r-input); font: inherit; font-size: .86rem; text-align: left; cursor: pointer;
}
.account-switcher:hover,
.account-switcher[aria-expanded="true"] { background: var(--sm-mint-soft); }
.account-switcher:focus-visible { outline: 2px solid var(--sm-accent); outline-offset: 2px; }
.account-switcher-text { display: inline-flex; flex-direction: column; min-width: 0; line-height: 1.2; }
.account-switcher-name { font-weight: 650; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; max-width: 11rem; }
.account-switcher-plan { font-size: .74rem; color: var(--sm-muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.account-switcher-chevron { flex: 0 0 auto; color: var(--sm-muted); }
.account-menu--up { padding: .35rem; background: var(--sm-surface); border-color: var(--sm-line); box-shadow: var(--sm-shadow-pop); border-radius: var(--sm-r-card); }
.account-menu--up > [role="menuitem"] {
  display: flex; align-items: center; width: 100%; padding: .62rem .75rem; border: 0; border-radius: 10px;
  background: transparent; color: var(--sm-ink); font: inherit; font-size: .88rem; text-align: left; text-decoration: none; cursor: pointer;
}
.account-menu--up > [role="menuitem"]:hover,
.account-menu--up > [role="menuitem"]:focus-visible { background: var(--sm-mint-soft); outline: none; }
.account-menu--up > #sign-out-btn { margin-top: .25rem; border-top: 1px solid var(--sm-line); border-radius: 0 0 10px 10px; color: var(--sm-danger); }
@media (max-width: 640px) {
  .account-switcher-text { display: none; }
}
.btn-primary,
.btn-secondary,
.btn-ghost,
.btn-inline { transition: background-color var(--sm-dur) var(--sm-ease), border-color var(--sm-dur) var(--sm-ease), color var(--sm-dur) var(--sm-ease), box-shadow var(--sm-dur) var(--sm-ease), transform var(--sm-dur-fast) var(--sm-ease); }
.btn-primary { box-shadow: var(--sm-shadow-btn); letter-spacing: -.005em; }
.btn-primary:hover { box-shadow: var(--sm-shadow-btn), 0 6px 16px -6px color-mix(in srgb, var(--sm-accent) 55%, transparent); }
.btn-secondary { background: var(--sm-surface); border-color: var(--sm-line-strong); box-shadow: var(--sm-shadow-xs); backdrop-filter: none; }
html[data-theme="dark"] .btn-secondary { background: var(--sm-surface); }
.btn-secondary:hover { background: var(--sm-tint); border-color: color-mix(in srgb, var(--sm-accent) 35%, var(--sm-line)); box-shadow: var(--sm-shadow-sm); transform: none; }
.btn-ghost:hover { box-shadow: none; }
.btn-primary:active:not(:disabled),
.btn-secondary:active:not(:disabled),
.btn-ghost:active:not(:disabled) { transform: translateY(1px) scale(.99); }
.btn-primary:focus-visible,
.btn-secondary:focus-visible,
.btn-ghost:focus-visible { box-shadow: var(--sm-ring); }
.sm-public-header .btn-primary.sm-start-free { box-shadow: var(--sm-shadow-btn); transition: background-color var(--sm-dur) var(--sm-ease), box-shadow var(--sm-dur) var(--sm-ease), transform var(--sm-dur-fast) var(--sm-ease); }
.sm-public-header .btn-primary.sm-start-free:hover { box-shadow: var(--sm-shadow-btn), 0 6px 16px -6px color-mix(in srgb, var(--sm-accent) 60%, transparent); }
.sm-public-header .btn-primary.sm-start-free:active { transform: translateY(1px); }
.sm-public-header .nav-dropdown-menu { border-radius: var(--sm-r-lg); border-color: color-mix(in srgb, var(--sm-line) 70%, transparent); box-shadow: var(--sm-shadow-lg); }
html.sm-nav-js .sm-public-header .nav-dropdown.is-open > .nav-dropdown-menu { animation: sm-pop-in var(--sm-dur) var(--sm-ease); }
.sm-public-header .nav-dropdown-item { transition: background-color var(--sm-dur-fast) ease; }
.account-menu--up { border-radius: var(--sm-r-lg); box-shadow: var(--sm-shadow-lg); }
@keyframes sm-pop-in { from { opacity: 0; transform: translate(-50%, -4px) scale(.98); } to { opacity: 1; transform: translateX(-50%); } }
@media (prefers-reduced-motion: reduce) {
  .btn-primary, .btn-secondary, .btn-ghost, .btn-inline, .sm-public-header .btn-primary.sm-start-free { transition: none; }
  .btn-primary:hover, .btn-secondary:hover, .btn-ghost:hover, .chip-btn:hover, .theme-pill:hover,
  .btn-primary:active, .btn-secondary:active, .btn-ghost:active, .sm-public-header .btn-primary.sm-start-free:active { transform: none !important; }
  html.sm-nav-js .sm-public-header .nav-dropdown.is-open > .nav-dropdown-menu { animation: none; }
}
:is(.logo-mark, .footer-brand-mark, .auth-modal-icon):has(> svg.sm-logo) {
  display: inline-flex; align-items: center; justify-content: center; width: auto; height: auto; padding: 0;
  border: 0; border-radius: 0; background: none; box-shadow: none; transform: none;
}
.logo-area:hover .logo-mark:has(> svg.sm-logo) { transform: none; }
svg.sm-logo { display: block; flex: 0 0 auto; width: 28px; height: 28px; transform: none; box-shadow: none; }
.auth-modal-icon svg.sm-logo { width: 40px; height: 40px; }
svg.sm-logo > rect { fill: #e6f3e9 !important; stroke: #e7e4dc !important; }
svg.sm-logo > g > path:first-child { fill: #145c32 !important; stroke: #0e3d1f !important; }
svg.sm-logo > g > path:last-child { fill: none !important; stroke: #b6f0c8 !important; }
@font-face {
  font-family: "SM Logo Grotesk";
  font-style: normal;
  font-weight: 300 700;
  font-display: swap;
  src: url("data:font/woff2;base64,d09GMgABAAAAAAioABQAAAAAEFAAAAg9AAEAAAAAAAAAAAAAAAAAAAAAAAAAAAAAGmUbgnwcgQw/SFZBUlYGYD9TVEFUWCceAGQvRBEICodwhkowhmABNgIkAzQLHAAEIAWEbgcgDAcbNQ6jopwyMiL4iwObyHQPrIhtqJW25cbKQ/PPNioHGCH6LWRcMh6gfLR4Nx7WVsph+CSep/Z7PXf3fUyBwQGCQmESX9eJLuvKjK8mFLKutqzRPUPm8lpWz/HEI0JVAPJ+Tn78fL7c7A94Bqt6qpYWXqghNfGVk4Z1F1i99rx60qG59AJ0nzwwllVHyk2OhdoV7ISakZWVBJwnCjTAvzjsH9d+dQNvYkfi7iuQPqERqR6KhjqGHg8xG2LHxz1rSRaKmZYAjVDBlqlR0jrCCiOvG2m/m3t2Uc0A6wAcQaqiiEZfTDJJ0RWTxLBGzduagHGAbRpzgrwDjnwVwl+KFwytsoI8cnH3htKYELsoaaBVAUFGldAFj8trFFDaSwmTHNF/NwMheqLXTiIsSJ9gBl/wD8j13Ph5+0qsQMzbDs9pa0ahFSO27R/iK5aj/ehhaNqTiOGb0a7o6MZZFANX2lFFDdJNHhnn9HHgG7jc4cW0ptR+KFdebpuofQ1qQXRiZczQhCapJ9lowGwwLKNrgWvaF9QLmkdEvxYxw5Y3JikxehJgVuJRN78NpiGxAGz8kfQHT9/pkdQ8H38jCFBN7nf0arqlmSaXTwNdtpIYMJQ7ojrAaTuT3MRKQiDO49mOnQa8RbGivlfOoLlNsIBAvuGzgGUoyXQdZqGxCHlL02MC6Jula6nVNNm0ekVJySOgvMQW1vzmDWjqhxKdt+AmgGlqDwMxevwWMijIwlkos5BeANNUdLezXhk8oVjRVjFwf6HOdKLNrW9ta1rxDrr+BpAxoJ+uPAbIpgRSkVBLKSRbDankN6RJaT/tf6AFT74eC8A0yEEgDwHzwCxA0wRk7AFxzz5NB5uK1aW6O2u0Lv4qiYtL+2I7kdocVL3kHSTCW6ajIDqugp1RLX67xrvaxYeJ7QhdcgjCwZpjtRNp4VdukOf8V8VgiO0OgKzu/BYgnLzKsms3AlRKm2krlTBSpolpYSTti+12QiiEd3SJg9hu2znr/QphHQe8Q4EdWk249S7Vcq+rufD2LRVT0BNBDiJGTFeAPkMANF5Ys8RBJhUnvGsu2fGEUnQ0FKkXXydihtA7hI0ZkUApqol6CSHMxqtvGWS6mIqmNzWhEuEq07pkf+m2p2FoVwNdb11zY7ui/SG3Lr6+ySE8d31iMpelN5sYs96UxfMaTGbGZDC/2eCy0eUU7brQ3P3C2HkxfpxWnrA3PCYnOj7OGpfsm+Iff6MokBBbGPgkUsq+/HqVsZ92jkHN1Rm761ScM2M2Y/1RnFS82/UwqAunppiGqlyyXNpHmmpqm8syo2bneX/3rz6dnKfXGyp7YyyWkfisJutljvi0eFN5QHJ+S87TJu1Wvzf49huVVmA08vXDCaibMDSo3Mv5ktTa6JQ6UwTPlpVaTIWdHV0/kKouGMngxwpVhUdSGFRQbJCfWtM51KBokNSa6i4hTPu8I6Pq5XCiPj0rLduYkwBFeC/btZXbep4/f5g73OT1n8Rh7QPOVzZ/qLpw2OxMSamLTqk1RfKhpWP/RXvXT76D7Q3HqN79i7vHZ3ePpx7uz1A3wU8gzRdxi8Jud02Yxk0b5qeiMFAAMihl3qq6QAA5AA6LdltMgGxME6A2BZLurR4jOIRTeO4XoYQl+aSJdJERsiELCAQKHASQqdNKbgStLjZWTzgn0kVDWdC4RMYlcXHBXhrOKziKM4pS8a4uGsVfzhIUnYN8HQY4BQWxbAgfGhmXmDIfjLZM3x4eKlWd3kl29bpq5eHBKAh0rybOVevRgpGm9Y5gmtYKOvS0H+qsJj1PNO+OSfO+heOddlfX36LbbnWa9WanrwDCPzlzHDif4e3tK6ebiUm/vNyNH6Vks8COZmMDA5Nkfh5dYaoBfy8e6jXEN0VZTug9rtndu7iGffHVznujB2gWLfCH5R6TsRvQw+smq10LYqCFkJUiJYqSvDztOcCrlaeH07OrR7EpTeBys4xq5av1OVr6pIbrrY5wwGnSC/TomJH+JWngRfN8nJ/TJor5/FDeb3E6zIJ2uNc+n58LkEjgIAyFrCzZVfsTdO9mL++FmwIAf2EBSWqKbNSUjAkoEJJ0tWRzLdkS5rWBDkIeWSEYXgitIfAMochgbMxO0rUtltRo0j42CcUh0M+nZinnD4Ui6YkgF+JjdLqHaLhzE3/+kgU5swUeYKyDU3MZXqqdnUlnXsnr74Y9xFrCR1CER8UiQmPDcYDv8fH4UDS29y+eKy9vVVTinLC7j2yO8DagkOAc4d/fGzKuoTFoIDTEh2oHcAjDlmkgdmdrOPmNOZmzRDUtk7RSUXhHfJYOXqlMgrdNfSAmrCXmvQCiLzAB2G1pBmJehG1hOoPVb4v+/53FWTZYlzFptrL0lUBQGJ1vvt6q43+xRP0BwOetwU0A37WWs/Bv0wlJXQDoKiD8W4ipV0OoaRJxwybXi/jli3+UPmyYI6d04asM4Sjj+Mpz4F868Qz2bIzMt6kaSxCY7AL6D3kgjSi6/ATE0gzwEfCUscafspjil7La5n9gE1V2LEicsmtV8hRTbMuQVpiUCVbGME86joNCRP8pYaN+Dmvi8RVCBo0u1rRi6T6l6a2CFfFV0wSSZ/9SyBOnRCyGJx+bIEFSjiVW1DUlFCkM4eTOvi+yYzFNYwRZQrQgzT2ORSq7tblB4LIIGDqe6EpUNBOXM9rIR7OMusvHXii0E9gjlK5YsHTHdl24NSGwrjZOZ/iDzs7U4A1oSq8hXb8PYkHKneKLPVjAi7bSt1Fds+jRBSTzkwLqiGT3FLLrOOE44bHjKDdetf8lqfmU/J83ehkAAAA=") format("woff2");
  unicode-range: U+4D, U+53, U+69, U+6E-6F, U+72, U+74, U+79;
}
:root { --sm-logo-ink: #111512; --sm-logo-mark: 2.1rem; --sm-font-logo: "SM Logo Grotesk", "Space Grotesk", system-ui, -apple-system, "Segoe UI", sans-serif; }
html[data-theme="dark"] { --sm-logo-ink: #eef2ee; }
@media (max-width: 380px) { :root { --sm-logo-mark: 1.94rem; } }
.logo-area, .sm-public-header .logo-area, .sm-footer-logo { gap: calc(var(--sm-logo-mark) * .285714); }
.logo-area .logo-mark svg.sm-logo, .sm-public-header .logo-mark svg.sm-logo,
.sm-footer-logo .footer-brand-mark svg.sm-logo, .sm-public-footer .footer-brand-mark svg.sm-logo { width: var(--sm-logo-mark); height: var(--sm-logo-mark); }
.logo-area .logo-text, .sm-public-header .logo-text, .sm-footer-logo strong, .sm-logo-word {
  font-family: var(--sm-font-logo); font-size: calc(var(--sm-logo-mark) * .542857); font-weight: 700;
  letter-spacing: -.01em; line-height: 1; color: var(--sm-logo-ink);
}
@media (pointer: coarse) {
  .btn-primary, .btn-secondary, .btn-ghost, .btn-danger, .btn-inline, .billing-pill,
  .chip-btn, .style-chip, .theme-pill, .edit-page-btn, .chat-quick-actions button,
  .account-menu-button, .account-menu-signout, .sm-text-action { min-height: 44px; }
  .sm-public-header .btn-primary.sm-start-free, .sm-public-header .btn-ghost.sm-signin-link, .sm-lang-link { min-height: 44px; }
  .sm-public-header .nav-toggle { width: 44px; height: 44px; }
  .sm-footer-col ul { gap: 0; }
  .sm-footer-col a, .sm-footer-langs a { display: inline-flex; align-items: center; min-height: 44px; }
  .page-breadcrumb a { display: inline-flex; align-items: center; min-height: 44px; }
  .sm-auth-forgot { display: inline-flex; align-items: center; min-height: 44px; }
  .logo-area, .sm-footer-logo { min-height: 44px; }
  .nav-toggle { min-width: 44px; min-height: 44px; }
  .api-endpoint summary { display: flex; align-items: center; min-height: 44px; }
  .sm-btn, .sm-btn.sm-btn-sm { min-height: 44px; }
  .mk-btn.mk-btn--sm, .mk-currency-switch { min-height: 44px; }
}
.mk-credit-art[hidden] { display: none; }
:where(.sm-dots, .hm-hero, .mk-hero, .bl-hero, .ld-launch, .ld-comic-hero, .mk-comic-page) {
  --sm-dots-tile: 22px;
  --sm-dots-at: 1px 1px;
  --sm-dots-r: 1.2px;
  --sm-dots-edge: 0px;
  --sm-dots-color: var(--sm-line);
  --sm-dots-opacity: 1;
  --sm-dots-fade: linear-gradient(#000, #000);
  --sm-dots-inset: 0px;
  --sm-dots-glow: #cbf7d8;
  --sm-dots-glow-opacity: 1;
  --sm-dots-glow-grow: 2px;
  --sm-dots-glow-size: min(32rem, 85vw);
  position: relative;
  isolation: isolate;
}
:where(html[data-theme="dark"]) :where(.sm-dots, .hm-hero, .mk-hero, .bl-hero, .ld-launch, .ld-comic-hero, .mk-comic-page) {
  --sm-dots-glow: #0e4628;
}
:where(.sm-dots, .hm-hero, .mk-hero, .bl-hero, .ld-launch, .ld-comic-hero, .mk-comic-page)::before,
:where(.sm-dots, .hm-hero, .mk-hero, .bl-hero, .ld-launch, .ld-comic-hero, .mk-comic-page)::after {
  content: "";
  position: absolute;
  z-index: -2;
  top: 0;
  right: 0;
  bottom: calc(-1 * var(--sm-dots-tile));
  left: calc(-1 * var(--sm-dots-tile));
  font-size: var(--sm-dots-tile);
  pointer-events: none;
  background: radial-gradient(circle at var(--sm-dots-at), var(--sm-dots-color) var(--sm-dots-r), transparent var(--sm-dots-edge)) 0 0 / var(--sm-dots-tile) var(--sm-dots-tile);
  opacity: var(--sm-dots-opacity);
  -webkit-mask: var(--sm-dots-fade) calc(var(--sm-dots-tile) + var(--sm-dots-inset)) var(--sm-dots-inset) / calc(100% - var(--sm-dots-tile) - 2 * var(--sm-dots-inset)) calc(100% - var(--sm-dots-tile) - 2 * var(--sm-dots-inset)) no-repeat;
  mask: var(--sm-dots-fade) calc(var(--sm-dots-tile) + var(--sm-dots-inset)) var(--sm-dots-inset) / calc(100% - var(--sm-dots-tile) - 2 * var(--sm-dots-inset)) calc(100% - var(--sm-dots-tile) - 2 * var(--sm-dots-inset)) no-repeat;
}
:where(.sm-dots, .hm-hero, .mk-hero, .bl-hero, .ld-launch, .ld-comic-hero, .mk-comic-page)::after {
  display: none;
  background: radial-gradient(circle at var(--sm-dots-at), var(--sm-dots-glow) calc(var(--sm-dots-r) + var(--sm-dots-glow-grow)), transparent calc(var(--sm-dots-edge) + var(--sm-dots-glow-grow))) 0 0 / var(--sm-dots-tile) var(--sm-dots-tile);
  opacity: var(--sm-dots-glow-opacity);
  -webkit-mask: radial-gradient(closest-side, #000, rgba(0, 0, 0, .5) 45%, transparent) 50% 50% / var(--sm-dots-glow-size) var(--sm-dots-glow-size) no-repeat, var(--sm-dots-fade) calc(var(--sm-dots-tile) + var(--sm-dots-inset)) var(--sm-dots-inset) / calc(100% - var(--sm-dots-tile) - 2 * var(--sm-dots-inset)) calc(100% - var(--sm-dots-tile) - 2 * var(--sm-dots-inset)) no-repeat;
  -webkit-mask-composite: source-in;
  mask: radial-gradient(closest-side, #000, rgba(0, 0, 0, .5) 45%, transparent) 50% 50% / var(--sm-dots-glow-size) var(--sm-dots-glow-size) no-repeat, var(--sm-dots-fade) calc(var(--sm-dots-tile) + var(--sm-dots-inset)) var(--sm-dots-inset) / calc(100% - var(--sm-dots-tile) - 2 * var(--sm-dots-inset)) calc(100% - var(--sm-dots-tile) - 2 * var(--sm-dots-inset)) no-repeat;
  mask-composite: intersect;
}
@media (prefers-reduced-motion: no-preference) {
  :where(.sm-dots, .hm-hero, .mk-hero, .bl-hero, .ld-launch, .ld-comic-hero, .mk-comic-page)::before { animation: sm-dots-drift 48s linear infinite, sm-dots-lock 48s steps(44) infinite; }
  :where(.sm-dots, .hm-hero, .mk-hero, .bl-hero, .ld-launch, .ld-comic-hero, .mk-comic-page)::after { display: block; animation: sm-dots-drift 48s linear infinite, sm-dots-glow 48s steps(8) infinite; }
}
@media (prefers-reduced-motion: reduce) {
  :where(.sm-dots, .hm-hero, .mk-hero, .bl-hero, .ld-launch, .ld-comic-hero, .mk-comic-page)::before { animation: none; transform: none; }
  :where(.sm-dots, .hm-hero, .mk-hero, .bl-hero, .ld-launch, .ld-comic-hero, .mk-comic-page)::after { display: none; animation: none; }
}
@keyframes sm-dots-drift {
  from { transform: translate3d(0, 0, 0); }
  to { transform: translate3d(1em, -1em, 0); }
}
@keyframes sm-dots-lock {
  from { mask-position: calc(var(--sm-dots-tile) + var(--sm-dots-inset)) var(--sm-dots-inset); }
  to { mask-position: var(--sm-dots-inset) calc(var(--sm-dots-tile) + var(--sm-dots-inset)); }
}
@keyframes sm-dots-glow {
  0% { mask-position: calc(73.71% + var(--sm-dots-tile)) 46%, calc(var(--sm-dots-tile) + var(--sm-dots-inset)) var(--sm-dots-inset); }
  2.78% { mask-position: calc(84.14% + var(--sm-dots-tile) * .97) calc(66% + var(--sm-dots-tile) * .03), calc(var(--sm-dots-tile) * .97 + var(--sm-dots-inset)) calc(var(--sm-dots-tile) * .03 + var(--sm-dots-inset)); }
  5.56% { mask-position: calc(90.45% + var(--sm-dots-tile) * .94) calc(80.64% + var(--sm-dots-tile) * .06), calc(var(--sm-dots-tile) * .94 + var(--sm-dots-inset)) calc(var(--sm-dots-tile) * .06 + var(--sm-dots-inset)); }
  8.33% { mask-position: calc(91.88% + var(--sm-dots-tile) * .92) calc(86% + var(--sm-dots-tile) * .08), calc(var(--sm-dots-tile) * .92 + var(--sm-dots-inset)) calc(var(--sm-dots-tile) * .08 + var(--sm-dots-inset)); }
  11.11% { mask-position: calc(88.26% + var(--sm-dots-tile) * .89) calc(80.64% + var(--sm-dots-tile) * .11), calc(var(--sm-dots-tile) * .89 + var(--sm-dots-inset)) calc(var(--sm-dots-tile) * .11 + var(--sm-dots-inset)); }
  13.89% { mask-position: calc(80.02% + var(--sm-dots-tile) * .86) calc(66% + var(--sm-dots-tile) * .14), calc(var(--sm-dots-tile) * .86 + var(--sm-dots-inset)) calc(var(--sm-dots-tile) * .14 + var(--sm-dots-inset)); }
  16.67% { mask-position: calc(68.16% + var(--sm-dots-tile) * .83) calc(46% + var(--sm-dots-tile) * .17), calc(var(--sm-dots-tile) * .83 + var(--sm-dots-inset)) calc(var(--sm-dots-tile) * .17 + var(--sm-dots-inset)); }
  19.44% { mask-position: calc(54.11% + var(--sm-dots-tile) * .81) calc(26% + var(--sm-dots-tile) * .19), calc(var(--sm-dots-tile) * .81 + var(--sm-dots-inset)) calc(var(--sm-dots-tile) * .19 + var(--sm-dots-inset)); }
  22.22% { mask-position: calc(39.57% + var(--sm-dots-tile) * .78) calc(11.36% + var(--sm-dots-tile) * .22), calc(var(--sm-dots-tile) * .78 + var(--sm-dots-inset)) calc(var(--sm-dots-tile) * .22 + var(--sm-dots-inset)); }
  25% { mask-position: calc(26.29% + var(--sm-dots-tile) * .75) calc(6% + var(--sm-dots-tile) * .25), calc(var(--sm-dots-tile) * .75 + var(--sm-dots-inset)) calc(var(--sm-dots-tile) * .25 + var(--sm-dots-inset)); }
  27.78% { mask-position: calc(15.86% + var(--sm-dots-tile) * .72) calc(11.36% + var(--sm-dots-tile) * .28), calc(var(--sm-dots-tile) * .72 + var(--sm-dots-inset)) calc(var(--sm-dots-tile) * .28 + var(--sm-dots-inset)); }
  30.56% { mask-position: calc(9.55% + var(--sm-dots-tile) * .69) calc(26% + var(--sm-dots-tile) * .31), calc(var(--sm-dots-tile) * .69 + var(--sm-dots-inset)) calc(var(--sm-dots-tile) * .31 + var(--sm-dots-inset)); }
  33.33% { mask-position: calc(8.12% + var(--sm-dots-tile) * .67) calc(46% + var(--sm-dots-tile) * .33), calc(var(--sm-dots-tile) * .67 + var(--sm-dots-inset)) calc(var(--sm-dots-tile) * .33 + var(--sm-dots-inset)); }
  36.11% { mask-position: calc(11.74% + var(--sm-dots-tile) * .64) calc(66% + var(--sm-dots-tile) * .36), calc(var(--sm-dots-tile) * .64 + var(--sm-dots-inset)) calc(var(--sm-dots-tile) * .36 + var(--sm-dots-inset)); }
  38.89% { mask-position: calc(19.98% + var(--sm-dots-tile) * .61) calc(80.64% + var(--sm-dots-tile) * .39), calc(var(--sm-dots-tile) * .61 + var(--sm-dots-inset)) calc(var(--sm-dots-tile) * .39 + var(--sm-dots-inset)); }
  41.67% { mask-position: calc(31.84% + var(--sm-dots-tile) * .58) calc(86% + var(--sm-dots-tile) * .42), calc(var(--sm-dots-tile) * .58 + var(--sm-dots-inset)) calc(var(--sm-dots-tile) * .42 + var(--sm-dots-inset)); }
  44.44% { mask-position: calc(45.89% + var(--sm-dots-tile) * .56) calc(80.64% + var(--sm-dots-tile) * .44), calc(var(--sm-dots-tile) * .56 + var(--sm-dots-inset)) calc(var(--sm-dots-tile) * .44 + var(--sm-dots-inset)); }
  47.22% { mask-position: calc(60.43% + var(--sm-dots-tile) * .53) calc(66% + var(--sm-dots-tile) * .47), calc(var(--sm-dots-tile) * .53 + var(--sm-dots-inset)) calc(var(--sm-dots-tile) * .47 + var(--sm-dots-inset)); }
  50% { mask-position: calc(73.71% + var(--sm-dots-tile) * .5) calc(46% + var(--sm-dots-tile) * .5), calc(var(--sm-dots-tile) * .5 + var(--sm-dots-inset)) calc(var(--sm-dots-tile) * .5 + var(--sm-dots-inset)); }
  52.78% { mask-position: calc(84.14% + var(--sm-dots-tile) * .47) calc(26% + var(--sm-dots-tile) * .53), calc(var(--sm-dots-tile) * .47 + var(--sm-dots-inset)) calc(var(--sm-dots-tile) * .53 + var(--sm-dots-inset)); }
  55.56% { mask-position: calc(90.45% + var(--sm-dots-tile) * .44) calc(11.36% + var(--sm-dots-tile) * .56), calc(var(--sm-dots-tile) * .44 + var(--sm-dots-inset)) calc(var(--sm-dots-tile) * .56 + var(--sm-dots-inset)); }
  58.33% { mask-position: calc(91.88% + var(--sm-dots-tile) * .42) calc(6% + var(--sm-dots-tile) * .58), calc(var(--sm-dots-tile) * .42 + var(--sm-dots-inset)) calc(var(--sm-dots-tile) * .58 + var(--sm-dots-inset)); }
  61.11% { mask-position: calc(88.26% + var(--sm-dots-tile) * .39) calc(11.36% + var(--sm-dots-tile) * .61), calc(var(--sm-dots-tile) * .39 + var(--sm-dots-inset)) calc(var(--sm-dots-tile) * .61 + var(--sm-dots-inset)); }
  63.89% { mask-position: calc(80.02% + var(--sm-dots-tile) * .36) calc(26% + var(--sm-dots-tile) * .64), calc(var(--sm-dots-tile) * .36 + var(--sm-dots-inset)) calc(var(--sm-dots-tile) * .64 + var(--sm-dots-inset)); }
  66.67% { mask-position: calc(68.16% + var(--sm-dots-tile) * .33) calc(46% + var(--sm-dots-tile) * .67), calc(var(--sm-dots-tile) * .33 + var(--sm-dots-inset)) calc(var(--sm-dots-tile) * .67 + var(--sm-dots-inset)); }
  69.44% { mask-position: calc(54.11% + var(--sm-dots-tile) * .31) calc(66% + var(--sm-dots-tile) * .69), calc(var(--sm-dots-tile) * .31 + var(--sm-dots-inset)) calc(var(--sm-dots-tile) * .69 + var(--sm-dots-inset)); }
  72.22% { mask-position: calc(39.57% + var(--sm-dots-tile) * .28) calc(80.64% + var(--sm-dots-tile) * .72), calc(var(--sm-dots-tile) * .28 + var(--sm-dots-inset)) calc(var(--sm-dots-tile) * .72 + var(--sm-dots-inset)); }
  75% { mask-position: calc(26.29% + var(--sm-dots-tile) * .25) calc(86% + var(--sm-dots-tile) * .75), calc(var(--sm-dots-tile) * .25 + var(--sm-dots-inset)) calc(var(--sm-dots-tile) * .75 + var(--sm-dots-inset)); }
  77.78% { mask-position: calc(15.86% + var(--sm-dots-tile) * .22) calc(80.64% + var(--sm-dots-tile) * .78), calc(var(--sm-dots-tile) * .22 + var(--sm-dots-inset)) calc(var(--sm-dots-tile) * .78 + var(--sm-dots-inset)); }
  80.56% { mask-position: calc(9.55% + var(--sm-dots-tile) * .19) calc(66% + var(--sm-dots-tile) * .81), calc(var(--sm-dots-tile) * .19 + var(--sm-dots-inset)) calc(var(--sm-dots-tile) * .81 + var(--sm-dots-inset)); }
  83.33% { mask-position: calc(8.12% + var(--sm-dots-tile) * .17) calc(46% + var(--sm-dots-tile) * .83), calc(var(--sm-dots-tile) * .17 + var(--sm-dots-inset)) calc(var(--sm-dots-tile) * .83 + var(--sm-dots-inset)); }
  86.11% { mask-position: calc(11.74% + var(--sm-dots-tile) * .14) calc(26% + var(--sm-dots-tile) * .86), calc(var(--sm-dots-tile) * .14 + var(--sm-dots-inset)) calc(var(--sm-dots-tile) * .86 + var(--sm-dots-inset)); }
  88.89% { mask-position: calc(19.98% + var(--sm-dots-tile) * .11) calc(11.36% + var(--sm-dots-tile) * .89), calc(var(--sm-dots-tile) * .11 + var(--sm-dots-inset)) calc(var(--sm-dots-tile) * .89 + var(--sm-dots-inset)); }
  91.67% { mask-position: calc(31.84% + var(--sm-dots-tile) * .08) calc(6% + var(--sm-dots-tile) * .92), calc(var(--sm-dots-tile) * .08 + var(--sm-dots-inset)) calc(var(--sm-dots-tile) * .92 + var(--sm-dots-inset)); }
  94.44% { mask-position: calc(45.89% + var(--sm-dots-tile) * .06) calc(11.36% + var(--sm-dots-tile) * .94), calc(var(--sm-dots-tile) * .06 + var(--sm-dots-inset)) calc(var(--sm-dots-tile) * .94 + var(--sm-dots-inset)); }
  97.22% { mask-position: calc(60.43% + var(--sm-dots-tile) * .03) calc(26% + var(--sm-dots-tile) * .97), calc(var(--sm-dots-tile) * .03 + var(--sm-dots-inset)) calc(var(--sm-dots-tile) * .97 + var(--sm-dots-inset)); }
  100% { mask-position: 73.71% calc(46% + var(--sm-dots-tile)), var(--sm-dots-inset) calc(var(--sm-dots-tile) + var(--sm-dots-inset)); }
}
/*! ── es.storymint.ca overrides (i18n/es/style-es.css) ── */
html[lang="es"] .btn-primary,
html[lang="es"] .btn-secondary,
html[lang="es"] .btn-ghost,
html[lang="es"] .btn-inline,
html[lang="es"] .btn-launch,
html[lang="es"] .upgrade-toast-btn,
html[lang="es"] .toolbar-submit,
html[lang="es"] .coming-soon-form .btn-primary,
html[lang="es"] .gift-credit-actions .btn-primary,
html[lang="es"] .gift-credit-actions .btn-secondary,
html[lang="es"] .realm-new-book-actions .btn-primary {
  white-space: normal;
  text-align: center;
  text-wrap: balance;
  line-height: 1.2;
  overflow-wrap: break-word;
}
html[lang="es"] .header-right .btn-primary,
html[lang="es"] .header-right .btn-ghost,
html[lang="es"] .editor-topbar-actions .btn-inline {
  white-space: nowrap;
}
html[lang="es"] .editor-topbar-actions {
  flex-wrap: wrap;
  row-gap: 0.35rem;
}
html[lang="es"] .sm-action-primary,
html[lang="es"] .sm-action-secondary {
  max-width: 100%;
}
html[lang="es"] .nav-links:not(.sm-public-nav) .nav-link {
  padding-inline: 0.55rem;
  font-size: clamp(0.8rem, 0.45rem + 0.6vw, 0.92rem);
}
html[lang="es"] .tier-badge {
  display: inline-block;
  max-width: 13rem;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  vertical-align: middle;
}
html[lang="es"] .toolbar-pill {
  min-width: 0;
  max-width: 100%;
}
html[lang="es"] .toolbar-pill select {
  max-width: min(11.5rem, 46vw);
  text-overflow: ellipsis;
}
html[lang="es"] .plan-mode-toggle {
  white-space: normal;
  line-height: 1.3;
}
html[lang="es"] .page-count-label {
  white-space: normal;
  line-height: 1.25;
}
html[lang="es"] .story-type-picker span {
  white-space: normal;
  text-align: center;
  line-height: 1.15;
  hyphens: auto;
}
html[lang="es"] .photo-transform-card span {
  max-width: calc(100% - 16px);
  white-space: normal;
  text-align: center;
}
html[lang="es"] .pricing-main .price-card-top h2 {
  font-size: clamp(1.2rem, 0.8rem + 1vw, 1.55rem);
  overflow-wrap: break-word;
  hyphens: auto;
}
html[lang="es"] .plan-price-meta {
  white-space: normal;
}
@media (max-width: 640px) {
  html[lang="es"] .pricing-main .billing-pill {
    min-width: 0;
    white-space: normal;
    line-height: 1.2;
  }
}
html[lang="es"] .credit-value-label {
  max-width: calc(100% - 1rem);
  text-align: center;
}
html[lang="es"] .tl-label {
  text-align: center;
  overflow-wrap: break-word;
  hyphens: auto;
  font-size: clamp(0.6rem, 0.5rem + 0.35vw, 0.72rem);
}
