/* MASAÉ — shared styles for every page
   Tokens, header, phone/tablet menu, buttons, footer, small utilities.
   Page-specific styles (the homepage journey, the contact letter, the shop grid)
   stay inline in each page. */

:root {
  --ivory: #F4EBDD;
  --burgundy: #7D241E;
  --sage: #5D7059;
  --botanical: #304A3B;
  --gold: #A58A55;
  --ink: #2B2420;
  --muted: #6b5d52;
  --serif: "Cormorant Garamond", Georgia, serif;
  --sans: "Jost", "Helvetica Neue", Arial, sans-serif;
}
* { box-sizing: border-box; margin: 0; padding: 0; }
html { -webkit-text-size-adjust: 100%; }
body { background: var(--ivory); color: var(--ink); font-family: var(--sans); font-weight: 300; overflow-x: hidden; }
img { max-width: 100%; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
:focus-visible { outline: 1px solid var(--burgundy); outline-offset: 4px; }

/* ---------- Header ---------- */
.site-header {
  position: fixed; inset: 0 0 auto 0; z-index: 50;
  display: flex; align-items: center; justify-content: space-between;
  padding: calc(22px + env(safe-area-inset-top, 0px)) clamp(16px, 4vw, 48px) 22px;
  color: var(--ivory); font-size: 11px; letter-spacing: .22em; text-transform: uppercase;
  transition: color .6s ease, background-color .6s ease;
}
.site-header.is-solid { color: var(--burgundy); background: rgba(244,235,221,.92); backdrop-filter: blur(8px); }
.site-header .logo { position: relative; display: block; aspect-ratio: 903 / 198; height: 24px; opacity: 0; transition: opacity .6s ease; }
.site-header .logo img { position: absolute; inset: 0; width: 100%; height: 100%; transition: opacity .6s ease; }
.site-header .logo .on-light { opacity: 0; }
.site-header.is-solid .logo .on-light { opacity: 1; }
.site-header.is-solid .logo .on-dark { opacity: 0; }
.site-header.is-solid .logo, .site-header.show-logo .logo { opacity: 1; }
.site-header nav { display: flex; gap: 28px; }
.site-header nav a { color: inherit; text-decoration: none; transition: opacity .4s ease; }
.site-header nav a:hover, .site-header nav a[aria-current="page"] { opacity: .65; }
@media (max-width: 900px) { .site-header nav { display: none; } }

/* ---------- Phone & tablet menu ---------- */
.menu-btn { display: none; align-items: center; gap: 10px; border: 0; background: none; padding: 6px 0 6px 12px; color: inherit;
  font: inherit; font-size: 11px; letter-spacing: .28em; text-transform: uppercase; cursor: pointer; }
.menu-btn .bars { position: relative; width: 22px; height: 9px; }
.menu-btn .bars::before, .menu-btn .bars::after { content: ""; position: absolute; left: 0; right: 0; height: 1px; background: currentColor; transition: transform .5s ease, top .5s ease; }
.menu-btn .bars::before { top: 0; } .menu-btn .bars::after { top: 8px; }
.menu-open .menu-btn .bars::before { top: 4px; transform: rotate(45deg); }
.menu-open .menu-btn .bars::after { top: 4px; transform: rotate(-45deg); }
@media (max-width: 900px) { .menu-btn { display: inline-flex; } }
.mobile-menu { position: fixed; inset: 0; z-index: 45; background: var(--ivory); display: flex; flex-direction: column; justify-content: center; align-items: center;
  gap: 6px; padding: 96px 24px calc(40px + env(safe-area-inset-bottom, 0px)); opacity: 0; visibility: hidden; transition: opacity .5s ease, visibility 0s linear .5s; }
.menu-open .mobile-menu { opacity: 1; visibility: visible; transition: opacity .5s ease; }
.mobile-menu a { font-family: var(--serif); font-size: clamp(28px, 7vw, 40px); line-height: 1.5; color: var(--burgundy); text-decoration: none;
  opacity: 0; transform: translateY(10px); transition: opacity .6s ease, transform .6s ease; }
.menu-open .mobile-menu a { opacity: 1; transform: none; }
.menu-open .mobile-menu a:nth-child(2) { transition-delay: .05s; } .menu-open .mobile-menu a:nth-child(3) { transition-delay: .1s; }
.menu-open .mobile-menu a:nth-child(4) { transition-delay: .15s; } .menu-open .mobile-menu a:nth-child(5) { transition-delay: .2s; }
.mobile-menu .menu-emblem { width: 76px; height: auto; margin-bottom: 18px; }
.menu-open .site-header { color: var(--burgundy); background: transparent; backdrop-filter: none; }
.menu-open .site-header .logo { opacity: 1; }
.menu-open .site-header .logo .on-light { opacity: 1; }
.menu-open .site-header .logo .on-dark { opacity: 0; }
.menu-open, .menu-open body { overflow: hidden; }

/* ---------- Type & small pieces ---------- */
.kicker { font-size: 11px; letter-spacing: .4em; text-transform: uppercase; color: var(--sage); }
.ornament { display: block; width: 120px; height: 24px; color: var(--gold); }
.tba { display: inline-block; margin-left: 6px; padding: 1px 6px; border: 1px dashed var(--gold); font-size: 9px; letter-spacing: .12em; text-transform: uppercase; color: var(--muted); vertical-align: middle; }

.btn { display: inline-block; padding: 14px 30px; border: 1px solid var(--burgundy); background: transparent; color: var(--burgundy);
  font: inherit; font-size: 11px; letter-spacing: .3em; text-transform: uppercase; text-decoration: none; cursor: pointer;
  transition: background-color .5s ease, color .5s ease; }
.btn:hover { background: var(--burgundy); color: var(--ivory); }
.btn-solid { background: var(--burgundy); color: var(--ivory); }
.btn-solid:hover { background: var(--botanical); border-color: var(--botanical); }

/* Page opener used by the inner pages */
.page-head { position: relative; padding: clamp(140px, 22vh, 220px) clamp(16px, 6vw, 80px) clamp(48px, 8vh, 90px); text-align: center; }
.page-head h1 { margin-top: 18px; font-family: var(--serif); font-weight: 400; font-size: clamp(38px, 6vw, 82px); line-height: 1.05; color: var(--burgundy); }
.page-head p { margin: 20px auto 0; max-width: 560px; font-size: 16px; line-height: 1.8; color: var(--muted); }

/* ---------- Footer ---------- */
.site-footer { position: relative; background: var(--ivory); color: #5a4d44; }
.footer-border { display: block; width: 100%; height: 34px; color: var(--gold); }
.footer-inner { max-width: 1240px; margin: 0 auto; padding: clamp(56px, 9vh, 96px) clamp(16px, 5vw, 64px) 0;
  display: grid; grid-template-columns: 1.3fr 1fr 1fr 1fr 1.5fr; gap: clamp(28px, 4vw, 56px); }
.footer-brand .footer-logo { display: block; width: clamp(140px, 13vw, 180px); height: auto; }
.footer-brand .by { margin-top: 22px; font-size: 10px; letter-spacing: .3em; text-transform: uppercase; color: var(--sage); }
.footer-col h4, .footer-news h4 { font-family: var(--sans); font-weight: 400; font-size: 11px; letter-spacing: .3em; text-transform: uppercase; color: var(--burgundy); margin-bottom: 18px; }
.footer-col ul { list-style: none; }
.footer-col li { margin-bottom: 11px; }
.footer-col a, .footer-bottom a, .footer-contact a { color: #5a4d44; text-decoration: none; font-size: 14px;
  background: linear-gradient(currentColor, currentColor) 0 100% / 0 1px no-repeat; transition: background-size .5s ease, color .4s ease; }
.footer-col a:hover, .footer-bottom a:hover, .footer-contact a:hover { color: var(--burgundy); background-size: 100% 1px; }
.footer-news > p:not(.news-note) { font-family: var(--serif); font-size: 20px; line-height: 1.3; color: var(--ink); }
.news-form { display: flex; margin-top: 18px; border-bottom: 1px solid var(--gold); }
.news-form input { flex: 1; min-width: 0; padding: 12px 0; border: 0; background: transparent; font: inherit; font-size: 14px; color: var(--ink); outline: none; }
.news-form input::placeholder { color: #9a8b7d; }
.news-form button { border: 0; background: none; padding: 0 0 0 12px; font: inherit; font-size: 11px; letter-spacing: .28em; text-transform: uppercase; color: var(--burgundy); cursor: pointer; }
.footer-news .news-note { font-family: var(--sans); line-height: 1.5; margin-top: 10px; font-size: 12px; color: var(--muted); min-height: 1.2em; }
.footer-contact { margin-top: 28px; display: grid; gap: 8px; font-size: 14px; }
.footer-bottom { max-width: 1240px; margin: clamp(48px, 8vh, 80px) auto 0; padding: 22px clamp(16px, 5vw, 64px) 84px;   /* extra room so the sound button never covers the legal links */
  border-top: 1px solid rgba(165,138,85,.35); display: flex; flex-wrap: wrap; gap: 12px 28px; justify-content: space-between; align-items: center; font-size: 12px; color: var(--muted); }
.footer-bottom nav { display: flex; flex-wrap: wrap; gap: 8px 22px; }
.footer-bottom a { font-size: 12px; color: var(--muted); }
@media (max-width: 1000px) { .footer-inner { grid-template-columns: 1fr 1fr 1fr; } .footer-brand, .footer-news { grid-column: 1 / -1; } }
@media (max-width: 600px)  { .footer-inner { grid-template-columns: 1fr 1fr; } .footer-brand { text-align: center; } .footer-brand .footer-logo { margin: 0 auto; }
  .footer-col:nth-child(4) { grid-column: 1 / -1; } .footer-bottom { justify-content: center; text-align: center; } }

@media (prefers-reduced-motion: reduce) {
  * { animation-duration: .001ms !important; animation-iteration-count: 1 !important; }
}

/* ---------- Background music button ---------- */
.sound-btn { position: fixed; z-index: 40; right: calc(16px + env(safe-area-inset-right, 0px)); bottom: calc(18px + env(safe-area-inset-bottom, 0px));
  width: 44px; height: 44px; padding: 0; display: grid; place-items: center; cursor: pointer; border-radius: 50%;
  color: var(--burgundy); background: rgba(244,235,221,.82); border: 1px solid rgba(165,138,85,.6);
  -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px); box-shadow: 0 6px 20px rgba(40,22,12,.18);
  transition: background-color .4s ease, color .4s ease, transform .4s ease; }
.sound-btn:hover { background: var(--ivory); transform: translateY(-1px); }
.sound-btn svg { width: 22px; height: 22px; }
.sound-btn .slash { opacity: 0; transition: opacity .3s ease; }
.sound-btn.is-muted .slash { opacity: 1; }
.sound-btn.is-muted .waves { opacity: 0; }
.sound-btn.is-muted { color: #8a7a6c; }
.sound-tip { position: absolute; right: 54px; top: 50%; transform: translateY(-50%); padding: 6px 12px; white-space: nowrap;
  font-size: 10px; letter-spacing: .24em; text-transform: uppercase; color: var(--burgundy); background: rgba(244,235,221,.94);
  border: 1px solid rgba(165,138,85,.45); opacity: 0; pointer-events: none; transition: opacity .4s ease; }
.sound-btn:hover .sound-tip, .sound-btn:focus-visible .sound-tip { opacity: 1; }
@media (hover: none) { .sound-tip { display: none; } }
.menu-open .sound-btn { display: none; }

/* a soft ring while sound is wanted but waiting for the first click */
.sound-btn::after { content: ""; position: absolute; inset: -1px; border-radius: 50%; border: 1px solid rgba(165,138,85,.7); opacity: 0; pointer-events: none; }
.sound-btn.is-waiting::after { animation: soundRing 2.6s ease-out infinite; }
@keyframes soundRing { 0% { transform: scale(1); opacity: .75; } 100% { transform: scale(1.7); opacity: 0; } }
.sound-btn.show-tip .sound-tip { opacity: 1; }
@media (prefers-reduced-motion: reduce) { .sound-btn.is-waiting::after { animation: none; opacity: .5; } }

/* ---------- Legal pages: Privacy Policy, Terms of Service, Refund Policy ---------- */
.legal-head { position: relative; padding: clamp(130px, 20vh, 190px) clamp(16px, 6vw, 80px) clamp(28px, 5vh, 48px); text-align: center; }
.legal-head .emblem { display: block; width: clamp(64px, 7vw, 86px); height: auto; margin: 0 auto 22px; }
.legal-head h1 { font-family: var(--serif); font-weight: 400; font-size: clamp(36px, 5.2vw, 68px); line-height: 1.05; color: var(--burgundy); }
.legal-updated { margin-top: 14px; font-size: 11px; letter-spacing: .24em; text-transform: uppercase; color: var(--sage); }
.legal-intro { margin: 22px auto 0; max-width: 560px; font-size: 16px; line-height: 1.8; color: var(--muted); }
.legal { max-width: 760px; margin: 0 auto; padding: clamp(24px, 5vh, 48px) clamp(20px, 5vw, 40px) clamp(70px, 12vh, 130px); }
.legal h2 { margin: clamp(34px, 5vh, 52px) 0 12px; padding-top: 26px; border-top: 1px solid rgba(165,138,85,.35);
  font-family: var(--serif); font-weight: 500; font-size: clamp(24px, 2.6vw, 32px); line-height: 1.2; color: var(--burgundy); }
.legal h2:first-child { margin-top: 0; }
.legal p, .legal li { font-size: 16px; line-height: 1.85; color: var(--ink); }
.legal p { margin-bottom: 14px; }
.legal ul { margin: 4px 0 16px; padding-left: 1.2em; }
.legal li { margin-bottom: 8px; padding-left: 4px; }
.legal li::marker { color: var(--gold); }
.legal strong { font-weight: 400; color: var(--burgundy); }
.legal a { color: var(--burgundy); text-decoration: underline; text-decoration-color: rgba(165,138,85,.7); text-underline-offset: 3px; }
.legal a:hover { text-decoration-color: var(--burgundy); }
.legal address { font-style: normal; font-size: 15px; line-height: 1.8; color: var(--muted); }
.legal-callout { margin: 0 0 8px; padding: 22px 26px; border: 1px solid rgba(165,138,85,.5); background: rgba(251,245,234,.7);
  font-family: var(--serif); font-size: clamp(20px, 2.2vw, 25px); line-height: 1.55; color: var(--ink); }
.legal-callout strong { font-weight: 500; }
