/* ============================================================
   SET — Interior Design Studio
   Palette + type derived from the brand boards:
   warm cream, charcoal, italic serif wordmark, tracked sans labels
   ============================================================ */

:root {
  /* Brand palette */
  --canvas: #efe9e5;   /* CANVAS  */
  --sand: #d7d0ca;     /* SAND    */
  --graphite: #302d2e; /* GRAPHITE */

  /* Derived roles */
  --cream: var(--canvas);
  --cream-light: var(--canvas);
  --paper: #f7f4f2;
  --charcoal: var(--graphite);
  --charcoal-deep: #262425;
  --ink: var(--graphite);
  --ink-soft: #7c7471;
  --line: var(--sand);
  --line-dark: #4a4647;

  /* On-dark text tones */
  --on-dark-soft: #a8a09b;
  --on-dark: #ded7d2;

  /* Type */
  --serif: "Cormorant Garamond", "Georgia", serif;
  --sans: "Jost", -apple-system, "Helvetica Neue", Arial, sans-serif;

  /* Metrics */
  --max: 1180px;
  --pad: 48px;
}

* { box-sizing: border-box; }

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--cream-light);
  color: var(--ink);
  font-family: var(--sans);
  font-weight: 300;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

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

a { color: inherit; text-decoration: none; }

/* Small tracked label — the "INTERIOR DESIGN STUDIO" treatment */
.label {
  font-family: var(--sans);
  font-weight: 300;
  font-size: 0.62rem;
  letter-spacing: 0.34em;
  text-transform: uppercase;
  color: var(--ink-soft);
  margin: 0;
}

/* Italic serif wordmark — the "set" logotype */
.wordmark {
  font-family: var(--serif);
  font-style: italic;
  font-weight: 300;
  letter-spacing: 0.28em;
  text-transform: lowercase;
}

/* ---------------- Header ---------------- */
.site-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 50;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 22px var(--pad);
  color: var(--cream);
  background: transparent;
  border-bottom: 1px solid transparent;
  transition: background 0.5s ease, color 0.5s ease,
              padding 0.5s ease, border-color 0.5s ease;
}

/* Past the hero: cream bar, dark type */
.site-header.is-scrolled {
  background: rgba(239, 233, 229, 0.92);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  color: var(--ink);
  border-bottom-color: var(--line);
  padding-top: 16px;
  padding-bottom: 16px;
}

.site-header .wordmark {
  font-size: 1.5rem;
  color: inherit;
}

.nav {
  display: flex;
  gap: 34px;
}

.nav a {
  font-size: 0.62rem;
  font-weight: 300;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: inherit;
  opacity: 0.75;
  padding-bottom: 3px;
  border-bottom: 1px solid transparent;
  transition: opacity 0.35s ease, border-color 0.35s ease;
}

.nav a:hover {
  opacity: 1;
  border-bottom-color: currentColor;
}

/* ---------------- Hero ---------------- */
.hero {
  position: relative;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--charcoal);
  color: var(--cream);
  text-align: center;
  padding: 0 24px;
}

.hero-mark {
  font-family: var(--serif);
  font-style: italic;
  font-weight: 300;
  text-transform: lowercase;
  font-size: clamp(4.5rem, 17vw, 12rem);
  line-height: 1;
  letter-spacing: 0.22em;
  /* optical centring: the tracking adds space after the last letter */
  text-indent: 0.22em;
  margin: 0 0 30px;
  color: var(--cream);
}

.hero-label {
  color: var(--on-dark-soft);
  font-size: 0.68rem;
  letter-spacing: 0.42em;
}

