/* =====================================================
   UrgenCare — stylesheet
   Palette:
   --ink     #14342B  deep pine (text / header)
   --mist    #F2F7F4  pale mint-grey (page)
   --sea     #2E86AB  trust blue (links / actions)
   --gold    #F6AE2D  marigold (badges / highlights)
   --coral   #D64550  alerts / declines
   Type: Sora (display) + Karla (body)
   ===================================================== */

:root {
  --ink:   #14342B;
  --mist:  #F2F7F4;
  --sea:   #2E86AB;
  --sea-d: #226685;
  --gold:  #F6AE2D;
  --coral: #D64550;
  --ok:    #2F9E62;
  --card:  #FFFFFF;
  --line:  #D8E4DE;
  --radius: 14px;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  font-family: 'Karla', system-ui, sans-serif;
  font-size: 16px;
  color: var(--ink);
  background: var(--mist);
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

h1, h2, h3, .brand { font-family: 'Sora', sans-serif; }
h1 { font-size: 1.9rem; margin: .2em 0 .4em; }
h2 { font-size: 1.25rem; margin: 1.4em 0 .5em; }
a  { color: var(--sea); }

/* ---------- header & badges ---------- */
.site-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
  padding: 14px 24px;
  background: var(--ink);
  color: #fff;
  position: sticky;
  top: 0;
  z-index: 20;
}
.brand { color: #fff; text-decoration: none; font-size: 1.25rem; letter-spacing: .5px; }
.brand strong { color: var(--gold); }
.brand-mark {
  display: inline-grid; place-items: center;
  width: 30px; height: 30px; margin-right: 6px;
  background: var(--gold); color: var(--ink);
  border-radius: 8px; font-size: 1rem;
}

.badges { display: flex; flex-wrap: wrap; gap: 10px; }
.badge {
  display: inline-flex; align-items: center; gap: 7px;
  padding: 8px 14px;
  background: rgba(255,255,255,.08);
  border: 1px solid rgba(255,255,255,.18);
  border-radius: 999px;
  color: #fff; text-decoration: none;
  font-weight: 500; font-size: .95rem;
  transition: background .15s;
}
.badge:hover { background: rgba(255,255,255,.18); }
.badge small {
  background: var(--gold); color: var(--ink);
  border-radius: 999px; padding: 1px 8px;
  font-size: .7rem; font-weight: 700;
}
.badge-active { background: var(--gold); border-color: var(--gold); color: var(--ink); }
.badge-active small { background: var(--ink); color: var(--gold); }
.badge-quiet { opacity: .75; }

/* ---------- layout ---------- */
.page { flex: 1; width: min(1060px, 100% - 40px); margin: 28px auto; }
.flash {
  width: min(1060px, 100% - 40px);
  margin: 16px auto -8px;
  padding: 12px 16px;
  background: #E7F6EE; border: 1px solid var(--ok);
  border-radius: var(--radius); font-weight: 500;
}

.card {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 20px 22px;
  margin-bottom: 18px;
}
.grid { display: grid; gap: 16px; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); }

/* ---------- forms & buttons ---------- */
label { display: block; font-weight: 700; margin: 12px 0 4px; font-size: .9rem; }
input[type=text], input[type=email], input[type=password], input[type=number],
input[type=date], textarea, select {
  width: 100%; padding: 10px 12px;
  border: 1px solid var(--line); border-radius: 10px;
  font: inherit; background: #fff;
}
textarea { min-height: 90px; resize: vertical; }

