:root {
  --ink: #22302f;
  --muted: #60706d;
  --line: #dfe7e2;
  --paper: #fbfaf6;
  --white: #ffffff;
  --sage: #416b62;
  --sage-dark: #244a45;
  --mint: #dceee6;
  --rose: #b95f50;
  --gold: #d7a74a;
  --danger: #b84242;
  --shadow: 0 18px 50px rgba(34, 48, 47, .11);
}

* {
  box-sizing: border-box;
}

[hidden] {
  display: none !important;
}

body {
  margin: 0;
  color: var(--ink);
  background: var(--paper);
  font-family: Arial, Helvetica, sans-serif;
  line-height: 1.55;
}

a {
  color: var(--sage-dark);
  text-decoration: none;
}

a:hover {
  text-decoration: underline;
}

img {
  max-width: 100%;
  display: block;
}

button,
input,
select,
textarea {
  font: inherit;
}

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

h1 {
  font-size: clamp(2.2rem, 4vw, 4.8rem);
  line-height: 1.02;
  letter-spacing: 0;
}

h2 {
  font-size: clamp(1.5rem, 2vw, 2.25rem);
  line-height: 1.15;
  letter-spacing: 0;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: .85rem clamp(1rem, 4vw, 3rem);
  background: rgba(251, 250, 246, .96);
  border-bottom: 1px solid var(--line);
  backdrop-filter: blur(12px);
}

/* ── Admin sidebar layout ──────────────────────────── */

.admin-layout {
  display: flex;
  min-height: 100vh;
}

.admin-sidebar {
  width: 228px;
  flex-shrink: 0;
  background: var(--white);
  border-right: 1px solid var(--line);
  display: flex;
  flex-direction: column;
  position: sticky;
  top: 0;
  height: 100vh;
  overflow-y: auto;
  z-index: 100;
}

.admin-content {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
}

.sidebar-brand {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: .9rem 1rem .8rem;
  border-bottom: 1px solid var(--line);
}

.sidebar-close-btn {
  display: none;
  border: 0;
  background: transparent;
  cursor: pointer;
  font-size: 1.1rem;
  color: var(--muted);
  padding: .1rem .3rem;
  line-height: 1;
}

.sidebar-nav {
  flex: 1;
  padding: .6rem 0;
  overflow-y: auto;
}

.sidebar-section {
  margin: 0;
  padding: .7rem 1rem .2rem;
  font-size: .65rem;
  font-weight: 900;
  text-transform: uppercase;
  letter-spacing: .07em;
  color: var(--muted);
}

.sidebar-link {
  display: block;
  margin: .05rem .55rem;
  padding: .48rem .65rem;
  border-radius: 6px;
  color: var(--ink);
  font-size: .88rem;
  font-weight: 600;
  text-decoration: none;
}

.sidebar-link:hover {
  background: var(--mint);
  color: var(--sage-dark);
  text-decoration: none;
}

.sidebar-link.active {
  background: var(--mint);
  color: var(--sage-dark);
  font-weight: 700;
}

.sidebar-footer {
  padding: .85rem 1rem;
  border-top: 1px solid var(--line);
  display: flex;
  flex-direction: column;
  gap: .6rem;
}

.sidebar-user-info {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: .35rem;
  font-size: .82rem;
}

.role-pill {
  display: inline-flex;
  align-items: center;
  background: var(--rose);
  color: var(--white);
  border-radius: 999px;
  padding: .08rem .45rem;
  font-size: .68rem;
  font-weight: 900;
  text-transform: capitalize;
}

.sidebar-signout {
  width: 100%;
  justify-content: center;
}

/* Sidebar overlay (mobile) */
.sidebar-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(22, 38, 36, .45);
  z-index: 400;
}

.sidebar-overlay.open {
  display: block;
}

/* Admin topbar (thin strip at top of content area) */
.admin-topbar {
  position: sticky;
  top: 0;
  z-index: 90;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: .85rem;
  padding: .6rem 1.5rem;
  background: rgba(251, 250, 246, .97);
  border-bottom: 1px solid var(--line);
  backdrop-filter: blur(12px);
}

