:root {
  --background: #fcfbf8;
  --foreground: #0c1117;
  --card: #ffffff;
  --secondary: #f1eee8;
  --border: #ded8cf;
  --muted: #68707b;
  --primary: #f43f46;
  --primary-dark: #d92e38;
  --primary-foreground: #ffffff;
  --shadow: 0 30px 70px rgba(12, 17, 23, 0.16);
  --container: 1280px;
  --pad: 24px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--background);
  color: var(--foreground);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  line-height: 1.55;
}

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

button,
a {
  -webkit-tap-highlight-color: transparent;
}

.page-shell {
  display: flex;
  min-height: 100vh;
  flex-direction: column;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  border-bottom: 1px solid var(--border);
  background: rgba(252, 251, 248, 0.82);
  backdrop-filter: blur(14px);
}

.header-inner,
.content-wrap,
.hero-inner {
  width: min(100%, var(--container));
  margin: 0 auto;
  padding-inline: var(--pad);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 64px;
  gap: 22px;
}

.brand {
  flex: 0 0 auto;
  font-family: "Inter Tight", Inter, sans-serif;
  font-size: 18px;
  font-weight: 900;
  letter-spacing: -0.015em;
  text-transform: uppercase;
}

.brand span,
.hero-copy h1 span,
.final-cta h2 span {
  color: var(--primary);
}

.main-nav {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 28px;
  min-width: 0;
}

.main-nav a,
.admin-link,
.start-button,
.primary-cta,
.outline-cta,
.inline-link,
.section-title-row a {
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.main-nav a {
  color: var(--muted);
  transition: color 0.18s ease;
  white-space: nowrap;
}

.main-nav a:hover,
.main-nav a.active,
.admin-link:hover,
.section-title-row a:hover,
.inline-link:hover {
  color: var(--primary);
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 12px;
  flex: 0 0 auto;
}

.admin-link {
  color: var(--muted);
}

.start-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 36px;
  padding: 0 16px;
  background: var(--foreground);
  color: var(--background);
  transition: background 0.18s ease;
}

.start-button:hover {
  background: var(--primary);
}

.menu-button {
  display: none;
  width: 36px;
  height: 36px;
  place-items: center;
  border: 1px solid var(--border);
  background: transparent;
  color: var(--foreground);
}

.menu-button span {
  display: block;
  width: 18px;
  height: 2px;
  background: currentColor;
}

.webapp-install-button {
  width: 38px;
  height: 38px;
  display: inline-grid;
  place-items: center;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: var(--card);
  color: var(--foreground);
  cursor: pointer;
  transition: background 0.18s ease, border-color 0.18s ease, color 0.18s ease, transform 0.18s ease;
}

.webapp-install-button svg {
  width: 19px;
  height: 19px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2.2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.webapp-install-button:hover,
.webapp-install-button.is-ready {
  border-color: var(--primary);
  background: var(--primary);
  color: var(--primary-foreground);
  transform: translateY(-1px);
}

.webapp-install-button.is-installed {
  border-color: color-mix(in srgb, var(--primary) 30%, var(--border));
  background: color-mix(in srgb, var(--primary) 8%, var(--card));
  color: var(--primary);
}

.webapp-install-overlay {
  position: fixed;
  inset: 0;
  z-index: 120;
  display: grid;
  place-items: center;
  background: rgba(12, 17, 23, 0.48);
  padding: 22px;
}

.webapp-install-modal {
  width: min(100%, 520px);
  border: 1px solid var(--border);
  background: var(--background);
  box-shadow: var(--shadow);
  padding: 28px;
}

.webapp-install-modal header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 18px;
  border-bottom: 1px solid var(--border);
  padding-bottom: 18px;
}

.webapp-install-modal h2 {
  margin: 8px 0 0;
  font-family: "Inter Tight", Inter, sans-serif;
  font-size: 30px;
  font-weight: 950;
  letter-spacing: -0.035em;
  line-height: 1;
  text-transform: uppercase;
}

.webapp-install-modal header button {
  width: 38px;
  height: 38px;
  border: 1px solid var(--border);
  background: var(--card);
  color: var(--foreground);
  font-size: 24px;
  line-height: 1;
  cursor: pointer;
}

.webapp-install-modal p,
.webapp-install-modal li {
  color: var(--muted);
  font-size: 15px;
  line-height: 1.7;
}

.webapp-install-modal ol {
  margin: 18px 0 24px;
  padding-left: 22px;
}

.webapp-install-primary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 42px;
  border: 1px solid var(--foreground);
  padding: 0 18px;
  color: var(--foreground);
  font-size: 11px;
  font-weight: 900;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.webapp-install-primary:hover {
  background: var(--foreground);
  color: var(--background);
}

.cf-eyebrow {
  margin: 0;
  color: var(--muted);
  font-family: "JetBrains Mono", ui-monospace, SFMono-Regular, Consolas, monospace;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

h1,
h2,
h3,
h4,
p {
  margin-top: 0;
}

.hero-section {
  padding: 80px 0;
}

.hero-inner {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(360px, 1fr);
  align-items: center;
  gap: 64px;
}

.hero-copy .cf-eyebrow {
  margin-bottom: 24px;
  font-weight: 800;
}

.hero-copy h1 {
  margin: 0 0 32px;
  max-width: 780px;
  font-family: "Inter Tight", Inter, sans-serif;
  font-size: clamp(48px, 6.4vw, 96px);
  font-weight: 900;
  letter-spacing: -0.035em;
  line-height: 0.94;
  text-transform: uppercase;
}

.hero-text {
  max-width: 54ch;
  margin-bottom: 40px;
  color: var(--muted);
  font-size: clamp(18px, 1.6vw, 20px);
  line-height: 1.72;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
}

.primary-cta,
.outline-cta {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  min-height: 54px;
  padding: 0 32px;
  transition: transform 0.18s ease, background 0.18s ease, color 0.18s ease;
}

.primary-cta {
  background: var(--primary);
  color: var(--primary-foreground);
}

.outline-cta {
  border: 2px solid var(--foreground);
  color: var(--foreground);
  text-decoration: underline;
  text-decoration-color: var(--primary);
  text-decoration-thickness: 3px;
  text-underline-offset: 8px;
}

.primary-cta:hover,
.outline-cta:hover {
  transform: translateY(-2px);
}

.outline-cta:hover {
  background: var(--foreground);
  color: var(--background);
}

.daily-card {
  border: 1px solid var(--border);
  border-radius: 16px;
  background: var(--secondary);
  padding: 32px;
  box-shadow: var(--shadow);
}

.daily-card__header {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 32px;
}

.daily-card h3 {
  margin: 4px 0 0;
  font-family: "Inter Tight", Inter, sans-serif;
  font-size: clamp(34px, 4vw, 42px);
  font-weight: 900;
  letter-spacing: -0.04em;
}

.daily-card h3 span {
  color: var(--muted);
  font-family: Inter, sans-serif;
  font-size: 16px;
  letter-spacing: 0;
}

.daily-card__goal {
  text-align: right;
}

.daily-card__goal strong {
  font-size: 15px;
}

.macro-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
}

