/* ClashRZ — shared design system */
@import url('https://fonts.googleapis.com/css2?family=Cinzel:wght@500;600;700&family=Source+Sans+3:wght@300;400;500;600&display=swap');

:root {
  --crz-bg-deep: #0a0c10;
  --crz-bg-panel: rgba(12, 14, 20, 0.92);
  --crz-bg-card: rgba(18, 20, 28, 0.88);
  --crz-gold: #c9a24e;
  --crz-gold-bright: #f0d878;
  --crz-gold-mid: #d4a848;
  --crz-gold-dim: #8a6828;
  --crz-gold-panel: #b88838;
  --crz-parchment-light: #e8c878;
  --crz-parchment-mid: #d4a048;
  --crz-parchment-dark: #a87830;
  --crz-text: #e8e4dc;
  --crz-text-muted: #9a958a;
  --crz-border: rgba(201, 162, 78, 0.45);
  --crz-border-strong: rgba(201, 162, 78, 0.75);
  --crz-shadow: 0 24px 80px rgba(0, 0, 0, 0.65);
  --crz-radius: 4px;
  --crz-font-display: 'Cinzel', 'Times New Roman', serif;
  --crz-font-body: 'Source Sans 3', 'Segoe UI', sans-serif;
  --crz-asura: #a855f7;
  --crz-asura-glow: rgba(168, 85, 247, 0.45);
  --crz-deva: #38bdf8;
  --crz-deva-glow: rgba(56, 189, 248, 0.45);
  --crz-gaia: #f97316;
  --crz-gaia-glow: rgba(249, 115, 22, 0.45);
  --crz-sidebar-w: 168px;
}

*, *::before, *::after { box-sizing: border-box; }

html, body {
  margin: 0;
  padding: 0;
  min-height: 100%;
  font-family: var(--crz-font-body);
  color: var(--crz-text);
  background: var(--crz-bg-deep);
  -webkit-font-smoothing: antialiased;
}

.crz-page {
  min-height: 100vh;
  position: relative;
  overflow-x: hidden;
}

.crz-bg {
  position: fixed;
  inset: 0;
  z-index: 0;
  background:
    url('img/Game-BG.jpeg') center center / cover no-repeat,
    linear-gradient(180deg, #060810 0%, #0c1018 35%, #0a0e14 100%);
}

.crz-bg::before {
  content: '';
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse 50% 40% at 8% 65%, rgba(255, 190, 80, 0.2) 0%, transparent 45%),
    radial-gradient(ellipse 50% 40% at 92% 65%, rgba(255, 190, 80, 0.2) 0%, transparent 45%),
    radial-gradient(ellipse 80% 50% at 50% 100%, rgba(30, 50, 25, 0.35) 0%, transparent 60%);
  pointer-events: none;
}

.crz-bg::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(0deg, rgba(0, 0, 0, 0.5) 0%, transparent 40%, transparent 75%, rgba(0, 0, 0, 0.25) 100%);
  pointer-events: none;
}

.crz-layout {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: var(--crz-sidebar-w) 1fr;
  min-height: 100vh;
  max-width: 1440px;
  margin: 0 auto;
  padding: 24px 32px 32px;
  gap: 28px;
}

.crz-brand {
  grid-column: 1 / -1;
  display: flex;
  align-items: center;
  margin-bottom: 8px;
}

.crz-brand-link {
  display: inline-flex;
  align-items: center;
  text-decoration: none;
  line-height: 0;
  transition: filter 0.2s, transform 0.2s;
}

.crz-brand-link:hover {
  filter: drop-shadow(0 0 14px rgba(201, 162, 78, 0.35));
  transform: translateY(-1px);
}

.crz-brand-logo {
  height: 56px;
  width: auto;
  max-width: 56px;
  object-fit: contain;
  display: block;
  filter: drop-shadow(0 2px 10px rgba(0, 0, 0, 0.45));
}

.crz-brand-logo--ingame {
  height: 44px;
  max-width: 44px;
}

.crz-sidebar {
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding-top: 4px;
}