.nav-toggle {
  display: none;
  border: 1px solid var(--line);
  background: var(--white);
  border-radius: 8px;
  padding: .38rem .62rem;
  font-size: 1.1rem;
  line-height: 1;
  cursor: pointer;
  flex-shrink: 0;
}

.topbar-title {
  font-weight: 800;
  font-size: .95rem;
  color: var(--ink);
}

.topbar-user-pill {
  display: flex;
  align-items: center;
  gap: .35rem;
  font-size: .82rem;
  flex-shrink: 0;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: .65rem;
  color: var(--ink);
  font-weight: 800;
  text-decoration: none;
}

.brand-mark {
  display: grid;
  place-items: center;
  width: 2.35rem;
  height: 2.35rem;
  color: var(--white);
  background: var(--sage);
  border-radius: 8px;
  font-size: .85rem;
}

.site-nav {
  display: flex;
  align-items: center;
  gap: .85rem;
  flex-wrap: wrap;
}

.site-nav a {
  color: var(--ink);
  font-weight: 700;
  font-size: .94rem;
}

.site-nav a.active {
  color: var(--sage-dark);
  text-decoration: underline;
  text-decoration-thickness: 2px;
  text-underline-offset: .25rem;
}

.admin-site-header {
  flex-wrap: wrap;
  z-index: 90;
}

.admin-site-header .brand {
  flex-shrink: 0;
}

.admin-site-nav {
  flex: 1 1 520px;
  gap: .15rem;
  justify-content: flex-end;
  min-width: 0;
}

.admin-site-nav a,
.admin-site-nav button.admin-nav-trigger {
  appearance: none;
  -webkit-appearance: none;
  display: inline-flex;
  align-items: center;
  min-height: 2.35rem;
  border: 0;
  border-bottom: 2px solid transparent;
  padding: .45rem .55rem;
  color: var(--ink);
  background: transparent;
  cursor: pointer;
  font-weight: 800;
  font-size: .9rem;
  text-decoration: none;
  white-space: nowrap;
}

.admin-site-nav a:hover,
.admin-site-nav button.admin-nav-trigger:hover {
  color: var(--sage-dark);
  text-decoration: none;
}

.admin-site-nav a.active,
.admin-site-nav button.admin-nav-trigger.active,
.admin-site-nav button.admin-nav-trigger.open {
  color: var(--sage-dark);
  border-bottom-color: var(--rose);
  text-decoration: none;
}

.admin-dropdown {
  position: relative;
  display: inline-flex;
}

.admin-site-nav button.admin-nav-trigger::after {
  content: "";
  width: 0;
  height: 0;
  margin-left: .35rem;
  border-left: .25rem solid transparent;
  border-right: .25rem solid transparent;
  border-top: .32rem solid currentColor;
}

.admin-dropdown-menu {
  position: absolute;
  top: calc(100% + .1rem);
  left: 0;
  z-index: 250;
  display: none;
  min-width: 180px;
  border: 1px solid var(--line);
  background: var(--white);
  box-shadow: 0 16px 40px rgba(34, 48, 47, .12);
}

.admin-dropdown.open .admin-dropdown-menu {
  display: grid;
}

@media (hover: hover) and (pointer: fine) {
  .admin-dropdown:hover .admin-dropdown-menu,
  .admin-dropdown:focus-within .admin-dropdown-menu {
    display: grid;
  }
}

.admin-dropdown-menu a {
  display: block;
  min-height: 0;
  border-bottom: 0;
  padding: .68rem .9rem;
  font-size: .86rem;
  font-weight: 700;
}

.admin-dropdown-menu a:hover,
.admin-dropdown-menu a.active {
  border-bottom: 0;
  background: var(--mint);
  color: var(--sage-dark);
}

.admin-nav-signout {
  margin: 0;
  margin-left: .7rem;
}

.admin-nav-signout .button {
  min-height: 2.2rem;
}

.link-button {
  border: 0;
  background: transparent;
  cursor: pointer;
  padding: 0;
}


.button,
button.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 2.65rem;
  padding: .72rem 1.05rem;
  border: 1px solid var(--sage);
  border-radius: 8px;
  color: var(--white);
  background: var(--sage);
  font-weight: 800;
  cursor: pointer;
  text-decoration: none;
  white-space: normal;
}

