/* Direction B — carte postale chic, sans dépendance distante. */
:root {
  --cream: #fbf7ef;
  --paper: #fffdf8;
  --ocean: #073f5c;
  --ocean-soft: #4f8da8;
  --terracotta: #ad4f31;
  --sun: #a86b00;
  --pine: #587153;
  --ink: #183044;
  --muted: #62707b;
  --line: #e6ded1;
  --shadow: 0 0.75rem 2rem rgb(24 48 68 / 10%);
  font-family: Inter, Avenir, "Segoe UI", Arial, sans-serif;
  color: var(--ink);
  background: var(--cream);
  line-height: 1.55;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  min-width: 18rem;
  margin: 0;
  background:
    radial-gradient(circle at 15% 20%, rgb(232 170 52 / 5%), transparent 25rem),
    linear-gradient(rgb(255 255 255 / 28%), rgb(255 255 255 / 28%)),
    var(--cream);
}
img { display: block; max-width: 100%; }
a { color: var(--ocean); }
button, input, select { font: inherit; }
button, .button { min-height: 2.75rem; }

.skip-link {
  position: fixed;
  z-index: 100;
  top: 0.5rem;
  left: 0.5rem;
  padding: 0.65rem 1rem;
  color: white;
  background: var(--ocean);
  border-radius: 0.4rem;
  transform: translateY(-150%);
}
.skip-link:focus { transform: translateY(0); }