.macro-grid article,
.mini-stats article {
  border: 1px solid var(--border);
  background: var(--card);
  padding: 16px;
}

.macro-grid strong {
  display: block;
  margin-top: 4px;
  font-size: 18px;
}

.meter {
  height: 4px;
  margin-top: 10px;
  background: var(--secondary);
}

.meter span {
  display: block;
  height: 100%;
  background: var(--primary);
}

.mini-stats {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 12px;
  margin-top: 24px;
}

.mini-stats strong {
  display: block;
  margin-top: 4px;
  font-family: "Inter Tight", Inter, sans-serif;
  font-size: 28px;
  font-weight: 900;
  letter-spacing: -0.04em;
}

.mini-stats article:last-child strong {
  color: var(--primary);
}

.need-section,
.final-cta {
  background: var(--foreground);
  color: var(--background);
}

.need-section,
.process-section,
.features-section,
.landing-managed-section,
.ranking-section,
.final-cta {
  padding: 96px 0;
}

.section-split-heading {
  display: grid;
  grid-template-columns: 1fr minmax(280px, 440px);
  gap: 32px;
  align-items: baseline;
  margin-bottom: 64px;
}

.section-split-heading h2,
.section-title-row h2,
.final-cta h2 {
  margin: 0;
  font-family: "Inter Tight", Inter, sans-serif;
  font-size: clamp(32px, 3.8vw, 48px);
  font-weight: 900;
  letter-spacing: -0.025em;
  line-height: 1.04;
  text-transform: uppercase;
}

.section-split-heading p {
  margin: 0;
  color: var(--muted);
  font-size: 16px;
}

.need-section .section-split-heading p,
.final-cta p {
  color: rgba(252, 251, 248, 0.68);
}

.need-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  column-gap: 48px;
  row-gap: 56px;
}

.need-grid p,
.process-grid p {
  margin: 0;
  color: var(--primary);
  font-family: "JetBrains Mono", ui-monospace, SFMono-Regular, Consolas, monospace;
  font-size: 14px;
}

.need-grid h3 {
  margin: 12px 0;
  font-family: "Inter Tight", Inter, sans-serif;
  font-size: 22px;
  font-weight: 800;
  letter-spacing: -0.01em;
  line-height: 1.08;
  text-transform: uppercase;
}

.need-grid span {
  color: rgba(252, 251, 248, 0.62);
  line-height: 1.7;
}

.process-section {
  border-bottom: 1px solid var(--border);
}

.section-title-row {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 32px;
  border-bottom: 2px solid var(--foreground);
  padding-bottom: 16px;
}

.section-title-row a {
  color: var(--primary);
  white-space: nowrap;
}

.process-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 32px;
}

.process-grid article {
  border: 1px solid var(--border);
  background: var(--card);
  padding: 32px;
  transition: border-color 0.18s ease;
}

.process-grid article:hover {
  border-color: var(--foreground);
}

.process-grid h3 {
  margin: 12px 0;
  font-family: "Inter Tight", Inter, sans-serif;
  font-size: 19px;
  font-weight: 800;
  letter-spacing: -0.01em;
  line-height: 1.15;
  text-transform: uppercase;
}

.process-grid span,
.features-grid p {
  color: var(--muted);
  font-size: 14px;
  line-height: 1.75;
}

.features-section {
  background: var(--secondary);
}

.features-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1px;
  background: var(--border);
}

.features-grid article {
  min-height: 190px;
  background: var(--background);
  padding: 32px;
}

.features-grid h3 {
  margin-bottom: 12px;
  font-family: "Inter Tight", Inter, sans-serif;
  font-size: 17px;
  font-weight: 800;
  letter-spacing: -0.005em;
  line-height: 1.22;
  text-transform: uppercase;
}

.inline-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-top: 40px;
  font-size: 13px;
}

.public-routes-strip {
  border-bottom: 1px solid var(--border);
  background: var(--background);
  padding: 84px 0;
}

.public-route-links {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 14px;
}

.public-route-links a {
  display: flex;
  min-height: 84px;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--border);
  background: var(--card);
  color: var(--foreground);
  font-size: 12px;
  font-weight: 900;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  transition: border-color 0.18s ease, color 0.18s ease, transform 0.18s ease;
}

.public-route-links a:hover {
  border-color: var(--primary);
  color: var(--primary);
  transform: translateY(-2px);
}

.public-route-hero {
  border-bottom: 1px solid var(--border);
  padding: 84px 0 64px;
  background: var(--background);
}

.public-route-hero .content-wrap {
  max-width: none;
}

.public-route-hero h1 {
  margin: 12px 0 20px;
  font-family: "Inter Tight", Inter, sans-serif;
  font-size: clamp(44px, 6.4vw, 84px);
  font-weight: 900;
  letter-spacing: -0.02em;
  line-height: 0.95;
  text-transform: uppercase;
}

.public-route-hero p:not(.cf-eyebrow) {
  max-width: 760px;
  color: var(--muted);
  font-size: clamp(17px, 1.6vw, 20px);
  line-height: 1.7;
}

.public-route-hero--blog {
  background: var(--background);
}

.public-blog-hero {
  padding: 76px 0 58px;
}

.public-blog-hero .content-wrap {
  max-width: none;
}

.public-blog-hero-title {
  max-width: 980px;
  margin: 22px 0 26px;
  font-size: clamp(48px, 6.3vw, 78px);
  letter-spacing: -0.035em;
  line-height: 0.92;
}

.public-blog-hero-title span {
  color: var(--primary);
}

.public-blog-hero-text {
  max-width: 680px;
  font-size: clamp(16px, 1.35vw, 18px);
  line-height: 1.65;
}

.public-route-hero--exercises {
  background: var(--background);
}

.public-exercises-hero {
  padding: 76px 0 58px;
}

.public-exercises-hero .content-wrap {
  max-width: none;
}

.public-exercises-hero-title {
  max-width: 900px;
  margin: 22px 0 26px;
  font-size: clamp(48px, 6.3vw, 78px);
  letter-spacing: -0.035em;
  line-height: 0.92;
}

.public-exercises-hero-title span {
  color: var(--primary);
}

.public-exercises-hero-text {
  max-width: 680px;
  font-size: clamp(16px, 1.35vw, 18px);
  line-height: 1.65;
}

.public-route-hero--recipes {
  background: var(--background);
}

.public-recipes-hero {
  padding: 76px 0 58px;
}

.public-recipes-hero .content-wrap {
  max-width: none;
}

.public-recipes-hero-title {
  max-width: 900px;
  margin: 22px 0 26px;
  font-size: clamp(48px, 6.3vw, 78px);
  letter-spacing: -0.035em;
  line-height: 0.92;
}

.public-recipes-hero-title span {
  color: var(--primary);
}

.public-recipes-hero-text {
  max-width: 680px;
  font-size: clamp(16px, 1.4vw, 19px);
  line-height: 1.65;
}

.public-route-hero--ranking {
  background: var(--background);
}