.button:hover {
  background: var(--sage-dark);
  text-decoration: none;
}

.button-small {
  min-height: 2.1rem;
  padding: .45rem .7rem;
  font-size: .9rem;
}

.button-outline {
  background: transparent;
  color: var(--sage-dark);
}

.button-outline.light {
  color: var(--white);
  border-color: rgba(255,255,255,.78);
}

.button-danger {
  background: var(--danger);
  border-color: var(--danger);
}

.button-row,
.table-actions {
  display: flex;
  align-items: center;
  gap: .65rem;
  flex-wrap: wrap;
}

.hero {
  min-height: min(72vh, 760px);
  display: grid;
  align-items: end;
  padding: clamp(5rem, 9vw, 9rem) clamp(1.1rem, 5vw, 5rem) clamp(3rem, 6vw, 5rem);
  color: var(--white);
  background-size: cover;
  background-position: center;
}

.hero-content {
  max-width: 760px;
}

.hero-content p {
  max-width: 680px;
  font-size: 1.18rem;
}

.eyebrow {
  color: var(--rose);
  font-weight: 900;
  text-transform: uppercase;
  letter-spacing: 0;
  font-size: .78rem;
}

.hero .eyebrow {
  color: var(--gold);
}

.section,
.page-hero,
.cta-band {
  padding: clamp(3rem, 7vw, 6rem) clamp(1.1rem, 5vw, 5rem);
}

.page-hero {
  background: var(--mint);
}

.page-hero h1 {
  max-width: 850px;
}

.section.narrow {
  max-width: 860px;
  margin: 0 auto;
}

.split,
.two-column,
.admin-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: clamp(1.4rem, 4vw, 3rem);
  align-items: start;
}

.section-image {
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  border-radius: 8px;
  box-shadow: var(--shadow);
}

.band {
  background: var(--white);
}

.section-heading {
  max-width: 720px;
  margin-bottom: 1.5rem;
}

.card-grid,
.quote-grid,
.metric-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1rem;
}

.review-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1rem;
}

.info-card,
.panel,
.metric,
blockquote {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 1.15rem;
  box-shadow: 0 12px 32px rgba(34, 48, 47, .07);
}

.info-card h2,
.info-card h3 {
  font-size: 1.15rem;
}

.quote-list {
  display: grid;
  gap: 1rem;
}

blockquote {
  margin: 0;
}

blockquote p {
  font-size: 1.05rem;
}

cite {
  color: var(--muted);
  font-style: normal;
  font-weight: 800;
}

.reviews-section {
  background: var(--paper);
}

.review-heading {
  max-width: none;
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 1rem;
  flex-wrap: wrap;
}

.review-heading > div:first-child {
  max-width: 720px;
}

.review-card {
  display: grid;
  gap: 1rem;
  align-content: start;
  min-height: 100%;
  background: var(--white);
  border: 1.5px solid #5bc6c5;
  border-radius: 8px;
  padding: clamp(1.35rem, 3vw, 2rem);
  box-shadow: 0 16px 36px rgba(34, 48, 47, .06);
}

.review-card h3 {
  margin-bottom: .2rem;
  color: #0f4d7a;
  font-size: clamp(1.35rem, 2vw, 1.8rem);
  line-height: 1.12;
}

.review-card p {
  margin-bottom: 0;
}

.review-quote {
  max-width: 34rem;
  color: var(--ink);
  font-size: 1.05rem;
  font-style: italic;
  line-height: 1.55;
}

.review-card footer {
  display: grid;
  gap: .2rem;
  margin-top: .5rem;
}

.star-rating {
  display: inline-flex;
  gap: .08rem;
  color: var(--gold);
  font-size: 1.35rem;
  line-height: 1;
  letter-spacing: 0;
}

.review-link {
  color: #89909a;
  font-weight: 800;
  text-decoration: none;
}

.review-link:hover {
  color: var(--sage-dark);
  text-decoration: underline;
}

.review-cta {
  display: flex;
  justify-content: center;
  margin-top: 2.75rem;
}

