/*
 * Casa Marés — the hotel's own stylesheet.
 *
 * Nothing in this file knows the booking engine exists. That is the point: the
 * widget inherits type and colour from wherever a block is placed, so this file
 * is the only thing deciding how the page feels. If you are evaluating the
 * engine, try changing --ink and --paper below and reloading — the booking UI
 * follows without touching a line of engine code.
 */

@import url('https://fonts.googleapis.com/css2?family=Instrument+Serif:ital@0;1&family=DM+Sans:opsz,wght@9..40,200;9..40,300;9..40,400;9..40,500&display=swap');

:root {
  --ink: #1e1c18;
  --paper: #fbf9f5;
  --bone: #f2eee6;
  --muted: #6d675d;
  --line: #ddd6ca;
  --sea: #2f4638;

  --shell: min(1240px, 100% - 48px);
  --gutter: clamp(64px, 9vw, 132px);
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: 'DM Sans', system-ui, sans-serif;
  font-weight: 300;
  font-size: 16.5px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}

h1,
h2,
h3,
.display {
  margin: 0;
  font-family: 'Instrument Serif', Georgia, serif;
  font-weight: 400;
  line-height: 1.06;
  letter-spacing: -0.015em;
}

p {
  margin: 0;
}

img {
  display: block;
  max-width: 100%;
}

a {
  color: inherit;
}

.shell {
  width: var(--shell);
  margin-inline: auto;
}

.eyebrow {
  font-size: 0.6875rem;
  font-weight: 400;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--muted);
}

.lede {
  font-size: 1.0625rem;
  color: var(--muted);
  max-width: 54ch;
}

/* ----------------------------------------------------------------- buttons */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  min-height: 46px;
  padding: 0 26px;
  border: 0;
  border-radius: 2px;
  background: var(--sea);
  color: #f6f3ec;
  font: inherit;
  font-size: 0.75rem;
  font-weight: 400;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  text-decoration: none;
  cursor: pointer;
  transition: opacity 0.2s ease;
}

.btn:hover {
  opacity: 0.85;
}

.btn--line {
  background: transparent;
  color: var(--ink);
  box-shadow: inset 0 0 0 1px var(--line);
}

.btn--light {
  background: rgba(255, 255, 255, 0.94);
  color: var(--ink);
}

/* --------------------------------------------------------------------- nav */

.nav {
  position: sticky;
  top: 0;
  z-index: 60;
  background: color-mix(in srgb, var(--paper) 88%, transparent);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line);
}

.nav__inner {
  display: flex;
  align-items: center;
  gap: 40px;
  min-height: 76px;
}

.nav__logo {
  font-family: 'Instrument Serif', serif;
  font-size: 1.3rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  text-decoration: none;
}

.nav__links {
  display: flex;
  gap: 30px;
  margin: 0 auto 0 0;
  padding: 0;
  list-style: none;
}

.nav__links a {
  font-size: 0.72rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  text-decoration: none;
  color: var(--muted);
  padding-bottom: 3px;
  border-bottom: 1px solid transparent;
}

.nav__links a:hover,
.nav__links a[aria-current='page'] {
  color: var(--ink);
  border-bottom-color: var(--ink);
}

.nav__end {
  display: flex;
  align-items: center;
  gap: 22px;
}

/* -------------------------------------------------------------------- hero */

.hero {
  position: relative;
  min-height: 84vh;
  display: grid;
  align-items: end;
  padding: 0 0 var(--gutter);
  color: #fff;
  overflow: hidden;
}

.hero__media {
  position: absolute;
  inset: 0;
}

.hero__media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* Weighted to the bottom, where the headline sits. A flat scrim strong enough
   to carry text would flatten the photograph as well. */
.hero__media::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(
    180deg,
    rgba(20, 18, 15, 0.36) 0%,
    rgba(20, 18, 15, 0.08) 26%,
    rgba(20, 18, 15, 0.52) 62%,
    rgba(20, 18, 15, 0.78) 100%
  );
}

.hero__body {
  position: relative;
  display: grid;
  gap: 20px;
  justify-items: start;
}

.hero h1 {
  /* In ch on the heading itself, so the measure tracks the display size rather
     than the body size it would resolve against on the container. */
  max-width: 13ch;
  font-size: clamp(3rem, 7.5vw, 6rem);
}

.hero p {
  max-width: 42ch;
  color: rgba(255, 255, 255, 0.86);
}

.hero .eyebrow {
  color: rgba(255, 255, 255, 0.82);
  /* The headline carries itself at six rem; eleven-pixel caps over a sunlit
     cliff do not, and the scrim cannot be deepened without dulling the photo. */
  text-shadow: 0 1px 12px rgba(20, 18, 15, 0.75);
}

