:root {
  --ink: #1b1a17;
  --muted: #6f6a61;
  --paper: #f7f3ed;
  --card: #fffdfa;
  --line: #e5ded3;
  --accent: #ef6b2e;
  --accent-dark: #bf4818;
  --accent-soft: #fff0e7;
  --green: #297a59;
  --green-soft: #e9f5ee;
  --amber: #a46709;
  --amber-soft: #fff4da;
  --red: #a94435;
  --shadow: 0 18px 48px rgba(44, 32, 18, .08);
  font-family: Inter, ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color: var(--ink);
  background: var(--paper);
}
* { box-sizing: border-box; }
body { margin: 0; min-height: 100vh; background: var(--paper); }
button, input, select { font: inherit; }
button { cursor: pointer; }
.muted { color: var(--muted); }
.eyebrow { margin: 0; color: var(--accent-dark); font-size: 11px; font-weight: 800; letter-spacing: .16em; }
.brand-mark { display: grid; place-items: center; width: 42px; height: 42px; border-radius: 12px; background: var(--ink); color: #fff; font-weight: 900; letter-spacing: -.04em; }
.login-body { background: #171714; }
.login-shell { display: grid; grid-template-columns: 1.15fr .85fr; min-height: 100vh; }
.login-story { position: relative; overflow: hidden; padding: 56px clamp(32px, 7vw, 110px); display: flex; flex-direction: column; justify-content: center; color: #fff; background: radial-gradient(circle at 75% 22%, rgba(239,107,46,.34), transparent 28%), linear-gradient(145deg,#171714 0%,#25211d 100%); }
.login-story::after { content: ""; position: absolute; width: 460px; height: 460px; right: -190px; bottom: -230px; border: 1px solid rgba(255,255,255,.12); border-radius: 50%; box-shadow: 0 0 0 70px rgba(255,255,255,.025), 0 0 0 140px rgba(255,255,255,.018); }
.login-story .eyebrow { margin-top: 76px; color: #f6a276; }
.login-story h1 { margin: 18px 0; max-width: 680px; font-family: Georgia, serif; font-size: clamp(50px, 7vw, 94px); line-height: .94; letter-spacing: -.055em; font-weight: 500; }
.login-story h1 em { color: #f59a69; font-weight: 400; }
.login-story > p:not(.eyebrow) { max-width: 510px; color: #c6c0b8; font-size: 18px; line-height: 1.6; }
.login-proof { margin-top: 70px; color: #aaa399; font-size: 13px; }
.login-proof span { display: inline-block; width: 7px; height: 7px; margin-right: 8px; border-radius: 50%; background: #55b889; box-shadow: 0 0 0 4px rgba(85,184,137,.12); }
.login-card { align-self: center; margin: 42px clamp(24px, 6vw, 90px); padding: 46px; border-radius: 26px; background: var(--card); box-shadow: var(--shadow); }
.login-card h2 { margin: 8px 0; font-family: Georgia, serif; font-size: 38px; font-weight: 500; letter-spacing: -.03em; }
.login-card form { display: grid; gap: 18px; margin-top: 34px; }
label { display: grid; gap: 8px; color: #4f4a43; font-size: 13px; font-weight: 700; }
input, select { width: 100%; border: 1px solid var(--line); border-radius: 12px; padding: 12px 14px; background: #fff; color: var(--ink); outline: none; }
input:focus, select:focus { border-color: var(--accent); box-shadow: 0 0 0 3px rgba(239,107,46,.12); }
.primary-button { border: 0; border-radius: 12px; padding: 13px 18px; background: var(--accent); color: #fff; font-weight: 800; box-shadow: 0 8px 18px rgba(239,107,46,.2); }
.primary-button:hover { background: var(--accent-dark); }
.primary-button:disabled { opacity: .55; cursor: wait; }
.secondary-button { border: 1px solid var(--line); border-radius: 11px; padding: 10px 14px; background: #fff; color: var(--ink); font-weight: 750; }
.danger-button { border-color: #efc6bc; color: var(--red); }
.form-error { min-height: 20px; margin: 0; color: var(--red); font-size: 13px; }
.login-help { margin: 28px 0 0; color: var(--muted); font-size: 12px; line-height: 1.5; }
.app-shell { min-height: 100vh; padding-left: 230px; }
.sidebar { position: fixed; inset: 0 auto 0 0; z-index: 5; display: flex; width: 230px; flex-direction: column; padding: 28px 20px; color: #eee9e0; background: #1b1a17; }
.sidebar .brand { display: flex; align-items: center; gap: 12px; }
.sidebar .brand small { display: block; color: #9d978d; font-size: 10px; letter-spacing: .12em; }
.sidebar nav { display: grid; gap: 7px; margin-top: 56px; }
.nav-button { display: flex; align-items: center; gap: 11px; width: 100%; border: 0; border-radius: 11px; padding: 11px 12px; color: #aaa49a; background: transparent; text-align: left; font-weight: 700; }
.nav-button.active { color: #fff; background: rgba(255,255,255,.09); }
.nav-dot { width: 7px; height: 7px; border-radius: 50%; background: currentColor; }
.sidebar-user { margin-top: auto; padding-top: 18px; border-top: 1px solid rgba(255,255,255,.1); }
.sidebar-user strong, .sidebar-user small { display: block; overflow: hidden; text-overflow: ellipsis; }
.sidebar-user small { margin-top: 3px; color: #918b82; }
.main { max-width: 1460px; margin: auto; padding: 34px clamp(24px, 4vw, 58px) 70px; }
.topbar { display: flex; align-items: center; justify-content: space-between; gap: 18px; margin-bottom: 30px; }
.topbar h1 { margin: 5px 0 0; font-family: Georgia, serif; font-size: clamp(30px, 4vw, 48px); font-weight: 500; letter-spacing: -.04em; }
.topbar-actions { display: flex; gap: 10px; align-items: center; }
.topbar-actions select { min-width: 135px; }
.content-grid { display: grid; gap: 18px; }
.hero { position: relative; overflow: hidden; display: grid; grid-template-columns: 1.2fr .8fr; min-height: 235px; border-radius: 24px; padding: 34px; color: #fff; background: linear-gradient(130deg, #24211d 0%, #34271e 60%, #633117 100%); box-shadow: var(--shadow); }
.hero::after { content: ""; position: absolute; inset: auto -55px -110px auto; width: 260px; height: 260px; border: 1px solid rgba(255,255,255,.13); border-radius: 50%; box-shadow: 0 0 0 44px rgba(255,255,255,.03), 0 0 0 88px rgba(255,255,255,.02); }
.hero .eyebrow { color: #f8ad83; }
.hero h2 { margin: 12px 0; font-family: Georgia, serif; font-size: clamp(34px, 5vw, 58px); font-weight: 500; letter-spacing: -.045em; }
.hero p { max-width: 560px; color: #c9c1b8; line-height: 1.55; }
.score-ring { position: relative; z-index: 1; align-self: center; justify-self: center; display: grid; place-items: center; width: 150px; height: 150px; border-radius: 50%; background: conic-gradient(#f1844f var(--score), rgba(255,255,255,.12) 0); }
.score-ring::before { content: ""; width: 116px; height: 116px; border-radius: 50%; background: #2b251f; }
.score-value { position: absolute; text-align: center; }
.score-value strong { display: block; font-family: Georgia, serif; font-size: 42px; }
.score-value small { color: #aaa198; }
.section-heading { display: flex; align-items: end; justify-content: space-between; gap: 16px; margin: 18px 0 12px; }
.section-heading h2 { margin: 0; font-family: Georgia, serif; font-size: 27px; font-weight: 500; letter-spacing: -.025em; }
.section-heading p { margin: 0; color: var(--muted); font-size: 13px; }
.kpi-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 14px; }
.card { border: 1px solid var(--line); border-radius: 17px; background: var(--card); box-shadow: 0 7px 22px rgba(42,31,17,.035); }
.kpi-card { padding: 18px; }
.kpi-top { display: flex; justify-content: space-between; gap: 10px; min-height: 39px; }
.kpi-top h3 { margin: 0; font-size: 13px; line-height: 1.35; }
.weight { color: var(--muted); font-size: 11px; white-space: nowrap; }
.kpi-number { margin: 18px 0 13px; font-family: Georgia, serif; font-size: 28px; }
.progress { height: 6px; overflow: hidden; border-radius: 999px; background: #eee7dc; }
.progress span { display: block; height: 100%; border-radius: inherit; background: var(--accent); }
.kpi-foot { display: flex; justify-content: space-between; margin-top: 9px; color: var(--muted); font-size: 11px; }
.split { display: grid; grid-template-columns: 1.1fr .9fr; gap: 16px; }
.reward-card, .metrics-card, .schedule-card, .studio { padding: 24px; }
.reward-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin-top: 18px; }
.reward-box { padding: 17px; border-radius: 13px; background: var(--accent-soft); }
.reward-box.final { background: var(--green-soft); }
.reward-box small, .metric small { display: block; color: var(--muted); }
.reward-box strong { display: block; margin-top: 7px; font-family: Georgia, serif; font-size: 25px; }
.status-pill { display: inline-flex; align-items: center; gap: 6px; border-radius: 999px; padding: 6px 9px; color: var(--amber); background: var(--amber-soft); font-size: 11px; font-weight: 800; }
.status-pill.good { color: var(--green); background: var(--green-soft); }
.metric-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 19px 12px; margin-top: 18px; }
.metric strong { display: block; margin-bottom: 4px; font-size: 20px; }
.schedule-list { display: grid; gap: 10px; margin-top: 18px; }
.shift { display: grid; grid-template-columns: 65px 1fr auto; gap: 16px; align-items: center; padding: 14px; border: 1px solid var(--line); border-radius: 13px; background: #fff; }
.shift-date { text-align: center; }
.shift-date strong, .shift-date small { display: block; }
.shift-date strong { font-family: Georgia, serif; font-size: 24px; }
.shift-date small, .shift-details small { color: var(--muted); }
.shift-details strong { display: block; margin-bottom: 3px; }
.empty { padding: 30px; border: 1px dashed #d6cec2; border-radius: 14px; color: var(--muted); text-align: center; }
.studio-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; margin-top: 18px; }
.studio-actions { display: flex; gap: 10px; margin-top: 16px; }
.version-list { display: grid; gap: 9px; margin-top: 18px; }
.version { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 12px 14px; border-radius: 12px; background: #f6f1e9; }
.version small { color: var(--muted); }
.notice { padding: 12px 14px; border-radius: 11px; color: var(--green); background: var(--green-soft); font-size: 13px; }
.error-notice { color: var(--red); background: #fbece8; }
.skeleton { min-height: 120px; overflow: hidden; background: linear-gradient(90deg,#eee8df 25%,#f8f4ef 50%,#eee8df 75%); background-size: 200% 100%; animation: shimmer 1.4s infinite; }
@keyframes shimmer { to { background-position: -200% 0; } }
.bottom-nav { display: none; }
@media (max-width: 1100px) { .kpi-grid { grid-template-columns: repeat(2, 1fr); } .split { grid-template-columns: 1fr; } }
@media (max-width: 760px) {
  .login-shell { grid-template-columns: 1fr; }
  .login-story { min-height: 42vh; padding: 32px 24px; }
  .login-story .eyebrow { margin-top: 40px; }
  .login-story h1 { font-size: 47px; }
  .login-proof { margin-top: 25px; }
  .login-card { margin: -20px 16px 24px; padding: 30px 23px; z-index: 2; }
  .app-shell { padding: 0; }
  .sidebar { display: none; }
  .main { padding: 22px 16px 92px; }
  .topbar { align-items: flex-start; }
  .topbar .eyebrow { margin-top: 4px; }
  .topbar h1 { font-size: 34px; }
  .topbar-actions { flex-direction: column; align-items: stretch; }
  .hero { grid-template-columns: 1fr; padding: 25px; }
  .score-ring { width: 125px; height: 125px; margin-top: 22px; }
  .score-ring::before { width: 96px; height: 96px; }
  .score-value strong { font-size: 34px; }
  .kpi-grid { grid-template-columns: 1fr; }
  .reward-grid, .metric-grid { grid-template-columns: 1fr 1fr; }
  .studio-grid { grid-template-columns: 1fr 1fr; }
  .shift { grid-template-columns: 54px 1fr; }
  .shift > button { grid-column: 1 / -1; }
  .bottom-nav { position: fixed; inset: auto 0 0; z-index: 5; display: grid; grid-template-columns: repeat(3, 1fr); padding: 8px 10px calc(8px + env(safe-area-inset-bottom)); border-top: 1px solid var(--line); background: rgba(255,253,250,.96); backdrop-filter: blur(14px); }
  .bottom-nav .nav-button { justify-content: center; flex-direction: column; gap: 3px; padding: 7px; color: var(--muted); font-size: 11px; }
  .bottom-nav .nav-button.active { color: var(--accent-dark); background: var(--accent-soft); }
}
@media (max-width: 430px) { .reward-grid, .metric-grid, .studio-grid { grid-template-columns: 1fr; } .topbar-actions select { min-width: 112px; } }
@media (prefers-reduced-motion: reduce) { * { scroll-behavior: auto !important; animation: none !important; } }