.cta-band {
  text-align: center;
  color: var(--white);
  background: var(--sage-dark);
}

.cta-band p {
  color: rgba(255,255,255,.86);
}

.site-footer {
  padding: 3rem clamp(1.1rem, 5vw, 5rem) 1.5rem;
  color: var(--white);
  background: #1f302e;
}

.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr;
  gap: 2rem;
}

.footer-grid a,
.footer-grid p {
  display: block;
  color: rgba(255,255,255,.82);
}

.footer-bottom {
  margin-top: 2rem;
  padding-top: 1rem;
  border-top: 1px solid rgba(255,255,255,.18);
  color: rgba(255,255,255,.7);
}

.auth-page {
  min-height: 72vh;
  display: grid;
  place-items: center;
  padding: 3rem 1rem;
}

.auth-panel {
  width: min(960px, 100%);
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2rem;
  align-items: center;
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: clamp(1.25rem, 4vw, 3rem);
  box-shadow: var(--shadow);
}

.stack-form {
  display: grid;
  gap: .9rem;
}

.form-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: .9rem;
}

label {
  display: grid;
  gap: .32rem;
  color: var(--ink);
  font-weight: 800;
}

input,
select,
textarea {
  width: 100%;
  border: 1px solid #cbd8d2;
  border-radius: 8px;
  background: var(--white);
  padding: .72rem .78rem;
  color: var(--ink);
}

textarea {
  resize: vertical;
}

.checkbox {
  display: flex;
  align-items: center;
  gap: .5rem;
}

.checkbox input {
  width: auto;
}

.fieldset {
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 1rem;
}

.fieldset legend {
  padding: 0 .4rem;
  color: var(--sage-dark);
  font-weight: 900;
}

.weekday-grid {
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  gap: .5rem;
  margin-top: .9rem;
}

.employee-actions {
  align-items: stretch;
}

.panel-divider {
  border: 0;
  border-top: 1px solid var(--line);
  margin: 1.2rem 0;
}

.flash {
  width: min(1100px, calc(100% - 2rem));
  margin: 1rem auto;
  border-radius: 8px;
  padding: .8rem 1rem;
  font-weight: 800;
}

.flash p {
  margin: 0;
}

.flash-success {
  background: #e6f4eb;
  color: #1e5b3f;
  border: 1px solid #b9ddc7;
}

.flash-error {
  background: #fde9e7;
  color: #8e332b;
  border: 1px solid #efb8b1;
}

.admin-body {
  background: #f5f7f4;
}

.admin-shell {
  width: min(1440px, 100%);
  margin: 0 auto;
  padding: 1rem clamp(1rem, 3vw, 2rem) 3rem;
}

.admin-identity {
  color: var(--muted);
  margin: .25rem 0 1rem;
}

.admin-identity span {
  margin-left: .5rem;
  color: var(--white);
  background: var(--rose);
  border-radius: 999px;
  padding: .18rem .5rem;
  font-size: .78rem;
}

.admin-page-heading,
.panel-heading,
.filter-bar,
.inline-form {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  flex-wrap: wrap;
}

.admin-page-heading {
  margin: 1rem 0 1.2rem;
}

.admin-page-heading h1 {
  font-size: clamp(1.8rem, 3vw, 3rem);
}

.metric-grid {
  margin-bottom: 1rem;
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.metric span {
  display: block;
  font-size: 2rem;
  color: var(--sage-dark);
  font-weight: 900;
}

.metric {
  color: var(--ink);
  text-decoration: none;
}

.metric:hover {
  border-color: var(--sage);
  transform: translateY(-1px);
  text-decoration: none;
}

.metric p {
  color: var(--muted);
  margin-bottom: 0;
}

.admin-grid {
  margin-bottom: 1rem;
}

.admin-grid.wide {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.panel {
  overflow: hidden;
}

.table-wrap {
  width: 100%;
  overflow-x: auto;
}

table {
  width: 100%;
  border-collapse: collapse;
  min-width: 720px;
}

th,
td {
  text-align: left;
  padding: .75rem;
  border-bottom: 1px solid var(--line);
  vertical-align: top;
}

th {
  color: var(--muted);
  font-size: .82rem;
  text-transform: uppercase;
  letter-spacing: 0;
}

.status {
  display: inline-flex;
  align-items: center;
  border-radius: 999px;
  background: var(--mint);
  color: var(--sage-dark);
  padding: .18rem .5rem;
  font-size: .82rem;
  font-weight: 900;
}

.list-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.5fr) auto;
  gap: .75rem;
  align-items: center;
  padding: .7rem 0;
  border-bottom: 1px solid var(--line);
}

