/* Shumly – light modern theme */

* { box-sizing: border-box; }
:root {
  --bg: #f8f9fb;
  --bg-card: #ffffff;
  --bg-input: #f1f3f5;
  --text: #1a1a2e;
  --text-muted: #6b7280;
  --accent: #10b981;
  --accent-hover: #059669;
  --accent-light: rgba(16, 185, 129, 0.1);
  --border: #e2e5ea;
  --border-focus: var(--accent);
  --shadow-sm: 0 1px 3px rgba(0,0,0,0.06);
  --shadow-md: 0 4px 16px rgba(0,0,0,0.08);
  --shadow-lg: 0 10px 40px rgba(0,0,0,0.1);
  --radius: 14px;
  --radius-sm: 8px;
  --danger: #ef4444;
  --danger-light: rgba(239,68,68,0.08);
}
body {
  font-family: 'Inter', system-ui, -apple-system, sans-serif;
  margin: 0;
  min-height: 100vh;
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}
.container { max-width: 56rem; margin: 0 auto; padding: 0 1.5rem; }

/* ---- Header ---- */
header {
  position: sticky;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  padding: 0.75rem 2rem;
  background: rgba(255,255,255,0.85);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
}
header .inner {
  max-width: 72rem;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 3.25rem;
}
header .logo {
  margin-right: auto;
  font-size: 1.3rem;
  font-weight: 700;
  color: var(--text);
  text-decoration: none;
  letter-spacing: -0.03em;
}
header .logo img {
  height: 180px;
  width: auto;
  vertical-align: middle;
  margin: -65px 0;
}
header .btn-ghost {
  padding: 0.45rem 0.9rem;
  background: transparent;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  color: var(--text);
  font: inherit;
  font-size: 0.875rem;
  font-weight: 500;
  cursor: pointer;
  text-decoration: none;
  transition: background 0.2s, border-color 0.2s, box-shadow 0.2s;
}
header .btn-ghost:hover {
  background: var(--bg);
  border-color: #cbd5e1;
  box-shadow: var(--shadow-sm);
}
header .btn-primary-nav {
  padding: 0.45rem 1rem;
  background: var(--accent);
  border: none;
  border-radius: var(--radius-sm);
  color: #fff;
  font-weight: 600;
  font: inherit;
  font-size: 0.875rem;
  cursor: pointer;
  text-decoration: none;
  transition: background 0.2s, box-shadow 0.2s;
}
header .btn-primary-nav:hover {
  background: var(--accent-hover);
  color: #fff;
  box-shadow: 0 2px 8px rgba(16,185,129,0.3);
}

/* ---- Dropdown (Login / Signup) ---- */
header .dropdown {
  position: relative;
  display: inline-block;
}
header .dropdown-panel {
  display: none;
  position: absolute;
  top: calc(100% + 0.5rem);
  right: 0;
  min-width: 280px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 0.75rem;
  box-shadow: var(--shadow-lg);
}
header .dropdown.open .dropdown-panel { display: block; }
header .dropdown-choice {
  display: block;
  width: 100%;
  padding: 0.8rem 1rem;
  margin-bottom: 0.5rem;
  text-align: left;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  color: var(--text);
  text-decoration: none;
  font: inherit;
  cursor: pointer;
  transition: background 0.15s, border-color 0.15s;
}
header .dropdown-choice:last-child { margin-bottom: 0; }
header .dropdown-choice:hover {
  background: var(--accent-light);
  border-color: var(--accent);
}
header .dropdown-choice small {
  display: block;
  margin-top: 0.2rem;
  color: var(--text-muted);
  font-size: 0.8rem;
}