.site-header {
  width: min(100% - 2rem, 92rem);
  min-height: 6rem;
  margin-inline: auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 2rem;
}
.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.9rem;
  color: var(--ocean);
  text-decoration: none;
}
.brand-mark {
  width: 3.75rem;
  height: 3.75rem;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.brand strong {
  display: block;
  font: 700 clamp(1.35rem, 2.2vw, 2rem)/1.1 Georgia, "Times New Roman", serif;
}
.brand small {
  display: block;
  margin-top: 0.35rem;
  color: var(--terracotta);
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.26em;
  text-transform: uppercase;
}
.desktop-navigation { display: flex; align-items: center; gap: clamp(1rem, 2.5vw, 2.75rem); }
.mobile-navigation { display: none; }
.site-header nav a, .nav-action {
  position: relative;
  padding: 0.45rem 0.1rem;
  border: 0;
  color: var(--ink);
  background: transparent;
  font-weight: 650;
  text-decoration: none;
  cursor: pointer;
}
.site-header nav a[aria-current="page"] { color: var(--terracotta); }
.site-header nav a[aria-current="page"]::after {
  position: absolute;
  right: 20%;
  bottom: -0.15rem;
  left: 20%;
  height: 0.15rem;
  content: "";
  background: var(--terracotta);
  border-radius: 1rem;
}
.site-header nav form { margin: 0; }

main { min-height: calc(100vh - 15rem); }
.home-hero {
  width: min(100% - 2rem, 92rem);
  margin: 0 auto;
  display: grid;
  grid-template-columns: minmax(20rem, 0.8fr) minmax(32rem, 1.4fr);
  gap: clamp(2rem, 5vw, 5rem);
  align-items: center;
}
.hero-copy { padding: clamp(2rem, 5vw, 5rem) 0; }
.sun-sketch {
  width: 5.5rem;
  height: auto;
  margin-bottom: 1rem;
  fill: none;
  stroke: var(--sun);
  stroke-width: 2;
  stroke-linecap: round;
}
.eyebrow {
  margin: 0 0 0.8rem;
  color: var(--terracotta);
  font-size: 0.75rem;
  font-weight: 800;
  letter-spacing: 0.18em;
  text-transform: uppercase;
}
h1, h2, h3 { color: var(--ocean); font-family: Georgia, "Times New Roman", serif; }
h1 { margin: 0; font-size: clamp(2.7rem, 5vw, 5.8rem); font-weight: 500; line-height: 0.98; letter-spacing: -0.045em; }
.hand-stroke {
  display: block;
  width: 9.5rem;
  height: 0.28rem;
  margin: 1.35rem 0 1.2rem;
  background: var(--terracotta);
  border-radius: 50%;
  transform: rotate(-1deg);
  clip-path: polygon(0 45%, 85% 0, 100% 48%, 85% 78%, 0 100%);
}
.hero-intro { max-width: 30rem; margin: 0 0 2rem; color: var(--ink); font-size: clamp(1.05rem, 1.5vw, 1.25rem); }
.hero-actions { display: flex; flex-wrap: wrap; gap: 1rem; }
.button, button:not(.nav-action) {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 1rem;
  width: max-content;
  padding: 0.75rem 1.5rem;
  border: 0.1rem solid var(--ocean);
  border-radius: 0.42rem;
  color: white;
  background: var(--ocean);
  box-shadow: none;
  font-weight: 700;
  text-decoration: none;
  cursor: pointer;
}
.button:hover, button:not(.nav-action):hover { background: #052f45; }
.button.outline { color: var(--ocean); background: transparent; }
.button.outline:hover { color: white; background: var(--ocean); }

.photo-collage {
  height: clamp(28rem, 55vw, 44rem);
  overflow: hidden;
  display: grid;
  grid-template-columns: 1fr 1.05fr;
  grid-template-rows: 1fr 1fr;
  gap: 0.22rem;
  border-radius: 2.1rem;
  background: white;
  box-shadow: var(--shadow);
}
.photo-collage img { width: 100%; height: 100%; object-fit: cover; }
.collage-dunes { grid-row: 1 / 3; }

.postcard-features { width: min(100% - 2rem, 92rem); margin: clamp(4rem, 8vw, 7rem) auto; }
.section-heading { max-width: 50rem; margin-bottom: 2rem; }
.section-heading h2 { margin: 0; font-size: clamp(2rem, 4vw, 3.6rem); font-weight: 500; line-height: 1.05; }
.feature-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1rem; }
.feature-card {
  min-height: 16rem;
  overflow: hidden;
  display: grid;
  grid-template-columns: minmax(8rem, 0.95fr) minmax(10rem, 1fr);
  background: var(--paper);
  border: 1px solid rgb(24 48 68 / 8%);
  border-radius: 1rem;
  box-shadow: var(--shadow);
}
.feature-card > img { width: 100%; height: 100%; object-fit: cover; }
.feature-card > div { padding: 1.6rem 1.4rem; }
.feature-icon {
  width: 3.2rem;
  height: 3.2rem;
  display: grid;
  place-items: center;
  margin-bottom: 1rem;
  border-radius: 50%;
  color: white;
  background: var(--ocean-soft);
  font: 2rem/1 Georgia, serif;
}
.feature-card.pine .feature-icon { background: var(--pine); }
.feature-card.terracotta .feature-icon { background: var(--terracotta); }
.feature-card h3 { margin: 0 0 0.8rem; font-size: 1.5rem; font-weight: 600; line-height: 1.05; }
.feature-card p { margin: 0; color: var(--muted); }

.page-shell {
  width: min(100% - 2rem, 76rem);
  margin: clamp(2rem, 5vw, 5rem) auto clamp(4rem, 8vw, 7rem);
}
.page-intro { max-width: 46rem; margin-bottom: 2rem; }
.page-intro h1 { font-size: clamp(2.7rem, 6vw, 5rem); }
.page-intro > p:last-child { max-width: 36rem; margin-top: 1.2rem; color: var(--muted); font-size: 1.1rem; }
.auth-shell { display: grid; grid-template-columns: 0.9fr minmax(22rem, 0.75fr); gap: clamp(2rem, 8vw, 8rem); align-items: center; max-width: 68rem; }
.auth-shell::before {
  content: "";
  position: fixed;
  z-index: -1;
  right: -9rem;
  bottom: -8rem;
  width: 32rem;
  height: 32rem;
  border: 5rem solid rgb(79 141 168 / 7%);
  border-radius: 50%;
}
.form-card {
  display: grid;
  gap: 1.25rem;
  padding: clamp(1.5rem, 4vw, 2.7rem);
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: 1.2rem;
  box-shadow: var(--shadow);
}
.field { display: grid; gap: 0.45rem; }
.field label { color: var(--ocean); font-weight: 750; }
.field small { color: var(--muted); }
input, select {
  width: 100%;
  min-height: 3rem;
  padding: 0.7rem 0.85rem;
  border: 1px solid #9fa8ab;
  border-radius: 0.45rem;
  color: var(--ink);
  background: white;
}
.form-footnote { margin: 0.2rem 0 0; color: var(--muted); }
.form-footnote a { font-weight: 700; }
.reservation-shell { max-width: 62rem; }
.reservation-card { grid-template-columns: 1fr 1fr; }
.reservation-card .full, .reservation-card .alert, .reservation-card button { grid-column: 1 / -1; }
.alert {
  width: min(100% - 2rem, 76rem);
  margin: 1rem auto;
  padding: 1rem 1.2rem;
  border-left: 0.28rem solid var(--terracotta);
  color: var(--ink);
  background: #fff8e7;
  border-radius: 0.2rem 0.6rem 0.6rem 0.2rem;
}
.form-card .alert { width: auto; margin: 0; }
.error { border-color: #ad352d; background: #fff0ed; }
.warning { margin-inline: 0; }
.page-heading-row { display: flex; align-items: end; justify-content: space-between; gap: 2rem; }

.table-wrap {
  overflow: hidden;
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: 1rem;
  box-shadow: var(--shadow);
}
table { width: 100%; border-collapse: collapse; }
th, td { padding: 1rem 1.2rem; text-align: left; border-bottom: 1px solid var(--line); }
th { color: var(--ocean); background: #f3ede3; font-size: 0.78rem; letter-spacing: 0.08em; text-transform: uppercase; }
tbody tr:last-child td { border-bottom: 0; }
.empty-row td { padding: 3rem; color: var(--muted); text-align: center; }
.badge { display: inline-block; padding: 0.3rem 0.72rem; border-radius: 99rem; font-size: 0.82rem; font-weight: 750; }
.pending { color: #704500; background: #ffe4a3; }
.approved { color: #175338; background: #cce9d6; }
.rejected { color: #742d29; background: #f2d2ce; }

.planning-shell { width: min(100% - 2rem, 92rem); }
.calendar-navigation {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  gap: 1rem;
  align-items: center;
  margin: 1rem 0;
}
.calendar-navigation h2 { margin: 0; font-size: clamp(1.5rem, 3vw, 2.2rem); text-align: center; }
.calendar-navigation a:last-child { justify-self: end; }
.calendar-legend { display: flex; flex-wrap: wrap; gap: 0.75rem; margin: 1rem 0; }
.calendar-legend .calendar-booking { position: static; width: auto; }
.calendar-scroll-hint { margin: 0.75rem 0; color: var(--muted); }
.calendar-empty { padding: 0.75rem 1rem; color: var(--ink); background: #fff8e7; border-radius: 0.5rem; }
.calendar-scroll {
  overflow-x: auto;
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: 1rem;
  box-shadow: var(--shadow);
  scrollbar-gutter: stable;
}
.calendar-grid { min-width: calc(10rem + var(--day-count) * 2.6rem); }
.calendar-header, .calendar-room {
  display: grid;
  grid-template-columns: 10rem repeat(var(--day-count), 2.6rem);
}
.calendar-header { position: sticky; z-index: 5; top: 0; min-height: 2.8rem; background: #f3ede3; }
.calendar-corner, .calendar-room-name {
  position: sticky;
  z-index: 4;
  left: 0;
  display: flex;
  align-items: center;
  padding: 0.65rem 0.8rem;
  color: var(--ocean);
  background: #f3ede3;
  border-right: 1px solid var(--line);
  font-size: 0.78rem;
  font-weight: 800;
}
.calendar-day { display: grid; place-items: center; border-right: 1px solid var(--line); font-size: 0.75rem; font-weight: 750; }
.calendar-day.weekend, .calendar-cell.weekend { background: rgb(7 63 92 / 5%); }
.calendar-day.today { box-shadow: inset 0 -0.2rem var(--terracotta); }
.calendar-room {
  position: relative;
  min-height: calc(var(--lane-count) * 2.35rem + 0.7rem);
  border-top: 1px solid var(--line);
}
.calendar-room-name { grid-column: 1; grid-row: 1; margin: 0; background: var(--room-color); }
.calendar-room-days { grid-column: 2 / -1; grid-row: 1; display: grid; grid-template-columns: repeat(var(--day-count), 2.6rem); }
.calendar-cell { border-right: 1px solid var(--line); }
.calendar-booking {
  position: absolute;
  z-index: 2;
  top: calc(0.35rem + var(--lane) * 2.35rem);
  left: calc(10rem + (var(--start) - 1) * 2.6rem + 0.1rem);
  width: calc(var(--span) * 2.6rem - 0.2rem);
  min-width: 2.2rem;
  height: 2rem;
  overflow: hidden;
  padding: 0.25rem 0.4rem;
  border: 2px solid var(--ink);
  border-radius: 0.35rem;
  color: var(--ink);
  background: var(--room-color, #d9eaf2);
  font-size: 0.72rem;
  font-weight: 800;
  line-height: 1.25;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.calendar-booking.approved { border-style: solid; }
.calendar-booking.pending {
  border-style: dashed;
  background: repeating-linear-gradient(135deg, var(--room-color, #d9eaf2) 0 0.45rem, #fffdf8 0.45rem 0.75rem);
}
.calendar-booking.continues-before { border-left-style: dotted; border-radius: 0 0.35rem 0.35rem 0; }
.calendar-booking.continues-after { border-right-style: dotted; border-radius: 0.35rem 0 0 0.35rem; }
.calendar-room-free { position: absolute; left: 10.75rem; top: 0.65rem; color: var(--muted); font-size: 0.8rem; }
.room-1 { --room-color: #d9eaf2; }
.room-2 { --room-color: #f1ddd5; }
.room-3 { --room-color: #e0e8d9; }
.room-4 { --room-color: #f6e4b8; }
.room-5 { --room-color: #e5ddf0; }
.room-6 { --room-color: #d9ece8; }
.room-7 { --room-color: #f0dde2; }

.reservation-list { display: grid; gap: 1rem; }
.request-card {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 1rem 2rem;
  align-items: center;
  padding: 1.4rem 1.5rem;
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: 0.9rem;
  box-shadow: 0 0.4rem 1.2rem rgb(24 48 68 / 7%);
}
.request-main h2 { margin: 0.15rem 0; font-size: 1.55rem; }
.request-main h2 span { display: inline-block; margin-left: 0.5rem; color: var(--terracotta); font: 700 0.7rem/1 sans-serif; letter-spacing: 0.08em; text-transform: uppercase; }
.request-main p { margin: 0.25rem 0; }
.request-meta { color: var(--terracotta); font-size: 0.8rem; font-weight: 750; letter-spacing: 0.05em; }
.request-actions { grid-column: 1 / -1; display: flex; gap: 0.7rem; padding-top: 1rem; border-top: 1px solid var(--line); }
.request-actions form { margin: 0; }
button.secondary { color: var(--ocean); background: transparent; }
button.secondary:hover { color: white; background: var(--terracotta); border-color: var(--terracotta); }
.empty-state { padding: 4rem 2rem; text-align: center; background: var(--paper); border: 1px solid var(--line); border-radius: 1rem; }
.empty-state > span { color: var(--sun); font-size: 3rem; }
.empty-state h2 { margin: 0.5rem 0; font-size: 2rem; }
.empty-state p { margin: 0; color: var(--muted); }

.site-footer {
  width: min(100% - 2rem, 92rem);
  margin: 0 auto;
  padding: 2rem 0;
  display: flex;
  justify-content: space-between;
  gap: 2rem;
  border-top: 1px solid var(--line);
  color: var(--muted);
  font-size: 0.9rem;
}
.site-footer p { margin: 0; }
.site-footer strong { color: var(--ocean); }
.site-footer span { margin-left: 0.75rem; }

:focus-visible { outline: 0.2rem solid var(--sun); outline-offset: 0.2rem; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

@media (max-width: 68rem) {
  .site-header { align-items: flex-start; padding-block: 1rem; }
  .site-header nav { justify-content: flex-end; gap: 1rem 1.5rem; flex-wrap: wrap; }
  .home-hero { grid-template-columns: 0.85fr 1.15fr; gap: 2rem; }
  .photo-collage { height: 35rem; }
  .feature-grid { grid-template-columns: 1fr; }
  .feature-card { grid-template-columns: minmax(12rem, 0.7fr) 1fr; min-height: 14rem; }
}

@media (max-width: 48rem) {
  .site-header { min-height: auto; flex-direction: column; gap: 0.8rem; }
  .brand-mark { width: 3rem; height: 3rem; }
  .brand strong { font-size: 1.35rem; }
  .desktop-navigation { display: none; }
  .mobile-navigation { display: block; width: 100%; border-top: 1px solid var(--line); }
  .mobile-navigation > summary {
    display: block;
    width: max-content;
    margin-left: auto;
    padding: 0.65rem 0;
    color: var(--ocean);
    font-weight: 750;
    cursor: pointer;
  }
  .mobile-navigation > nav { display: none; }
  .mobile-navigation[open] > nav { display: flex; }
  .site-header nav { width: 100%; justify-content: flex-start; gap: 0.4rem 1.15rem; padding-bottom: 0.6rem; flex-wrap: wrap; }
  .site-header nav a, .nav-action { white-space: nowrap; }
  .home-hero { grid-template-columns: 1fr; }
  .hero-copy { padding: 2.5rem 0 0; }
  .sun-sketch { width: 4.5rem; }
  .photo-collage { height: min(115vw, 34rem); border-radius: 1.4rem; }
  .postcard-features { margin-top: 4rem; }
  .feature-card { grid-template-columns: 1fr; }
  .feature-card > img { height: 13rem; }
  .auth-shell { grid-template-columns: 1fr; gap: 0; }
  .reservation-card { grid-template-columns: 1fr; }
  .page-heading-row { align-items: flex-start; flex-direction: column; }
  .calendar-navigation { grid-template-columns: 1fr 1fr; }
  .calendar-navigation h2 { grid-column: 1 / -1; grid-row: 1; }
  .calendar-navigation a { grid-row: 2; width: 100%; padding-inline: 0.75rem; }
  .table-wrap { overflow: visible; border: 0; background: transparent; box-shadow: none; }
  table, tbody, tr, td { display: block; }
  thead { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
  tbody { display: grid; gap: 1rem; }
  tbody tr { padding: 0.6rem 1rem; background: var(--paper); border: 1px solid var(--line); border-radius: 0.8rem; box-shadow: 0 0.4rem 1.2rem rgb(24 48 68 / 7%); }
  td { display: grid; grid-template-columns: 8rem 1fr; gap: 1rem; padding: 0.65rem 0; border-bottom: 1px solid var(--line); }
  td::before { content: attr(data-label); color: var(--ocean); font-size: 0.75rem; font-weight: 800; letter-spacing: 0.06em; text-transform: uppercase; }
  .empty-row td { display: block; padding: 2rem 0.5rem; }
  .empty-row td::before { display: none; }
  .request-card { grid-template-columns: 1fr; }
  .request-status, .request-actions { grid-column: 1; }
  .site-footer { flex-direction: column; gap: 0.4rem; }
  .site-footer span { display: block; margin-left: 0; }
}

@media (max-width: 28rem) {
  .hero-actions, .hero-actions .button, .form-card button { width: 100%; }
  .photo-collage { grid-template-columns: 1fr; grid-template-rows: 1.2fr 0.8fr; }
  .collage-dunes { grid-row: auto; }
  .collage-pins { display: none; }
  td { grid-template-columns: 6.5rem 1fr; }
  .request-actions { flex-direction: column; }
  .request-actions button { width: 100%; }
}