.hero-rule {
  position: absolute;
  bottom: 52px;
  left: 50%;
  width: 1px;
  height: 60px;
  background: linear-gradient(to bottom, transparent, #6b6462);
}

/* ---------------- Sections ---------------- */
.section {
  padding: 130px var(--pad);
}

.section--light {
  background: var(--cream-light);
  color: var(--ink);
}

.section--sand {
  background: var(--sand);
  color: var(--ink);
}

.section--sand .label { color: #6d6663; }

.section--dark {
  background: var(--charcoal);
  color: var(--cream);
}

.section--dark .label { color: var(--on-dark-soft); }

.section-label {
  text-align: center;
  margin-bottom: 18px;
}

.section-title {
  font-family: var(--serif);
  font-weight: 300;
  font-size: clamp(2rem, 4vw, 2.9rem);
  letter-spacing: 0.06em;
  text-align: center;
  margin: 0 0 18px;
}

.section-intro {
  max-width: 480px;
  margin: 0 auto 70px;
  text-align: center;
  font-size: 0.9rem;
  color: var(--on-dark-soft);
}

/* ---------------- Studio ---------------- */
.studio {
  max-width: 820px;
  margin: 0 auto;
  text-align: center;
  padding-bottom: 90px;
}

.statement {
  font-family: var(--serif);
  font-weight: 300;
  font-size: clamp(1.6rem, 3.4vw, 2.5rem);
  line-height: 1.35;
  letter-spacing: 0.02em;
  margin: 0 0 34px;
}

.statement em {
  font-style: italic;
}

.studio-body {
  max-width: 540px;
  margin: 0 auto;
  font-size: 0.92rem;
  color: var(--ink-soft);
}

/* ---------------- Portfolio plates ---------------- */
.portfolio { padding-top: 40px; }

.plate-grid {
  max-width: 1060px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 54px 40px;
}

/* Photo card — bordered plate with caption beneath */
.plate {
  margin: 0;
  background: var(--paper);
  padding: 14px 14px 0;
  box-shadow: 0 1px 2px rgba(48, 45, 46, 0.06), 0 10px 30px rgba(48, 45, 46, 0.05);
  transition: transform 0.5s cubic-bezier(0.2, 0.7, 0.3, 1),
              box-shadow 0.5s ease;
}

.plate:hover {
  transform: translateY(-5px);
  box-shadow: 0 2px 4px rgba(48, 45, 46, 0.08), 0 18px 44px rgba(48, 45, 46, 0.10);
}

.plate-img {
  position: relative;
  overflow: hidden;
  background: var(--sand);
  aspect-ratio: 3 / 4;
  cursor: ew-resize;
  /* let vertical scrolling through the plate still work on touch */
  touch-action: pan-y;
}

/* Stacked frames — only the active one is shown */
.plate-img .frame {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0;
  /* No cross-fade: during a scrub two semi-transparent frames would
     let the backdrop show through and read as a washed-out blend. */
}

.plate-img .frame.is-active { opacity: 1; }

/* Scrub position indicator */
.ticks {
  position: absolute;
  left: 14px;
  right: 14px;
  bottom: 14px;
  display: flex;
  gap: 3px;
  opacity: 0;
  transition: opacity 0.3s ease;
  pointer-events: none;
}

.plate:hover .ticks,
.plate:focus-visible .ticks { opacity: 1; }

.tick {
  flex: 1;
  height: 2px;
  background: rgba(239, 233, 229, 0.35);
  transition: background 0.15s ease;
}

.tick.is-on { background: rgba(239, 233, 229, 0.95); }

.plate:focus-visible {
  outline: 1px solid var(--graphite);
  outline-offset: 4px;
}

.portfolio-hint {
  text-align: center;
  margin: 0 0 54px;
  font-size: 0.56rem;
  letter-spacing: 0.28em;
  color: var(--ink-soft);
}

.plate figcaption {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 7px;
  padding: 20px 8px 24px;
}

.plate-name {
  font-family: var(--serif);
  font-style: italic;
  font-weight: 400;
  font-size: 1.32rem;
  letter-spacing: 0.03em;
}

.plate-meta {
  font-size: 0.56rem;
  letter-spacing: 0.3em;
}

/* ---------------- Services ---------------- */
.services .section-title {
  max-width: 620px;
  margin-left: auto;
  margin-right: auto;
}

.service-grid {
  max-width: 1060px;
  margin: 58px auto 0;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  background: var(--paper);
  border: 1px solid rgba(48, 45, 46, 0.09);
}

.service {
  padding: 46px 38px 42px;
  border-right: 1px solid rgba(48, 45, 46, 0.09);
}

.service:last-child { border-right: 0; }

.service-scope {
  font-size: 0.56rem;
  letter-spacing: 0.3em;
  margin-bottom: 22px;
}

.service-name {
  font-family: var(--serif);
  font-style: italic;
  font-weight: 400;
  font-size: 1.55rem;
  letter-spacing: 0.03em;
  margin: 0 0 16px;
}

.service-body {
  font-size: 0.88rem;
  line-height: 1.75;
  color: var(--ink-soft);
  margin: 0 0 30px;
}

.service-meta {
  margin: 0;
  padding-top: 20px;
  border-top: 1px dashed rgba(48, 45, 46, 0.18);
  font-size: 0.74rem;
  letter-spacing: 0.06em;
  color: var(--ink-soft);
}

/* ---------------- Store ---------------- */
.store-soon {
  max-width: 560px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  gap: 28px;
}

.store-soon__rule {
  flex: 1;
  height: 1px;
  background: var(--line-dark);
}

.store-soon__title {
  font-family: var(--serif);
  font-style: italic;
  font-weight: 400;
  font-size: 2rem;
  letter-spacing: 0.04em;
  margin: 0;
  white-space: nowrap;
}

@media (max-width: 600px) {
  .store-soon { gap: 18px; }
  .store-soon__title { font-size: 1.5rem; }
}

.store-note {
  text-align: center;
  margin: 70px 0 0;
  font-size: 0.78rem;
  letter-spacing: 0.06em;
  color: var(--on-dark-soft);
}

/* ---------------- Contact card ---------------- */
.contact {
  display: flex;
  justify-content: center;
}

.card {
  background: var(--charcoal);
  color: var(--cream);
  width: min(430px, 100%);
  aspect-ratio: 1.62 / 1;
  padding: 44px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.card-name {
  font-family: var(--serif);
  font-weight: 300;
  font-size: 2.1rem;
  line-height: 1.1;
  margin: 0;
}

.card-name em {
  font-style: italic;
  display: block;
}

.card-name span {
  font-family: var(--sans);
  font-weight: 200;
  font-size: 1.7rem;
  letter-spacing: 0.04em;
  display: block;
}

.card-role {
  margin-top: -14px;
}

.card-lines {
  display: flex;
  flex-direction: column;
  gap: 6px;
  font-size: 0.72rem;
  letter-spacing: 0.14em;
  color: var(--on-dark);
}

.card-lines a {
  width: fit-content;
  border-bottom: 1px solid transparent;
  transition: border-color 0.35s ease;
}

.card-lines a:hover { border-bottom-color: currentColor; }

/* ---------------- Footer ---------------- */
.site-footer {
  background: var(--charcoal-deep);
  color: var(--on-dark-soft);
  text-align: center;
  padding: 60px var(--pad);
}

.footer-mark {
  display: block;
  font-size: 1.35rem;
  color: var(--cream);
  margin-bottom: 16px;
}

.site-footer .label { font-size: 0.56rem; }

/* ---------------- Reveal on scroll ---------------- */
.plate,
.store-soon {
  opacity: 0;
  transform: translateY(18px);
  transition: opacity 0.9s ease, transform 0.9s cubic-bezier(0.2, 0.7, 0.3, 1),
              box-shadow 0.5s ease;
}

.plate.is-visible,
.store-soon.is-visible {
  opacity: 1;
  transform: none;
}

/* Hover lift must not fight the reveal transform */
.plate.is-visible:hover { transform: translateY(-5px); }

@media (prefers-reduced-motion: reduce) {
  .plate,
  .store-soon {
    opacity: 1;
    transform: none;
    transition: none;
  }
  html { scroll-behavior: auto; }
}

/* ---------------- Responsive ---------------- */
@media (max-width: 760px) {
  :root { --pad: 24px; }

  .site-header { padding: 18px var(--pad); }
  .nav { gap: 18px; }
  .nav a { font-size: 0.55rem; letter-spacing: 0.2em; }
  .site-header .wordmark { font-size: 1.25rem; }

  .section { padding: 90px var(--pad); }
  .plate-grid { grid-template-columns: 1fr; gap: 40px; }
  .plate-img { cursor: default; }

  .service-grid { grid-template-columns: 1fr; }
  .service {
    border-right: 0;
    border-bottom: 1px solid rgba(48, 45, 46, 0.09);
  }
  .service:last-child { border-bottom: 0; }
  .card { padding: 32px; aspect-ratio: auto; gap: 34px; }
}

@media (max-width: 420px) {
  .nav a:not(:last-child) { display: none; }
}