/* ---- Hero (index.html) ---- */
.hero {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 0 1.5rem 4rem;
  background: linear-gradient(160deg, #f0fdf4 0%, #f8f9fb 40%, #eff6ff 100%);
}
.hero-logo {
  width: clamp(400px, 55vw, 720px);
  height: auto;
  margin-bottom: -3rem;
}
.hero h1 {
  font-size: clamp(2.2rem, 5vw, 3.5rem);
  font-weight: 700;
  letter-spacing: -0.03em;
  margin: 0 0 1rem;
  line-height: 1.12;
  color: var(--text);
}
.hero .tagline {
  font-size: 1.125rem;
  color: var(--text-muted);
  max-width: 30rem;
  margin: 0 auto 2.5rem;
}
.hero .btn-chatgpt {
  display: inline-flex;
  align-items: center;
  gap: 0.75rem;
  padding: 1rem 2.25rem;
  font-size: 1.125rem;
  font-weight: 600;
  background: var(--accent);
  color: #fff;
  border: none;
  border-radius: var(--radius);
  text-decoration: none;
  cursor: pointer;
  transition: background 0.2s, transform 0.15s, box-shadow 0.2s;
  box-shadow: 0 4px 14px rgba(16,185,129,0.3);
}
.hero .btn-chatgpt:hover {
  background: var(--accent-hover);
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(16,185,129,0.35);
}

/* ---- Auth pages (centered card) ---- */
.auth-page {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}
.auth-page main {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 2rem 1rem;
}
.auth-card {
  width: 100%;
  max-width: 24rem;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 2.25rem;
  box-shadow: var(--shadow-md);
}
.auth-card h1 { font-size: 1.5rem; margin: 0 0 1.5rem; font-weight: 700; }

/* ---- Forms ---- */
.form-group { margin-bottom: 1.25rem; }
.form-group label {
  display: block;
  font-size: 0.8125rem;
  font-weight: 500;
  color: var(--text-muted);
  margin-bottom: 0.35rem;
}
input[type="text"],
input[type="email"],
input[type="password"],
input[type="tel"],
input[type="number"] {
  width: 100%;
  padding: 0.7rem 0.9rem;
  background: var(--bg-input);
  border: 1.5px solid var(--border);
  border-radius: var(--radius-sm);
  color: var(--text);
  font: inherit;
  font-size: 0.9375rem;
  transition: border-color 0.2s, box-shadow 0.2s;
}
input[type="date"] {
  width: 100%;
  padding: 0.75rem 0.9rem;
  background: var(--bg-input);
  border: 1.5px solid var(--border);
  border-radius: var(--radius-sm);
  color: var(--text);
  font: inherit;
  font-size: 0.9375rem;
  cursor: pointer;
  transition: border-color 0.2s, box-shadow 0.2s;
  appearance: none;
  -webkit-appearance: none;
}
input[type="date"]::-webkit-calendar-picker-indicator {
  display: none;
  -webkit-appearance: none;
}
input[type="date"]::-webkit-date-and-time-value {
  text-align: left;
}
input:focus {
  outline: none;
  border-color: var(--border-focus);
  box-shadow: 0 0 0 3px var(--accent-light);
}
select.input-select {
  width: 100%;
  padding: 0.75rem 0.9rem;
  background: var(--bg-input);
  border: 1.5px solid var(--border);
  border-radius: var(--radius-sm);
  color: var(--text);
  font: inherit;
  font-size: 0.9375rem;
  cursor: pointer;
  appearance: auto;
  transition: border-color 0.2s, box-shadow 0.2s;
}
select.input-select:focus {
  outline: none;
  border-color: var(--border-focus);
  box-shadow: 0 0 0 3px var(--accent-light);
}
.sr-only {
  position: absolute;
  width: 1px; height: 1px;
  padding: 0; margin: -1px;
  overflow: hidden;
  clip: rect(0,0,0,0);
  border: 0;
}

/* ---- Buttons ---- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  padding: 0.75rem 1.25rem;
  font-size: 0.9375rem;
  font-weight: 600;
  background: var(--accent);
  color: #fff;
  border: none;
  border-radius: var(--radius-sm);
  font-family: inherit;
  cursor: pointer;
  transition: background 0.2s, box-shadow 0.2s;
}
.btn:hover { background: var(--accent-hover); box-shadow: 0 2px 8px rgba(16,185,129,0.25); }
.btn:disabled { opacity: 0.5; cursor: not-allowed; }
.btn-secondary {
  background: var(--bg-input);
  color: var(--text);
  border: 1.5px solid var(--border);
}
.btn-secondary:hover { background: var(--bg); border-color: #cbd5e1; }
.btn-danger {
  background: var(--danger);
  color: #fff;
}
.btn-danger:hover { background: #dc2626; }
.btn-sm {
  padding: 0.4rem 0.75rem;
  font-size: 0.8125rem;
  width: auto;
}
.mt-2 { margin-top: 0.5rem; }
.mt-4 { margin-top: 1.5rem; }
.text-center { text-align: center; }
.auth-card a { color: var(--accent); text-decoration: none; font-weight: 500; }
.auth-card a:hover { text-decoration: underline; }

/* ---- Multi-step signup ---- */
.steps {
  display: flex;
  gap: 0.5rem;
  margin-bottom: 1.5rem;
}
.step-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--border);
  transition: background 0.2s, box-shadow 0.2s;
}
.step-dot.done { background: var(--accent); }
.step-dot.current { background: var(--accent); box-shadow: 0 0 0 4px var(--accent-light); }
.add-service-row {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr auto;
  gap: 0.6rem;
  align-items: end;
  margin-bottom: 0.6rem;
}
.add-service-row input { margin: 0; }
.btn-add-service {
  padding: 0.7rem 1rem;
  background: transparent;
  border: 2px dashed var(--border);
  border-radius: var(--radius-sm);
  color: var(--text-muted);
  font: inherit;
  font-size: 0.875rem;
  font-weight: 500;
  cursor: pointer;
  white-space: nowrap;
  transition: border-color 0.2s, color 0.2s;
}
.btn-add-service:hover { border-color: var(--accent); color: var(--accent); }
.service-block {
  margin-bottom: 0.75rem;
  padding: 1rem;
  background: var(--bg);
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
}