.public-ranking-hero {
  padding: 76px 0 58px;
}

.public-ranking-hero .content-wrap {
  max-width: none;
}

.public-ranking-hero-title {
  max-width: 900px;
  margin: 22px 0 26px;
  font-size: clamp(48px, 6.3vw, 76px);
  letter-spacing: -0.035em;
  line-height: 0.92;
}

.public-ranking-hero-title span {
  color: var(--primary);
}

.public-ranking-hero-text {
  max-width: 680px;
  font-size: clamp(16px, 1.35vw, 18px);
  line-height: 1.65;
}

.public-route-hero--shop {
  background: var(--background);
}

.public-shop-hero {
  padding: 76px 0 58px;
}

.public-shop-hero .content-wrap {
  max-width: none;
}

.public-shop-hero-title {
  max-width: 980px;
  margin: 22px 0 26px;
  font-size: clamp(52px, 7vw, 92px);
  letter-spacing: -0.035em;
  line-height: 0.9;
}

.public-shop-hero-title span {
  color: var(--primary);
}

.public-shop-hero-text {
  max-width: 720px;
  font-size: clamp(18px, 1.75vw, 21px);
  line-height: 1.65;
}

.public-route-content {
  padding: 72px 0 96px;
}

.landing-managed-section {
  border-bottom: 1px solid var(--border);
  background: var(--background);
}

.landing-managed-section--blog {
  border-top: 1px solid var(--border);
  background: var(--background);
}

.landing-managed-section--exercises {
  border-top: 1px solid var(--border);
  background: var(--background);
}

.landing-managed-section--recipes {
  border-top: 1px solid var(--border);
  background: var(--background);
}

.landing-managed-section--shop {
  border-top: 1px solid var(--border);
  background: var(--background);
}

.managed-section-description {
  max-width: 760px;
  margin: -12px 0 32px;
  color: var(--muted);
  font-size: 15px;
  line-height: 1.7;
}

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

.landing-managed-grid--shop,
.landing-managed-grid--blog {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.public-card,
.public-empty {
  min-height: 100%;
  border: 1px solid var(--border);
  background: var(--card);
  padding: 18px;
}

.public-card {
  display: flex;
  flex-direction: column;
  gap: 12px;
  transition: border-color 0.18s ease, transform 0.18s ease, box-shadow 0.18s ease;
}

.public-card:hover {
  border-color: var(--foreground);
  box-shadow: 0 18px 40px rgba(12, 17, 23, 0.08);
  transform: translateY(-2px);
}

.public-card-media {
  display: grid;
  place-items: center;
  min-height: 150px;
  margin: -18px -18px 4px;
  overflow: hidden;
  border-bottom: 1px solid var(--border);
  background: linear-gradient(135deg, rgba(244, 63, 70, 0.08), rgba(12, 17, 23, 0.04));
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
}

.public-card-media img {
  width: 100%;
  height: 100%;
  min-height: 150px;
  object-fit: cover;
}

.public-card-kicker {
  color: var(--primary);
  font-family: "JetBrains Mono", ui-monospace, SFMono-Regular, Consolas, monospace;
  font-size: 10px;
  font-weight: 900;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.public-card h3 {
  margin: 0;
  font-family: "Inter Tight", Inter, sans-serif;
  font-size: 19px;
  font-weight: 850;
  letter-spacing: -0.01em;
  line-height: 1.16;
  text-transform: uppercase;
}

.public-card p,
.public-card li,
.public-empty {
  color: var(--muted);
  font-size: 13px;
  line-height: 1.65;
}

.public-card ul {
  margin: 0;
  padding-left: 18px;
}

.public-card-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: auto;
}

.public-pill {
  display: inline-flex;
  align-items: center;
  border-radius: 999px;
  background: var(--secondary);
  padding: 5px 9px;
  color: var(--foreground);
  font-size: 11px;
  font-weight: 800;
}

.public-card-action {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 34px;
  margin-top: 4px;
  border: 1px solid var(--foreground);
  padding: 0 12px;
  color: var(--foreground);
  font-size: 12px;
  font-weight: 850;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.public-card-action:hover {
  background: var(--foreground);
  color: var(--background);
}

.public-blog-shell {
  display: grid;
  gap: 44px;
}

.public-blog-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.public-blog-tabs button {
  min-height: 28px;
  border: 1px solid var(--border);
  border-radius: 0;
  background: var(--card);
  color: var(--foreground);
  padding: 7px 13px;
  font-size: 10px;
  font-weight: 900;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  cursor: pointer;
}

.public-blog-tabs button.is-active {
  border-color: var(--foreground);
  background: var(--foreground);
  color: var(--background);
}

.public-blog-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: clamp(28px, 3.2vw, 48px);
}

.public-blog-card {
  min-width: 0;
  display: grid;
  gap: 9px;
  background: transparent;
}

.public-blog-media {
  display: grid;
  place-items: center;
  aspect-ratio: 4 / 3;
  border: 1px solid var(--border);
  background: color-mix(in srgb, var(--card) 86%, var(--secondary));
  overflow: hidden;
}

.public-blog-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.public-blog-media span {
  max-width: 82%;
  color: color-mix(in srgb, var(--muted) 28%, transparent);
  font-size: clamp(1.35rem, 2vw, 2rem);
  font-weight: 950;
  line-height: 1.05;
  text-align: center;
}

.public-blog-card small {
  margin-top: 8px;
  color: var(--primary);
  font-family: "JetBrains Mono", ui-monospace, SFMono-Regular, Consolas, monospace;
  font-size: 9px;
  font-weight: 900;
  letter-spacing: 0.34em;
  text-transform: uppercase;
}

.public-blog-card h3 {
  margin: 0;
  color: var(--foreground);
  font-size: 19px;
  font-weight: 950;
  letter-spacing: -0.045em;
  line-height: 1.05;
}

.public-blog-card p {
  margin: 0;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.55;
}

.public-blog-card footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-top: 8px;
  padding-top: 14px;
  border-top: 1px solid var(--border);
}

.public-blog-card footer span,
.public-blog-card footer a {
  color: var(--muted);
  font-family: "JetBrains Mono", ui-monospace, SFMono-Regular, Consolas, monospace;
  font-size: 9px;
  font-weight: 800;
  letter-spacing: 0.22em;
  text-transform: uppercase;
}

.public-blog-card footer a {
  color: var(--primary);
  text-decoration: none;
}

.public-exercises-shell {
  display: grid;
  gap: 44px;
}

.public-exercise-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.public-exercise-tabs button {
  min-height: 28px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  border: 1px solid var(--border);
  border-radius: 0;
  background: var(--card);
  color: var(--foreground);
  padding: 7px 13px;
  font-size: 10px;
  font-weight: 900;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  cursor: pointer;
}

.public-exercise-tabs button span,
.public-recipe-tabs button span,
.public-recipe-tags button span,
.public-recipe-ratings button span {
  min-width: 20px;
  display: inline-grid;
  place-items: center;
  border-radius: 999px;
  background: color-mix(in srgb, var(--foreground) 7%, transparent);
  color: color-mix(in srgb, currentColor 72%, transparent);
  padding: 2px 6px;
  font-family: "Inter", system-ui, sans-serif;
  font-size: 9px;
  font-weight: 950;
  letter-spacing: 0;
  line-height: 1;
}