.note {
  border-top: 1px solid var(--line);
  padding: 1rem 0;
}

.note small,
small {
  color: var(--muted);
}

.filter-bar {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: .8rem;
  margin-bottom: 1rem;
}

.filter-bar input,
.filter-bar select,
.inline-form select {
  width: auto;
  min-width: 180px;
}

.cms-selector {
  align-items: flex-end;
}

.cms-selector label {
  min-width: 240px;
}

.tab-nav {
  display: flex;
  align-items: center;
  gap: .45rem;
  flex-wrap: wrap;
}

.tab-nav a {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--white);
  padding: .48rem .75rem;
  color: var(--ink);
  font-weight: 800;
}

.tab-nav a.active,
.tab-nav a:hover {
  border-color: var(--sage);
  background: var(--mint);
  color: var(--sage-dark);
  text-decoration: none;
}

.page-tabs {
  margin-bottom: 1rem;
}

.cms-list-panel {
  margin-top: 1rem;
}

.image-preview-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1rem;
}

.image-preview-grid figure {
  margin: 0;
}

.image-preview-grid img {
  width: 100%;
  aspect-ratio: 16 / 9;
  object-fit: cover;
  border: 1px solid var(--line);
  border-radius: 8px;
}

.image-preview-grid figcaption {
  margin-top: .35rem;
  color: var(--muted);
  font-size: .9rem;
  font-weight: 800;
}

.datetime-pair {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1rem;
}

.datetime-card {
  border: 1px solid #bed0c8;
  border-radius: 8px;
  background: #f8fcfa;
  padding: 1rem;
}

.datetime-card input {
  margin-top: .2rem;
  border-color: #9fb8ae;
  background: var(--white);
}

.note-actions {
  margin-top: .65rem;
}

.note.is-editing [data-note-text],
.note.is-editing .note-actions {
  display: none;
}

.inquiry-message {
  white-space: pre-wrap;
}

.note-edit-form {
  margin: 0 0 .75rem;
}

.clock-panel h2 {
  font-size: clamp(1.4rem, 2vw, 2rem);
}

.decision-form {
  display: flex;
  align-items: center;
  gap: .45rem;
  margin-bottom: .4rem;
}

.decision-form input {
  min-width: 180px;
}

.compact-form {
  border-bottom: 1px solid var(--line);
  padding-bottom: 1rem;
  margin-bottom: 1rem;
}

.edit-row {
  display: grid;
  grid-template-columns: 1fr 1.5fr 90px auto auto;
  gap: .5rem;
  align-items: start;
  padding-top: 1rem;
  border-top: 1px solid var(--line);
}

.review-edit-row {
  grid-template-columns: 1fr 1fr 80px 120px 90px auto minmax(180px, 1.4fr) auto;
}

.link-danger {
  border: 0;
  background: transparent;
  color: var(--danger);
  padding: .2rem 0 .8rem;
  cursor: pointer;
  font-weight: 800;
}

.faq-list {
  display: grid;
  gap: .75rem;
}

details {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 1rem;
}

summary {
  cursor: pointer;
  font-weight: 900;
}

