/* ==========================================================================
   The Epeys' Guest Inn — Core Stylesheet
   ========================================================================== */

/* --- Fonts ---------------------------------------------------------------
   TEMPORARY: loaded via Google Fonts CDN for now.
   TODO before launch: self-host as /assets/fonts/*.woff2 and replace this
   @import with @font-face rules (see README-fonts.txt for exact steps).
----------------------------------------------------------------------------*/
@import url('https://fonts.googleapis.com/css2?family=Fraunces:opsz,wght@9..144,400;9..144,500;9..144,600&family=Work+Sans:wght@400;500;600;700&display=swap');

/* --- Design tokens -------------------------------------------------------*/
:root {
  /* Colors — anchored to the logo (deep umber + brass gold) */
  --color-umber:        #211712;  /* nav, footer, dark anchors */
  --color-umber-soft:   #2E241C;  /* body text — warmer than pure black */
  --color-gold:         #C9982F;  /* fills only: buttons, borders, icons */
  --color-gold-dark:    #8A6A1E;  /* text-safe gold — links, labels on light bg */
  --color-gold-bright:  #D8B65C;  /* text-safe gold on DARK backgrounds only */
  --color-ivory:        #F7F1E4;  /* dominant background */
  --color-white:        #FFFFFF;  /* card surfaces */
  --color-border:       #E4D9C2;  /* hairline borders on light surfaces */
  --color-text-muted:   #5A4E3F;  /* secondary body text */
  --color-text-faint:   #9C8A6B;  /* footer text, least emphasis */

  /* Type */
  --font-display: 'Fraunces', Georgia, serif;
  --font-body: 'Work Sans', -apple-system, 'Segoe UI', Roboto, sans-serif;

  /* Spacing scale */
  --space-xs: 0.5rem;
  --space-sm: 1rem;
  --space-md: 1.5rem;
  --space-lg: 2.5rem;
  --space-xl: 4rem;
  --space-2xl: 6rem;

  /* Radius */
  --radius-sm: 6px;
  --radius-md: 10px;
  --radius-lg: 16px;

  /* Layout */
  --max-width: 1140px;

  /* Shadows — used sparingly, only on hover/elevation states */
  --shadow-sm: 0 2px 8px rgba(33,23,18,0.06);
  --shadow-md: 0 12px 32px rgba(33,23,18,0.12);
  --shadow-gold: 0 10px 28px rgba(201,152,47,0.28);

  /* Motion */
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
}

/* --- Reset -----------------------------------------------------------------*/
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--color-ivory);
  color: var(--color-umber-soft);
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; height: auto; display: block; }
a { color: inherit; text-decoration: none; }
ul { list-style: none; margin: 0; padding: 0; }
button { font-family: inherit; cursor: pointer; }

/* Visible focus states for keyboard navigation (accessibility) */
a:focus-visible, button:focus-visible, input:focus-visible, textarea:focus-visible {
  outline: 2px solid var(--color-gold-dark);
  outline-offset: 2px;
}

/* --- Typography ------------------------------------------------------------*/
h1, h2, h3 {
  font-family: var(--font-display);
  font-weight: 500;
  line-height: 1.2;
  margin: 0 0 var(--space-sm);
  color: var(--color-umber-soft);
}
h1 { font-size: clamp(1.9rem, 4vw, 2.6rem); }
h2 { font-size: clamp(1.5rem, 3vw, 1.9rem); }
h3 { font-size: 1.2rem; }

p { margin: 0 0 var(--space-sm); color: var(--color-text-muted); }

.eyebrow {
  display: block;
  font-family: var(--font-body);
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--color-gold-dark);
  margin-bottom: var(--space-xs);
}

/* --- Layout helpers ----------------------------------------------------- */
.container {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 var(--space-md);
}
.section { padding: var(--space-xl) 0; }
.section--tight { padding: var(--space-lg) 0; }
.text-center { text-align: center; }

/* --- Buttons ------------------------------------------------------------ */
.btn {
  display: inline-block;
  font-size: 0.9rem;
  font-weight: 500;
  padding: 0.8rem 1.6rem;
  border-radius: var(--radius-sm);
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}
.btn-primary {
  background: var(--color-gold);
  color: var(--color-umber);
}
.btn-primary:hover { box-shadow: 0 4px 14px rgba(201,152,47,0.35); }
.btn-outline {
  background: transparent;
  border: 1.5px solid var(--color-gold);
  color: var(--color-gold-dark);
}
.btn-outline:hover { background: rgba(201,152,47,0.08); }
.btn-dark {
  background: var(--color-umber);
  color: var(--color-gold-bright);
}

