.layout-public {
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
}
.layout-public main {
  flex: 1;
  display: flex;
  flex-direction: column;
}
.layout-public .container { max-width: 1080px; margin: 0 auto; padding: 0 16px; }

.public-header {
  display: flex; align-items: center; justify-content: space-between;
  padding: 10px 20px; background: #fff; border-bottom: 2px solid #0f2942;
  position: sticky; top: 0; z-index: 20;
}
.public-nav { display: flex; gap: 12px; align-items: center; flex-wrap: wrap; }
.public-nav a { color: #475569; text-decoration: none; font-size: 0.92rem; }
.public-nav a:not(.btn):hover { color: #0f2942; }
.public-nav-logout { margin: 0; display: inline; }
.public-nav-logout-btn {
  border: none;
  background: none;
  padding: 0;
  font: inherit;
  color: #475569;
  font-size: 0.92rem;
  cursor: pointer;
  text-decoration: none;
}
.public-nav-logout-btn:hover { color: #0f2942; }

.public-footer {
  text-align: center; padding: 20px 16px 28px; color: #64748b; font-size: 0.82rem;
  border-top: 1px solid #cbd5e1; margin-top: auto; background: #fff;
}
.public-footer .footer-links { margin: 0 0 8px; }
.public-footer .footer-links a { color: #0f2942; text-decoration: none; }
.site-legal { margin: 8px 0 0; color: #94a3b8; font-size: 0.78rem; line-height: 1.6; }

.landing-shell {
  flex: 1;
  background: linear-gradient(180deg, #f8fafc 0%, #f1f5f9 55%, #eef2f7 100%);
  border-bottom: 1px solid #cbd5e1;
}
.landing-hero { padding: 28px 16px 32px; }
.hero-grid { display: grid; gap: 20px; align-items: start; }
@media (min-width: 768px) {
  .hero-grid { grid-template-columns: 1fr 1.15fr; }
}
.landing-hero-grid {
  align-items: center;
  gap: 28px 36px;
}
@media (min-width: 768px) {
  .landing-hero-grid {
    min-height: min(72vh, 640px);
  }
}
.landing-brand-mark {
  --needle-x: 50.9%;
  --needle-y: 49.1%;
  --needle-angle: -42deg;
  position: relative;
  width: min(100%, 320px);
  margin: 0 auto;
  justify-self: center;
}
@media (min-width: 768px) {
  .landing-brand-mark {
    width: min(100%, 500px);
    margin: 0;
    justify-self: end;
  }
}
.landing-brand-mark__svg {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 1;
  overflow: visible;
}
.landing-dal {
  filter: drop-shadow(0 10px 28px rgba(15, 46, 77, 0.12));
}
.landing-diamond-cta {
  cursor: pointer;
  outline: none;
}
.landing-needle {
  transition: fill 0.18s ease, filter 0.18s ease;
  pointer-events: none;
}
.landing-needle--light {
  fill: #f97b2d;
}
.landing-needle--dark {
  fill: #e5601a;
}
@keyframes landing-diamond-glow {
  0%,
  100% {
    filter: drop-shadow(0 2px 8px rgba(249, 123, 45, 0.22));
  }
  50% {
    filter: drop-shadow(0 10px 26px rgba(249, 123, 45, 0.48));
  }
}
@media (prefers-reduced-motion: no-preference) {
  .landing-diamond-cta .landing-needle--light {
    animation: landing-diamond-glow 2.8s ease-in-out infinite;
  }
}
@media (prefers-reduced-motion: reduce) {
  .landing-diamond-cta .landing-needle--light {
    filter: drop-shadow(0 4px 14px rgba(249, 123, 45, 0.3));
  }
}
.landing-diamond-cta:hover .landing-needle--light,
.landing-diamond-cta:focus-visible .landing-needle--light {
  fill: #f0701f;
  filter: drop-shadow(0 6px 18px rgba(249, 123, 45, 0.55));
  animation: none;
}
.landing-diamond-cta:hover .landing-needle--dark,
.landing-diamond-cta:focus-visible .landing-needle--dark {
  fill: #c95510;
}
.landing-diamond-cta:focus-visible .landing-needle--light {
  stroke: #0f2942;
  stroke-width: 6px;
}
.landing-diamond-cta__hit {
  pointer-events: all;
}
.landing-diamond-cta__label {
  position: absolute;
  left: var(--needle-x);
  top: var(--needle-y);
  z-index: 1;
  width: 7.5rem;
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  font-family: "Vazirmatn", Tahoma, sans-serif;
  font-size: clamp(0.68rem, 2.4vw, 0.82rem);
  font-weight: 700;
  line-height: 1.35;
  text-align: center;
  color: #fff;
  pointer-events: none;
  transform: translate(-50%, -50%) rotate(var(--needle-angle));
}
@media (min-width: 768px) {
  .landing-diamond-cta__label {
    width: 8.25rem;
    font-size: 0.88rem;
  }
}
.landing-hero-copy {
  text-align: right;
}
.landing-hero-copy .lead,
.landing-hero-copy .landing-hero-copy__sub {
  margin-right: 0;
  margin-left: 0;
}
.landing-hero-copy__sub {
  margin-bottom: 0;
}
.hero-copy h1 { font-size: 1.75rem; margin: 4px 0 10px; color: #0f2942; letter-spacing: -0.02em; }
.landing-hero-copy h1 {
  font-size: clamp(1.85rem, 4vw, 2.35rem);
  margin-bottom: 14px;
}
.landing-hero-copy .hero-tag {
  margin-bottom: 10px;
}
.landing-hero-copy .lead {
  margin-bottom: 18px;
}
.hero-tag {
  display: inline-block; margin: 0 0 6px; padding: 2px 8px;
  background: #e2e8f0; color: #334155; font-size: 0.78rem; font-weight: 500;
  border: 1px solid #cbd5e1;
}
.lead { color: #475569; line-height: 1.75; max-width: 38em; margin: 0 0 16px; font-size: 0.95rem; }
.hero-cta { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 12px; }
.hero-grid--single { max-width: 640px; margin: 0 auto; }
@media (min-width: 768px) {
  .hero-grid--single { grid-template-columns: 1fr; }
}
.hero-copy--center { text-align: center; }
.hero-copy--center .lead { margin-left: auto; margin-right: auto; }
.lead-sub { color: #64748b; line-height: 1.7; max-width: 36em; margin: 0 auto 8px; font-size: 0.88rem; }
.hero-cta--center { justify-content: center; }

.panel {
  background: #fff; border: 1px solid #cbd5e1; border-radius: 8px;
  overflow: hidden; box-shadow: var(--shadow);
}
.panel-head {
  padding: 10px 14px; background: #0f2942; color: #f8fafc;
  font-size: 0.85rem; font-weight: 600; font-family: var(--font-display);
  border-bottom: 3px solid #0d9488;
}
.dl-board { margin: 0; padding: 0; }
.dl-board div {
  display: grid; grid-template-columns: 1fr auto; gap: 8px 16px;
  padding: 10px 14px; border-bottom: 1px solid #e2e8f0; font-size: 0.9rem;
}
.dl-board div:last-child { border-bottom: none; }
.dl-board dt { margin: 0; color: #64748b; font-weight: 500; }
.dl-board dd { margin: 0; color: #0f2942; font-weight: 600; text-align: left; }

.status-strip {
  display: flex; align-items: center; gap: 8px; padding: 8px 14px;
  background: #ecfdf5; border-bottom: 1px solid #99f6e4; font-size: 0.85rem;
}
.status-strip .dot { width: 8px; height: 8px; border-radius: 50%; background: #0d9488; flex-shrink: 0; }
.panel-note { padding: 12px 14px; margin: 0; color: #475569; font-size: 0.88rem; line-height: 1.65; }

.features-section { padding: 24px 16px 32px; }
.features-intro { margin: 0 0 12px; color: #64748b; font-size: 0.88rem; }
.features-section h2 { font-size: 1.1rem; margin: 0 0 12px; color: #0f2942; }
.panel-row {
  display: grid; gap: 4px; padding: 12px 14px;
  border-bottom: 1px solid #e2e8f0;
}
.panel-row:last-child { border-bottom: none; }
.panel-row h3 { margin: 0; font-size: 0.95rem; color: #0f2942; }
.panel-row p { margin: 4px 0 0; font-size: 0.85rem; color: #64748b; line-height: 1.55; }

.prose-section { padding: 32px 16px; max-width: 720px; margin: 0 auto; }
.judge-guide-table { width: 100%; margin: 12px 0 24px; font-size: 0.9rem; }
.algo-list { line-height: 1.9; }

.layout-auth { min-height: 100vh; display: flex; align-items: center; justify-content: center; position: relative; }
.auth-backdrop { position: fixed; inset: 0; background: #0f2942; z-index: 0; }
.auth-shell { position: relative; z-index: 1; width: min(440px, 94vw); padding: 16px; }
.auth-shell.wide { width: min(720px, 94vw); }
.card-elevated { background: #fff; }
.auth-card {
  padding: 24px; border: 1px solid #cbd5e1; border-radius: 8px;
  border-top: 3px solid #0d9488;
}
.auth-card h1 { margin: 0 0 8px; font-size: 1.25rem; color: #0f2942; }
.auth-sub { color: #64748b; margin-bottom: 16px; font-size: 0.9rem; }
.auth-form label { display: block; margin-top: 10px; font-weight: 600; color: #334155; font-size: 0.88rem; }
.auth-form input {
  width: 100%; padding: 10px 12px; margin-top: 4px; border-radius: 6px;
  border: 1px solid #94a3b8; font-size: 0.95rem; font-family: inherit;
}
.auth-divider { text-align: center; margin: 16px 0; color: #94a3b8; font-size: 0.85rem; }
.auth-divider span { background: #fff; padding: 0 8px; }
.auth-footer-link { text-align: center; margin-top: 12px; }
.auth-footer-link a { color: #cbd5e1; font-size: 0.88rem; }
.auth-legal { text-align: center; margin-top: 16px; }
.auth-legal .site-legal { color: #64748b; }
.hint { font-size: 0.82rem; color: #64748b; text-align: center; margin-top: 8px; }
.judge-persona-stages { display: flex; flex-direction: column; gap: 16px; margin-bottom: 14px; }
.demo-persona-stage {
  padding: 12px 14px;
  border: 1px solid #e2e8f0;
  border-radius: 10px;
  background: #fff;
}
.demo-persona-stage--start {
  border-color: #5eead4;
  background: #f8fafc;
  box-shadow: 0 0 0 1px #99f6e4;
}
.demo-persona-stage-head {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  margin-bottom: 6px;
}
.demo-persona-stage-title {
  margin: 0;
  font-size: 1rem;
  font-weight: 700;
  color: #0f2942;
}
.demo-persona-stage-badge {
  font-size: 0.72rem;
  font-weight: 600;
  padding: 3px 8px;
  border-radius: 999px;
  background: #0d9488;
  color: #fff;
}
.demo-persona-stage-hint {
  margin: 0 0 10px;
  font-size: 0.82rem;
  line-height: 1.45;
  color: #334155;
}
.demo-persona-stage .judge-grid { margin-bottom: 0; }
.judge-grid { display: grid; gap: 10px; grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)); margin-bottom: 14px; }
.judge-card {
  border: 1px solid #cbd5e1; border-radius: 8px; padding: 12px; background: #f8fafc;
}
.judge-card h3 { margin: 0 0 4px; font-size: 0.95rem; }
.role-label { color: #64748b; font-size: 0.8rem; margin: 0 0 10px; }

.btn {
  display: inline-block; border: none; border-radius: 8px;
  padding: 10px 16px; font-size: 0.95rem; cursor: pointer;
  text-decoration: none; text-align: center; font-family: inherit; font-weight: 500;
}
.btn.primary { background: #f97316; color: #fff; }
.btn.secondary { background: #0d9488; color: #fff; }
.btn.ghost {
  background: #fff; color: #0f2942; border: 1px solid #94a3b8;
}
.btn.lg { padding: 11px 18px; }
.btn.block { display: block; width: 100%; margin-top: 8px; }
.btn-sm { padding: 7px 12px; font-size: 0.85rem; }
.status-pill { display: inline-block; padding: 2px 8px; border-radius: 4px; font-size: 0.75rem; margin-bottom: 6px; border: 1px solid; }
.status-pill.green { background: #ecfdf5; color: #0d9488; border-color: #99f6e4; }