:root {
  color-scheme: light;
  --canvas: #f3f5f4;
  --surface: #ffffff;
  --surface-soft: #edf2f1;
  --navy: #14283b;
  --navy-deep: #0c1b29;
  --text: #17232d;
  --muted: #69757d;
  --line: #dfe5e3;
  --orange: #ff6b45;
  --orange-deep: #e9522f;
  --aqua: #bce8de;
  --blue: #d8e7ff;
  --sand: #f2e5d6;
  --success: #44d3a2;
  --danger: #d94b3b;
  --shadow-sm: 0 1px 2px rgba(15, 32, 45, .05), 0 8px 24px rgba(15, 32, 45, .05);
  --shadow-lg: 0 28px 70px rgba(15, 32, 45, .16);
  --display: "Avenir Next", "Century Gothic", "Trebuchet MS", sans-serif;
  --body: "Aptos", "Trebuchet MS", sans-serif;
  --mono: "Lucida Console", "Courier New", monospace;
}

* { box-sizing: border-box; }
html { min-width: 320px; color: var(--text); background: var(--canvas); scroll-behavior: smooth; }
body { min-width: 320px; min-height: 100vh; margin: 0; font-family: var(--body); background: var(--canvas); }
button, input, select { font: inherit; }
button { color: inherit; }
button:focus-visible, input:focus-visible, select:focus-visible { outline: 3px solid rgba(255, 107, 69, .34); outline-offset: 3px; }
[hidden] { display: none !important; }

.eyebrow {
  margin: 0 0 9px;
  color: var(--muted);
  font-family: var(--mono);
  font-size: 9px;
  font-weight: 700;
  letter-spacing: .15em;
}