.btn {
  display: inline-block; cursor: pointer;
  padding: 10px 20px; margin-top: 14px;
  background: var(--sea); color: #fff;
  border: 0; border-radius: 999px;
  font: 700 .95rem 'Karla', sans-serif;
  text-decoration: none;
  transition: background .15s;
}
.btn:hover { background: var(--sea-d); }
.btn-gold  { background: var(--gold); color: var(--ink); }
.btn-gold:hover { background: #E09B18; }
.btn-danger { background: var(--coral); }
.btn-sm { padding: 6px 14px; font-size: .85rem; margin-top: 6px; }

/* ---------- status pills & tables ---------- */
.pill {
  display: inline-block; padding: 3px 10px;
  border-radius: 999px; font-size: .78rem; font-weight: 700;
}
.pill-pending   { background: #FDF1DA; color: #8A6100; }
.pill-approved, .pill-confirmed { background: #E7F6EE; color: #1C6B42; }
.pill-rejected, .pill-declined, .pill-cancelled { background: #FBE4E6; color: #96222C; }

table { width: 100%; border-collapse: collapse; font-size: .95rem; }
th, td { text-align: left; padding: 10px 8px; border-bottom: 1px solid var(--line); vertical-align: top; }
th { font-size: .8rem; text-transform: uppercase; letter-spacing: .06em; color: #567; }

/* ---------- home page with UK map backdrop ---------- */
body.home { background: var(--ink); color: #fff; }
body.home .page { position: relative; }

.uk-backdrop {
  position: fixed;
  inset: 0;
  display: grid;
  place-items: center;
  pointer-events: none;
  z-index: 0;
}
.uk-backdrop svg { height: 92vh; max-width: 90vw; opacity: .95; }

.uk-land { fill: #1D4A3D; stroke: #6FBF9A; stroke-width: 2; }

.beacon { fill: var(--gold); }
.beacon-ring {
  fill: none; stroke: var(--gold); stroke-width: 2;
  animation: pulse 2.6s ease-out infinite;
  transform-origin: center;
  transform-box: fill-box;
}
@keyframes pulse {
  0%   { opacity: .9; transform: scale(.4); }
  100% { opacity: 0;  transform: scale(2.4); }
}
@media (prefers-reduced-motion: reduce) { .beacon-ring { animation: none; opacity: .4; } }

.hero {
  position: relative; z-index: 1;
  max-width: 520px;
  margin-top: 8vh;
  background: rgba(20, 52, 43, .78);
  backdrop-filter: blur(3px);
  border: 1px solid rgba(255,255,255,.15);
  border-radius: var(--radius);
  padding: 30px 32px;
}
.hero h1 { font-size: 2.3rem; line-height: 1.15; margin: 0 0 .4em; }
.hero h1 em { color: var(--gold); font-style: normal; }
.hero p  { font-size: 1.05rem; line-height: 1.55; color: #DCE9E2; }

/* ---------- calendar ---------- */
.cal { display: grid; grid-template-columns: repeat(7, 1fr); gap: 6px; margin-top: 10px; }
.cal .dow { text-align: center; font-size: .75rem; font-weight: 700; color: #567; padding: 4px 0; }
.cal-day {
  min-height: 62px; padding: 6px;
  background: #fff; border: 1px solid var(--line); border-radius: 10px;
  font-size: .85rem; position: relative;
  display: block; color: inherit; text-decoration: none;
}
.cal-day.blank { background: transparent; border: 0; }
.cal-day.past  { opacity: .38; }
.cal-day .num  { font-weight: 700; }
a.cal-day:hover { border-color: var(--sea); }
.cal-day.avail    { background: #E7F6EE; border-color: var(--ok); }
.cal-day.selected { outline: 3px solid var(--gold); }
.cal-day .dot {
  position: absolute; right: 7px; bottom: 7px;
  width: 9px; height: 9px; border-radius: 50%;
  background: var(--ok);
}
.cal-head { display: flex; align-items: center; justify-content: space-between; }

/* ---------- footer ---------- */
.site-footer {
  padding: 18px 24px;
  text-align: center;
  font-size: .85rem;
  color: #4E6B60;
}
body.home .site-footer { color: #9DBDAF; position: relative; z-index: 1; }

@media (max-width: 640px) {
  .site-header { padding: 12px 14px; }
  .badge { padding: 7px 11px; font-size: .85rem; }
  .hero { margin-top: 3vh; padding: 22px; }
  .hero h1 { font-size: 1.7rem; }
  .cal-day { min-height: 46px; }
}