/* --- Header / Nav --------------------------------------------------------*/
.site-header {
  background: var(--color-umber);
  position: sticky;
  top: 0;
  z-index: 100;
}
.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1.1rem 0;
  gap: var(--space-md);
}
.nav__brand {
  display: flex;
  align-items: center;
  gap: 0.7rem;
  color: var(--color-gold-bright);
  font-family: var(--font-display);
  font-size: 1.1rem;
  font-weight: 500;
  white-space: nowrap;
}
.nav__brand img { height: 50px; width: auto; display: block; }
.nav__links {
  display: flex;
  align-items: center;
  gap: var(--space-md);
  font-size: 0.9rem;
}
.nav__links a { color: var(--color-ivory); }
.nav__links a:hover, .nav__links a[aria-current="page"] { color: var(--color-gold-bright); }
.nav__toggle {
  display: none;
  background: none;
  border: none;
  color: var(--color-ivory);
  font-size: 2rem;
  line-height: 1;
  padding: 0.3rem 0.4rem;
  margin: -0.3rem -0.4rem;
}

@media (max-width: 780px) {
  .nav__links {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: var(--color-umber);
    flex-direction: column;
    align-items: flex-start;
    padding: var(--space-sm) var(--space-md) var(--space-md);
    gap: var(--space-sm);
  }
  .nav__links.is-open { display: flex; }
  .nav__toggle { display: block; }
}

/* --- Footer --------------------------------------------------------------*/
.site-footer {
  background: var(--color-umber);
  color: var(--color-text-faint);
  padding: var(--space-xl) 0 var(--space-md);
}
.site-footer a { color: var(--color-ivory); }
.site-footer a:hover { color: var(--color-gold-bright); }
.footer__grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: var(--space-lg);
  padding-bottom: var(--space-lg);
  border-bottom: 1px solid rgba(255,255,255,0.1);
}
.footer__heading {
  color: var(--color-gold-bright);
  font-family: var(--font-body);
  font-size: 0.8rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  margin-bottom: var(--space-sm);
}
.footer__grid li { margin-bottom: 0.6rem; font-size: 0.9rem; }
.footer__bottom {
  padding-top: var(--space-md);
  font-size: 0.8rem;
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: var(--space-xs);
}

/* --- Cards ---------------------------------------------------------------*/
.card {
  background: var(--color-white);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  overflow: hidden;
}
.card__body { padding: var(--space-md); }
.card__image { aspect-ratio: 4/3; object-fit: cover; width: 100%; background: var(--color-border); }

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

/* ==========================================================================
   Polish layer — motion, hover states, signature details
   ========================================================================== */

/* --- Buttons, refined --------------------------------------------------- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  box-shadow: var(--shadow-sm);
  transition: transform 0.2s var(--ease), box-shadow 0.2s var(--ease);
}
.btn svg { width: 18px; height: 18px; flex-shrink: 0; }
.btn-primary:hover { transform: translateY(-2px); box-shadow: var(--shadow-gold); }
.btn-outline:hover { transform: translateY(-2px); box-shadow: var(--shadow-sm); }
.btn:active { transform: translateY(0); }

/* --- Cards, refined: lift + image zoom on hover -------------------------- */
.card {
  transition: transform 0.35s var(--ease), box-shadow 0.35s var(--ease);
}
.card:hover { transform: translateY(-6px); box-shadow: var(--shadow-md); }
.card__image-wrap { overflow: hidden; }
.card__image-wrap .card__image { transition: transform 0.5s var(--ease); }
.card:hover .card__image-wrap .card__image { transform: scale(1.06); }

/* --- Icon system -----------------------------------------------------------
   Icons are .webp images, not inline SVG — supplied by the site owner in
   /assets/img/icons/. See README-icons.txt for the exact filenames expected.
----------------------------------------------------------------------------*/
.icon {
  width: 22px;
  height: 22px;
  object-fit: contain;
  display: inline-block;
  vertical-align: middle;
}
.icon-circle {
  width: 52px;
  height: 52px;
  border-radius: 50%;
  background: rgba(201,152,47,0.12);
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto var(--space-sm);
}
.icon-circle .icon { width: 26px; height: 26px; }