/* Brand */
.brand { display: inline-flex; align-items: center; gap: 12px; color: inherit; text-decoration: none; }
.brand > span:last-child { display: flex; flex-direction: column; gap: 2px; }
.brand strong, .login-brand strong, .mobile-login-brand strong { font-family: var(--display); font-size: 17px; letter-spacing: -.025em; }
.brand small { color: var(--muted); font-family: var(--mono); font-size: 7px; letter-spacing: .12em; }
.brand-mark {
  position: relative;
  width: 42px;
  height: 42px;
  display: inline-grid;
  place-items: center;
  flex: 0 0 auto;
  border-radius: 13px;
  background: var(--navy);
  box-shadow: 0 8px 18px rgba(20, 40, 59, .18);
}
.brand-mark::before { content: ""; width: 17px; height: 17px; border: 2px solid #fff; border-radius: 50%; opacity: .96; }
.brand-mark i::before, .brand-mark i::after { content: ""; position: absolute; left: 20px; top: 12px; width: 2px; height: 9px; border-radius: 2px; background: var(--orange); transform-origin: 50% 100%; }
.brand-mark i::after { height: 7px; transform: translateY(2px) rotate(125deg); }
.brand-mark--light { background: rgba(255,255,255,.12); border: 1px solid rgba(255,255,255,.16); box-shadow: none; }

/* Login */
.login-screen {
  position: relative;
  min-height: 100vh;
  overflow: hidden;
  padding: 50px 24px;
  display: grid;
  place-items: center;
  background:
    radial-gradient(circle at 12% 12%, rgba(65, 118, 143, .28), transparent 28%),
    radial-gradient(circle at 88% 88%, rgba(45, 125, 105, .2), transparent 30%),
    linear-gradient(145deg, #17354c 0%, #10283b 46%, #091a28 100%);
}
.login-screen::before { content: ""; position: absolute; inset: 0; opacity: .18; background-image: linear-gradient(rgba(255,255,255,.035) 1px, transparent 1px), linear-gradient(90deg, rgba(255,255,255,.035) 1px, transparent 1px); background-size: 48px 48px; mask-image: linear-gradient(to bottom, #000, transparent 78%); }
.login-orbit { position: absolute; border: 1px solid rgba(255,255,255,.07); border-radius: 50%; pointer-events: none; }
.login-orbit--one { width: 620px; height: 620px; left: -390px; top: -310px; box-shadow: 0 0 0 85px rgba(255,255,255,.018), 0 0 0 170px rgba(255,255,255,.012); }
.login-orbit--two { width: 460px; height: 460px; right: -230px; bottom: -260px; box-shadow: 0 0 0 70px rgba(66,211,168,.018); }
.login-time { position: absolute; right: 3vw; top: 50%; transform: translateY(-50%); color: rgba(255,255,255,.025); font-family: var(--display); font-size: min(23vw, 340px); font-weight: 600; letter-spacing: -.095em; white-space: nowrap; user-select: none; }
.login-time span { color: rgba(68,211,162,.045); }
.login-card { position: relative; z-index: 2; width: min(448px, 100%); padding: 38px 40px 34px; border: 1px solid rgba(255,255,255,.55); border-radius: 28px; background: rgba(255,255,255,.965); box-shadow: 0 38px 100px rgba(1,12,20,.38); animation: login-arrive .5s cubic-bezier(.2,.8,.2,1) both; }
.login-brand { display: flex; align-items: center; gap: 12px; }
.login-brand > span:last-child { display: flex; flex-direction: column; gap: 3px; }
.login-brand .brand-mark--light { width: 40px; height: 40px; border: 0; background: var(--navy); box-shadow: 0 8px 18px rgba(20,40,59,.16); }
.login-brand strong { color: var(--text); font-size: 16px; }
.login-brand small { color: #929ca1; font-family: var(--mono); font-size: 6px; letter-spacing: .13em; }
.login-copy { margin: 46px 0 32px; }
.soft-pill { display: inline-flex; align-items: center; gap: 8px; padding: 7px 10px; border-radius: 999px; background: #e8f6f1; color: #3e7b69; font-size: 9px; font-weight: 700; }
.soft-pill i { width: 6px; height: 6px; border-radius: 50%; background: var(--success); box-shadow: 0 0 0 4px rgba(68,211,162,.13); }
.login-copy h1 { margin: 18px 0 9px; font-family: var(--display); font-size: clamp(43px, 5vw, 58px); font-weight: 600; line-height: .93; letter-spacing: -.06em; }
.login-copy p { margin: 0; color: var(--muted); font-size: 12px; }
.login-card label { display: block; margin-bottom: 8px; color: var(--text); font-size: 10px; font-weight: 700; }
.password-row { height: 56px; display: flex; align-items: center; gap: 11px; padding: 0 9px 0 15px; border: 1px solid var(--line); border-radius: 15px; background: var(--canvas); transition: .2s; }
.password-row:focus-within { border-color: #81928c; background: #fff; box-shadow: 0 0 0 4px rgba(20,40,59,.06); }
.password-row > svg, .login-security > svg, .password-toggle svg { width: 19px; flex: 0 0 auto; fill: none; stroke: currentColor; stroke-width: 1.7; color: var(--muted); }
.password-row input { min-width: 0; flex: 1; border: 0; outline: 0; background: transparent; color: var(--text); font-size: 14px; }
.password-row input::placeholder { color: #9aa3a8; }
.password-toggle { width: 39px; height: 39px; display: grid; place-items: center; border: 0; border-radius: 10px; background: transparent; cursor: pointer; }
.password-toggle:hover { background: #e8eceb; }
.password-toggle svg { grid-area: 1 / 1; width: 18px; }
.password-toggle .eye-closed { display: none; }
.password-toggle[aria-pressed="true"] .eye-open { display: none; }
.password-toggle[aria-pressed="true"] .eye-closed { display: block; }
.login-button { width: 100%; margin-top: 13px; padding: 10px 11px 10px 18px; display: flex; justify-content: space-between; align-items: center; border: 0; border-radius: 15px; background: var(--orange); color: #fff; font-size: 12px; font-weight: 700; cursor: pointer; box-shadow: 0 13px 30px rgba(255,107,69,.22); transition: .2s ease; }
.login-button:hover { background: var(--orange-deep); transform: translateY(-1px); box-shadow: 0 17px 34px rgba(255,107,69,.28); }
.login-button i { width: 37px; height: 37px; display: grid; place-items: center; border-radius: 11px; background: rgba(255,255,255,.17); font-size: 18px; font-style: normal; }
.form-message { min-height: 18px; margin: 9px 0 0; color: var(--danger); font-size: 10px; }
.login-security { margin-top: 19px; padding-top: 19px; display: flex; align-items: center; gap: 10px; border-top: 1px solid var(--line); }
.login-security > svg { width: 21px; color: #4a8b78; }
.login-security > span { display: flex; flex-direction: column; gap: 2px; }
.login-security strong { color: #4d5b62; font-size: 9px; }
.login-security small { color: #8a959a; font-size: 8px; }
.login-footnote { position: absolute; z-index: 2; bottom: 20px; margin: 0; color: rgba(255,255,255,.28); font-family: var(--mono); font-size: 7px; letter-spacing: .13em; }
.auth-view[hidden] { display: none; }
.auth-input-row { margin-bottom: 15px; }
.auth-label-row { display: flex; align-items: center; justify-content: space-between; }
.auth-link { border: 0; padding: 0; background: transparent; color: #4b776a; font-size: 9px; font-weight: 700; cursor: pointer; }
.auth-link:focus { border: 0; background: transparent; }
.auth-link:hover { color: var(--orange-deep); text-decoration: underline; }
.auth-switch { margin: 5px 0 0; text-align: center; color: var(--muted); font-size: 9px; }
.auth-back { border: 0; padding: 0; background: transparent; color: var(--muted); font-size: 9px; cursor: pointer; }
.auth-back:hover { color: var(--text); }
.login-copy--compact { margin: 25px 0 25px; }
.login-copy--compact h1 { font-size: 44px; line-height: .98; }
.auth-form-stack { display: flex; flex-direction: column; gap: 13px; }
.auth-form-stack label { display: flex; flex-direction: column; gap: 7px; }
.auth-form-stack input { width: 100%; height: 48px; padding: 0 13px; border: 1px solid var(--line); border-radius: 12px; outline: 0; background: var(--canvas); color: var(--text); font-size: 12px; }
.auth-form-stack input:focus { border-color: #81928c; background: #fff; box-shadow: 0 0 0 4px rgba(20,40,59,.05); }
.auth-form-stack .login-button { margin-top: 2px; }
.password-hint { margin-top: -4px; color: var(--muted); font-size: 8px; line-height: 1.5; }

@keyframes login-arrive { from { opacity: 0; transform: translateY(14px) scale(.985); } }

/* Header and page */
.site-header {
  position: sticky;
  top: 0;
  z-index: 40;
  height: 82px;
  padding: 0 max(24px, calc((100vw - 1180px) / 2));
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid rgba(223,229,227,.85);
  background: rgba(243,245,244,.86);
  backdrop-filter: blur(18px);
}
.header-actions { display: flex; align-items: center; gap: 12px; }
.install-button { padding: 9px 14px; border: 1px solid var(--line); border-radius: 10px; background: var(--surface); color: var(--muted); font-size: 10px; cursor: pointer; }
.admin-button { height: 42px; padding: 0 14px; display: inline-flex; align-items: center; gap: 7px; border: 1px solid var(--line); border-radius: 12px; background: var(--surface); color: var(--text); font-size: 9px; font-weight: 700; cursor: pointer; }
.admin-button svg { width: 17px; fill: none; stroke: currentColor; stroke-width: 1.7; }
.admin-button:hover { border-color: #bbc5c1; box-shadow: var(--shadow-sm); }
.icon-button { width: 43px; height: 43px; display: grid; place-items: center; border: 1px solid var(--line); border-radius: 13px; background: var(--surface); cursor: pointer; box-shadow: 0 2px 8px rgba(20,40,59,.03); transition: .2s; }
.icon-button:hover { border-color: #bdc7c3; transform: translateY(-1px); box-shadow: var(--shadow-sm); }
.icon-button svg { width: 20px; fill: none; stroke: currentColor; stroke-width: 1.7; }
main { max-width: 1180px; margin: 0 auto; padding: 54px 24px 110px; }
.page-intro { margin-bottom: 30px; display: flex; justify-content: space-between; align-items: end; }
.page-intro h1 { margin: 0; font-family: var(--display); font-size: clamp(38px, 4.8vw, 58px); font-weight: 600; line-height: 1; letter-spacing: -.055em; }
.page-intro > p { max-width: 280px; margin: 0 0 5px; color: var(--muted); font-size: 12px; text-align: right; }

/* Main punch area */
.hero-grid { display: grid; grid-template-columns: 215px minmax(0, 1fr); gap: 18px; }
.date-card { min-height: 360px; padding: 25px; display: flex; flex-direction: column; border: 1px solid rgba(138,165,185,.25); border-radius: 25px; background: linear-gradient(160deg, #dceaff 0%, #eef5ff 100%); box-shadow: var(--shadow-sm); }
.date-card__top { display: flex; justify-content: space-between; align-items: center; color: #47657d; font-family: var(--mono); font-size: 8px; font-weight: 700; letter-spacing: .12em; }
.date-card__dot { width: 8px; height: 8px; border-radius: 50%; background: #6f98ba; box-shadow: 0 0 0 5px rgba(111,152,186,.12); }
.date-card > strong { margin-top: auto; font-family: var(--display); font-size: 92px; font-weight: 500; line-height: .9; letter-spacing: -.08em; color: #26465e; }
.date-card > span { margin-top: 8px; color: #587287; font-family: var(--mono); font-size: 9px; letter-spacing: .12em; }
.date-card p { margin: 28px 0 0; padding-top: 20px; border-top: 1px solid rgba(65,100,126,.15); color: #5f7a8e; font-size: 10px; line-height: 1.55; }
.punch-card { position: relative; min-height: 360px; overflow: hidden; display: flex; flex-direction: column; border-radius: 25px; background: linear-gradient(135deg, #173146 0%, var(--navy-deep) 100%); color: #fff; box-shadow: var(--shadow-lg); }
.punch-card__glow { position: absolute; width: 360px; height: 360px; right: -100px; top: -205px; border-radius: 50%; background: rgba(98, 208, 175, .12); box-shadow: 0 0 90px rgba(98,208,175,.12); }
.punch-card__topline { position: relative; z-index: 1; padding: 22px 27px 0; display: flex; align-items: center; justify-content: space-between; }
.status-badge { padding: 8px 11px; display: inline-flex; align-items: center; gap: 8px; border: 1px solid rgba(255,255,255,.1); border-radius: 999px; background: rgba(255,255,255,.06); color: rgba(255,255,255,.63); font-family: var(--mono); font-size: 8px; letter-spacing: .08em; }
.status-dot { width: 7px; height: 7px; border-radius: 50%; background: #8fa0ad; }
.is-active .status-dot { background: var(--success); box-shadow: 0 0 0 5px rgba(68,211,162,.13); animation: pulse 1.8s infinite; }
.is-active .status-badge { color: #9ce9d0; background: rgba(68,211,162,.08); }
.serial { color: rgba(255,255,255,.27); font-family: var(--mono); font-size: 8px; letter-spacing: .11em; }
.punch-card__content { position: relative; z-index: 1; flex: 1; padding: 24px 34px 25px; display: flex; align-items: center; justify-content: space-between; gap: 30px; }
.clock-wrap .eyebrow { color: rgba(255,255,255,.4); }
.live-clock { display: block; font-family: var(--display); font-size: clamp(62px, 7.7vw, 92px); font-weight: 500; line-height: .94; letter-spacing: -.075em; font-variant-numeric: tabular-nums; }
.live-clock span { margin-left: 11px; color: var(--success); font-family: var(--mono); font-size: .18em; letter-spacing: 0; vertical-align: top; }
.shift-caption { margin: 14px 0 0; color: rgba(255,255,255,.48); font-size: 11px; }
.punch-button { min-width: 196px; padding: 17px 17px; display: flex; align-items: center; gap: 13px; border: 0; border-radius: 18px; background: var(--orange); color: #fff; cursor: pointer; box-shadow: 0 13px 30px rgba(0,0,0,.2); transition: .22s cubic-bezier(.2,.8,.2,1); }
.punch-button:hover { background: #ff7959; transform: translateY(-2px); box-shadow: 0 18px 34px rgba(0,0,0,.24); }
.punch-button:active { transform: translateY(0) scale(.98); }
.punch-button:disabled { cursor: wait; opacity: .7; }
.punch-button__icon { width: 42px; height: 42px; display: grid; place-items: center; flex: 0 0 auto; border-radius: 13px; background: rgba(255,255,255,.16); font-size: 20px; }
.punch-button__copy { text-align: left; }
.punch-button__copy small { display: block; margin-bottom: 4px; color: rgba(255,255,255,.66); font-family: var(--mono); font-size: 7px; letter-spacing: .09em; }
.punch-button__copy strong { font-size: 12px; letter-spacing: .015em; }
.is-active .punch-button { background: #e7edf0; color: var(--navy); }
.is-active .punch-button__icon { background: rgba(20,40,59,.08); }
.is-active .punch-button__copy small { color: rgba(20,40,59,.55); }
.punch-card__footer { position: relative; z-index: 1; padding: 16px 28px; display: grid; grid-template-columns: 1fr 1fr; gap: 30px; border-top: 1px solid rgba(255,255,255,.08); background: rgba(0,0,0,.08); }
.punch-card__footer > span { display: flex; flex-direction: column; gap: 5px; }
.punch-card__footer > span:last-child { padding-left: 25px; border-left: 1px solid rgba(255,255,255,.08); }
.punch-card__footer small { color: rgba(255,255,255,.32); font-family: var(--mono); font-size: 7px; letter-spacing: .09em; }
.punch-card__footer strong { color: rgba(255,255,255,.78); font-size: 11px; font-weight: 600; }
.punch-card__footer > span:last-child strong { color: #87dfc1; }

/* Sections and stats */
.month-section, .entries-section { margin-top: 78px; }
.section-heading { margin-bottom: 24px; display: flex; justify-content: space-between; align-items: end; gap: 25px; }
.section-heading h2, .dialog-header h2 { margin: 0; font-family: var(--display); font-size: clamp(30px, 4vw, 43px); font-weight: 600; line-height: 1; letter-spacing: -.045em; }
.month-nav { height: 43px; display: flex; align-items: center; gap: 3px; padding: 4px; border: 1px solid var(--line); border-radius: 13px; background: var(--surface); box-shadow: 0 3px 12px rgba(20,40,59,.03); }
.month-nav button { height: 33px; min-width: 34px; border: 0; border-radius: 9px; background: transparent; cursor: pointer; transition: .15s; }
.month-nav button:hover { background: var(--surface-soft); }
.month-nav .month-label { min-width: 128px; color: var(--text); font-family: var(--mono); font-size: 8px; font-weight: 700; letter-spacing: .08em; }
.stat-grid { display: grid; grid-template-columns: 1.2fr 1fr .8fr; gap: 14px; }
.stat-card { min-height: 226px; padding: 22px; display: flex; flex-direction: column; border: 1px solid var(--line); border-radius: 21px; background: var(--surface); box-shadow: var(--shadow-sm); }
.stat-card__head { display: flex; align-items: center; justify-content: space-between; margin-bottom: auto; }
.stat-icon { width: 39px; height: 39px; display: grid; place-items: center; border-radius: 12px; }
.stat-icon svg { width: 19px; fill: none; stroke: currentColor; stroke-width: 1.7; }
.stat-card--hours .stat-icon { background: var(--blue); color: #456b9d; }
.stat-card--money .stat-icon { background: var(--aqua); color: #2c7661; }
.stat-card--shifts .stat-icon { background: var(--sand); color: #9a6741; }
.stat-index { color: #a7afb2; font-family: var(--mono); font-size: 8px; }
.stat-card > p { margin: 25px 0 9px; color: var(--muted); font-family: var(--mono); font-size: 8px; letter-spacing: .11em; }
.stat-card > strong { font-family: var(--display); font-size: clamp(32px, 4vw, 47px); font-weight: 600; line-height: 1; letter-spacing: -.055em; }
.stat-card > strong small { font-size: .45em; }
.stat-card > small { margin-top: 10px; color: var(--muted); font-size: 9px; }
.progress-track { height: 5px; margin-top: 22px; overflow: hidden; border-radius: 999px; background: #ecf0ef; }
.progress-track span { display: block; width: 0; height: 100%; border-radius: inherit; background: linear-gradient(90deg, #5a8bc6, #77b9d5); transition: width .8s cubic-bezier(.2,.8,.2,1); }

/* Entries */
.section-heading--entries { align-items: center; }
.outline-button { padding: 12px 16px; border: 1px solid var(--line); border-radius: 13px; background: var(--surface); font-size: 10px; font-weight: 700; cursor: pointer; box-shadow: 0 3px 12px rgba(20,40,59,.03); transition: .18s; }
.outline-button span { margin-right: 5px; color: var(--orange); font-size: 14px; }
.outline-button:hover { border-color: #bbc5c1; transform: translateY(-1px); box-shadow: var(--shadow-sm); }
.entries-surface { overflow: hidden; border: 1px solid var(--line); border-radius: 21px; background: var(--surface); box-shadow: var(--shadow-sm); }
.day-group + .day-group { border-top: 1px solid var(--line); }
.day-heading { padding: 20px 23px 12px; display: flex; align-items: baseline; justify-content: space-between; gap: 20px; background: #fafbfb; }
.day-heading strong { font-family: var(--display); font-size: 16px; font-weight: 600; letter-spacing: -.02em; }
.day-heading span { color: var(--muted); font-family: var(--mono); font-size: 7px; letter-spacing: .09em; }
.entry-row { min-height: 76px; margin: 0 23px; display: grid; grid-template-columns: 135px 1.25fr 1fr .8fr 40px; align-items: center; gap: 18px; border-top: 1px solid #edf0ef; }
.entry-time { font-family: var(--mono); font-size: 10px; font-weight: 700; }
.entry-time > span:not(.active-chip) { margin: 0 4px; color: #b1b8bb; }
.active-chip { display: inline-block; margin-left: 7px; padding: 4px 6px; border-radius: 6px; background: #d7f5ea; color: #347c66; font-family: var(--mono); font-size: 6px; letter-spacing: .07em; }
.entry-duration strong, .entry-earnings strong { display: block; font-family: var(--display); font-size: 17px; font-weight: 600; letter-spacing: -.025em; }
.entry-duration small, .entry-earnings small, .entry-note { color: var(--muted); font-size: 9px; }
.entry-note { overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
.edit-entry { width: 36px; height: 36px; display: grid; place-items: center; border: 1px solid var(--line); border-radius: 11px; background: #fafbfb; color: var(--muted); cursor: pointer; transition: .18s; }
.edit-entry:hover { border-color: #b9c3bf; background: var(--surface-soft); color: var(--text); }
.empty-state { padding: 65px 20px 70px; text-align: center; }
.empty-icon { width: 58px; height: 58px; margin: 0 auto 18px; display: grid; place-items: center; border-radius: 18px; background: var(--blue); color: #5a7ca6; }
.empty-icon svg { width: 27px; fill: none; stroke: currentColor; stroke-width: 1.5; }
.empty-state h3 { margin: 0 0 7px; font-family: var(--display); font-size: 20px; }
.empty-state p { margin: 0; color: var(--muted); font-size: 11px; }
.site-footer { max-width: 1180px; margin: 0 auto; padding: 24px; display: flex; justify-content: space-between; border-top: 1px solid var(--line); color: var(--muted); font-size: 9px; }

/* Dialogs */
.sheet-dialog { width: min(660px, calc(100% - 28px)); max-height: min(820px, calc(100% - 28px)); padding: 0; border: 0; border-radius: 23px; background: var(--surface); color: var(--text); box-shadow: 0 30px 100px rgba(7,20,30,.32); }
.sheet-dialog::backdrop { background: rgba(11,24,35,.62); backdrop-filter: blur(5px); }
.sheet-dialog[open] { animation: dialog-in .25s ease-out; }
.dialog-shell { padding: 29px; }
.dialog-header { display: flex; justify-content: space-between; align-items: flex-start; gap: 20px; padding-bottom: 21px; border-bottom: 1px solid var(--line); }
.dialog-header h2 { font-size: 35px; }
.dialog-close { width: 38px; height: 38px; border: 1px solid var(--line); border-radius: 11px; background: var(--canvas); color: var(--muted); font-size: 24px; line-height: 1; cursor: pointer; }
.form-grid { padding: 27px 0; display: grid; grid-template-columns: 1fr 1fr; gap: 20px; }
.form-grid label { display: flex; flex-direction: column; gap: 8px; color: var(--text); font-size: 10px; font-weight: 700; }
.form-grid label span { color: var(--muted); font-weight: 400; }
.form-wide { grid-column: 1 / -1; }
.form-grid input, .form-grid select { width: 100%; height: 49px; padding: 0 13px; border: 1px solid var(--line); border-radius: 12px; background: var(--canvas); color: var(--text); font-size: 13px; }
.form-grid input:focus, .form-grid select:focus { border-color: #94a49e; background: #fff; }
.setting-note { margin: -4px 0 8px; padding: 13px 14px; border-radius: 10px; background: #eff5f3; color: #56726a; font-size: 9px; line-height: 1.55; }
.dialog-section-title { margin-top: 22px; padding-bottom: 11px; display: flex; align-items: center; gap: 9px; border-bottom: 1px solid var(--line); }
.dialog-section-title span { width: 25px; height: 20px; display: grid; place-items: center; border-radius: 6px; background: var(--surface-soft); color: var(--muted); font-family: var(--mono); font-size: 7px; }
.dialog-section-title strong { font-size: 10px; }
.dialog-section-title small { color: var(--muted); font-weight: 400; }
.form-grid--profile { padding-bottom: 4px; }
.form-grid input[readonly] { color: var(--muted); cursor: not-allowed; }
.dialog-actions { padding-top: 20px; display: flex; justify-content: flex-end; align-items: center; gap: 14px; border-top: 1px solid var(--line); }
.dialog-actions--split { justify-content: space-between; }
.solid-button { padding: 13px 17px; border: 0; border-radius: 12px; background: var(--navy); color: #fff; font-size: 10px; font-weight: 700; cursor: pointer; }
.solid-button span { margin-left: 14px; color: var(--aqua); }
.danger-button, .logout-button { border: 0; border-bottom: 1px solid currentColor; padding: 5px 0; background: transparent; color: var(--danger); font-size: 9px; cursor: pointer; }
.logout-button { color: var(--muted); }

/* Admin */
.admin-dialog { width: min(1060px, calc(100% - 24px)); height: min(780px, calc(100% - 24px)); padding: 0; border: 0; border-radius: 25px; background: var(--surface); color: var(--text); box-shadow: 0 35px 120px rgba(7,20,30,.4); }
.admin-dialog::backdrop { background: rgba(8,21,31,.68); backdrop-filter: blur(5px); }
.admin-shell { height: 100%; display: flex; flex-direction: column; }
.admin-header { padding: 26px 29px 22px; display: flex; align-items: flex-start; justify-content: space-between; border-bottom: 1px solid var(--line); }
.admin-header h2 { margin: 0; font-family: var(--display); font-size: 35px; letter-spacing: -.045em; }
.admin-layout { min-height: 0; flex: 1; display: grid; grid-template-columns: 190px minmax(0, 1fr); }
.admin-sidebar { padding: 20px 13px; display: flex; flex-direction: column; gap: 5px; border-right: 1px solid var(--line); background: #f7f9f8; }
.admin-nav { padding: 13px 14px; display: flex; align-items: center; gap: 10px; border: 0; border-radius: 11px; background: transparent; color: var(--muted); font-size: 10px; font-weight: 700; text-align: left; cursor: pointer; }
.admin-nav span { font-family: var(--mono); font-size: 7px; opacity: .55; }
.admin-nav.is-active { background: var(--navy); color: #fff; box-shadow: 0 9px 20px rgba(20,40,59,.16); }
.admin-content { overflow: auto; padding: 27px 29px 40px; }
.admin-panel-heading { margin-bottom: 20px; display: flex; align-items: center; justify-content: space-between; gap: 20px; }
.admin-panel-heading h3 { margin: 0; font-family: var(--display); font-size: 25px; letter-spacing: -.035em; }
.admin-panel-heading p { margin: 5px 0 0; color: var(--muted); font-size: 10px; }
.create-user-card, .system-card { margin-bottom: 18px; padding: 20px; border: 1px solid #cddbd6; border-radius: 17px; background: #f5f9f7; }
.create-user-head { margin-bottom: 16px; display: flex; justify-content: space-between; }
.create-user-head strong { font-size: 11px; }
.create-user-head button { border: 0; background: transparent; color: var(--muted); cursor: pointer; }
.admin-form-grid { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 13px; }
.admin-form-grid label, .system-card > label:not(.switch-row) { display: flex; flex-direction: column; gap: 6px; font-size: 8px; font-weight: 700; }
.admin-form-grid input, .admin-form-grid select, .system-card input[type="text"] { width: 100%; height: 42px; padding: 0 11px; border: 1px solid var(--line); border-radius: 10px; background: #fff; color: var(--text); font-size: 10px; }
.create-user-card > .solid-button { margin-top: 5px; }
.admin-user-list { display: flex; flex-direction: column; gap: 9px; }
.admin-user-card { border: 1px solid var(--line); border-radius: 15px; background: #fff; transition: .18s; }
.admin-user-card:hover { border-color: #c6cfcc; box-shadow: var(--shadow-sm); }
.admin-user-summary { min-height: 70px; padding: 12px 14px; display: grid; grid-template-columns: 42px minmax(140px, 1fr) minmax(140px, .8fr) auto 34px; align-items: center; gap: 12px; }
.user-avatar { width: 38px; height: 38px; display: grid; place-items: center; border-radius: 12px; background: var(--blue); color: #486987; font-family: var(--display); font-size: 14px; font-weight: 700; }
.admin-user-name strong, .admin-user-contact strong { display: block; font-size: 10px; }
.admin-user-name small, .admin-user-contact small { display: block; margin-top: 3px; color: var(--muted); font-size: 8px; }
.role-chip { padding: 6px 8px; border-radius: 999px; background: var(--surface-soft); color: var(--muted); font-family: var(--mono); font-size: 6px; letter-spacing: .06em; }
.role-chip--admin { background: #e2edff; color: #4a6e9c; }
.role-chip--inactive { background: #f8e5e1; color: #a65343; }
.expand-user { width: 32px; height: 32px; border: 0; border-radius: 9px; background: var(--canvas); color: var(--muted); cursor: pointer; }
.admin-user-editor { padding: 17px; border-top: 1px solid var(--line); background: #fafbfb; }
.admin-user-editor[hidden] { display: none; }
.admin-user-actions { margin-top: 14px; display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.admin-active-label { flex-direction: row !important; align-items: center; justify-content: space-between; padding: 0 11px; border: 1px solid var(--line); border-radius: 10px; background: #fff; }
.admin-active-label input { width: 19px; height: 19px; accent-color: var(--orange); }
.admin-loading { padding: 28px; color: var(--muted); text-align: center; font-size: 10px; }
.invite-button { border: 0; border-bottom: 1px solid currentColor; padding: 4px 0; background: transparent; color: #4c776b; font-size: 8px; cursor: pointer; }
.setup-link-result { margin: 10px 0 0; padding: 10px; border-radius: 9px; background: #fff4df; color: #765b2c; font-size: 8px; line-height: 1.5; word-break: break-all; }
.system-card { max-width: 580px; padding: 23px; background: #fafbfb; }
.switch-row { margin-top: 22px; padding: 16px 0; display: flex; align-items: center; justify-content: space-between; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.switch-row span { display: flex; flex-direction: column; gap: 4px; }
.switch-row strong { font-size: 10px; }
.switch-row small { color: var(--muted); font-size: 8px; }
.switch-row input { width: 38px; height: 21px; accent-color: var(--orange); }
.smtp-status { margin: 18px 0; padding: 14px; border-radius: 11px; background: var(--surface-soft); font-size: 9px; line-height: 1.6; }
.smtp-status.is-ready { background: #e8f6f1; color: #397361; }

/* Feedback */
.toast { position: fixed; left: 50%; bottom: 26px; z-index: 200; max-width: calc(100% - 30px); padding: 13px 18px; transform: translate(-50%, 100px); border-radius: 12px; background: var(--navy); color: #fff; box-shadow: var(--shadow-lg); font-size: 11px; opacity: 0; transition: .28s ease; }
.toast.is-visible { transform: translate(-50%, 0); opacity: 1; }
.toast.is-error { background: var(--danger); }
.reveal { opacity: 0; transform: translateY(12px); animation: reveal .48s ease forwards; }
.reveal--1 { animation-delay: .03s; }
.reveal--2 { animation-delay: .11s; }
.reveal--3 { animation-delay: .18s; }

@keyframes reveal { to { opacity: 1; transform: translateY(0); } }
@keyframes pulse { 65% { box-shadow: 0 0 0 6px rgba(68,211,162,0); } 100% { box-shadow: 0 0 0 0 rgba(68,211,162,0); } }
@keyframes dialog-in { from { opacity: 0; transform: translateY(14px) scale(.985); } }

@media (max-width: 900px) {
  .admin-layout { grid-template-columns: 1fr; }
  .admin-sidebar { padding: 10px 14px; flex-direction: row; border-right: 0; border-bottom: 1px solid var(--line); }
  .admin-nav { flex: 1; justify-content: center; }
  .admin-form-grid { grid-template-columns: 1fr 1fr; }
  .admin-user-summary { grid-template-columns: 42px 1fr auto 34px; }
  .admin-user-contact { display: none; }
  .hero-grid { grid-template-columns: 175px minmax(0, 1fr); }
  .date-card { min-height: 345px; padding: 20px; }
  .date-card > strong { font-size: 72px; }
  .punch-card { min-height: 345px; }
  .punch-card__content { padding: 22px 26px; }
  .punch-button { min-width: 175px; }
  .stat-grid { grid-template-columns: 1fr 1fr; }
  .stat-card--hours { grid-column: 1 / -1; }
  .entry-row { grid-template-columns: 120px 1fr 1fr 40px; }
  .entry-note { display: none; }
}

@media (max-width: 680px) {
  .login-screen { padding: 22px 14px 28px; place-items: start center; overflow-x: hidden; overflow-y: auto; }
  .login-time { display: none; }
  .login-card { padding: 28px 22px 25px; border-radius: 23px; }
  .login-copy { margin: 38px 0 28px; }
  .login-copy h1 { font-size: 45px; }
  .login-footnote { position: static; margin-top: 18px; }
  .site-header { height: 70px; padding: 0 16px; }
  .brand-mark { width: 38px; height: 38px; border-radius: 12px; }
  .brand-mark i::before, .brand-mark i::after { left: 18px; top: 10px; }
  .brand strong { font-size: 15px; }
  .install-button { display: none !important; }
  .admin-button { width: 42px; padding: 0; justify-content: center; font-size: 0; }
  .admin-button svg { width: 19px; }
  main { padding: 34px 15px 75px; }
  .page-intro { margin-bottom: 22px; }
  .page-intro > p { display: none; }
  .page-intro h1 { font-size: 38px; }
  .hero-grid { grid-template-columns: 1fr; gap: 12px; }
  .date-card { min-height: auto; padding: 14px 17px; display: grid; grid-template-columns: 1fr auto auto; align-items: center; gap: 10px; border-radius: 17px; }
  .date-card__top { display: block; }
  .date-card__dot { display: none; }
  .date-card > strong { margin: 0; font-size: 35px; letter-spacing: -.05em; }
  .date-card > span { margin: 0; font-size: 8px; }
  .date-card p { display: none; }
  .punch-card { min-height: 430px; border-radius: 21px; }
  .punch-card__topline { padding: 18px 18px 0; }
  .punch-card__content { flex-direction: column; align-items: stretch; justify-content: center; gap: 27px; padding: 27px 20px 24px; }
  .live-clock { font-size: clamp(62px, 20vw, 84px); }
  .punch-button { width: 100%; padding: 14px; }
  .punch-card__footer { padding: 15px 19px; gap: 15px; }
  .punch-card__footer > span:last-child { padding-left: 15px; }
  .punch-card__footer strong { font-size: 9px; }
  .month-section, .entries-section { margin-top: 58px; }
  .section-heading { display: block; }
  .month-nav { margin-top: 19px; justify-content: space-between; }
  .stat-grid { grid-template-columns: 1fr 1fr; gap: 10px; }
  .stat-card { min-height: 190px; padding: 18px; border-radius: 18px; }
  .stat-card--hours { grid-column: 1 / -1; }
  .stat-card > strong { font-size: 34px; }
  .section-heading--entries { display: flex; align-items: center; }
  .section-heading--entries .eyebrow { display: none; }
  .section-heading--entries h2 { font-size: 27px; }
  .outline-button { padding: 11px 12px; font-size: 0; }
  .outline-button span { margin: 0; font-size: 17px; }
  .entries-surface { border-radius: 18px; }
  .day-heading { padding: 17px 16px 10px; }
  .day-heading strong { font-size: 14px; }
  .entry-row { min-height: 83px; margin: 0 16px; grid-template-columns: 1fr auto 38px; gap: 8px; }
  .entry-time { grid-column: 1; }
  .entry-duration { grid-column: 2; text-align: right; }
  .entry-earnings { grid-column: 1; grid-row: 2; }
  .entry-note { display: none; }
  .edit-entry { grid-column: 3; grid-row: 1 / 3; }
  .site-footer { padding: 22px 16px; }
  .site-footer > span:last-child { display: none; }
  .sheet-dialog { width: calc(100% - 18px); max-height: calc(100% - 18px); border-radius: 19px; }
  .dialog-shell { padding: 21px 17px; }
  .dialog-header h2 { font-size: 29px; }
  .form-grid { grid-template-columns: 1fr; gap: 17px; }
  .form-wide { grid-column: 1; }
  .admin-dialog { width: calc(100% - 10px); height: calc(100% - 10px); border-radius: 19px; }
  .admin-header { padding: 19px 17px 16px; }
  .admin-header h2 { font-size: 27px; }
  .admin-content { padding: 20px 14px 30px; }
  .admin-form-grid { grid-template-columns: 1fr; }
  .admin-panel-heading { align-items: flex-start; }
  .admin-panel-heading h3 { font-size: 21px; }
  .admin-user-summary { grid-template-columns: 38px 1fr 32px; gap: 9px; }
  .admin-user-summary .role-chip { display: none; }
  .admin-user-editor { padding: 13px; }
  .admin-user-actions { align-items: flex-end; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; }
}