/* ---- Dashboard ---- */
.dashboard-page { min-height: 100vh; }
.dashboard-page header {
  position: sticky;
  padding: 0.75rem 2rem;
  border-bottom: 1px solid var(--border);
}
.dashboard-page header .inner { max-width: 72rem; }
.dashboard-page main { padding: 2rem 1.5rem; }
.dashboard-page h1 { font-size: 1.5rem; margin: 0 0 1.5rem; font-weight: 700; }
.dashboard-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.5rem;
  margin-bottom: 1.5rem;
  box-shadow: var(--shadow-sm);
}
.dashboard-card h2 { font-size: 1.1rem; margin: 0 0 1rem; font-weight: 600; }

/* ---- Booking list ---- */
.booking-list { list-style: none; padding: 0; margin: 0; }
.booking-list li {
  padding: 1rem 1.125rem;
  background: var(--bg);
  border-radius: var(--radius-sm);
  margin-bottom: 0.6rem;
  border: 1px solid var(--border);
  transition: box-shadow 0.15s;
}
.booking-list li:hover { box-shadow: var(--shadow-sm); }
.booking-list .actions { margin-top: 0.5rem; }
.booking-list button, .booking-list a {
  font-size: 0.8125rem;
  color: var(--accent);
  background: none;
  border: none;
  cursor: pointer;
  font: inherit;
  font-weight: 500;
  text-decoration: none;
  margin-right: 1rem;
}
.booking-list button:hover, .booking-list a:hover { text-decoration: underline; }
.booking-list .cancel { color: var(--danger); }

/* ---- Footer ---- */
.site-footer {
  border-top: 1px solid var(--border);
  padding: 1.5rem 0;
  margin-top: 3rem;
}
.site-footer .inner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 1.25rem 2rem;
  font-size: 0.8125rem;
  color: var(--text-muted);
}
.site-footer a {
  color: var(--text-muted);
  text-decoration: none;
  transition: color 0.15s;
}
.site-footer a:hover {
  color: var(--accent);
  text-decoration: underline;
}