/* ── Gold sidebar (reference: dark bronze frame, metallic gold inset) ── */
.crz-parchment-nav {
  grid-row: 2;
  align-self: start;
  position: relative;
  width: 175px;
  padding: 9px;
  background:
    linear-gradient(160deg, #2a1c08 0%, #1a1008 40%, #221808 60%, #1a1008 100%);
  border: 1px solid #504018;
  box-shadow:
    0 8px 28px rgba(0, 0, 0, 0.7),
    inset 0 1px 0 rgba(212, 168, 72, 0.2),
    inset 0 -1px 0 rgba(0, 0, 0, 0.5);
}

.crz-parchment-nav__inset {
  position: relative;
  z-index: 1;
  padding: 6px 0;
  background:
    url("data:image/svg+xml,%3Csvg viewBox='0 0 200 400' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='200' height='400' filter='url(%23n)' opacity='0.07'/%3E%3C/svg%3E"),
    repeating-linear-gradient(
      90deg,
      transparent 0px,
      transparent 3px,
      rgba(255, 230, 140, 0.04) 3px,
      rgba(255, 230, 140, 0.04) 4px
    ),
    linear-gradient(90deg,
      #7a5818 0%,
      #b88828 12%,
      #d4a038 28%,
      #e8c050 42%,
      #f0d060 50%,
      #e8c050 58%,
      #d4a038 72%,
      #b88828 88%,
      #7a5818 100%);
  border: 2px solid #5a4010;
  box-shadow:
    inset 0 0 0 1px rgba(255, 235, 160, 0.55),
    inset 0 2px 8px rgba(255, 248, 200, 0.3),
    inset 0 -4px 12px rgba(60, 35, 5, 0.35),
    0 0 12px rgba(212, 168, 72, 0.12);
}

/* Metal corner brackets — dark bronze with gold rivets */
.crz-frame-bracket {
  position: absolute;
  width: 26px;
  height: 26px;
  z-index: 2;
  pointer-events: none;
  background:
    linear-gradient(135deg, #c8a050 0%, #806020 35%, #a88838 55%, #504018 100%);
  box-shadow:
    inset 0 1px 0 rgba(255, 230, 160, 0.55),
    inset 0 -1px 2px rgba(0, 0, 0, 0.5),
    1px 1px 5px rgba(0, 0, 0, 0.6);
}

.crz-frame-bracket::after {
  content: '';
  position: absolute;
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: radial-gradient(circle at 35% 35%, #e0e4e8, #5a6068);
  box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.5);
}

.crz-frame-bracket--tl { top: 4px; left: 4px; clip-path: polygon(0 0, 100% 0, 0 100%); }
.crz-frame-bracket--tl::after { top: 5px; left: 5px; }

.crz-frame-bracket--tr { top: 4px; right: 4px; clip-path: polygon(0 0, 100% 0, 100% 100%); }
.crz-frame-bracket--tr::after { top: 5px; right: 5px; }

.crz-frame-bracket--bl { bottom: 4px; left: 4px; clip-path: polygon(0 0, 0 100%, 100% 100%); }
.crz-frame-bracket--bl::after { bottom: 5px; left: 5px; }

.crz-frame-bracket--br { bottom: 4px; right: 4px; clip-path: polygon(100% 0, 0 100%, 100% 100%); }
.crz-frame-bracket--br::after { bottom: 5px; right: 5px; }

.crz-nav-link {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 11px 14px;
  text-decoration: none;
  color: #2a1808;
  font-family: var(--crz-font-display);
  font-size: 0.92rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  border: none;
  border-bottom: 1px solid rgba(80, 50, 10, 0.2);
  transition: color 0.2s, background 0.2s;
  position: relative;
  z-index: 1;
}

/* Force the nav link colour in every state — the game page loads the Travian
   gpack, whose a:visited{color:#99c01a} (green) was leaking onto visited links
   (LOGIN/REGISTER). Higher specificity than the gpack's a:visited. */
.crz-nav-link:link,
.crz-nav-link:visited {
  color: #2a1808;
}

.crz-parchment-nav__inset .crz-nav-link:last-child {
  border-bottom: none;
}

.crz-nav-icon {
  width: 20px;
  height: 20px;
  flex-shrink: 0;
  color: #2a1808;
}

.crz-nav-link span {
  position: relative;
  z-index: 1;
}

.crz-nav-link:hover {
  color: #1a1008;
}

.crz-nav-link:hover::before {
  content: '';
  position: absolute;
  left: 6px;
  right: 6px;
  top: 4px;
  bottom: 4px;
  background: linear-gradient(90deg, rgba(240, 210, 120, 0.35) 0%, rgba(220, 180, 80, 0.45) 50%, rgba(240, 210, 120, 0.35) 100%);
  box-shadow: 0 0 12px rgba(220, 180, 80, 0.25);
  z-index: 0;
}

.crz-nav-link.is-active {
  color: #1a1008;
}

.crz-nav-link.is-active::before {
  content: '';
  position: absolute;
  left: 4px;
  right: 4px;
  top: 3px;
  bottom: 3px;
  background: linear-gradient(90deg,
    rgba(255, 240, 160, 0.55) 0%,
    rgba(255, 220, 100, 0.75) 30%,
    rgba(255, 235, 140, 0.85) 50%,
    rgba(255, 220, 100, 0.75) 70%,
    rgba(255, 240, 160, 0.55) 100%);
  box-shadow:
    0 0 14px rgba(255, 210, 80, 0.45),
    inset 0 1px 0 rgba(255, 255, 220, 0.5);
  z-index: 0;
}

.crz-nav-link.is-active .crz-nav-icon {
  color: #2a1a08;
}

.crz-main {
  display: flex;
  flex-direction: column;
  min-width: 0;
}

.crz-panel {
  flex: 1;
  position: relative;
}

/* Ornate panel — thin gold filigree frame, dark glass interior (reference) */
.crz-ornate-panel {
  position: relative;
  padding: 4px;
  background:
    linear-gradient(145deg, #f0d878 0%, #d4a848 18%, #b88828 50%, #d4a848 82%, #f0d878 100%);
  border: 1px solid #f8e8a0;
  box-shadow:
    0 0 0 1px rgba(40, 28, 8, 0.85),
    0 0 24px rgba(212, 168, 72, 0.18),
    0 18px 56px rgba(0, 0, 0, 0.78),
    inset 0 1px 0 rgba(255, 248, 200, 0.45),
    inset 0 -1px 0 rgba(80, 50, 10, 0.35);
}

.crz-ornate-panel__inner {
  position: relative;
  padding: 28px 32px 24px;
  background:
    linear-gradient(180deg, rgba(12, 14, 20, 0.96) 0%, rgba(6, 8, 12, 0.98) 100%);
  border: 1px solid rgba(212, 168, 72, 0.55);
  box-shadow:
    inset 0 0 0 1px rgba(0, 0, 0, 0.6),
    inset 0 0 80px rgba(0, 0, 0, 0.55);
}

.crz-ornate-crown {
  position: absolute;
  top: -7px;
  left: 50%;
  transform: translateX(-50%);
  width: 18px;
  height: 14px;
  z-index: 5;
  pointer-events: none;
}

.crz-ornate-crown::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, #e8c050 0%, #a87828 100%);
  clip-path: polygon(50% 100%, 0 30%, 15% 0, 85% 0, 100% 30%);
  border: 1px solid #f8e8a0;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.5);
}

.crz-ornate-crown::after {
  content: '';
  position: absolute;
  top: 2px;
  left: 50%;
  transform: translateX(-50%) rotate(45deg);
  width: 8px;
  height: 8px;
  background: linear-gradient(135deg, #fff8d0 0%, #f0d878 50%, #c89830 100%);
  border: 1px solid #f8e8a0;
  box-shadow: 0 0 10px rgba(240, 200, 96, 0.7);
}

.crz-ornate-filigree {
  position: absolute;
  width: 48px;
  height: 48px;
  background: url('img/filigree-corner.svg') no-repeat center / contain;
  pointer-events: none;
  z-index: 3;
  opacity: 1;
  filter: drop-shadow(0 1px 3px rgba(0, 0, 0, 0.6));
}

.crz-ornate-filigree--tl { top: 2px; left: 2px; }
.crz-ornate-filigree--tr { top: 2px; right: 2px; transform: scaleX(-1); }
.crz-ornate-filigree--bl { bottom: 2px; left: 2px; transform: scaleY(-1); }
.crz-ornate-filigree--br { bottom: 2px; right: 2px; transform: scale(-1, -1); }

.crz-panel::before,
.crz-panel::after,
.crz-panel .crz-corner-bl,
.crz-panel .crz-corner-br {
  display: none;
}

.crz-panel-inner {
  padding: 48px 56px;
}

.crz-title {
  font-family: var(--crz-font-display);
  font-size: clamp(1.6rem, 3vw, 2.2rem);
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--crz-gold-bright);
  text-align: center;
  margin: 0 0 12px;
}

.crz-subtitle {
  text-align: center;
  color: var(--crz-text-muted);
  font-size: 1.05rem;
  font-weight: 300;
  margin: 0 0 36px;
  letter-spacing: 0.02em;
}

/* button.crz-btn beats Travian global button:hover (padding:0, font-size:11px) */
button.crz-btn,
a.crz-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 14px 40px;
  font-family: var(--crz-font-display);
  font-size: 0.95rem;
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  text-decoration: none;
  color: #1a1408;
  border: none;
  cursor: pointer;
  line-height: normal;
  text-align: center;
  text-shadow: 0 1px 0 rgba(255, 255, 255, 0.25);
  background: linear-gradient(180deg, #f5d888 0%, #d4a84a 30%, #a07828 70%, #806020 100%);
  box-shadow:
    0 4px 0 #5a4010,
    0 8px 24px rgba(0, 0, 0, 0.45),
    inset 0 1px 0 rgba(255, 255, 255, 0.4),
    inset 0 -2px 4px rgba(0, 0, 0, 0.15);
  clip-path: polygon(12px 0, calc(100% - 12px) 0, 100% 50%, calc(100% - 12px) 100%, 12px 100%, 0 50%);
  transition: transform 0.15s, box-shadow 0.15s, filter 0.15s;
}

button.crz-btn:hover,
button.crz-btn:focus,
a.crz-btn:hover,
a.crz-btn:focus {
  transform: translateY(-1px);
  padding: 14px 40px;
  font-size: 0.95rem;
  line-height: normal;
  text-align: center;
  background: linear-gradient(180deg, #ffe8a0 0%, #e0b858 30%, #b08830 70%, #907028 100%);
  box-shadow:
    0 4px 0 #5a4010,
    0 10px 32px rgba(201, 162, 78, 0.4),
    inset 0 1px 0 rgba(255, 255, 255, 0.5);
  filter: brightness(1.03);
}

button.crz-btn:active,
a.crz-btn:active { transform: translateY(0); }

button.crz-btn:disabled,
a.crz-btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
  transform: none;
}

.crz-footer {
  grid-column: 1 / -1;
  text-align: center;
  padding-top: 16px;
  font-size: 0.78rem;
  color: var(--crz-text-muted);
}

.crz-footer-links {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 4px 0;
  margin-bottom: 8px;
}

.crz-footer-links a {
  color: var(--crz-text-muted);
  text-decoration: none;
  padding: 0 10px;
  border-right: 1px solid rgba(154, 149, 138, 0.3);
}

.crz-footer-links a:last-child { border-right: none; }
.crz-footer-links a:hover { color: var(--crz-gold); }

/* Landing hero */
.crz-landing .crz-hero {
  text-align: center;
  padding: 8px 0 16px;
}

.crz-landing .crz-hero-eyebrow {
  font-family: var(--crz-font-display);
  font-size: 0.75rem;
  letter-spacing: 0.4em;
  text-transform: uppercase;
  color: var(--crz-gold);
  margin: 0 0 18px;
}

.crz-landing .crz-hero h1 {
  font-family: var(--crz-font-display);
  font-size: clamp(2rem, 5vw, 3.2rem);
  font-weight: 600;
  line-height: 1.12;
  letter-spacing: 0.08em;
  color: var(--crz-text);
  margin: 0 0 18px;
  text-transform: uppercase;
  text-shadow: 0 2px 24px rgba(0, 0, 0, 0.45);
}

.crz-landing .crz-hero h1 em {
  font-style: normal;
  color: var(--crz-gold-bright);
}

.crz-landing .crz-hero-lead {
  font-size: 1.05rem;
  font-weight: 300;
  color: var(--crz-text-muted);
  max-width: 560px;
  margin: 0 auto 32px;
  line-height: 1.65;
  letter-spacing: 0.02em;
}

.crz-landing .crz-hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  justify-content: center;
  align-items: center;
  margin-bottom: 12px;
}

.crz-landing .crz-hero-note {
  font-size: 0.9rem;
  color: var(--crz-text-muted);
  margin: 0 0 44px;
}

.crz-landing .crz-hero-note a {
  color: var(--crz-gold);
  text-decoration: none;
}

.crz-landing .crz-hero-note a:hover {
  text-decoration: underline;
}

.crz-landing a.crz-btn--ghost {
  color: var(--crz-gold) !important;
  background: transparent !important;
  box-shadow: none !important;
  border: 1px solid rgba(201, 162, 78, 0.45) !important;
  clip-path: none !important;
  border-radius: var(--crz-radius);
  text-shadow: none !important;
}

.crz-landing a.crz-btn--ghost:hover,
.crz-landing a.crz-btn--ghost:focus {
  background: rgba(201, 162, 78, 0.12) !important;
  filter: none;
  transform: translateY(-1px);
}

.crz-landing .crz-features {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
  margin-top: 0;
}

.crz-landing .crz-feature {
  position: relative;
  padding: 28px 22px 24px;
  border: 1px solid rgba(201, 162, 78, 0.22);
  background:
    linear-gradient(180deg, rgba(20, 22, 30, 0.96) 0%, rgba(8, 10, 16, 0.98) 100%);
  box-shadow:
    inset 0 1px 0 rgba(201, 162, 78, 0.1),
    0 10px 28px rgba(0, 0, 0, 0.35);
  text-align: center;
  transition: border-color 0.25s, transform 0.2s ease, box-shadow 0.25s ease;
}

.crz-landing .crz-feature::before {
  content: '';
  position: absolute;
  top: 0;
  left: 16px;
  right: 16px;
  height: 1px;
  background: linear-gradient(90deg,
    transparent,
    rgba(201, 162, 78, 0.45),
    transparent);
}

.crz-landing .crz-feature:hover {
  border-color: rgba(201, 162, 78, 0.38);
  transform: translateY(-2px);
  box-shadow:
    inset 0 1px 0 rgba(201, 162, 78, 0.14),
    0 14px 32px rgba(0, 0, 0, 0.42),
    0 0 20px rgba(201, 162, 78, 0.08);
}

.crz-landing .crz-feature h3 {
  font-family: var(--crz-font-display);
  font-size: 0.82rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--crz-gold-bright);
  margin: 0 0 12px;
}

.crz-landing .crz-feature p {
  font-size: 0.9rem;
  color: var(--crz-text-muted);
  margin: 0;
  line-height: 1.55;
}

.crz-landing .crz-feature-emblem {
  width: 44px;
  height: 44px;
  margin: 0 auto 14px;
  background-size: contain;
  background-repeat: no-repeat;
  background-position: center;
  filter: drop-shadow(0 2px 8px rgba(0, 0, 0, 0.4));
}

.crz-landing .crz-feature--asura .crz-feature-emblem {
  background-image: url('img/emblem-asura.svg');
}

.crz-landing .crz-feature--deva .crz-feature-emblem {
  background-image: url('img/emblem-deva.svg');
}

.crz-landing .crz-feature--gaia .crz-feature-emblem {
  background-image: url('img/emblem-gaia.svg');
}

.crz-landing .crz-feature--asura:hover {
  border-color: rgba(155, 95, 207, 0.45);
  box-shadow:
    inset 0 1px 0 rgba(155, 95, 207, 0.12),
    0 14px 32px rgba(0, 0, 0, 0.42),
    0 0 20px rgba(155, 95, 207, 0.12);
}

.crz-landing .crz-feature--deva:hover {
  border-color: rgba(90, 168, 232, 0.45);
  box-shadow:
    inset 0 1px 0 rgba(90, 168, 232, 0.12),
    0 14px 32px rgba(0, 0, 0, 0.42),
    0 0 20px rgba(90, 168, 232, 0.12);
}

.crz-landing .crz-feature--gaia:hover {
  border-color: rgba(224, 128, 64, 0.45);
  box-shadow:
    inset 0 1px 0 rgba(224, 128, 64, 0.12),
    0 14px 32px rgba(0, 0, 0, 0.42),
    0 0 20px rgba(224, 128, 64, 0.12);
}

/* Legacy hero classes (unused outside landing) */
.crz-hero {
  text-align: center;
  padding: 20px 0 40px;
}

.crz-hero-eyebrow {
  font-family: var(--crz-font-display);
  font-size: 0.75rem;
  letter-spacing: 0.4em;
  text-transform: uppercase;
  color: var(--crz-gold);
  margin-bottom: 20px;
}

.crz-hero h1 {
  font-family: var(--crz-font-display);
  font-size: clamp(2rem, 5vw, 3.2rem);
  font-weight: 700;
  line-height: 1.15;
  letter-spacing: 0.06em;
  color: var(--crz-text);
  margin: 0 0 20px;
  text-transform: uppercase;
}

.crz-hero h1 em {
  font-style: normal;
  color: var(--crz-gold-bright);
}

.crz-hero-lead {
  font-size: 1.15rem;
  font-weight: 300;
  color: var(--crz-text-muted);
  max-width: 560px;
  margin: 0 auto 36px;
  line-height: 1.6;
}

.crz-features {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
  margin-top: 48px;
}

.crz-feature {
  padding: 24px 20px;
  border: 1px solid rgba(201, 162, 78, 0.2);
  background: var(--crz-bg-card);
  text-align: center;
}

.crz-feature h3 {
  font-family: var(--crz-font-display);
  font-size: 0.85rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--crz-gold);
  margin: 0 0 10px;
}

