/* Design tokens (TASK-21, AutoLiberty teal — primary #7db2bb from autoliberty.cz
   app.build.css (2026-09-19); dark/hover/tints from the proven TASK-7 teal era) */
:root {
  --accent: #7db2bb; /* AutoLiberty 2026 — teal CTA / utility (--bs-primary in their app.build.css) */
  --accent-dark: #5d939b; /* teal-dark — hover states (TASK-7 teal era) */
  --brand-accent: #5d939b; /* small accents (icons, eyebrows, links) — teal-dark for readability */
  --dark: #24565c; /* teal-deep — footer, reservation card (color-in-color) */
  --card-tint: #e8f0f2;
  --band-cream: #faf6ef;
  --band-tint: #e4eef0;
  --ink: #121111;
  --ink-soft: #555;
  --selected: #7db2bb; /* teal — calendar selected day, distinct from busy red */
  --surface: #fff;
  --radius-card: 20px;
  --radius-btn: 9px;
  --font: "Jost", system-ui, -apple-system, "Segoe UI", sans-serif;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; scroll-padding-top: 4.8rem; }

body {
  font-family: var(--font);
  color: var(--ink);
  background: var(--surface);
  margin: 0;
}

/* --- centered container inside full-bleed bands ------------------------ */
.container { max-width: 68rem; margin: 0 auto; padding: 0 1.25rem; }