@media (max-width: 900px) {
  /* Sidebar slides in from left on mobile */
  .admin-sidebar {
    position: fixed;
    top: 0;
    left: 0;
    bottom: 0;
    height: 100%;
    z-index: 500;
    transform: translateX(-100%);
    transition: transform .22s ease;
  }

  .admin-sidebar.open {
    transform: translateX(0);
  }

  .sidebar-close-btn {
    display: block;
  }

  /* Show hamburger and user pill in topbar */
  .nav-toggle {
    display: inline-flex;
  }

  .topbar-user-pill {
    display: flex;
  }

  /* Public site nav */
  .site-nav {
    display: none;
    width: 100%;
    align-items: stretch;
    flex-direction: column;
  }

  .site-nav.open {
    display: flex;
  }

  .site-header {
    align-items: center;
    flex-wrap: wrap;
  }

  .admin-site-nav {
    gap: .3rem;
    justify-content: flex-start;
  }

  .admin-site-nav a,
  .admin-site-nav button.admin-nav-trigger,
  .admin-nav-signout .button {
    width: 100%;
    justify-content: flex-start;
  }

  .admin-dropdown {
    display: block;
    width: 100%;
  }

  .admin-site-nav button.admin-nav-trigger {
    justify-content: space-between;
  }

  .admin-dropdown-menu {
    position: static;
    width: 100%;
    min-width: 0;
    margin-bottom: .35rem;
    box-shadow: none;
  }

  .admin-dropdown-menu a {
    padding-left: 1rem;
  }

  /* Layout grids */
  .split,
  .two-column,
  .admin-grid,
  .auth-panel,
  .footer-grid,
  .admin-grid.wide {
    grid-template-columns: 1fr;
  }

  .card-grid,
  .quote-grid,
  .review-grid,
  .metric-grid {
    grid-template-columns: 1fr;
  }

  .form-grid,
  .edit-row,
  .review-edit-row,
  .weekday-grid,
  .datetime-pair,
  .image-preview-grid {
    grid-template-columns: 1fr;
  }

  .list-row {
    grid-template-columns: 1fr;
  }

  .filter-bar input,
  .filter-bar select,
  .inline-form select {
    width: 100%;
  }

  .hero {
    min-height: 640px;
  }

  /* Calendar */
  .schedule-layout {
    grid-template-columns: 1fr;
  }

  .cal-toolbar {
    gap: .5rem;
  }

  .cal-week-container {
    font-size: .78rem;
  }
}

@media (max-width: 980px) {
  .nav-toggle-public {
    display: inline-flex;
  }
}

/* ── Schedule Calendar ──────────────────────────── */

.schedule-layout {
  display: grid;
  grid-template-columns: 1fr 290px;
  gap: 1.2rem;
  align-items: start;
}

.cal-toolbar {
  display: flex;
  align-items: center;
  gap: .75rem;
  margin-bottom: .8rem;
  flex-wrap: wrap;
}

.cal-view-tabs {
  display: flex;
  gap: .2rem;
}

.cal-view-tabs a {
  display: inline-flex;
  align-items: center;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: var(--white);
  padding: .35rem .72rem;
  font-size: .85rem;
  font-weight: 700;
  color: var(--ink);
  text-decoration: none;
}

.cal-view-tabs a.active,
.cal-view-tabs a:hover {
  background: var(--mint);
  color: var(--sage-dark);
  border-color: var(--sage);
  text-decoration: none;
}

.cal-nav {
  display: flex;
  gap: .25rem;
}

.cal-title {
  font-size: 1rem;
  font-weight: 700;
  color: var(--ink);
}

/* Calendar container */
.cal-container {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: 8px;
  overflow: hidden;
  min-height: 400px;
}

/* Week view */
.cal-week-container {
  overflow-x: auto;
}

.cal-week-header {
  display: grid;
  grid-template-columns: 54px repeat(7, minmax(80px, 1fr));
  border-bottom: 2px solid var(--line);
  background: var(--paper);
}

.cal-time-gutter {
  border-right: 1px solid var(--line);
}

.cal-day-header {
  padding: .45rem .3rem;
  text-align: center;
  border-right: 1px solid var(--line);
}

.cal-day-header.today {
  background: var(--mint);
}

.cal-day-name {
  display: block;
  font-size: .72rem;
  font-weight: 900;
  text-transform: uppercase;
  color: var(--muted);
}

.cal-day-num {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 1.75rem;
  height: 1.75rem;
  font-size: .9rem;
  font-weight: 700;
}

.today-badge {
  background: var(--sage);
  color: var(--white);
  border-radius: 50%;
}

.cal-week-body {
  display: grid;
  grid-template-columns: 54px repeat(7, minmax(80px, 1fr));
}