.public-exercise-tabs button.is-active {
  border-color: var(--foreground);
  background: var(--foreground);
  color: var(--background);
}

.public-exercise-tabs button.is-active span,
.public-recipe-tabs button.is-active span,
.public-recipe-tags button.is-active span,
.public-recipe-ratings button.is-active span {
  background: color-mix(in srgb, currentColor 18%, transparent);
  color: currentColor;
}

.public-exercises-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: clamp(28px, 3.2vw, 48px);
}

.public-exercise-card {
  min-width: 0;
  display: grid;
  gap: 9px;
  background: transparent;
}

.public-exercise-media {
  position: relative;
  display: grid;
  place-items: center;
  aspect-ratio: 16 / 9;
  border: 1px solid var(--border);
  background: color-mix(in srgb, var(--card) 86%, var(--secondary));
  overflow: hidden;
}

.public-exercise-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.public-exercise-media > span {
  max-width: 80%;
  color: color-mix(in srgb, var(--muted) 28%, transparent);
  font-size: clamp(1.45rem, 2.2vw, 2rem);
  font-weight: 950;
  text-align: center;
}

.public-exercise-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-top: 8px;
}

.public-exercise-meta small {
  color: var(--foreground);
  font-family: "JetBrains Mono", ui-monospace, SFMono-Regular, Consolas, monospace;
  font-size: 9px;
  font-weight: 900;
  letter-spacing: 0.34em;
  text-transform: uppercase;
}