/* --- Signature divider ----------------------------------------------------
   A recurring brand mark: thin gold rule with a small diamond at center,
   echoing the linework in the logo. Used between major sections instead
   of a hard border or color block.
----------------------------------------------------------------------------*/
.divider--signature {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.75rem;
  margin: 0 auto;
  width: 100%;
  max-width: 220px;
}
.divider--signature::before,
.divider--signature::after {
  content: '';
  flex: 1;
  height: 1px;
  background: var(--color-border);
}
.divider--signature .diamond {
  width: 7px;
  height: 7px;
  background: var(--color-gold);
  transform: rotate(45deg);
  flex-shrink: 0;
}

/* --- Hero frame: subtle offset gold border, echoes the logo's linework --- */
.hero-frame {
  position: relative;
}
.hero-frame::after {
  content: '';
  position: absolute;
  top: 16px; left: 16px; right: -16px; bottom: -16px;
  border: 1.5px solid var(--color-gold);
  border-radius: var(--radius-lg);
  z-index: -1;
}

/* --- Floating stat badge, overlaps the hero image corner ----------------- */
.badge-float {
  position: absolute;
  bottom: -22px;
  left: -20px;
  background: var(--color-white);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-md);
  padding: 1rem 1.4rem;
  display: flex;
  align-items: center;
  gap: 0.85rem;
  max-width: calc(100% - 24px);
}
.badge-float__number {
  font-family: var(--font-display);
  font-size: 1.6rem;
  color: var(--color-gold-dark);
  line-height: 1;
  flex-shrink: 0;
}
.badge-float__label {
  font-size: 0.78rem;
  color: var(--color-text-muted);
  line-height: 1.35;
  max-width: 12ch;
}
@media (max-width: 600px) {
  .badge-float { left: 12px; bottom: -18px; padding: 0.8rem 1.1rem; }
}


/* --- Scroll reveal (motion-safe) ------------------------------------------*/
.reveal {
  opacity: 0;
  transform: translateY(18px);
  transition: opacity 0.7s var(--ease), transform 0.7s var(--ease);
}
.reveal.is-visible {
  opacity: 1;
  transform: translateY(0);
}
@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1; transform: none; transition: none; }
  .card:hover, .btn-primary:hover, .btn-outline:hover { transform: none; }
}

/* --- Alternating section tone (subtle, not a color block) ---------------- */
.section--alt { background: var(--color-white); }

/* --- Hero: responsive by default, no inline styles ------------------------*/
.hero {
  display: grid;
  grid-template-columns: 1.1fr 1fr;
  gap: var(--space-2xl);
  align-items: center;
}
.hero__media {
  position: relative;
  margin-right: 16px;
  margin-bottom: 20px;
}
.hero__media .hero__media-inner {
  aspect-ratio: 4/3;
  overflow: hidden;
  border-radius: var(--radius-lg);
  position: relative;
}
.hero__media img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.hero__actions {
  display: flex;
  gap: var(--space-sm);
  flex-wrap: wrap;
  margin-top: var(--space-md);
}
@media (max-width: 860px) {
  .hero { grid-template-columns: 1fr; gap: var(--space-lg); }
  .hero__media { order: -1; margin-right: 0; }
  .hero-frame::after { top: 10px; left: 10px; right: -10px; bottom: -10px; }
}

/* --- Simple two-up feature row (About teaser, Locations comparison) ------ */
.split {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--space-xl);
  align-items: center;
}
.split img { border-radius: var(--radius-lg); aspect-ratio: 4/3; object-fit: cover; width: 100%; }
@media (max-width: 780px) {
  .split { grid-template-columns: 1fr; gap: var(--space-md); }
}
.split--reverse .split__media { order: 2; }
@media (max-width: 780px) {
  .split--reverse .split__media { order: -1; }
}

/* --- Small compact card row (Guides teaser) ------------------------------ */
.mini-card {
  display: block;
  padding: var(--space-md);
  background: var(--color-white);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  transition: transform 0.25s var(--ease), box-shadow 0.25s var(--ease);
}
.mini-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-sm); }
.mini-card__label { color: var(--color-gold-dark); font-size: 0.8rem; font-weight: 600; }


/* --- Skip link (accessibility) -------------------------------------------*/
.skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
  background: var(--color-gold);
  color: var(--color-umber);
  padding: 0.75rem 1.25rem;
  z-index: 200;
  border-radius: 0 0 var(--radius-sm) 0;
}
.skip-link:focus { left: 0; }