/* Comprehensive modern, minimal light-theme stylesheet
   Uses primary colors: #0193ca and #006083
   File: app/static/css/style.css
*/

:root {
  /* Brand colors */
  --color-primary: #0193ca;
  --color-primary-600: #006083;

  /* Neutrals */
  --color-bg: #f6fbfc;
  --color-surface: #ffffff;
  --color-text: #0b2130; /* deep, but soft black */
  --color-muted: #6b7280;
  --color-border: rgba(3, 15, 25, 0.06);

  /* UI */
  --radius-sm: 6px;
  --radius-md: 10px;
  --radius-lg: 16px;
  --shadow-1: 0 1px 2px rgba(3, 7, 15, 0.04);
  --shadow-2: 0 8px 30px rgba(3, 7, 15, 0.06);

  /* Layout */
  --max-width: 1100px;
  --content-padding: 1.25rem;
  --gap: 1rem;

  /* Type */
  --font-sans: 'IBM Plex Sans', system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --base-size: 16px;
  --line-height: 1.5;
}

/* Reset & base ----------------------------------------------------------- */
*, *::before, *::after { box-sizing: border-box; }
html, body, #app { height: 100%; }
html { font-size: var(--base-size); -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  font-family: var(--font-sans);
  color: var(--color-text);
  background: linear-gradient(180deg, var(--color-bg) 0%, #fcfeff 100%);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  line-height: var(--line-height);
  -webkit-tap-highlight-color: transparent;

  /* Make footer stick to bottom via flex layout */
  display: flex;
  flex-direction: column;
  min-height: 100dvh;
}

main { flex: 1 0 auto; }

img { max-width: 100%; height: auto; display: block; }
a { color: var(--color-primary); text-decoration: none; }
a:hover { text-decoration: underline; }

/* Containers ------------------------------------------------------------ */
.container {
  width: 100%;
  max-width: var(--max-width);
  margin-left: auto;
  margin-right: auto;
  padding-left: var(--content-padding);
  padding-right: var(--content-padding);
}

.section { padding: 3.5rem 0; }
.section--tight { padding: 1.5rem 0; }

/* Typography ------------------------------------------------------------ */
h1, h2, h3, h4, h5 { margin: 0 0 0.5rem 0; color: var(--color-text); font-weight: 600; }
h1 { font-size: 2.125rem; line-height: 1.12; }
h2 { font-size: 1.5rem; }
h3 { font-size: 1.125rem; }
 p { margin: 0 0 1rem 0; color: rgba(11,33,48,0.85); }
.small { font-size: 0.875rem; color: var(--color-muted); }
.lead { font-size: 1.0625rem; color: rgba(11,33,48,0.95); }

/* Navbar --------------------------------------------------------------- */
.navbar {
  background: rgba(255,255,255,0.9);
  backdrop-filter: blur(6px);
  border-bottom: 1px solid var(--color-border);
  box-shadow: var(--shadow-1);
  position: sticky; top: 0; z-index: 40;
}
.navbar__inner {
  display: flex; align-items: center; justify-content: space-between;
  gap: 1rem; padding: 0.625rem 0;
}
.brand { display: flex; align-items: center; gap: 0.75rem; }
.brand__logo { width: 36px; height: 36px; display: inline-flex; align-items:center; justify-content:center; border-radius: 8px; background: linear-gradient(180deg, var(--color-primary) 0%, var(--color-primary-600) 100%); box-shadow: var(--shadow-1); }
.brand__logo img, .brand__logo svg { width: 22px; height: 22px; display:block; }
.brand__title { font-weight: 700; color: var(--color-text); font-size: 1rem; }
.brand__title .accent { color: var(--color-primary); }

.nav { display:flex; gap: 0.75rem; align-items:center; }
.nav a { padding: 0.4rem 0.6rem; border-radius: 8px; color: var(--color-text); font-weight: 500; }
.nav a:hover { background: rgba(1,147,202,0.06); color: var(--color-primary-600); }

/* Navbar tweaks + mobile behavior */
.navbar__toggle {
  display: inline-flex; /* Ensure it shows in mobile view */
  align-items: center;
  justify-content: center;
  padding: 8px;
  background: transparent;
  border: none;
  cursor: pointer;
}

/* Consolidated logo, toggle, and mobile nav styles */
/* Logo image: show rectangular image as-is and animate subtly */
.brand__logo-img {
  display: block;
  height: 40px; /* Increased size */
  width: auto;
  object-fit: contain;
  padding-top: 4px;
  padding-bottom: 4px;
  transition: transform 220ms cubic-bezier(.2,1.4,.4,1);
}

/* Toggle SVG styling: use currentColor so stroke follows text color */
.navbar__toggle .icon { width: 24px; height: 24px; display: inline-block; color: var(--color-text); }
.navbar__toggle .icon svg, .navbar__toggle .icon { stroke: currentColor; }

/* Ensure only one icon (hamburger or cross) is visible at a time */
.navbar__toggle .icon--menu {
  display: inline-block;
}
.navbar__toggle .icon--close {
  display: none;
}

.navbar__toggle[aria-expanded="true"] .icon--menu {
  display: none;
}
.navbar__toggle[aria-expanded="true"] .icon--close {
  display: inline-block;
}

/* Make sure brand sits to the left and toggle to the right with spacing */
.brand { margin-right: auto; }
.navbar__toggle { margin-left: 12px; }

/* Mobile safe spacing: ensure container padding prevents touching edges */
@media (max-width: 639px) {
  .navbar { padding-left: var(--content-padding); padding-right: var(--content-padding); }
  .navbar__inner { min-height: 56px; }
  .brand__logo-img { height: 28px; }
  .navbar__toggle { padding: 8px; }

  .nav {
    display: none;
    position: absolute;
    left: var(--content-padding);
    right: var(--content-padding);
    top: calc(100% + 8px);
    background: var(--color-surface);
    box-shadow: var(--shadow-2);
    border-top: 1px solid var(--color-border);
    padding: 0.75rem;
    flex-direction: column;
    gap: 0.5rem;
    z-index: 30;
    border-radius: 10px;
  }

  .nav.open {
    display: flex; /* Ensure the menu appears when open */
  }
}

/* Hide the hamburger icon on desktop */
@media (min-width: 640px) {
  .navbar__toggle {
    display: none;
  }
}

/* Removed legacy .navbar__icon pseudo rules to avoid conflicts with SVG icons */

/* End consolidated styles */

/* Inherit site font for form controls and buttons */
button, input, select, textarea { font: inherit; }

/* Buttons -------------------------------------------------------------- */
.btn {
  display: inline-flex; align-items: center; gap: 0.6rem;
  padding: 0.55rem 0.9rem; font-weight: 600; font-size: 0.95rem;
  border-radius: 9px; border: 1px solid transparent; cursor: pointer; transition: all 160ms ease;
  text-decoration: none; /* prevent underline for link buttons */
  font-family: var(--font-sans);
}
.btn:focus { outline: none; box-shadow: 0 0 0 4px rgba(1,147,202,0.12); }

.btn--primary {
  background: var(--color-primary); color: #fff; border-color: rgba(1,147,202,0.08);
}
.btn--primary:hover { background: var(--color-primary-600); }

.btn--outline {
  background: transparent; border: 1px solid var(--color-border); color: var(--color-text);
}
.btn--ghost { background: transparent; color: var(--color-text); }

/* Link-style button (used in navbar logout) */
.btn--link {
  background: transparent;
  border: none;
  padding: 0.25rem 0.5rem;
  color: var(--color-text);
  font-weight: 600;
  cursor: pointer;
}
.btn--link:hover {
  color: var(--color-primary-600);
  text-decoration: underline;
}
.btn--link:focus { outline: none; box-shadow: 0 0 0 4px rgba(1,147,202,0.12); border-radius: 6px; }

/* Cards ---------------------------------------------------------------- */
.card {
  background: var(--color-surface); border-radius: var(--radius-md); padding: 1rem; box-shadow: var(--shadow-1); border: 1px solid var(--color-border);
}
.card--highlight { box-shadow: var(--shadow-2); }
.card__title { font-size: 1rem; margin-bottom: 0.5rem; }
.card__meta { font-size: 0.875rem; color: var(--color-muted); }

/* Narrow, centered card helper (good for auth forms) */
.card--narrow {
  max-width: 560px;
  margin-left: auto;
  margin-right: auto;
}

/* Hero ----------------------------------------------------------------- */
.hero {
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 5rem 1.25rem;
  background: linear-gradient(180deg, var(--color-bg) 0%, #eef7fb 100%);
}

.hero__inner {
  width: 100%;
  max-width: 900px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
  align-items: center;
}

.hero .kicker {
  background: rgba(1,147,202,0.08);
  color: var(--color-primary-600);
  font-weight: 700;
  letter-spacing: .08em;
  text-transform: uppercase;
}

.hero__title {
  font-size: clamp(2rem, 4vw, 3rem);
  line-height: 1.1;
  font-weight: 700;
  background: linear-gradient(90deg, var(--color-primary) 0%, var(--color-primary-600) 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.hero__lead {
  font-size: 1.2rem;
  color: rgba(11,33,48,.8);
  max-width: 60ch;
}

.cta-group {
  display: inline-flex;
  gap: .75rem;
  align-items: center;
  justify-content: center;
  margin-top: .25rem;
}

.btn--secondary {
  background: rgba(1,147,202,0.08);
  color: var(--color-primary-600);
  border: 1px solid rgba(1,147,202,0.12);
}
.btn--secondary:hover {
  background: rgba(1,147,202,0.14);
}

/* Feature bullets */
.feature-list {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: .75rem 1rem;
  margin-top: .75rem;
  width: 100%;
  max-width: 900px;
}
.feature-list li {
  list-style: none;
  display: flex;
  gap: .5rem;
  align-items: center;
  justify-content: center;
  color: rgba(11,33,48,.85);
}
.feature-list li::before {
  content: '\2713';
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: rgba(1,147,202,0.1);
  color: var(--color-primary-600);
  font-weight: 700;
  font-size: .9rem;
}

/* Stats row */
.stats {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: .75rem;
  margin-top: 1rem;
  width: 100%;
}
.stat {
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  padding: .9rem;
  box-shadow: var(--shadow-1);
}
.stat__value {
  font-weight: 700;
  font-size: 1.25rem;
  color: var(--color-text);
}
.stat__label {
  font-size: .9rem;
  color: var(--color-muted);
}

/* Simple entrance animation */
@keyframes fade-up {
  from { opacity: 0; transform: translateY(12px);}
  to { opacity: 1; transform: translateY(0);}
}
.hero__inner > * {
  animation: fade-up 540ms cubic-bezier(.2,1,.3,1) both;
}
.hero__inner > *:nth-child(1){
  animation-delay: .02s;
}
.hero__inner > *:nth-child(2){
  animation-delay: .08s;
}
.hero__inner > *:nth-child(3){
  animation-delay: .14s;
}
.hero__inner > *:nth-child(4){
  animation-delay: .2s;
}

/* Footer --------------------------------------------------------------- */
.footer {
  background: linear-gradient(180deg, rgba(240, 246, 248, 0.9) 0%, rgba(231, 244, 248, 0.9) 100%);
  backdrop-filter: blur(6px);
  border-top: 1px solid var(--color-border);
  box-shadow: var(--shadow-1);
  color: var(--color-muted);
}
.footer__inner {
  display: grid;
  grid-template-columns: auto 1fr auto; /* center content between left and right */
  align-items: center;
  padding: 1rem 0; /* slightly roomier */
}
.footer__col { min-width: 0; }
.footer__col--left { justify-self: start; color: var(--color-muted); font-weight: 600; display: inline-flex; gap: .35rem; align-items: baseline; }
.footer__vat-label { opacity: .8; letter-spacing: .02em; }
.footer__vat { color: var(--color-text); font-weight: 700; }
.footer__col--center { justify-self: center; text-align: center; color: var(--color-muted); font-weight: 500; }
.footer__col--center p { margin: 0; }
.footer__col--right { justify-self: end; }
.footer__links { display: inline-flex; align-items: center; gap: 1rem; }
.footer__dot { opacity: .4; }

/* New: footer link styles */
.footer__link { color: var(--color-primary); font-weight: 600; text-decoration: none; transition: color .2s ease, opacity .2s ease; }
.footer__link:hover { color: var(--color-primary-600); text-decoration: underline; }

/* Make the footer cookie settings button appear like a text link */
.footer__button-link {
  background: transparent;
  border: 0;
  padding: 0;
  color: var(--color-primary);
  font: inherit;
  cursor: pointer;
}
.footer__button-link:hover { color: var(--color-primary-600); text-decoration: underline; }

/* Mobile: stack neatly */
@media (max-width: 640px) {
  .footer__inner { grid-template-columns: 1fr; gap: .5rem; }
  .footer__col--left { order: 1; }
  .footer__col--center { order: 2; justify-self: start; text-align: left; }
  .footer__col--right { order: 3; justify-self: start; }
  .footer__links { gap: .75rem; }
}

/* Accessibility & Interactions ----------------------------------------- */
:focus { outline: none; }
:focus-visible { outline: none; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0; }

/* Small helpers */
.hide { display: none !important; }
.inline { display:inline-block; }
.nowrap { white-space: nowrap; }

/* Responsiveness ------------------------------------------------------- */
@media (min-width: 640px) {
  .hero { grid-template-columns: 1fr 1fr; }
  h1 { font-size: 2.5rem; }
}
@media (min-width: 900px) {
  :root { --content-padding: 2rem; }
  .grid--3 { grid-template-columns: repeat(3, 1fr); }
}

/* Reduced motion */
@media (prefers-reduced-motion: reduce) {
  * { transition: none !important; animation-duration: 0.001ms !important; animation-iteration-count: 1 !important; }
}

/* Print friendly */
@media print {
  body { background: white; color: black; }
  .navbar, .footer { display: none; }
}

/* Prevent underline on navbar links and refine hover */
.nav a { text-decoration: none; }
.nav a:hover { text-decoration: none; color: var(--color-primary-600); transform: translateY(-3px); }

/* Make hover feel bouncy for interactive elements */
.nav a, .btn {
  transition: transform 260ms cubic-bezier(.2,1.4,.4,1), color 160ms ease, background-color 160ms ease;
}

.nav a:active, .btn:active { transform: translateY(0); }
.nav a:focus, .btn:focus { outline: none; box-shadow: 0 0 0 6px rgba(1,147,202,0.08); }

/* Hamburger icon (CSS-only) */
/* .navbar__icon {
  display: inline-block;
  width: 20px;
  height: 14px;
  position: relative;
}
.navbar__icon::before,
.navbar__icon::after,
.navbar__icon span {
  content: '';
}
.navbar__icon::before,
.navbar__icon::after {
  position: absolute;
  left: 0; right: 0; height: 2px; background: var(--color-text); border-radius: 2px; transition: transform 260ms cubic-bezier(.2,1.4,.4,1), opacity 200ms linear;
}
.navbar__icon::before { top: 0; }
.navbar__icon::after { bottom: 0; }
/* middle bar using a pseudo inner element via box-shadow */
.navbar__icon { box-shadow: 0 6px 0 var(--color-text); }

/* Toggle open state -> morph to X */
.navbar__toggle[aria-expanded="true"] .navbar__icon::before {
  transform: translateY(6px) rotate(45deg);
}
.navbar__toggle[aria-expanded="true"] .navbar__icon::after {
  transform: translateY(-6px) rotate(-45deg);
}
.navbar__toggle[aria-expanded="true"] .navbar__icon { box-shadow: none; }

/* Animate mobile nav with a small bouncy entrance */
@keyframes nav-slide-bounce {
  0% { transform: translateY(-10px); opacity: 0; }
  60% { transform: translateY(6px); opacity: 1; }
  100% { transform: translateY(0); opacity: 1; }
}
.nav.open { animation: nav-slide-bounce 360ms cubic-bezier(.2,1.4,.4,1); }

/* Ensure buttons in navbar don't get underlined (override global anchors) */
.navbar a, .nav a { text-decoration: none; }

/* --- Overrides: buttons, hero mobile polish, equal cards --- */
/* Kill underline on any button link, across states */
a.btn, .btn, .btn:link, .btn:visited, .btn:hover, .btn:focus, .btn:active { text-decoration: none !important; }

/* Ensure hero CTAs wrap nicely on small screens */
.cta-group { flex-wrap: wrap; }
.cta-group .btn { white-space: nowrap; }

/* Feature items as neat equal cards */
.feature-list { align-items: stretch; }
.feature-list li {
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  padding: 0.6rem 0.75rem;
}

/* Stats: equal height, centered content */
.stats { gap: 1rem; }
.stat { display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; min-height: 96px; }
.stat__value { font-size: 1.35rem; }

/* Responsive tweaks for small screens */
@media (max-width: 639px) {
  .cta-group { gap: 0.5rem; }
  .cta-group .btn { flex: 1 1 46%; justify-content: center; }
  .feature-list { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 420px) {
  .feature-list { grid-template-columns: 1fr; }
  .cta-group .btn { flex-basis: 100%; }
}

/* --- Mobile polish follow-up: features no boxes, even stats grid --- */
/* Feature items: no white boxes */
.feature-list li {
  background: transparent !important;
  border: 0 !important;
  box-shadow: none !important;
  padding: 0.4rem 0.25rem !important;
}

/* Stats grid: consistent columns on small screens */
@media (max-width: 639px) {
  .stats { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 420px) {
  .stats { grid-template-columns: 1fr; }
}

/* Ensure stat cards feel equal in height */
.stat { min-height: 110px; }

/* --- Center features on mobile: single column, centered items --- */
@media (max-width: 639px) {
  .feature-list { display: flex !important; flex-direction: column; align-items: center; justify-content: center; gap: 0.6rem; }
  .feature-list li { display: inline-flex; align-items: center; justify-content: center; text-align: center; padding: 0.25rem 0 !important; }
  .feature-list li::before { margin-right: 0.5rem; }
}

/* --- Final centering fix for features on mobile --- */
/* Remove default UL padding and center the container */
.feature-list { padding-left: 0 !important; margin-left: auto !important; margin-right: auto !important; list-style: none !important; }

@media (max-width: 639px) {
  .feature-list { display: flex !important; flex-direction: column; align-items: center; justify-content: center; gap: 0.6rem; max-width: 540px; }
  .feature-list li { width: 100%; max-width: 520px; display: inline-flex; align-items: center; justify-content: center; text-align: center; padding: 0.25rem 0 !important; }
  .feature-list li::before { margin-right: 0.5rem; flex: 0 0 22px; }
}

/* --- Mobile centering fix for feature list (final override) --- */
@media (max-width: 639px) {
  /* Center the whole list block within the hero and make it a neat single column */
  .hero .feature-list {
    max-width: 520px;
    width: 100%;
    margin-left: auto !important;
    margin-right: auto !important;
    padding-left: 0 !important; /* remove default ul indent */

    /* Use flex column and stretch items so bullets align cleanly */
    display: flex !important;
    flex-direction: column !important;
    align-items: stretch !important;
    justify-content: center !important;
    gap: 0.6rem !important;
  }

  /* Left-align the content inside each row so the checkmark + label align tight,
     while the overall block stays centered via its max-width */
  .hero .feature-list li {
    width: 100% !important;
    max-width: 520px;
    display: flex !important;
    align-items: center !important;
    justify-content: flex-start !important;
    text-align: left !important;
  }

  .hero .feature-list li::before {
    margin-right: 0.5rem;
    flex: 0 0 22px; /* keep the bullet size consistent */
  }
}

/* --- Mobile centering hard override for feature list --- */
@media (max-width: 639px) {
  .hero .feature-list {
    margin-left: auto !important;
    margin-right: auto !important;
    align-items: center !important; /* center the column */
  }
  .hero .feature-list li {
    width: auto !important;        /* shrink to content so it can truly center */
    max-width: 100% !important;
    justify-content: center !important; /* center the row content */
    text-align: center !important;
  }
}

/* --- Definitive mobile centering for features: one-column grid, centered items --- */
@media (max-width: 639px) {
  .hero .feature-list {
    display: grid !important;
    grid-template-columns: 1fr !important;
    justify-items: center !important; /* center each li within the grid */
    align-items: start !important;
    max-width: 520px;
    width: 100%;
    margin-left: auto !important;
    margin-right: auto !important;
    padding-left: 0 !important;
    gap: 0.6rem !important;
  }
  .hero .feature-list li {
    width: auto !important; /* shrink to content so it centers */
    justify-content: center !important;
    text-align: center !important;
  }
}

/* --- Ultimate mobile centering: shrink-to-content and center --- */
@media (max-width: 639px) {
  .hero .feature-list {
    display: inline-flex !important;   /* shrink to content width */
    flex-direction: column !important;
    align-items: center !important;
    justify-content: center !important;
    gap: 0.6rem !important;
    padding-left: 0 !important;       /* remove ul indent */
    margin: 0 auto !important;         /* center the block */
    width: auto !important;            /* no full-width */
    max-width: none !important;
  }
  .hero .feature-list li {
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    text-align: center !important;
    width: auto !important;
  }
}

/* Split section (image + text) ---------------------------------------- */
.split { display: grid; gap: 1.25rem; align-items: center; }
.split__media, .split__content { width: 100%; }
.media-frame { border-radius: var(--radius-lg); border: 1px solid var(--color-border); box-shadow: var(--shadow-2); background: var(--color-surface); }
@media (min-width: 900px) { .split { grid-template-columns: 1.1fr 1fr; gap: 2rem; } }

/* Reveal-on-scroll utility */
.reveal { opacity: 0; transform: translateY(12px); transition: opacity 480ms ease, transform 480ms cubic-bezier(.2,1,.3,1); will-change: transform, opacity; }
.reveal.is-visible { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1 !important; transform: none !important; transition: none !important; }
}

/* End of stylesheet */

/* Forms (booking) ------------------------------------------------------- */
.form { display:block; }
.form__grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 0.9rem 1rem;
  border: 0;
  margin: 0;
  padding: 0;
}

.form__group { display:flex; flex-direction: column; gap: 0.35rem; }
.form__group--full { grid-column: 1 / -1; }

label { font-weight: 600; color: var(--color-text); }
.req { color: #b91c1c; }

input[type="text"], input[type="email"], input[type="tel"], input[type="date"], input[type="time"], input[type="password"], select, textarea {
  appearance: none;
  width: 100%;
  padding: 0.6rem 0.7rem;
  border-radius: 10px;
  border: 1px solid var(--color-border);
  background: #fff;
  color: var(--color-text);
  font: inherit;
  box-shadow: var(--shadow-1);
}
input:focus, select:focus, textarea:focus {
  outline: none;
  border-color: rgba(1,147,202,0.5);
  box-shadow: 0 0 0 4px rgba(1,147,202,0.12);
}
.is-invalid { border-color: #dc2626 !important; }

.form__actions { display:flex; gap:0.5rem; align-items:center; justify-content:flex-start; margin-top: 0.5rem; }

/* Alerts --------------------------------------------------------------- */
.alert {
  border-radius: var(--radius-md);
  padding: 0.8rem 1rem;
  border: 1px solid var(--color-border);
  box-shadow: var(--shadow-1);
  margin-bottom: 1rem;
}
.alert--success { background: #ecfdf5; border-color: #a7f3d0; color: #065f46; }
.alert--error { background: #fef2f2; border-color: #fecaca; color: #7f1d1d; }
.list--errors { margin: 0.25rem 0 0; padding-left: 1.1rem; }
.list--errors li { margin: 0.15rem 0; }
.strong { font-weight: 600; }
.mono { font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace; }

@media (min-width: 720px) {
  .form__grid { grid-template-columns: repeat(2, 1fr); }
}

/* Booking flow (Calendly-like) ----------------------------------------- */
.booking { display:block; }
.booking__steps {
  display:flex; gap: .5rem; align-items:center; margin: 0 0 1rem 0; padding: 0; list-style:none;
}
.step { display:flex; align-items:center; gap:.4rem; padding: .35rem .5rem; border-radius: 999px; border:1px solid var(--color-border); color: var(--color-muted); }
.step__num { display:inline-flex; align-items:center; justify-content:center; width: 24px; height:24px; border-radius:50%; background: rgba(1,147,202,0.06); color: var(--color-primary-600); font-weight:700; font-size:.9rem; }
.step.is-active { background: rgba(1,147,202,0.08); border-color: rgba(1,147,202,0.2); color: var(--color-primary-600); }
.step__label { font-weight:600; font-size:.9rem; }

.panel { margin-bottom: 1rem; }
/* New: add gentle fade/slide-in when activated */
.panel { opacity: 0; transform: translateY(6px); transition: opacity 220ms ease, transform 260ms cubic-bezier(.2,1,.3,1); }
.panel.is-active { opacity: 1; transform: none; }

.panel__actions { display:flex; gap:.5rem; align-items:center; justify-content:flex-end; margin-top: .75rem; }

/* Panel stack crossfade/height transition */
.panel-stack {
  position: relative;
  transition: height 280ms cubic-bezier(.2,1,.3,1);
}
.panel-stack > .panel {
  position: absolute;
  inset: 0;
  opacity: 0;
  pointer-events: none;
  transform: translateY(6px);
}
.panel-stack > .panel.is-active {
  opacity: 1;
  pointer-events: auto;
  transform: none;
}
/* Ensure stacking context for the active panel */
.panel-stack > .panel { z-index: 0; }
.panel-stack > .panel.is-active { z-index: 1; }

/* Calendar */
.calendar { padding: .75rem; }
.calendar__header { display:flex; align-items:center; justify-content:space-between; gap:.5rem; margin-bottom:.5rem; }
.calendar__title { font-size: 1.2rem; font-weight: 700; }
.calendar__grid { display:flex; flex-direction:column; gap:.25rem; }
/* New: fades when swapping months */
.calendar__grid { transition: opacity 220ms ease, transform 240ms cubic-bezier(.2,1,.3,1); }
.calendar__grid.is-fade { opacity: 0; transform: translateY(4px); }
.calendar__row { display:grid; grid-template-columns: repeat(7, 1fr); gap:.25rem; }
.calendar__row--head { padding-bottom: .25rem; border-bottom:1px solid var(--color-border); }
.calendar__day { font-size:.9rem; font-weight: 600; color: var(--color-muted); text-align:center; }
.calendar__cell { display:inline-flex; align-items:center; justify-content:center; width:100%; aspect-ratio: 1 / 1; border-radius: 10px; border: 1px solid var(--color-border); background:#fff; box-shadow: var(--shadow-1); cursor: pointer; font-size: 1.05rem; font-weight: 700; }
/* New: smoother hover/press */
.calendar__cell { transition: background-color 160ms ease, border-color 160ms ease, transform 120ms ease, box-shadow 160ms ease; }
.calendar__cell:active { transform: translateY(1px) scale(0.99); }
.calendar__cell:hover { background: rgba(1,147,202,0.06); }
.calendar__cell.is-selected { background: var(--color-primary); color:#fff; border-color: rgba(1,147,202,0.2); box-shadow: var(--shadow-2); }
.calendar__cell.is-disabled { opacity: .45; cursor: not-allowed; }
.calendar__cell.is-empty { background: transparent; border: 1px dashed transparent; box-shadow:none; }
/* New: low availability (yellow tint) */
.calendar__cell.is-low { background: rgba(255, 193, 7, 0.18); border-color: rgba(255, 193, 7, 0.45); }
.calendar__cell.is-low:hover { background: rgba(255, 193, 7, 0.24); }
/* New: public holiday (Christmas) */
.calendar__cell.is-holiday { background: rgba(220, 38, 38, 0.15); border-color: rgba(220, 38, 38, 0.5); color: #7f1d1d; }
/* Ensure selected state wins over info tints */
.calendar__cell.is-selected.is-low,
.calendar__cell.is-selected.is-holiday { background: var(--color-primary); color:#fff; border-color: rgba(1,147,202,0.2); }
/* Keep holiday visible even when disabled */
.calendar__cell.is-disabled.is-holiday { opacity: 0.85; }

/* Banners (warning/info/error callouts) --------------------------------- */
.banner {
  display: flex;
  align-items: flex-start;
  gap: 0.75rem;
  padding: 0.9rem 1rem;
  border: 1px solid var(--color-border);
  border-left-width: 5px;
  border-radius: var(--radius-md);
  background: var(--color-surface);
  box-shadow: var(--shadow-1);
  margin-bottom: 1rem;
}
.banner__icon {
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  border-radius: 999px;
  background: rgba(0,0,0,0.04);
  color: inherit;
}
.banner__content { flex: 1 1 auto; }
.banner__title { margin: 0 0 0.25rem; font-size: 1.1rem; font-weight: 700; }
.banner__text { margin: 0; color: rgba(11,33,48,0.8); }

/* Variants */
.banner--warning { border-left-color: #f59e0b; background: rgba(245, 158, 11, 0.06); color: #b45309; }
.banner--danger  { border-left-color: #ef4444; background: rgba(239, 68, 68, 0.06); color: #991b1b; }
.banner--info    { border-left-color: var(--color-primary); background: rgba(1, 147, 202, 0.06); color: var(--color-primary-600); }

/* Toasts (flash messages) ---------------------------------------------- */
.toast-container {
  position: fixed;
  top: 14px;
  right: 14px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  z-index: 20000;
  pointer-events: none; /* only toasts receive events */
}
.toast {
  pointer-events: auto;
  display: flex;
  align-items: center;
  gap: 10px;
  max-width: min(92vw, 420px);
  padding: 10px 12px;
  border: 1px solid var(--color-border);
  border-left-width: 4px;
  border-radius: 10px;
  background: var(--color-surface);
  color: var(--color-text);
  box-shadow: var(--shadow-2);
  opacity: 0;
  transform: translateY(-6px);
  transition: opacity 200ms ease, transform 240ms cubic-bezier(.2,1,.3,1);
}
.toast.is-visible { opacity: 1; transform: translateY(0); }
.toast.is-hiding { opacity: 0; transform: translateY(-6px); }
.toast__content { flex: 1 1 auto; }
.toast__close {
  background: transparent;
  border: 0;
  color: inherit;
  font-size: 1.1rem;
  line-height: 1;
  cursor: pointer;
}

/* Toast variants */
.toast--success { border-left-color: #22c55e; background: #ecfdf5; color: #065f46; }
.toast--error   { border-left-color: #ef4444; background: #fef2f2; color: #7f1d1d; }
.toast--info    { border-left-color: var(--color-primary); background: rgba(1,147,202,0.06); color: var(--color-primary-600); }

@media (max-width: 480px) {
  .toast-container { left: 10px; right: 10px; }
  .toast { max-width: 100%; }
}

/* Booking time slots ---------------------------------------------------- */
.times {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(90px, 1fr));
  gap: 0.5rem;
  margin-top: 0.5rem;
  transition: opacity 220ms ease, transform 240ms cubic-bezier(.2,1,.3,1);
}
.times.is-fade { opacity: 0; transform: translateY(4px); }

.timeslot {
  display: inline-flex;
  align-items: center; justify-content: center;
  padding: 0.55rem 0.7rem;
  border: 1px solid var(--color-border);
  border-radius: 10px;
  background: #fff;
  color: var(--color-text);
  box-shadow: var(--shadow-1);
  cursor: pointer;
  font-weight: 700;
}
.timeslot:hover { background: rgba(1,147,202,0.06); border-color: rgba(1,147,202,0.28); }
.timeslot.is-selected {
  background: var(--color-primary);
  color: #fff;
  border-color: rgba(1,147,202,0.28);
  box-shadow: var(--shadow-2);
}

/* Timezone badge shown next to selected date --------------------------- */
.tz-badge {
  display: inline-flex;
  align-items: center;
  gap: .25rem;
  padding: 0 .4rem;
  height: 22px;
  border: 1px solid var(--color-border);
  border-radius: 999px;
  font-size: .75rem;
  color: var(--color-muted);
  background: #fff;
}

/* Auth (Login) page --------------------------------------------------- */
.section.auth { padding: 2rem 0; }
.auth-header { text-align: center; margin: 0 0 1rem; }
.auth-header .page-title { font-size: 1.75rem; line-height: 1.2; margin: 0; }
.auth-header .page-subtitle { margin: .25rem 0 0; color: var(--color-muted); }

/* Cookie Consent Banner ------------------------------------------------- */
.cookie-banner {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  inset: auto auto 0 auto; /* override any previous inset: 0 */
  padding: 0.75rem;
  background: transparent;
  z-index: 30000;
  pointer-events: auto; /* ensure clicks are handled by banner */
}
.cookie-banner__inner {
  pointer-events: auto;
  max-width: 560px;
  width: 100%;
}
/* Emphasize Accept, align actions evenly */
/* Removed old accept min-width to keep buttons equal */
.cookie-banner__actions .btn { height: 40px; }
@media (max-width: 639px) {
  .cookie-banner__actions { justify-content: stretch; }
  .cookie-banner__actions .btn { flex: 1 1 auto; min-width: 0; }
  /* Removed old accept flex-boost to keep equal widths */
}

/* Consent modal overrides: center dialog with dark backdrop and lock page */
.cookie-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(3, 7, 15, 0.55);
  z-index: 29990;
  opacity: 0;
  transition: opacity 220ms ease;
  pointer-events: none; /* do not block clicks unless visible */
}
.cookie-backdrop.is-visible { opacity: 1; pointer-events: auto; }

/* Centered modal container */
.cookie-banner {
  position: fixed !important;
  inset: 0 !important;
  left: 0; right: 0; top: 0; bottom: 0;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  padding: 1rem;
  background: transparent !important;
  z-index: 30000;
  pointer-events: none; /* block underlying via backdrop, but only inner is clickable */
  opacity: 0;
  transform: translateY(8px) scale(0.98);
  transition: opacity 240ms ease, transform 300ms cubic-bezier(.2,1,.3,1);
}
.cookie-banner.is-visible { opacity: 1; transform: none; }
.cookie-banner__inner { pointer-events: auto; max-width: 560px; width: 100%; }
body.consent-open { overflow: hidden; }

/* Visual card for consent dialog */
.cookie-banner__inner {
  background: #fff;
  color: var(--color-text);
  border: 1px solid var(--color-border);
  border-radius: 14px;
  box-shadow: var(--shadow-3, 0 10px 30px rgba(0,0,0,.18));
  padding: 1rem;
}
@media (min-width: 640px) {
  .cookie-banner__inner { padding: 1.25rem 1.25rem; }
}
/* Header with flags */
.cookie-banner__head { display: flex; align-items: center; justify-content: center; margin: 0 0 0.25rem; }
.cookie-banner__flags { display: inline-flex; align-items: center; gap: 6px; }
.cookie-banner__flags img { height: 22px; width: auto; display: inline-block; vertical-align: middle; }

/* Layout inside banner */
.cookie-banner__row {
  display: flex;
  flex-direction: column;
  align-items: stretch;
  gap: 1rem;
}
.cookie-banner__text { margin: 0; line-height: 1.5; text-align: center; }
.cookie-banner__actions {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  width: 100%;
}
.cookie-banner__actions .btn {
  width: 100%;
  flex: 0 0 auto !important;
  min-width: 0 !important;
  justify-content: center;
}

/* Settings panel: smooth expand/collapse */
.cookie-settings {
  border-top: 1px solid var(--color-border);
  margin-top: 0.75rem;
  padding-top: 0.75rem;
  max-height: 0;
  overflow: hidden;
  opacity: 0;
  transform: translateY(-4px);
  transition: max-height 260ms ease, opacity 200ms ease, transform 260ms cubic-bezier(.2,1,.3,1);
}
.cookie-settings.is-open {
  max-height: 1200px; /* large enough for content */
  opacity: 1;
  transform: none;
}

/* Settings options */
.cookie-banner__form { display: grid; gap: 0.5rem 1rem; }
.cookie-opt { display: grid; grid-template-columns: 1fr; gap: 0.25rem; padding: 0.5rem 0; }
.cookie-opt small { color: var(--color-muted); }
.cookie-opt--required small { color: var(--color-muted); }
.cookie-opt label { display: inline-flex; align-items: center; gap: 0.5rem; font-weight: 600; }
.cookie-opt input[type="checkbox"] { width: 18px; height: 18px; }

/* Consent actions: neutral styling, equal widths (override any earlier rules) */
/* Removed legacy horizontal/equal-width block to enforce vertical stack */
/* .cookie-banner__actions { display: inline-flex; gap: 0.5rem; flex-wrap: wrap; width: 100%; }
.cookie-banner__actions .btn { flex: 1 1 0 !important; min-width: 0 !important; justify-content: center; }
.cookie-banner__actions #cookie-accept-all {
  background: var(--color-primary) !important;
  box-shadow: none !important;
  border: 1px solid rgba(1,147,202,0.08) !important;
}
.cookie-banner__actions #cookie-accept-all:hover { filter: none !important; transform: none !important; }
.cookie-banner__actions #cookie-reject-all { background: transparent; border-color: var(--color-border); color: var(--color-text); }
.cookie-banner__actions #cookie-toggle-settings { color: var(--color-text); } */

/* Ensure hidden consent elements are not hit-tested or displayed */
.cookie-backdrop[hidden],
.cookie-banner[hidden] {
  display: none !important;
}
/* Extra safety: when banner is not visible, disable inner pointer events */
.cookie-banner:not(.is-visible) .cookie-banner__inner { pointer-events: none; }