.public-exercise-meta span {
  border-radius: 4px;
  background: color-mix(in srgb, var(--primary) 14%, var(--secondary));
  color: var(--primary);
  padding: 5px 8px;
  font-size: 8px;
  font-weight: 900;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.public-exercise-card h3 {
  margin: 0;
  color: var(--foreground);
  font-size: 18px;
  font-weight: 950;
  letter-spacing: -0.04em;
  line-height: 1.05;
  text-transform: uppercase;
}

.public-exercise-card h3:first-letter {
  color: var(--primary);
}

.public-exercise-card p {
  margin: 0;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.55;
}

.public-exercise-link {
  width: fit-content;
  margin-top: 2px;
  color: var(--primary);
  font-size: 10px;
  font-weight: 900;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.public-recipes-shell {
  display: grid;
  gap: 44px;
}

.public-recipe-controls {
  display: grid;
  gap: 18px;
}

.public-recipe-tabs,
.public-recipe-tags,
.public-recipe-ratings {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.public-recipe-tabs button,
.public-recipe-tags button,
.public-recipe-ratings button {
  min-height: 28px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  border: 1px solid var(--border);
  border-radius: 0;
  background: var(--card);
  color: var(--foreground);
  padding: 7px 13px;
  font-size: 10px;
  font-weight: 900;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  cursor: pointer;
}

.public-recipe-tabs button.is-active {
  border-color: var(--foreground);
  background: var(--foreground);
  color: var(--background);
}

.public-recipe-tags button,
.public-recipe-ratings button {
  min-height: 24px;
  border-color: transparent;
  border-radius: 999px;
  background: var(--secondary);
  padding: 6px 12px;
  font-size: 9px;
}

.public-recipe-tags button.is-active {
  background: var(--primary);
  color: #fff;
}

.public-recipe-ratings button {
  border-color: color-mix(in srgb, #f43f46 18%, transparent);
  background: color-mix(in srgb, #f43f46 8%, var(--secondary));
}

.public-recipe-ratings button::before {
  content: "\2605";
  margin-right: 5px;
  color: var(--primary);
}

.public-recipe-ratings button.is-active {
  border-color: var(--primary);
  background: var(--primary);
  color: #fff;
}

.public-recipe-ratings button.is-active::before {
  color: #fff;
}

.public-recipes-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: clamp(28px, 3.2vw, 48px);
}

.public-recipe-card {
  min-width: 0;
  display: grid;
  gap: 9px;
  background: transparent;
  cursor: pointer;
}

.public-recipe-card:focus-visible {
  outline: 2px solid var(--primary);
  outline-offset: 8px;
}

.public-recipe-media {
  position: relative;
  display: grid;
  place-items: center;
  aspect-ratio: 4 / 3;
  border: 1px solid var(--border);
  background: color-mix(in srgb, var(--card) 86%, var(--secondary));
  overflow: hidden;
}

.public-recipe-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.public-recipe-media span {
  max-width: 80%;
  color: color-mix(in srgb, var(--muted) 28%, transparent);
  font-size: clamp(1.45rem, 2.2vw, 2rem);
  font-weight: 950;
  text-align: center;
}

.public-recipe-card small {
  margin-top: 8px;
  color: var(--primary);
  font-family: "JetBrains Mono", ui-monospace, SFMono-Regular, Consolas, monospace;
  font-size: 9px;
  font-weight: 900;
  letter-spacing: 0.34em;
  text-transform: uppercase;
}

.public-recipe-card h3 {
  margin: 0;
  color: var(--foreground);
  font-size: 18px;
  font-weight: 950;
  letter-spacing: -0.04em;
  line-height: 1.05;
  text-transform: uppercase;
}

.public-recipe-rating {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 7px;
  color: var(--muted);
  font-size: 12px;
}

.public-recipe-card > .public-recipe-rating {
  display: none;
}

.public-recipe-rating-badge {
  position: absolute;
  top: 10px;
  right: 10px;
  z-index: 2;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  min-height: 30px;
  padding: 6px 9px;
  border: 1px solid color-mix(in srgb, #f43f46 28%, var(--border));
  border-radius: 999px;
  background: color-mix(in srgb, var(--background) 88%, transparent);
  color: var(--foreground);
  box-shadow: 0 12px 24px rgba(2, 6, 23, 0.12);
  font-family: Inter, system-ui, sans-serif;
  font-size: 12px;
  line-height: 1;
  backdrop-filter: blur(10px);
}

.public-recipe-rating-badge span {
  color: #f43f46;
  font-size: 14px;
}

.public-recipe-rating-badge strong {
  color: inherit;
  font-size: 13px;
  font-weight: 950;
}

.public-recipe-rating-badge small {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 18px;
  height: 18px;
  padding: 0 5px;
  border-radius: 999px;
  background: color-mix(in srgb, #f43f46 12%, transparent);
  color: #f43f46;
  font-size: 10px;
  font-weight: 900;
}

.public-recipe-rating-badge--empty {
  border-color: color-mix(in srgb, var(--muted) 22%, var(--border));
  color: var(--muted);
}

.public-recipe-rating strong {
  color: var(--foreground);
  font-weight: 950;
}

.public-recipe-rating--empty {
  color: color-mix(in srgb, var(--muted) 78%, transparent);
  font-size: 11px;
}

.public-recipe-stars {
  display: inline-flex;
  gap: 1px;
  color: color-mix(in srgb, var(--muted) 38%, transparent);
  line-height: 1;
}

.public-recipe-stars .is-filled {
  color: #f43f46;
}

.public-recipe-comments {
  display: grid;
  gap: 8px;
  margin-top: 2px;
}

.public-recipe-comments blockquote {
  margin: 0;
  padding: 9px 0 0;
  border-top: 1px solid var(--border);
}

.public-recipe-comments p {
  margin: 0;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.45;
}

.public-recipe-comments cite {
  display: block;
  margin-top: 5px;
  color: var(--foreground);
  font-size: 9px;
  font-style: normal;
  font-weight: 900;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.public-recipe-macros {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
  margin: 2px 0 0;
  padding: 13px 0 0;
  border-top: 1px solid var(--border);
}

.public-recipe-macros div,
.public-recipe-macros dt,
.public-recipe-macros dd {
  margin: 0;
}

.public-recipe-macros div {
  display: grid;
  gap: 3px;
  text-align: center;
}

.public-recipe-macros dt {
  color: var(--muted);
  font-family: "JetBrains Mono", ui-monospace, SFMono-Regular, Consolas, monospace;
  font-size: 8px;
  font-weight: 900;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.public-recipe-macros dd {
  color: var(--foreground);
  font-size: 13px;
  font-weight: 950;
}

body.public-modal-open {
  overflow: hidden;
}

.public-recipe-modal-overlay {
  position: fixed;
  inset: 0;
  z-index: 120;
  display: grid;
  place-items: center;
  padding: 24px;
  background: rgba(2, 6, 23, 0.48);
  backdrop-filter: blur(6px);
}

.public-recipe-modal {
  width: min(980px, 100%);
  max-height: min(860px, calc(100vh - 48px));
  display: grid;
  grid-template-rows: auto minmax(0, 1fr);
  border: 1px solid var(--border);
  background: var(--background);
  color: var(--foreground);
  box-shadow: 0 30px 80px rgba(2, 6, 23, 0.22);
  overflow: hidden;
}

.public-recipe-modal-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 18px;
  padding: clamp(22px, 3vw, 34px);
  border-bottom: 1px solid var(--border);
}

.public-recipe-modal-header small {
  display: block;
  margin-bottom: 8px;
  color: var(--primary);
  font-family: "JetBrains Mono", ui-monospace, SFMono-Regular, Consolas, monospace;
  font-size: 10px;
  font-weight: 900;
  letter-spacing: 0.34em;
  text-transform: uppercase;
}

.public-recipe-modal-header h2 {
  margin: 0;
  max-width: 760px;
  color: var(--foreground);
  font-size: clamp(28px, 4vw, 52px);
  font-weight: 950;
  letter-spacing: 0.02em;
  line-height: 0.95;
  text-transform: uppercase;
}

.public-recipe-modal-header button {
  width: 42px;
  height: 42px;
  flex: 0 0 auto;
  border: 1px solid var(--border);
  background: var(--card);
  color: var(--foreground);
  font-size: 26px;
  line-height: 1;
  cursor: pointer;
}

.public-recipe-modal-body {
  min-height: 0;
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(300px, 0.95fr);
  gap: 18px;
  padding: clamp(18px, 2.4vw, 28px);
  overflow: auto;
  overscroll-behavior: contain;
}

.public-recipe-modal-panel {
  min-width: 0;
  border: 1px solid var(--border);
  background: var(--card);
  padding: clamp(18px, 2.2vw, 24px);
}

.public-recipe-modal-panel h3 {
  margin: 0 0 14px;
  color: var(--foreground);
  font-size: 19px;
  font-weight: 950;
}

.public-recipe-modal-panel p,
.public-recipe-modal-panel li {
  color: var(--muted);
  font-size: 15px;
  line-height: 1.65;
}

.public-recipe-modal-panel ul,
.public-recipe-modal-panel ol {
  margin: 0;
  padding-left: 20px;
}

.public-recipe-modal-visual {
  min-height: 340px;
  display: grid;
  place-items: center;
  padding: 0;
  overflow: hidden;
}

.public-recipe-modal-visual img,
.public-recipe-video-frame,
.public-recipe-video-frame iframe {
  width: 100%;
  height: 100%;
}

.public-recipe-modal-visual img {
  object-fit: cover;
}

.public-recipe-video-frame {
  aspect-ratio: 16 / 9;
}

.public-recipe-video-frame iframe {
  display: block;
  border: 0;
}

.public-recipe-modal-placeholder {
  width: 100%;
  height: 100%;
  min-height: 340px;
  display: grid;
  place-items: center;
  background: color-mix(in srgb, var(--card) 86%, var(--secondary));
  color: color-mix(in srgb, var(--muted) 28%, transparent);
  font-size: clamp(2rem, 5vw, 4.4rem);
  font-weight: 950;
  text-align: center;
}

.public-recipe-modal-summary {
  align-content: start;
  display: grid;
  gap: 18px;
}

.public-recipe-modal-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.public-recipe-modal-tags span {
  padding: 7px 10px;
  border-radius: 999px;
  background: color-mix(in srgb, var(--primary) 10%, transparent);
  color: var(--primary);
  font-size: 11px;
  font-weight: 900;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.public-recipe-modal-macros {
  margin-top: 0;
}

.public-recipe-modal-benefits {
  grid-column: 1 / -1;
  border-color: color-mix(in srgb, var(--primary) 28%, var(--border));
  background: color-mix(in srgb, var(--primary) 6%, var(--card));
}

.public-shop-shell {
  display: grid;
  gap: 24px;
}

.public-shop-controls {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 14px 24px;
  align-items: end;
}

.public-shop-filter-group {
  display: grid;
  gap: 8px;
}

.public-shop-filter-group:first-child {
  grid-column: 1 / -1;
}

.public-shop-filter-group:nth-child(2) {
  grid-column: 1 / 2;
  grid-row: 2;
}

.public-shop-filter-group p {
  margin: 0;
  color: var(--muted);
  font-family: "JetBrains Mono", ui-monospace, SFMono-Regular, Consolas, monospace;
  font-size: 10px;
  font-weight: 900;
  letter-spacing: 0.36em;
  text-transform: uppercase;
}

.public-shop-tabs,
.public-shop-goals {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.public-shop-tabs button,
.public-shop-goals button,
.public-shop-cart {
  min-height: 28px;
  border: 1px solid var(--border);
  border-radius: 0;
  background: var(--card);
  color: var(--foreground);
  padding: 7px 13px;
  font-size: 10px;
  font-weight: 900;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  cursor: pointer;
}

.public-shop-tabs button.is-active {
  border-color: var(--foreground);
  background: var(--foreground);
  color: var(--background);
}

.public-shop-goals button {
  border-color: transparent;
  border-radius: 999px;
  background: var(--secondary);
}

.public-shop-goals button.is-active {
  background: var(--primary);
  color: #fff;
}

.public-shop-cart {
  min-height: 39px;
  border-color: var(--foreground);
  grid-column: 2 / 3;
  grid-row: 2;
  justify-self: end;
  padding: 9px 18px;
}

.public-shop-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(210px, 250px));
  justify-content: start;
  align-items: start;
  gap: clamp(16px, 1.8vw, 24px);
}

.public-shop-card {
  display: grid;
  min-width: 0;
  gap: 9px;
  border: 1px solid var(--border);
  border-radius: 10px;
  background: var(--card);
  padding: 10px;
  box-shadow: 0 14px 30px color-mix(in srgb, var(--foreground) 7%, transparent);
  transition: border-color 0.18s ease, box-shadow 0.18s ease, transform 0.18s ease;
}

.public-shop-card:hover {
  border-color: color-mix(in srgb, var(--primary) 55%, var(--border));
  box-shadow: 0 18px 36px color-mix(in srgb, var(--foreground) 12%, transparent);
  transform: translateY(-2px);
}

.public-shop-card__media {
  display: grid;
  place-items: center;
  min-height: 150px;
  max-height: 180px;
  aspect-ratio: 1 / 0.82;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: linear-gradient(135deg, color-mix(in srgb, var(--card) 92%, var(--secondary)), color-mix(in srgb, var(--card) 72%, var(--secondary)));
  overflow: hidden;
}

.public-shop-card__media img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  padding: 10px;
}

.public-shop-card__media span {
  max-width: 82%;
  color: color-mix(in srgb, var(--muted) 28%, transparent);
  font-size: clamp(1.4rem, 2.2vw, 2rem);
  font-weight: 950;
  text-align: center;
}

.public-shop-card small {
  color: var(--muted);
  font-family: "JetBrains Mono", ui-monospace, SFMono-Regular, Consolas, monospace;
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0.34em;
  text-transform: uppercase;
}

.public-shop-card h3 {
  margin: 0;
  color: var(--foreground);
  font-size: 16px;
  font-weight: 900;
  line-height: 1.2;
}

.public-shop-card strong {
  color: var(--primary);
  font-size: 19px;
  line-height: 1;
}

.public-shop-card a,
.public-shop-card button {
  min-height: 34px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--foreground);
  border-radius: 0;
  background: transparent;
  color: var(--foreground);
  font-size: 10px;
  font-weight: 900;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  text-decoration: none;
  padding: 8px 10px;
  cursor: pointer;
}

.public-shop-card a:hover,
.public-shop-card button:hover {
  background: var(--foreground);
  color: var(--background);
}

.public-cart-overlay {
  position: fixed;
  inset: 0;
  z-index: 90;
  pointer-events: none;
  background: rgba(12, 17, 23, 0);
  transition: background 0.22s ease;
}

.public-cart-overlay.is-open {
  pointer-events: auto;
  background: rgba(12, 17, 23, 0.42);
}

.public-cart-drawer {
  position: fixed;
  top: 0;
  right: 0;
  z-index: 100;
  width: min(100%, 460px);
  height: 100vh;
  display: grid;
  grid-template-rows: auto 1fr auto;
  border-left: 1px solid var(--border);
  background: var(--background);
  box-shadow: -30px 0 80px rgba(12, 17, 23, 0.18);
  transform: translateX(104%);
  transition: transform 0.24s ease;
}

.public-cart-drawer.is-open {
  transform: translateX(0);
}

.public-cart-drawer header,
.public-cart-drawer footer {
  padding: 24px;
  background: var(--background);
}

.public-cart-drawer header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid var(--border);
}

.public-cart-drawer h2 {
  margin: 0;
  font-family: "Inter Tight", Inter, sans-serif;
  font-size: 24px;
  font-weight: 950;
  letter-spacing: -0.04em;
  line-height: 1;
  text-transform: uppercase;
}

.public-cart-drawer header button {
  width: 36px;
  height: 36px;
  border: 0;
  background: transparent;
  color: var(--foreground);
  font-size: 34px;
  line-height: 1;
  cursor: pointer;
}

.public-cart-body {
  min-height: 0;
  overflow-y: auto;
  padding: 24px;
}

.public-cart-empty {
  margin: 44px 0 0;
  color: var(--muted);
  text-align: center;
}

.public-cart-list {
  display: grid;
  gap: 16px;
}

.public-cart-item {
  display: grid;
  grid-template-columns: 76px minmax(0, 1fr);
  gap: 14px;
  border-bottom: 1px solid var(--border);
  padding-bottom: 16px;
}

.public-cart-item__media {
  width: 76px;
  height: 76px;
  display: grid;
  place-items: center;
  border: 1px solid var(--border);
  background: color-mix(in srgb, var(--card) 86%, var(--secondary));
  overflow: hidden;
}

.public-cart-item__media img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  padding: 7px;
}

.public-cart-item__media span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
}

.public-cart-item__content {
  min-width: 0;
  display: grid;
  gap: 4px;
}

.public-cart-item__content small {
  color: var(--muted);
  font-family: "JetBrains Mono", ui-monospace, SFMono-Regular, Consolas, monospace;
  font-size: 9px;
  font-weight: 900;
  letter-spacing: 0.22em;
  text-transform: uppercase;
}

.public-cart-item__content strong {
  color: var(--foreground);
  font-size: 15px;
  line-height: 1.2;
}

.public-cart-item__content span {
  color: var(--primary);
  font-size: 15px;
  font-weight: 900;
}

.public-cart-item__content a {
  width: fit-content;
  color: var(--foreground);
  font-size: 10px;
  font-weight: 900;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.public-cart-item__actions {
  grid-column: 2;
  display: flex;
  align-items: center;
  gap: 8px;
}

.public-cart-item__actions button {
  min-width: 30px;
  min-height: 30px;
  border: 1px solid var(--border);
  background: var(--card);
  color: var(--foreground);
  font-weight: 900;
  cursor: pointer;
}

.public-cart-item__actions button:last-child {
  margin-left: auto;
  padding: 0 10px;
  color: var(--primary);
  font-size: 10px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.public-cart-item__actions b {
  min-width: 18px;
  text-align: center;
}

.public-cart-notice {
  margin: 18px 0 0;
  border: 1px solid color-mix(in srgb, var(--primary) 32%, var(--border));
  background: color-mix(in srgb, var(--primary) 8%, var(--background));
  padding: 12px;
  color: var(--foreground);
  font-size: 13px;
}

.public-cart-drawer footer {
  border-top: 1px solid var(--border);
}

.public-cart-total {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 18px;
}

.public-cart-total span {
  color: var(--muted);
  font-family: "JetBrains Mono", ui-monospace, SFMono-Regular, Consolas, monospace;
  font-size: 10px;
  font-weight: 900;
  letter-spacing: 0.34em;
  text-transform: uppercase;
}

.public-cart-total strong {
  color: var(--foreground);
  font-size: 26px;
  font-weight: 950;
}

.public-cart-drawer footer button {
  width: 100%;
  min-height: 48px;
  border: 0;
  background: var(--primary);
  color: #fff;
  font-size: 12px;
  font-weight: 950;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  cursor: pointer;
}

.public-cart-drawer footer button:disabled {
  cursor: not-allowed;
  opacity: 0.45;
}

.public-video-link {
  border-color: var(--primary);
  color: var(--primary);
}

.public-empty {
  display: grid;
  min-height: 160px;
  place-items: center;
  text-align: center;
}

.is-public-hidden {
  display: none !important;
}

.ranking-section {
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  background: var(--background);
}

.ranking-wrap {
  width: min(100%, var(--container));
  margin: 0 auto;
  padding-inline: var(--pad);
}

.ranking-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  margin-bottom: 46px;
}

.ranking-toolbar p {
  margin: 0;
  color: var(--muted);
  font-family: "JetBrains Mono", ui-monospace, SFMono-Regular, Consolas, monospace;
  font-size: 10px;
  font-weight: 900;
  letter-spacing: 0.34em;
  text-transform: uppercase;
}

.ranking-toolbar strong {
  color: var(--foreground);
}

.ranking-period-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 0;
}

.ranking-period-tabs button {
  min-height: 28px;
  border: 1px solid var(--border);
  border-left-width: 0;
  background: var(--card);
  color: var(--foreground);
  padding: 7px 14px;
  font-size: 9px;
  font-weight: 900;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  cursor: pointer;
}

.ranking-period-tabs button:first-child {
  border-left-width: 1px;
}

.ranking-period-tabs button.is-active {
  border-color: var(--foreground);
  background: var(--foreground);
  color: var(--background);
}

.ranking-table-wrap {
  overflow-x: auto;
}

.ranking-table {
  width: 100%;
  min-width: 760px;
  border-collapse: collapse;
  text-align: left;
}

.ranking-table thead tr {
  border-bottom: 1px solid var(--border);
  color: var(--muted);
  font-family: "JetBrains Mono", ui-monospace, SFMono-Regular, Consolas, monospace;
  font-size: 11px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.ranking-table th,
.ranking-table td {
  padding: 20px 8px;
  vertical-align: middle;
}

.ranking-table tbody tr {
  border-bottom: 1px solid var(--border);
  transition: background 0.18s ease;
}

.ranking-table tbody tr:hover {
  background: var(--secondary);
}

.ranking-table td:first-child {
  color: var(--primary);
  font-family: "Inter Tight", Inter, sans-serif;
  font-size: 24px;
  font-weight: 900;
}

.ranking-table td:nth-child(2) {
  font-weight: 800;
}

.ranking-user {
  display: inline-flex;
  align-items: center;
  gap: 13px;
}

.ranking-avatar {
  width: 31px;
  height: 31px;
  display: inline-grid;
  place-items: center;
  border-radius: 999px;
  background: var(--secondary);
  color: var(--foreground);
  font-size: 10px;
  font-weight: 900;
}

.ranking-table td:nth-child(4) {
  color: var(--muted);
  font-size: 13px;
}

.policy-page {
  background: var(--background);
}

.policy-hero {
  border-bottom: 1px solid var(--border);
  padding: 80px 0 58px;
}

.policy-hero h1 {
  max-width: 900px;
  margin: 18px 0 22px;
  font-family: "Inter Tight", Inter, sans-serif;
  font-size: clamp(44px, 6vw, 78px);
  font-weight: 950;
  letter-spacing: -0.025em;
  line-height: 0.94;
  text-transform: uppercase;
}

.policy-hero h1 span {
  color: var(--primary);
}

.policy-hero p:not(.cf-eyebrow) {
  max-width: 780px;
  color: var(--muted);
  font-size: clamp(16px, 1.4vw, 19px);
  line-height: 1.7;
}

.policy-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 28px;
}

.policy-meta span,
.policy-section a:not(.policy-back) {
  border-radius: 999px;
  background: var(--secondary);
  padding: 7px 11px;
  color: var(--foreground);
  font-size: 12px;
  font-weight: 800;
}

.policy-content {
  padding: 54px 0 96px;
}

.policy-layout {
  display: grid;
  grid-template-columns: 230px minmax(0, 1fr);
  gap: 34px;
  align-items: start;
}

.policy-toc {
  position: sticky;
  top: 88px;
  display: grid;
  gap: 8px;
  border: 1px solid var(--border);
  background: var(--card);
  padding: 14px;
}

.policy-toc a {
  border-bottom: 1px solid var(--border);
  padding: 10px 4px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 800;
}

.policy-toc a:last-child {
  border-bottom: 0;
}

.policy-toc a:hover {
  color: var(--primary);
}

.policy-card {
  display: grid;
  gap: 18px;
}

.policy-section {
  border: 1px solid var(--border);
  background: var(--card);
  padding: clamp(22px, 3vw, 34px);
}

.policy-section h2 {
  margin: 0 0 14px;
  font-family: "Inter Tight", Inter, sans-serif;
  font-size: clamp(22px, 2vw, 30px);
  font-weight: 900;
  letter-spacing: -0.02em;
  line-height: 1.05;
  text-transform: uppercase;
}

.policy-section p,
.policy-section li {
  color: var(--muted);
  font-size: 15px;
  line-height: 1.78;
}

.policy-section p:last-child,
.policy-section ul:last-child {
  margin-bottom: 0;
}

.policy-section ul {
  padding-left: 20px;
}

.policy-section a:not(.policy-back) {
  display: inline-flex;
  margin: 0 2px;
  padding: 2px 7px;
  color: var(--primary);
}

.policy-highlight {
  display: grid;
  gap: 7px;
  margin-top: 20px;
  border-left: 4px solid var(--primary);
  background: color-mix(in srgb, var(--primary) 7%, var(--background));
  padding: 16px 18px;
}

.policy-highlight strong {
  color: var(--foreground);
  font-size: 15px;
}

.policy-highlight span {
  color: var(--muted);
  font-size: 14px;
  line-height: 1.65;
}

.policy-table {
  display: grid;
  border: 1px solid var(--border);
}

.policy-table > div {
  display: grid;
  grid-template-columns: minmax(120px, 210px) minmax(0, 1fr);
  gap: 18px;
  border-bottom: 1px solid var(--border);
  padding: 15px 16px;
}

.policy-table > div:last-child {
  border-bottom: 0;
}

.policy-table strong {
  color: var(--foreground);
  font-size: 14px;
}

.policy-table span {
  color: var(--muted);
  font-size: 14px;
  line-height: 1.65;
}

.policy-back {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 42px;
  margin-top: 10px;
  border: 1px solid var(--foreground);
  padding: 0 18px;
  color: var(--foreground);
  font-size: 12px;
  font-weight: 900;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.policy-back:hover {
  background: var(--foreground);
  color: var(--background);
}

.ranking-table th:last-child,
.ranking-table td:last-child {
  text-align: right;
  font-family: "JetBrains Mono", ui-monospace, SFMono-Regular, Consolas, monospace;
  font-weight: 800;
}

.level {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 5px;
  min-width: 58px;
  min-height: 24px;
  background: #f3f0ea;
  padding: 5px 9px;
  color: var(--foreground);
  font-size: 8px;
  font-weight: 900;
  line-height: 1;
  text-transform: uppercase;
}

.level--start {
  background: #dff9f2;
  color: #00a98f;
}

.level--constant {
  background: #f8e8da;
  color: #c26722;
}

.level--disciplined {
  background: #fff0cd;
  color: #d98908;
}

.level--veteran {
  background: #e9edf2;
  color: #718093;
}

.level--athlete {
  background: #eee2ff;
  color: #9d6cff;
}

.level--titan {
  background: #fde2df;
  color: var(--primary);
}

.final-cta__grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 48px;
  align-items: center;
}

.final-cta h2 {
  font-size: clamp(36px, 4.6vw, 58px);
}

.final-cta p {
  margin-bottom: 32px;
  font-size: 18px;
  line-height: 1.75;
}

.final-cta .primary-cta:hover {
  background: var(--background);
  color: var(--foreground);
}

.site-footer {
  border-top: 1px solid var(--border);
  background: var(--background);
  padding: 80px 0 40px;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 64px;
  margin-bottom: 64px;
}

.footer-note h4 {
  display: inline-block;
  margin-bottom: 24px;
  font-family: "Inter Tight", Inter, sans-serif;
  font-size: 24px;
  font-style: italic;
  font-weight: 900;
  letter-spacing: -0.02em;
  line-height: 1;
  text-decoration: underline;
  text-decoration-color: var(--primary);
  text-decoration-thickness: 2px;
  text-underline-offset: 5px;
  text-transform: uppercase;
}

.footer-note p {
  max-width: 68ch;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.75;
}

.footer-note blockquote {
  margin: 24px 0 0;
  font-style: italic;
}

.footer-links {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 32px;
}

.footer-links .cf-eyebrow {
  margin-bottom: 16px;
  font-weight: 800;
}

.footer-links a {
  display: block;
  margin-bottom: 9px;
  color: var(--muted);
  font-size: 14px;
}

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

.footer-bottom {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  border-top: 1px solid var(--border);
  padding-top: 40px;
}

.footer-bottom p {
  margin: 0;
  color: var(--muted);
  font-family: "JetBrains Mono", ui-monospace, SFMono-Regular, Consolas, monospace;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.cf-reveal {
  animation: reveal-up 0.72s ease both;
}

.daily-card.cf-reveal {
  animation-delay: 0.2s;
}

@keyframes reveal-up {
  from {
    opacity: 0;
    transform: translateY(12px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@media (max-width: 1100px) {
  .main-nav {
    display: none;
  }

  .main-nav.is-open {
    position: absolute;
    top: 64px;
    left: 0;
    right: 0;
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0;
    border-bottom: 1px solid var(--border);
    background: var(--background);
    padding: 12px var(--pad);
    box-shadow: 0 18px 40px rgba(12, 17, 23, 0.12);
  }

  .main-nav.is-open a {
    padding: 12px;
  }

  .menu-button {
    display: grid;
  }

  .hero-inner {
    grid-template-columns: 1fr;
  }

  .policy-layout {
    grid-template-columns: 1fr;
  }

  .policy-toc {
    position: static;
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .daily-card {
    max-width: 720px;
  }

  .need-grid,
  .process-grid,
  .features-grid,
  .public-route-links,
  .landing-managed-grid,
  .landing-managed-grid--shop,
  .landing-managed-grid--blog,
  .public-blog-grid,
  .public-exercises-grid,
  .public-recipes-grid,
  .public-shop-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .public-shop-grid {
    grid-template-columns: repeat(auto-fill, minmax(210px, 250px));
  }

  .public-shop-controls {
    grid-template-columns: 1fr;
  }

  .public-shop-cart {
    width: fit-content;
    grid-column: 1;
    grid-row: auto;
    justify-self: start;
  }

  .public-recipe-modal-body {
    grid-template-columns: 1fr;
  }

  .public-recipe-modal-visual {
    min-height: 300px;
  }
}

@media (max-width: 760px) {
  :root {
    --pad: 18px;
  }

  .admin-link,
  .start-button {
    display: none;
  }

  .main-nav.is-open {
    grid-template-columns: 1fr;
  }

  .hero-section,
  .need-section,
  .process-section,
  .features-section,
  .public-routes-strip,
  .landing-managed-section,
  .ranking-section,
  .final-cta {
    padding: 64px 0;
  }

  .hero-copy h1 {
    font-size: clamp(42px, 13vw, 62px);
  }

  .hero-text {
    font-size: 17px;
  }

  .primary-cta,
  .outline-cta {
    width: 100%;
  }

  .daily-card {
    padding: 22px;
  }

  .daily-card__header,
  .section-title-row,
  .footer-bottom {
    align-items: flex-start;
    flex-direction: column;
  }

  .daily-card__goal {
    text-align: left;
  }

  .ranking-toolbar {
    align-items: flex-start;
    flex-direction: column;
    margin-bottom: 28px;
  }

  .macro-grid,
  .mini-stats,
  .section-split-heading,
  .need-grid,
  .process-grid,
  .features-grid,
  .public-route-links,
  .landing-managed-grid,
  .landing-managed-grid--shop,
  .landing-managed-grid--blog,
  .public-blog-grid,
  .public-exercises-grid,
  .public-recipes-grid,
  .public-shop-grid,
  .final-cta__grid,
  .footer-grid,
  .footer-links {
    grid-template-columns: 1fr;
  }

  .policy-table > div {
    grid-template-columns: 1fr;
    gap: 6px;
  }

  .policy-toc {
    grid-template-columns: 1fr;
  }

  .section-split-heading {
    margin-bottom: 42px;
  }

  .section-split-heading h2,
  .section-title-row h2,
  .final-cta h2 {
    font-size: clamp(30px, 9vw, 40px);
  }

  .need-grid,
  .process-grid {
    gap: 22px;
  }

  .public-shop-card {
    grid-template-columns: 112px minmax(0, 1fr);
    align-items: stretch;
    gap: 8px 12px;
  }

  .public-shop-card__media {
    grid-row: 1 / span 4;
    min-height: 112px;
    max-height: none;
    aspect-ratio: 1;
  }

  .public-shop-card small,
  .public-shop-card h3,
  .public-shop-card strong,
  .public-shop-card a,
  .public-shop-card button {
    grid-column: 2;
  }

  .public-shop-card a,
  .public-shop-card button {
    align-self: end;
  }

  .process-grid article,
  .features-grid article,
  .public-card {
    padding: 24px;
  }

  .public-card-media {
    margin: -24px -24px 4px;
  }

  .public-recipe-modal-overlay {
    padding: 10px;
  }

  .public-recipe-modal {
    max-height: calc(100vh - 20px);
  }

  .public-recipe-modal-header {
    padding: 18px;
  }

  .public-recipe-modal-header h2 {
    font-size: clamp(24px, 9vw, 36px);
  }

  .public-recipe-modal-body {
    gap: 12px;
    padding: 12px;
  }

  .public-recipe-modal-panel {
    padding: 16px;
  }

  .public-recipe-modal-visual,
  .public-recipe-modal-placeholder {
    min-height: 240px;
  }

  .footer-grid {
    gap: 42px;
  }
}
