:root {
  --ink: #1c2430;
  --muted: #5c6775;
  --line: #d9e0e6;
  --paper: #f4f7f5;
  --panel: #ffffff;
  --green: #1f6b4a;
  --green-dark: #154c34;
  --amber: #8a5a12;
  --danger: #8d2d2d;
  --shadow: 0 10px 30px rgba(28, 36, 48, 0.06);
}

* { box-sizing: border-box; }
body {
  margin: 0;
  color: var(--ink);
  background: var(--paper);
  font-family: Outfit, "Segoe UI", sans-serif;
  line-height: 1.5;
}
h1, h2, h3 { font-family: Fraunces, Georgia, serif; font-weight: 560; line-height: 1.2; }
a { color: var(--green-dark); }
button, input, select, textarea { font: inherit; color: inherit; }
.wrap { width: min(1120px, calc(100% - 2rem)); margin-inline: auto; }
.topbar {
  background: var(--panel);
  border-bottom: 1px solid var(--line);
}
.topbar-inner, .footer-inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
  min-height: 4rem;
}
.brand { color: inherit; text-decoration: none; font-family: Fraunces, Georgia, serif; font-size: 1.35rem; }
.nav, .lang-switch, .card-actions, .admin-tabs { display: flex; flex-wrap: wrap; gap: 0.5rem; align-items: center; }
.page-main { padding: 2rem 0 4rem; }
.lede { max-width: 40rem; color: var(--muted); }
.kine-grid, .split { display: grid; gap: 1rem; }
.kine-grid { grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); margin: 1.5rem 0; }
.kine-card, .panel {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 16px;
  padding: 1rem 1.1rem;
  box-shadow: var(--shadow);
}
.kine-card h2, .panel h2 { margin: 0 0 0.35rem; font-size: 1.25rem; }
.kine-card p, .muted { color: var(--muted); }
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  padding: 0.55rem 0.95rem;
  border: 1px solid transparent;
  text-decoration: none;
  cursor: pointer;
  background: transparent;
}
.btn-solid { background: var(--green); color: white; }
.btn-solid:hover { background: var(--green-dark); }
.btn-outline { border-color: var(--line); background: white; }
.btn-sm { padding: 0.35rem 0.7rem; font-size: 0.92rem; }
.btn:disabled { opacity: 0.6; cursor: wait; }
.field { display: flex; flex-direction: column; gap: 0.3rem; }
.field-full { grid-column: 1 / -1; }
.form-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: 0.8rem; }
input, select, textarea {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 0.55rem 0.7rem;
  background: white;
}
.msg { border-radius: 12px; padding: 0.8rem 1rem; margin: 1rem 0; }
.msg-error { background: #fdecec; color: var(--danger); }
.msg-ok { background: #e7f6ee; color: var(--green-dark); }
.hidden { display: none !important; }
.local-banner {
  background: #f4e4c4;
  color: #6a4208;
  text-align: center;
  padding: 0.65rem 1rem;
  font-weight: 600;
  border-bottom: 1px solid #e2c48a;
}
.steps, .admin-tabs { margin: 1rem 0; }
.step-pill, .admin-tabs button, .lang-btn {
  border: 1px solid var(--line);
  background: white;
  border-radius: 999px;
  padding: 0.35rem 0.7rem;
}
.step-pill.is-active, .admin-tabs button.is-active, .lang-btn.is-active {
  background: var(--green);
  color: white;
  border-color: var(--green);
}
.step-pill.is-done { color: var(--green-dark); }
.type-grid, .day-cols { display: grid; gap: 0.7rem; }
.type-grid { grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); }
.day-cols { grid-template-columns: repeat(7, minmax(0, 1fr)); }
.type-card, .slot {
  text-align: left;
  border: 1px solid var(--line);
  background: white;
  border-radius: 12px;
  padding: 0.7rem;
  cursor: pointer;
}
.type-card { display: flex; flex-direction: column; gap: 0.2rem; }
.type-card.is-selected, .slot.is-selected { border-color: var(--green); outline: 2px solid rgba(31, 107, 74, 0.25); }
.day-col h3 { margin: 0 0 0.4rem; font-size: 0.95rem; }
.day-col h3 em { display: block; font-style: normal; color: var(--muted); }
.slot { display: flex; flex-direction: column; width: 100%; margin-bottom: 0.35rem; }
.slot small { color: var(--muted); }
.slot.origin-google { background: #f3f7ff; }
.slot.origin-backoffice { background: #f7f4ea; }
.slot-empty { color: var(--muted); font-size: 0.92rem; }
.week-nav, .toolbar { display: flex; justify-content: space-between; gap: 0.7rem; align-items: center; margin-bottom: 0.8rem; }
.line { display: flex; justify-content: space-between; gap: 0.8rem; align-items: center; padding: 0.7rem 0; border-bottom: 1px solid var(--line); }
.line span, .check { color: var(--muted); display: block; }
.hours-row { display: grid; grid-template-columns: 8rem repeat(4, 1fr); gap: 0.5rem; align-items: end; margin-bottom: 0.6rem; }
.site-footer { border-top: 1px solid var(--line); background: white; }
.footer-inner { min-height: 3.5rem; color: var(--muted); font-size: 0.92rem; }
.notice { max-width: 42rem; }
.notice h1 { margin-bottom: 0.4rem; }
.check { display: flex; gap: 0.5rem; align-items: center; margin: 0.4rem 0; }
.check input { width: auto; }
.function-nav { display: flex; flex-wrap: wrap; gap: 0.5rem; margin: 1rem 0 1.5rem; }
.closed-note, .status-wait {
  background: #f4e4c4;
  color: #6a4208;
  border-radius: 12px;
  padding: 0.8rem 1rem;
}
.status-wait { display: inline-block; font-weight: 600; }
.mail-text {
  white-space: pre-wrap;
  background: #f7f8f6;
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 0.8rem;
  margin: 0.4rem 0 0.8rem;
}
.checklist h3, .field-full h3 { margin: 0.6rem 0 0.2rem; font-size: 1.05rem; }
.line-stack { display: block; }
.line-stack .card-actions { margin: 0.4rem 0 0.2rem; }
.status-card { margin-top: 1rem; }

.mock-banner {
  position: sticky;
  top: 0;
  z-index: 30;
  background: #f4e4c4;
  color: #6a4208;
  text-align: center;
  padding: 0.65rem 1rem;
  font-weight: 600;
  border-bottom: 1px solid #e2c48a;
}
.mock-kine { margin: 0; color: var(--muted); }
.mock-nav { display: flex; justify-content: space-between; gap: 0.8rem; align-items: flex-start; margin-bottom: 1rem; }
.mock-stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 0.8rem; }
.mock-stat h2 { font-size: 1.05rem; }
.mock-stat strong { display: block; margin: 0.35rem 0; font-size: 1.55rem; }
.mock-table-wrap { overflow-x: auto; background: var(--panel); border: 1px solid var(--line); border-radius: 16px; }
.mock-table { width: 100%; border-collapse: collapse; }
.mock-table th, .mock-table td { text-align: left; padding: 0.65rem 0.7rem; border-bottom: 1px solid var(--line); vertical-align: top; }
.mock-table th { font-size: 0.85rem; color: var(--muted); font-weight: 600; }
.mock-row { cursor: pointer; }
.mock-row:hover, .mock-row:focus { background: #f3f8f5; }
.mock-dl { display: grid; grid-template-columns: 12rem 1fr; gap: 0.35rem 1rem; margin: 1rem 0; }
.mock-dl dt { color: var(--muted); }
.mock-dl dd { margin: 0; }
.signin-card { max-width: 36rem; margin: 1.5rem auto; display: flex; flex-direction: column; gap: 0.8rem; }
.signin-card h1 { margin: 0; }
.signin-card p { margin: 0; }

@media (max-width: 900px) {
  .day-cols { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .hours-row { grid-template-columns: 1fr 1fr; }
  .topbar-inner, .line, .mock-nav { align-items: flex-start; flex-direction: column; }
  .mock-dl { grid-template-columns: 1fr; }
}