.crz-feature p {
  font-size: 0.9rem;
  color: var(--crz-text-muted);
  margin: 0;
  line-height: 1.5;
}

/* Register form */
.crz-form {
  max-width: 420px;
  margin: 0 auto;
}

.crz-field {
  margin-bottom: 18px;
}

.crz-field label {
  display: block;
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--crz-text-muted);
  margin-bottom: 6px;
}

.crz-field input[type="text"],
.crz-field input[type="email"],
.crz-field input[type="password"] {
  width: 100%;
  padding: 12px 14px;
  font-family: var(--crz-font-body);
  font-size: 1rem;
  color: var(--crz-text);
  background: rgba(0, 0, 0, 0.35);
  border: 1px solid rgba(201, 162, 78, 0.25);
  border-radius: var(--crz-radius);
  outline: none;
  transition: border-color 0.2s;
}

.crz-field input:focus {
  border-color: var(--crz-gold);
}

.crz-field input.is-error { border-color: #c44; }

.crz-field-error {
  font-size: 0.8rem;
  color: #e07070;
  margin-top: 4px;
}

.crz-checkbox {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  font-size: 0.85rem;
  color: var(--crz-text-muted);
  margin-bottom: 24px;
}

.crz-checkbox input { margin-top: 3px; accent-color: var(--crz-gold); flex-shrink: 0; }

/* Let the label text wrap inside the flex row instead of overflowing the panel. */
.crz-checkbox > span {
  min-width: 0;
  line-height: 1.45;
  overflow-wrap: anywhere;
}

.crz-form-actions {
  text-align: center;
  margin-top: 28px;
}

.crz-alert {
  padding: 12px 16px;
  margin-bottom: 20px;
  border-radius: var(--crz-radius);
  font-size: 0.9rem;
}

.crz-alert-success {
  background: rgba(60, 140, 80, 0.2);
  border: 1px solid rgba(80, 180, 100, 0.4);
  color: #8fd4a0;
}

.crz-alert-error {
  background: rgba(180, 60, 60, 0.15);
  border: 1px solid rgba(200, 80, 80, 0.35);
  color: #e09090;
}

.crz-server-pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 16px;
  margin-bottom: 24px;
  border: 1px solid var(--crz-border);
  background: rgba(201, 162, 78, 0.08);
  font-size: 0.85rem;
  color: var(--crz-gold-bright);
}