/* ---- Utilities ---- */
.flex { display: flex; gap: 0.75rem; flex-wrap: wrap; align-items: center; }
.alert { padding: 0.875rem 1rem; border-radius: var(--radius-sm); margin-bottom: 1rem; font-size: 0.9rem; }
.alert-success { background: var(--accent-light); color: #047857; }
.alert-error { background: var(--danger-light); color: var(--danger); }
.alert-info { background: rgba(107,114,128,0.08); color: var(--text-muted); }

/* ---- Shop list / booking flow ---- */
.shop-list { display: grid; gap: 1rem; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); }
.shop-card {
  display: block;
  padding: 1.25rem;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  text-decoration: none;
  color: inherit;
  box-shadow: var(--shadow-sm);
  transition: border-color 0.15s, box-shadow 0.15s, transform 0.15s;
}
.shop-card:hover { border-color: var(--accent); box-shadow: var(--shadow-md); transform: translateY(-2px); }
.service-list { list-style: none; padding: 0; margin: 0; }
.service-list li { margin-bottom: 0.5rem; }
.service-list button {
  width: 100%;
  padding: 1rem;
  text-align: left;
  border: 1.5px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--bg-card);
  color: var(--text);
  cursor: pointer;
  font: inherit;
  transition: border-color 0.15s, background 0.15s;
}
.service-list button:hover { border-color: var(--accent); background: var(--accent-light); }
.slot-list { display: flex; flex-wrap: wrap; gap: 0.5rem; margin: 0.5rem 0; }
.slot-list button {
  padding: 0.5rem 0.8rem;
  border: 1.5px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--bg-card);
  color: var(--text);
  cursor: pointer;
  font-size: 0.875rem;
  font-weight: 500;
  transition: border-color 0.15s, background 0.15s;
}
.slot-list button:hover { border-color: var(--accent); }
.slot-list button.selected { background: var(--accent); color: #fff; border-color: var(--accent); }
.token-box {
  font-family: 'SF Mono', 'Fira Code', monospace;
  font-size: 0.8125rem;
  padding: 0.75rem;
  background: var(--bg-input);
  border-radius: var(--radius-sm);
  word-break: break-all;
  border: 1px solid var(--border);
}

/* ---- Back link ---- */
.dashboard-page a[href*="dashboard"] {
  color: var(--text-muted);
  text-decoration: none;
  font-size: 0.875rem;
  font-weight: 500;
}
.dashboard-page a[href*="dashboard"]:hover { color: var(--accent); }

/* ---- Timetable ---- */
.timetable-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  flex-wrap: wrap;
  margin-bottom: 1.25rem;
}
.timetable-nav {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}
.timetable-nav button {
  padding: 0.4rem 0.75rem;
  font-size: 0.8125rem;
  font-weight: 500;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  cursor: pointer;
  color: var(--text);
  font-family: inherit;
  transition: background 0.15s, border-color 0.15s;
}
.timetable-nav button:hover { background: var(--bg); border-color: #cbd5e1; }
.timetable-nav .week-label {
  font-size: 0.9375rem;
  font-weight: 600;
  min-width: 14rem;
  text-align: center;
}
.timetable-wrapper {
  overflow-x: auto;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--bg-card);
  box-shadow: var(--shadow-sm);
}
.timetable-grid {
  display: grid;
  grid-template-columns: 60px repeat(7, 1fr);
  min-width: 720px;
}
.timetable-corner {
  background: var(--bg-input);
  border-bottom: 1px solid var(--border);
  border-right: 1px solid var(--border);
}
.timetable-day-header {
  padding: 0.6rem 0.25rem;
  text-align: center;
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--text-muted);
  background: var(--bg-input);
  border-bottom: 1px solid var(--border);
  border-right: 1px solid var(--border);
}
.timetable-day-header:last-child { border-right: none; }
.timetable-day-header .day-date {
  display: block;
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--text);
  letter-spacing: normal;
  text-transform: none;
}
.timetable-day-header.today { background: var(--accent-light); }
.timetable-hour-label {
  padding: 0 0.5rem;
  font-size: 0.7rem;
  font-weight: 500;
  color: var(--text-muted);
  text-align: right;
  border-right: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  height: 50px;
  display: flex;
  align-items: flex-start;
  justify-content: flex-end;
  padding-top: 2px;
}
.timetable-cell {
  position: relative;
  border-right: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  height: 50px;
  cursor: pointer;
  transition: background 0.1s;
}
.timetable-cell:last-child { border-right: none; }
.timetable-cell:hover { background: var(--accent-light); }
.timetable-event {
  position: absolute;
  left: 2px;
  right: 2px;
  border-radius: 5px;
  padding: 3px 6px;
  font-size: 0.6875rem;
  font-weight: 500;
  line-height: 1.35;
  overflow: hidden;
  cursor: pointer;
  z-index: 2;
  box-shadow: 0 1px 3px rgba(0,0,0,0.12);
  transition: box-shadow 0.15s;
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
}
.timetable-event:hover { box-shadow: 0 2px 8px rgba(0,0,0,0.2); }
.timetable-event .ev-time { font-size: 0.625rem; font-weight: 600; opacity: 0.95; }
.timetable-event .ev-service { font-weight: 600; margin-top: 1px; }

/* Event popup */
.event-popup {
  position: fixed;
  z-index: 200;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.125rem;
  box-shadow: var(--shadow-lg);
  min-width: 240px;
  max-width: 320px;
}
.event-popup h4 { margin: 0 0 0.5rem; font-size: 0.9375rem; }
.event-popup p { margin: 0.25rem 0; font-size: 0.8125rem; color: var(--text-muted); }
.event-popup .popup-actions { margin-top: 0.75rem; display: flex; gap: 0.5rem; }
.event-popup .popup-close {
  position: absolute;
  top: 0.5rem;
  right: 0.75rem;
  background: none;
  border: none;
  font-size: 1.125rem;
  cursor: pointer;
  color: var(--text-muted);
}

/* Add booking form */
.add-booking-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.3);
  z-index: 150;
  display: flex;
  align-items: center;
  justify-content: center;
}
.add-booking-form {
  background: var(--bg-card);
  border-radius: var(--radius);
  padding: 2rem;
  width: 100%;
  max-width: 28rem;
  box-shadow: var(--shadow-lg);
  font-size: 1rem;
}
.add-booking-form h3 { margin: 0 0 1.25rem; font-size: 1.125rem; font-weight: 600; }
.add-booking-form .form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.75rem;
}

/* ---- Responsive ---- */
@media (max-width: 640px) {
  header { padding: 0.75rem 1rem; }
  header .inner { gap: 0.4rem; }
  header .btn-ghost, header .btn-primary-nav { padding: 0.4rem 0.6rem; font-size: 0.8rem; }
  .hero { padding: 0 1rem 3rem; }
  .auth-card { padding: 1.5rem; }
  .add-service-row { grid-template-columns: 1fr; }
  .timetable-grid { min-width: 600px; }
}