/* --- utility band (teal, scrolls away) ------------------------------------ */
.utility-band { background: var(--accent); color: #fff; }
.utility-inner {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  padding: .45rem 0;
  font-size: .9rem;
  font-weight: 500;
}
.utility-item a { color: #fff; text-decoration: none; }
.utility-item a:hover { text-decoration: underline; }

/* --- sticky full-width nav bar ----------------------------------------- */
.nav-bar {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(255, 255, 255, .94);
  backdrop-filter: blur(6px);
  box-shadow: 0 1px 12px rgba(0, 0, 0, .09);
}
.nav-inner {
  display: flex;
  align-items: center;
  gap: 1.5rem;
  padding: .8rem 0;
}
.nav-bar .brand { font-weight: 700; font-size: 1.15rem; letter-spacing: .04em; text-decoration: none; color: var(--ink); }
.anchor-nav { display: flex; gap: 1.3rem; margin-left: auto; }
.anchor-nav a { text-decoration: none; color: var(--ink); font-weight: 500; }
.anchor-nav a:hover { color: var(--accent-dark); }

/* --- mobile hamburger (TASK-32; visible only <=640px) ------------------- */
.nav-toggle {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 44px;
  height: 40px;
  padding: 0 10px;
  background: none;
  border: 0;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}
.nav-toggle span {
  display: block;
  width: 100%;
  height: 2px;
  border-radius: 2px;
  background: var(--ink);
  transition: transform .2s ease, opacity .2s ease;
}
/* open state: bars morph into an X (aria-expanded is synced by nav.js) */
.nav-toggle[aria-expanded="true"] span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.nav-toggle[aria-expanded="true"] span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }
/* mobile panel CTA — desktop keeps the separate .cta.cta-small in the row;
 * specificity (0,2,0) beats .cta's own display so this must win in both modes */
.anchor-nav .nav-cta { display: none; }

/* --- buttons / CTA ----------------------------------------------------- */
.cta {
  display: inline-block;
  background: var(--accent);
  color: #fff;
  text-decoration: none;
  font-family: var(--font);
  font-weight: 700;
  letter-spacing: .08em;
  text-transform: uppercase;
  font-size: .9rem;
  padding: .7rem 1.5rem;
  border-radius: var(--radius-btn);
  border: none;
  cursor: pointer;
}
.cta:hover { background: var(--accent-dark); color: #fff; }
.cta.cta-small { padding: .45rem 1.1rem; font-size: .8rem; }
.cta:disabled { opacity: .45; cursor: not-allowed; }

/* --- hero (full-bleed photo band) --------------------------------------- */
.hero {
  min-height: 62vh;
  display: flex;
  align-items: flex-end;
  background-size: cover;
  background-position: center;
}
.hero-inner { padding: 3.2rem 0; color: #fff; background: linear-gradient(transparent 10%, rgba(0, 0, 0, .68)); width: 100%; }
.hero-inner h1 { margin: 0 0 .6rem; font-size: clamp(2rem, 5vw, 4.2rem); font-weight: 700; line-height: 1.05; text-shadow: 0 2px 8px rgba(0, 0, 0, .45); }
.hero-claim { margin: 0 0 1.4rem; font-size: 1.2rem; max-width: 34rem; text-shadow: 0 1px 6px rgba(0, 0, 0, .45); }

/* --- feature strip (floating card overlapping the hero) ----------------- */
.feature-strip {
  background: var(--surface);
  border-radius: var(--radius-card);
  box-shadow: 0 2px 14px rgba(0, 0, 0, .08);
  display: grid;
  /* TASK-14: 8 icons in one row on wide screens, 4+4 below ~1130 px
   * (auto-fit with min 9.5rem used to wrap 7+1) */
  grid-template-columns: repeat(8, 1fr);
  gap: 1.2rem .8rem;
  padding: 1.4rem 1.6rem;
  max-width: 68rem;
  margin: -1.6rem auto 0;
  position: relative;
  z-index: 4;
}
@media (max-width: 1129px) {
  .feature-strip { grid-template-columns: repeat(4, 1fr); } /* TASK-14: 4+4 */
}
.feature { display: flex; flex-direction: column; align-items: center; text-align: center; gap: .45rem; font-size: .85rem; color: var(--ink-soft); }
.feature-icon { display: flex; color: var(--brand-accent); }
.feature-icon svg { width: 27px; height: 27px; }
.feature-note { max-width: 68rem; margin: .6rem auto 0; padding: 0 1.25rem; }

/* --- full-bleed color bands ---------------------------------------------- */
.band-cream { background: var(--band-cream); }
.band-tint { background: var(--band-tint); }
.band-white { background: var(--surface); }

/* --- sections ----------------------------------------------------------- */
.section { padding: 3rem 0 2.5rem; }
.section-head { text-align: center; margin-bottom: 1.8rem; }
.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: .5rem;
  color: var(--brand-accent);
  font-size: .8rem;
  font-weight: 700;
  letter-spacing: .14em;
  text-transform: uppercase;
}
.eyebrow::before, .eyebrow::after { content: "—"; color: var(--brand-accent); }
.section-head h2 { margin: .3rem 0 0; font-size: clamp(1.6rem, 3.4vw, 2.4rem); font-weight: 700; }

/* --- about section ------------------------------------------------------- */
.about-grid { display: flex; gap: 2.2rem; align-items: flex-start; flex-wrap: wrap; }
.about-photo { flex: 0 0 auto; max-width: 24rem; width: 100%; border-radius: var(--radius-card); box-shadow: 0 3px 16px rgba(0, 0, 0, .14); }
.about-photo.about-plan { max-width: 34rem; background: var(--surface); padding: 1rem; }
.about-text { flex: 1 1 18rem; min-width: 16rem; }
.about-text p { margin-top: 0; }
.about-media { display: flex; flex-direction: column; gap: 1.2rem; max-width: 34rem; }
.about-media .about-photo { max-width: 100%; }
.check-list { list-style: none; padding: 0; margin: 1rem 0 0; }
.check-list li { padding-left: 1.7rem; position: relative; margin-bottom: .45rem; }
.check-list li::before {
  content: "✔";
  position: absolute;
  left: 0;
  color: var(--brand-accent);
  font-weight: 700;
}

/* --- banners (inline confirmation / errors) ------------------------------- */
.banner { padding: .75rem 1.1rem; border-radius: var(--radius-btn); }
.banner.ok { background: #e8f6ec; border: 1px solid #9fd6ae; color: #0a7d28; }
.banner.error { background: #fdecee; border: 1px solid #f0b6be; color: #b00020; }
.error { color: #b00020; }
.ok { color: #0a7d28; }
.muted { color: #8a8a8a; font-size: .9rem; }

/* --- reservation card (deep teal color-in-color) ---------------------------- */
.reservation-card {
  background: var(--dark);
  color: #fff;
  border-radius: var(--radius-card);
  padding: 1.6rem 1.8rem;
}
.reservation-card .reservation-intro { color: #f2f7f8; }
.reservation-card .calendars { display: flex; flex-wrap: wrap; gap: 1rem 2.5rem; align-items: flex-start; margin-top: 1.2rem; }
.calendar {
  flex: 0 0 auto;
  background: var(--surface);
  border-radius: 14px;
  padding: .9rem 1rem;
}
.cal-head { display: flex; justify-content: space-between; align-items: center; margin: 0 0 .5rem; }
.cal-head .cal-label { font-weight: 700; text-align: center; flex: 1; color: var(--ink); }
.cal-head button {
  width: 2.6rem; padding: .2rem;
  background: var(--surface); border: 1px solid #d8e2e5; border-radius: var(--radius-btn);
  font-size: 1.1rem;
}
.cal-head button:hover { border-color: var(--accent); color: var(--accent-dark); }
.cal-grid { display: grid; grid-template-columns: repeat(7, 2.4rem); gap: 2px; }
.cal-grid .dow { font-weight: 600; text-align: center; color: var(--ink-soft); }
.cal-grid .day {
  width: 2.4rem; height: 2.4rem; padding: 0; text-align: center;
  border: 1px solid #dbe4e7; background: var(--surface); border-radius: 6px;
  font-family: var(--font);
}
.cal-grid .day:hover:not(.busy):not(.past) { border-color: var(--accent); }
.cal-grid .day.empty { border: none; background: transparent; }
.cal-grid .day.past { color: #bbb; background: #f4f4f4; cursor: not-allowed; }
.cal-grid .day.busy { color: #fff; background: #d47a72; cursor: not-allowed; border-color: #d47a72; }
.cal-grid .day.selected { background: var(--selected); border-color: var(--selected); color: #fff; font-weight: 700; }
.cal-legend { flex-basis: 100%; color: #dcebec; font-size: .9rem; margin: .2rem 0 0; }
.cal-legend .day { display: inline-block; width: .9rem; height: .9rem; vertical-align: middle; border: 1px solid #ccc; border-radius: 3px; }
.cal-legend .day.busy { background: #d47a72; border-color: #d47a72; }
.cal-legend .day.selected { background: var(--selected); border-color: var(--selected); }
.range-summary { font-weight: 700; margin: 1.2rem 0 0; }
/* --- booking two-column layout (calendar + form) ------------------------------ */
.booking-layout { display: grid; grid-template-columns: minmax(0, 1fr) 18rem; gap: 2rem; align-items: start; }
#request-form {
  background: var(--surface);
  border-radius: 14px;
  padding: 1.2rem 1.3rem;
  display: flex; flex-direction: column; gap: .5rem;
}
@media (max-width: 1000px) {
  .booking-layout { grid-template-columns: 1fr; }
  #request-form { max-width: 24rem; }
}
#request-form label { font-weight: 600; color: var(--ink); }
#request-form input { padding: .5rem .7rem; border: 1px solid #cbd5e0; border-radius: var(--radius-btn); font-family: var(--font); }
#request-form input:focus { outline: 2px solid var(--accent); border-color: var(--accent); }

/* --- contact cards ----------------------------------------------------------- */
.contact-grid { display: flex; gap: 1.6rem; flex-wrap: wrap; }
.contact-card {
  flex: 1 1 16rem;
  border-radius: var(--radius-card);
  padding: 1.3rem 1.5rem;
  background: var(--card-tint);
}
.contact-card strong { display: block; margin: .4rem 0 .6rem; font-size: 1.05rem; }
.contact-icon { display: flex; color: var(--brand-accent); }
.contact-icon svg { width: 26px; height: 26px; }
.contact-card a { color: var(--brand-accent); text-decoration: none; font-weight: 500; }
.contact-card a:hover { text-decoration: underline; }

/* --- form base (admin forms) -------------------------------------------------- */
form:not(#request-form) { display: flex; flex-direction: column; gap: .5rem; max-width: 20rem; }
label { font-weight: 600; }
input { padding: .4rem; font-family: var(--font); }
button { padding: .4rem .8rem; cursor: pointer; font-family: var(--font); }

/* --- misc --------------------------------------------------------------------- */
table { border-collapse: collapse; width: 100%; }
th, td { border: 1px solid #ddd; padding: .4rem .5rem; text-align: left; vertical-align: top; }
td form { display: inline; margin-right: .3rem; }

/* --- footer (full-width deep teal) ------------------------------------- */
.site-footer {
  background: var(--dark);
  color: #d8e6e8;
  text-align: center;
  padding: 1.6rem 0;
  margin: 0;
}
.site-footer a { color: #9fd0d6; text-decoration: none; }
.site-footer a:hover { text-decoration: underline; }

/* --- responsive ------------------------------------------------------------------ */
@media (max-width: 640px) {
  .utility-inner { flex-direction: column; align-items: center; gap: .2rem; padding: .5rem 0; }
  /* TASK-32: one clean header row (brand + hamburger); the anchor menu becomes
   * a dropdown panel below the brand row inside the sticky header */
  .nav-inner { flex-wrap: wrap; gap: .8rem; padding: .9rem 0; }
  .nav-toggle { display: flex; margin-left: auto; }
  .anchor-nav { display: none; margin-left: 0; }
  .anchor-nav .mobile-hide { display: none; }
  .nav-inner > .cta.cta-small { display: none; } /* row CTA lives in the panel now */
  .anchor-nav.nav-open {
    display: flex;
    flex-direction: column;
    width: 100%;
    gap: 0;
    padding: .2rem 0 .7rem;
    border-top: 1px solid rgba(0, 0, 0, .08);
  }
  .anchor-nav.nav-open a:not(.nav-cta) {
    padding: .8rem .25rem;
    border-bottom: 1px solid rgba(0, 0, 0, .05);
  }
  .anchor-nav.nav-open .nav-cta {
    display: inline-flex;
    justify-content: center;
    margin-top: .6rem;
    padding: .8rem 1.2rem;
    font-size: .85rem;
  }
  .hero { min-height: 46vh; }
  .hero-inner { padding: 2rem 0; }
  .feature-strip { margin: -1rem auto 0; grid-template-columns: repeat(2, 1fr); padding: 1.1rem 1rem; }
  .reservation-card { padding: 1.2rem 1rem; }
  .cal-grid { grid-template-columns: repeat(7, 2rem); }
  .cal-grid .day { width: 2rem; height: 2rem; }
  .about-photo { max-width: 100%; }
}


/* --- gallery (TASK-24) ------------------------------------------------------------ */
.gallery-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 1.2rem;
}
.gallery-item {
  display: block;
  position: relative;
  border-radius: var(--radius-card);
  overflow: hidden;
  background: var(--card-tint);
  text-decoration: none;
}
.gallery-item img {
  display: block;
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  transition: transform .25s ease;
}
.gallery-item:hover img,
.gallery-item:focus-visible img { transform: scale(1.045); }
.gallery-item:focus-visible { outline: 3px solid var(--accent-dark); outline-offset: 2px; }
.gallery-caption {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  padding: 1.7rem .9rem .6rem;
  background: linear-gradient(transparent, rgba(0, 0, 0, .62));
  color: #fff;
  font-size: .9rem;
  font-weight: 600;
  letter-spacing: .01em;
}

/* --- lightbox (TASK-24) ------------------------------------------------------------ */
body.lightbox-open { overflow: hidden; }
.lightbox {
  position: fixed;
  inset: 0;
  z-index: 90;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(0, 0, 0, .82);
  padding: 2.2rem;
}
.lightbox[hidden] { display: none; }
.lightbox img {
  max-width: min(1100px, 92vw);
  max-height: 84vh;
  border-radius: var(--radius-btn);
  object-fit: contain;
}
.lightbox-close, .lightbox-prev, .lightbox-next {
  position: absolute;
  width: 2.6rem;
  height: 2.6rem;
  border: none;
  border-radius: 50%;
  background: rgba(255, 255, 255, .92);
  color: var(--ink);
  font-size: 1.25rem;
  line-height: 1;
  cursor: pointer;
}
.lightbox-close:hover, .lightbox-prev:hover, .lightbox-next:hover { background: var(--accent); color: #fff; }
.lightbox-close { top: 1.1rem; right: 1.1rem; }
.lightbox-prev { left: 1rem; top: 50%; transform: translateY(-50%); }
.lightbox-next { right: 1rem; top: 50%; transform: translateY(-50%); }
.lightbox-count {
  position: absolute;
  top: 1.5rem;
  left: 1.4rem;
  color: #fff;
  font-size: .95rem;
}
@media (max-width: 640px) {
  .lightbox { padding: .6rem; }
  .lightbox-prev { left: .35rem; }
  .lightbox-next { right: .35rem; }
}

/* TASK-30: pricing quote — structured lines (owner note 21. 9.: label line,
   bare calculation line, service-fee line; total only on the submit button) */
.price-quote {
  margin: 0.6rem 0 0.2rem;
  color: #24565c;
}
.price-quote .quote-label {
  font-size: 0.95rem;
  color: #3f5b63;
}
.price-quote .quote-calc {
  font-weight: 700;
  font-size: 1.15rem;
}
.price-quote .quote-fee {
  font-size: 0.95rem;
}
.addons {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
  margin: 0.8rem 0;
}
.addons label {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.95rem;
}
.addons input[type="checkbox"] {
  width: 1.05rem;
  height: 1.05rem;
  accent-color: #7db2bb;
}

/* TASK-31: pricing section (Cenik) — one period per row, ordered
   Jaro/Leto/Podzim/Zima (owner note 21. 9.: single-column list with the
   tip beside the title+price). */
.pricing-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1rem;
}
.pricing-row {
  display: flex;
  align-items: flex-start;
  gap: 1.1rem;
}
.pricing-main {
  flex: 0 0 15rem;
}
.pricing-price {
  font-size: 1.55rem;
  font-weight: 700;
  color: #24565c;
  margin: 0.3rem 0 0;
}
.pricing-tip {
  margin: 0;
  flex: 1;
  font-size: 0.97rem;
}
.pricing-note {
  margin-top: 1.1rem;
  font-size: 0.95rem;
  color: #3f5b63;
}
@media (max-width: 640px) {
  .pricing-row {
    flex-direction: column;
    gap: 0.5rem;
  }
}