.crz-server-pill.is-loading strong {
  opacity: 0.65;
}

.crz-panel-inner--center {
  text-align: center;
}

.crz-login-lead {
  color: var(--crz-text-muted);
  margin: 0 auto 28px;
  max-width: 420px;
  line-height: 1.55;
}

.crz-login-lead a {
  color: var(--crz-gold);
  text-decoration: none;
}

.crz-login-lead a:hover {
  text-decoration: underline;
}

.crz-btn.is-loading {
  position: relative;
  color: transparent !important;
  pointer-events: none;
  opacity: 0.92;
}

.crz-btn.is-loading::after {
  content: '';
  position: absolute;
  left: 50%;
  top: 50%;
  width: 18px;
  height: 18px;
  margin: -9px 0 0 -9px;
  border: 2px solid rgba(26, 20, 8, 0.2);
  border-top-color: #1a1408;
  border-radius: 50%;
  animation: crz-spin 0.65s linear infinite;
}

@keyframes crz-spin {
  to { transform: rotate(360deg); }
}

@media (max-width: 900px) {
  .crz-layout {
    grid-template-columns: 1fr;
    padding: 16px;
  }

  .crz-parchment-nav {
    width: 100%;
    margin-bottom: 16px;
  }

  .crz-parchment-nav__inset {
    display: flex;
    flex-wrap: wrap;
  }

  .crz-parchment-nav__inset .crz-nav-link {
    flex: 1 1 45%;
    border-bottom: 1px solid rgba(100, 80, 55, 0.22);
  }

  .crz-panel-inner { padding: 28px 20px; }

  .crz-landing .crz-features { grid-template-columns: 1fr; }

  .crz-features { grid-template-columns: 1fr; }
}