.cal-time-gutter-col {
  border-right: 1px solid var(--line);
}

.cal-time-slot {
  border-bottom: 1px solid var(--line);
  font-size: .68rem;
  color: var(--muted);
  padding: .15rem .35rem 0;
  text-align: right;
}

.cal-day-col {
  border-right: 1px solid var(--line);
  cursor: crosshair;
}

.cal-day-col.today {
  background: rgba(220,238,230,.12);
}

.cal-hour-line {
  position: absolute;
  left: 0;
  right: 0;
  height: 1px;
  background: var(--line);
  pointer-events: none;
}

.cal-shift-block {
  position: absolute;
  left: 2px;
  right: 2px;
  border-radius: 4px;
  padding: 2px 4px;
  font-size: .73rem;
  color: var(--white);
  overflow: hidden;
  text-decoration: none;
  line-height: 1.3;
  z-index: 1;
  cursor: pointer;
}

.cal-shift-block:hover {
  filter: brightness(.88);
  text-decoration: none;
}

.cal-shift-time {
  display: block;
  font-size: .67rem;
  opacity: .85;
}

.cal-shift-name {
  display: block;
  font-weight: 700;
}

.cal-shift-client {
  display: block;
  opacity: .85;
}

/* Month view */
.cal-month {
  min-width: 0;
}

.cal-month-header {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  background: var(--paper);
  border-bottom: 1px solid var(--line);
}

.cal-month-dayname {
  padding: .4rem;
  text-align: center;
  font-size: .72rem;
  font-weight: 900;
  text-transform: uppercase;
  color: var(--muted);
}

.cal-month-row {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  border-bottom: 1px solid var(--line);
}

.cal-month-cell {
  border-right: 1px solid var(--line);
  padding: .35rem;
  min-height: 90px;
  cursor: pointer;
  vertical-align: top;
}

.cal-month-cell:hover {
  background: rgba(220,238,230,.2);
}

.cal-month-cell.other-month {
  background: var(--paper);
  opacity: .7;
}

.cal-month-cell.today {
  background: rgba(220,238,230,.35);
}

.cal-month-date {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 1.5rem;
  height: 1.5rem;
  font-size: .82rem;
  font-weight: 700;
  color: var(--muted);
  margin-bottom: .2rem;
}

.cal-month-cell.today .cal-month-date {
  background: var(--sage);
  color: var(--white);
  border-radius: 50%;
}

.cal-month-event {
  display: block;
  font-size: .7rem;
  color: var(--white);
  border-radius: 3px;
  padding: 1px 5px;
  margin-bottom: 2px;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
  text-decoration: none;
}

.cal-month-event:hover {
  filter: brightness(.88);
  text-decoration: none;
}

.cal-month-more {
  display: block;
  font-size: .7rem;
  color: var(--muted);
  font-weight: 700;
  padding: 0 2px;
}

/* Day view */
.cal-day-view {
  overflow-x: hidden;
}

.cal-day-view-grid {
  display: grid;
  grid-template-columns: 54px 1fr;
}

.cal-day-view-inner {
  position: relative;
}

.cal-day-hour {
  position: absolute;
  left: 0;
  right: 0;
  display: grid;
  grid-template-columns: 54px 1fr;
  pointer-events: none;
}

.cal-time-label {
  font-size: .68rem;
  color: var(--muted);
  text-align: right;
  padding-right: .5rem;
  line-height: 1;
}

.cal-day-hour-line {
  border-top: 1px solid var(--line);
}

.cal-day-shift {
  position: absolute;
  left: 60px;
  right: 8px;
  border-radius: 5px;
  padding: .35rem .5rem;
  font-size: .82rem;
  color: var(--white);
  text-decoration: none;
  overflow: hidden;
  line-height: 1.4;
  z-index: 1;
}

.cal-day-shift:hover {
  filter: brightness(.88);
  text-decoration: none;
}

/* Quick add panel */
.schedule-quick-add .panel {
  padding: 1.1rem;
}

.schedule-quick-add h2 {
  font-size: 1.1rem;
  margin-bottom: .8rem;
}

.cal-loading {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 300px;
  color: var(--muted);
  font-weight: 700;
}