.hero--short {
  min-height: 52vh;
}

/* --------------------------------------------------------- the booking shelf */

/*
 * The search block sits in this card. It is a plain light surface on purpose:
 * the widget samples the background and text colour of whatever contains it, so
 * a legible parent is all the configuration it needs.
 */
.shelf {
  position: relative;
  z-index: 5;
  margin-top: -46px;
  margin-bottom: calc(var(--gutter) * -0.2);
  padding: 8px;
  background: var(--paper);
  border: 1px solid var(--line);
  box-shadow: 0 30px 60px -40px rgba(30, 28, 24, 0.5);
}

.shelf--flat {
  margin-top: 0;
  box-shadow: none;
}

/* ---------------------------------------------------------------- sections */

.section {
  padding: var(--gutter) 0;
}

.section--bone {
  background: var(--bone);
}

.section__head {
  display: grid;
  gap: 16px;
  max-width: 62ch;
  margin-bottom: 56px;
}

.section__head h2 {
  font-size: clamp(2.1rem, 4.4vw, 3.4rem);
}

.section__head--center {
  margin-inline: auto;
  text-align: center;
  justify-items: center;
}

/* ------------------------------------------------------------------ spreads */

.spread {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(40px, 6vw, 96px);
  align-items: center;
}

.spread__text {
  display: grid;
  gap: 22px;
  max-width: 46ch;
}

.spread__text h2 {
  font-size: clamp(1.9rem, 3.6vw, 2.9rem);
}

.spread__text p {
  color: var(--muted);
}

.spread img {
  width: 100%;
  aspect-ratio: 4 / 5;
  object-fit: cover;
}

.spread--flip .spread__media {
  order: -1;
}

.pull {
  font-family: 'Instrument Serif', serif;
  font-style: italic;
  font-size: 1.35rem;
  line-height: 1.4;
  color: var(--ink);
}

/* ------------------------------------------------------------- experiences */

.tiles {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 30px;
}

.tile {
  display: grid;
  gap: 14px;
}

.tile img {
  width: 100%;
  aspect-ratio: 3 / 4;
  object-fit: cover;
}

.tile h3 {
  font-size: 1.4rem;
}

.tile p {
  font-size: 0.9375rem;
  color: var(--muted);
}

/* --------------------------------------------------------------- rate notes */

.notes {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 34px;
  padding-top: 44px;
  border-top: 1px solid var(--line);
}

.note {
  display: grid;
  gap: 8px;
  align-content: start;
}

.note h3 {
  font-size: 1.15rem;
}

.note p {
  font-size: 0.9rem;
  color: var(--muted);
}

/* ------------------------------------------------------------------- footer */

.foot {
  padding: var(--gutter) 0 48px;
  background: #1a1815;
  color: rgba(246, 243, 236, 0.62);
  font-size: 0.875rem;
}

.foot__top {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr;
  gap: 48px;
  padding-bottom: 48px;
  border-bottom: 1px solid rgba(246, 243, 236, 0.14);
}

.foot h2 {
  color: #f6f3ec;
  font-size: clamp(1.8rem, 3.4vw, 2.6rem);
  margin-bottom: 18px;
}

.foot h4 {
  margin: 0 0 14px;
  color: #f6f3ec;
  font-size: 0.6875rem;
  font-weight: 400;
  letter-spacing: 0.2em;
  text-transform: uppercase;
}

.foot ul {
  margin: 0;
  padding: 0;
  list-style: none;
  display: grid;
  gap: 9px;
}

.foot a {
  text-decoration: none;
}

.foot a:hover {
  color: #f6f3ec;
}

.foot__base {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  justify-content: space-between;
  padding-top: 26px;
  font-size: 0.78rem;
  color: rgba(246, 243, 236, 0.4);
}

/* Discreet demo label — host chrome, not engine chrome. */
.demo-banner {
  position: sticky;
  top: 0;
  z-index: 40;
  background: var(--ink);
  color: var(--paper);
  font-size: 0.8125rem;
  font-weight: 400;
}

.demo-banner__inner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem 1.25rem;
  padding-block: 0.55rem;
}

.demo-banner__cta {
  color: inherit;
  text-underline-offset: 0.15em;
}

/* ---------------------------------------------------------------- responsive */

@media (max-width: 900px) {
  :root {
    --shell: min(1240px, 100% - 36px);
  }

  .nav__links {
    display: none;
  }

  .spread,
  .foot__top {
    grid-template-columns: 1fr;
  }

  .spread--flip .spread__media {
    order: 0;
  }

  .shelf {
    margin-top: 0;
  }

  .hero {
    min-height: 74vh;
  }
}
