:root {
  --bg: #fbf8ec;
  --ink: #142f53;
  --muted: #495b70;
  --surface: #fffdf6;
  --line: #d3ceba;
  --accent: #183d71;
  --on-accent: #fffaf0;
  --body-font: "DM Sans", system-ui, sans-serif;
  --display-font: "Cormorant Garamond", Georgia, serif;
  --butter: #f8efc6;
  --wash: #e2edf1;
  --deep: #152e4e;
  --gutter: max(clamp(1.25rem, 5vw, 5rem), calc((100vw - 92rem) / 2));
}

.tide-home {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font: 1rem/1.55 var(--body-font);
}

.tide-home *, .tide-home *::before, .tide-home *::after { box-sizing: border-box; }
.tide-home :where(h1, h2, h3, p, figure) { margin: 0; }
.tide-home :where(a, button) { color: inherit; }
.tide-home :where(button) { font: inherit; cursor: pointer; }
.tide-home :where(a, button):focus-visible { outline: 2px solid currentColor; outline-offset: 4px; }
.tide-home :where(img) { display: block; max-width: 100%; }
.tide-home :where(#main, #collection, #about) { scroll-margin-top: 5rem; }

.tide-home .skip-link {
  position: fixed;
  top: 0.75rem;
  left: 0.75rem;
  z-index: 30;
  padding: 0.7rem 1.1rem;
  transform: translateY(-160%);
  background: var(--deep);
  color: var(--on-accent);
}

.tide-home .skip-link:focus { transform: none; }

.tide-announcement {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.6rem;
  padding-inline: 0.9rem;
  background: var(--deep);
  color: var(--on-accent);
  font-size: 0.875rem;
  line-height: 1.25;
  text-align: center;
}

.tide-announcement a {
  display: inline-flex;
  min-height: 2.75rem;
  align-items: center;
  text-decoration: none;
}

.tide-announcement a:hover { text-decoration: underline; text-underline-offset: 0.2em; }

.tide-header {
  position: sticky;
  top: 0;
  z-index: 10;
  background: var(--bg);
  border-bottom: 1px solid var(--line);
}

.tide-header-inner {
  min-height: 4.6rem;
  padding-inline: var(--gutter);
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 1rem;
}

.tide-nav {
  display: flex;
  align-items: center;
  gap: clamp(1rem, 2vw, 2rem);
  font-size: 0.9rem;
  font-weight: 600;
}

.tide-nav a,
.tide-footer nav a {
  display: flex;
  align-items: center;
  min-height: 2.75rem;
  text-decoration: none;
}

.tide-nav a:hover, .tide-footer nav a:hover { text-decoration: underline; text-underline-offset: 0.25em; }

.tide-wordmark {
  display: inline-block;
  font: 600 clamp(1.75rem, 3.3vw, 3.2rem)/1 var(--display-font);
  letter-spacing: -0.075em;
  text-decoration: none;
  white-space: nowrap;
}

.tide-bag {
  display: inline-flex;
  justify-self: end;
  align-items: center;
  gap: 0.5rem;
  min-height: 2.75rem;
  padding: 0;
  background: transparent;
  border: 0;
  font-size: 0.9rem;
  font-weight: 600;
}

.tide-bag-icon {
  position: relative;
  width: 0.85rem;
  height: 0.8rem;
  margin-top: 0.175rem;
  border: 1px solid currentColor;
  border-radius: 0 0 0.13rem 0.13rem;
}

.tide-bag-icon::before {
  content: "";
  position: absolute;
  width: 0.42rem;
  height: 0.33rem;
  left: 50%;
  bottom: 100%;
  transform: translateX(-50%);
  border: 1px solid currentColor;
  border-bottom: 0;
  border-radius: 0.4rem 0.4rem 0 0;
}

.tide-bag-count {
  min-width: 1.4rem;
  padding: 0.06rem 0.26rem;
  border-radius: 2rem;
  background: var(--wash);
  text-align: center;
  font-variant-numeric: tabular-nums;
}

.tide-hero {
  --hero-space: clamp(2.6rem, 4.5vw, 5rem);
  display: grid;
  grid-template-columns: 1fr minmax(0, 1.02fr);
  align-items: center;
  gap: clamp(1.4rem, 4vw, 5rem);
  overflow: clip;
  padding: var(--hero-space) var(--gutter);
  background:
    radial-gradient(ellipse at 82% 84%, #cbdfe5, transparent 41%),
    radial-gradient(ellipse at 16% 12%, #fcf7df 0%, transparent 56%),
    var(--butter);
}

.tide-hero-copy { position: relative; padding-block: 1rem 0.4rem; }

.tide-kicker {
  margin-block-end: 1rem;
  font-size: 0.875rem;
  font-weight: 700;
  letter-spacing: 0.13em;
  line-height: 1.35;
  text-transform: uppercase;
}

.tide-hero h1 {
  margin-inline-start: -0.04em;
  font: 500 clamp(4.8rem, 9.4vw, 9.2rem)/0.81 var(--display-font);
  letter-spacing: -0.075em;
}

.tide-home :is(h1, h2) em { font-weight: 500; }

.tide-intro {
  max-width: 26ch;
  margin-block: 1.7rem 1.9rem;
  color: var(--muted);
  font-size: clamp(1rem, 1.35vw, 1.23rem);
}

.tide-cta {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 3.1rem;
  padding: 0.65rem 1.5rem;
  border: 1px solid var(--deep);
  border-radius: 99rem;
  background: var(--deep);
  color: var(--on-accent);
  font-weight: 600;
  text-decoration: none;
  transition: color 180ms, background 180ms;
}

.tide-cta:hover { background: transparent; color: var(--deep); }

.tide-hero-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.45rem 1.55rem;
}

.tide-hero-visual {
  --window: 48% 48% 3px 3px / 37% 37% 3px 3px;
  position: relative;
  width: 100%;
  max-width: 35rem;
  margin-inline: auto;
  padding: 0 1.1rem 1.45rem 0;
  perspective: 1050px;
}

.tide-hero-depth {
  position: relative;
  transform-style: preserve-3d;
}

.tide-hero-frame {
  position: absolute;
  inset: 0.9rem -0.9rem -0.9rem 0.9rem;
  border: 1px solid #728c9b;
  border-radius: var(--window);
  background: #e9f1eb75;
  box-shadow: 0 2rem 3.75rem -2.6rem #1c3f566f;
}

.tide-hero-window {
  position: relative;
  aspect-ratio: 0.99;
  overflow: hidden;
  border-radius: var(--window);
  background: var(--wash);
  box-shadow: 0 14px 40px -26px #193e5a;
}

.tide-horizon {
  position: absolute;
  right: -0.8rem;
  bottom: 3rem;
  width: clamp(3.8rem, 9vw, 7rem);
  aspect-ratio: 1;
  border: 1px solid #f8f2dca8;
  border-radius: 50%;
  background:
    radial-gradient(ellipse at 28% 24%, #fff6d294, transparent 51%),
    repeating-radial-gradient(ellipse at 57% 57%, #aecbd81c 0 3px, #5f81934f 4px 5px, #b7ceda4d 6px 9px),
    linear-gradient(147deg, #d8e9e9ac, #a1c6d4bd 56%, #54839dae);
  box-shadow: inset -0.35rem -0.45rem 0.8rem #32596b48, inset 0.35rem 0.3rem 0.8rem #fffbe69c, 0 0.75rem 1.5rem #142f532c;
  pointer-events: none;
}

.tide-feature-link {
  position: absolute;
  left: clamp(0.45rem, 2.75vw, 2rem);
  bottom: -1.45rem;
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: 0.65rem;
  width: min(16rem, 80%);
  min-height: 4.4rem;
  padding: 0.45rem 0.65rem 0.45rem 0.45rem;
  border: 1px solid #e0dccd;
  border-radius: 0.4rem;
  background: var(--surface);
  box-shadow: 0 0.6rem 1.6rem #142f5329;
  text-decoration: none;
  transition: box-shadow 200ms ease;
}

.tide-feature-link:hover { box-shadow: 0 0.8rem 2rem #142f5340; }
.tide-feature-link img { width: 3.4rem; height: 3.4rem; object-fit: cover; border-radius: 0.2rem; }
.tide-feature-link > span:nth-child(2) { display: grid; gap: 0.14rem; }
.tide-feature-link > span:nth-child(2) > span { color: var(--muted); font-size: 0.875rem; line-height: 1.2; }
.tide-feature-link strong { font: 600 1.35rem/1 var(--display-font); }
.tide-feature-plus {
  display: grid;
  place-items: center;
  width: 1.7rem;
  aspect-ratio: 1;
  border: 1px solid var(--line);
  border-radius: 50%;
  line-height: 1;
  transition: background 200ms ease, color 200ms ease;
}

.tide-feature-link:hover .tide-feature-plus { background: var(--accent); color: var(--on-accent); }

@media (prefers-reduced-motion: no-preference) and (hover: hover) and (pointer: fine) {
  .tide-hero-depth {
    transform: rotateX(var(--tide-pitch, 0deg)) rotateY(var(--tide-yaw, 0deg));
    transition: transform 220ms cubic-bezier(.2,.7,.3,1);
  }

  .tide-hero-frame { transform: translateZ(-22px); }
  .tide-hero-window { transform: translateZ(12px); }
  .tide-horizon { transform: translateZ(37px); }
  .tide-feature-link { transform: translateZ(40px); }
}

.tide-hero-window img, .tide-editorial-photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.tide-hero-window img { object-position: 50% 0%; }

.tide-collection {
  padding: clamp(3.15rem, 7vw, 7rem) var(--gutter);
}

.tide-collection-head {
  display: flex;
  flex-wrap: wrap;
  align-items: end;
  justify-content: space-between;
  gap: 1rem 2rem;
  margin-block-end: 0.75rem;
  border-bottom: 1px solid var(--line);
}

.tide-collection-head h2, .tide-editorial h2 {
  font: 500 clamp(3.2rem, 6vw, 6rem)/0.91 var(--display-font);
  letter-spacing: -0.066em;
}

.tide-collection-head h2 { padding-block-end: 0.45rem; }
.tide-collection-head p { padding-block-end: 1rem; color: var(--muted); }

.tide-filters {
  display: flex;
  flex-wrap: wrap;
  column-gap: clamp(0.5rem, 2vw, 1.7rem);
}

.tide-filters button {
  position: relative;
  min-height: 2.75rem;
  padding: 0.65rem 0.14rem;
  border: 0;
  background: transparent;
  color: var(--muted);
  font-size: clamp(0.875rem, 1vw, 1rem);
}

.tide-filters button:is([aria-pressed="true"], :hover) { color: var(--ink); }
.tide-filters button[aria-pressed="true"] { font-weight: 700; }

.tide-filters button[aria-pressed="true"]::after {
  position: absolute;
  right: 0;
  bottom: -1px;
  left: 0;
  height: 2px;
  background: var(--accent);
  content: "";
}

.tide-catalog-tools {
  display: grid;
  grid-template-columns: minmax(0, 17rem) 1fr minmax(0, 11rem);
  align-items: end;
  gap: clamp(0.6rem, 2vw, 1.35rem);
  margin-block-end: 1.35rem;
}

.tide-catalog-tools label { display: grid; gap: 0.22rem; min-width: 0; }
.tide-control-label { color: var(--muted); font-size: 0.875rem; font-weight: 600; }

.tide-catalog-tools :is(input, select) {
  width: 100%;
  min-height: 2.75rem;
  padding-inline: 0.75rem;
  border: 1px solid var(--line);
  border-radius: 0.3rem;
  background: var(--surface);
  color: var(--ink);
  font: 500 1rem var(--body-font);
}

.tide-catalog-tools select {
  appearance: none;
  padding-inline-end: 2rem;
  background:
    linear-gradient(45deg, transparent 48%, var(--ink) 50% 61%, transparent 63%) right 0.94rem center / 0.32rem 0.32rem no-repeat,
    linear-gradient(135deg, transparent 38%, var(--ink) 40% 51%, transparent 53%) right 0.66rem center / 0.32rem 0.32rem no-repeat,
    var(--surface);
  cursor: pointer;
}

.tide-catalog-tools :is(input, select):focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.tide-catalog-count { align-self: end; padding-block-end: 0.63rem; color: var(--muted); font-size: 0.875rem; }

.tide-home .tide-products {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 2.25rem clamp(0.85rem, 2.25vw, 2.2rem);
}

.tide-products .product-card {
  min-width: 0;
  padding: 0;
  background: transparent;
  border: 0;
}

.tide-products .product-photo {
  position: relative;
  display: block;
  aspect-ratio: 1;
  overflow: hidden;
  border-radius: 0.75rem 0.75rem 0.15rem 0.15rem;
  background: var(--wash);
}

.tide-products .product-photo::after {
  position: absolute;
  right: 0.65rem;
  bottom: 0.65rem;
  display: grid;
  place-items: center;
  width: 2rem;
  aspect-ratio: 1;
  border: 1px solid #d8d4c2;
  border-radius: 50%;
  background: var(--surface);
  color: var(--ink);
  font-size: 1.14rem;
  line-height: 1;
  content: "+";
  transition: color 200ms ease, background 200ms ease;
}

.tide-products .product-photo:hover::after { background: var(--accent); color: var(--on-accent); }

.tide-products .product-photo img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: contain;
  transition: transform 450ms cubic-bezier(.2,.8,.2,1);
}

@media (hover: hover) and (prefers-reduced-motion: no-preference) {
  .tide-products .product-card:hover .product-photo img { transform: scale(1.04); }
}

.tide-products .product-info {
  display: block;
  padding: 0.9rem 0.12rem 0;
}

.tide-products .product-category {
  margin-block-end: 0.18rem;
  color: var(--muted);
  font-size: 0.875rem;
}

.tide-products .product-info h3 {
  margin: 0;
  font: 600 clamp(1.4rem, 2.05vw, 2.15rem)/1.05 var(--display-font);
  letter-spacing: -0.035em;
}

.tide-products .product-info a { text-decoration: none; }
.tide-products .product-info a:hover { text-decoration: underline; text-underline-offset: 0.13em; }
.tide-products .product-price { display: block; margin-block-start: 0.4rem; font-variant-numeric: tabular-nums; }

.tide-editorial {
  display: grid;
  grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr);
  background: var(--wash);
}

.tide-editorial-photo {
  min-height: clamp(22rem, 39vw, 37rem);
  overflow: hidden;
  background: #d7e3e6;
}

.tide-editorial-copy {
  align-self: center;
  padding: clamp(3rem, 6vw, 6rem) var(--gutter) clamp(3rem, 6vw, 6rem) clamp(1.5rem, 5vw, 5.2rem);
}

.tide-editorial-copy h2 { max-width: 9ch; }
.tide-editorial-copy > p:not(.tide-kicker) { margin-block: 1.25rem 0.6rem; max-width: 34ch; color: var(--muted); }

.tide-look-list {
  max-width: 24rem;
  padding: 0;
  margin: 1.45rem 0 0;
  border-top: 1px solid #9eb0b9;
  list-style: none;
}

.tide-look-list a {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
  min-height: 2.9rem;
  border-bottom: 1px solid #9eb0b9;
  font-weight: 600;
  text-decoration: none;
}

.tide-look-list a:hover > span { text-decoration: underline; text-underline-offset: 0.23em; }
.tide-look-list small { color: var(--muted); font-size: 0.875rem; font-weight: 400; }

.tide-text-link {
  display: inline-flex;
  align-items: center;
  min-height: 2.75rem;
  font-weight: 700;
  text-decoration-thickness: 1px;
  text-underline-offset: 0.28em;
}

.tide-text-link:hover { text-decoration-thickness: 2px; }

.tide-service {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  padding: clamp(1.25rem, 3vw, 2.6rem) var(--gutter);
  text-align: center;
}

.tide-service a {
  display: grid;
  align-content: center;
  justify-items: center;
  gap: 0.18rem;
  min-height: 5.5rem;
  padding: 0.75rem;
  text-decoration: none;
}

.tide-service a + a { border-inline-start: 1px solid var(--line); }
.tide-service a:hover strong { text-decoration: underline; text-underline-offset: 0.17em; }
.tide-service strong { font: 600 1.8rem/1.1 var(--display-font); letter-spacing: -0.045em; }
.tide-service span { color: var(--muted); font-size: 0.875rem; }

.tide-footer {
  padding: clamp(2rem, 4.5vw, 4.2rem) var(--gutter) 1.6rem;
  background: var(--deep);
  color: var(--on-accent);
}

.tide-footer-content {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr;
  gap: 1.4rem;
  padding-block-end: 2rem;
}

.tide-footer-brand .tide-wordmark { font-size: clamp(2.6rem, 5vw, 5rem); }
.tide-footer-brand p { margin-block-start: 0.65rem; color: #e1eaf0; }
.tide-footer nav h2 { margin-block-end: 0.15rem; font: 700 1rem/1.5 var(--body-font); }
.tide-footer nav a { width: fit-content; color: #e1eaf0; font-size: 0.9rem; }

.tide-footer-base {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 0.7rem;
  padding-block-start: 1.2rem;
  border-top: 1px solid #5d728e;
  font-size: 0.875rem;
}

.tide-cards { display: flex; align-items: center; gap: 0.36rem; padding: 0; margin: 0; list-style: none; }
.tide-cards img { width: 2.06rem; height: 1.375rem; }

@keyframes tide-arrive {
  from { opacity: 0; transform: translateY(1rem); }
  to { opacity: 1; transform: translateY(0); }
}

@keyframes tide-drift {
  from { transform: scale(1.045) translateY(0.4%); }
  to { transform: scale(1) translateY(0); }
}

@keyframes tide-horizon-turn {
  from { rotate: 0.1 1 0 -21deg; translate: 0 0.85rem; }
  to { rotate: 0.1 1 0 0deg; translate: 0; }
}

@media (prefers-reduced-motion: no-preference) {
  html:has(.tide-home) { scroll-behavior: smooth; }
  .tide-hero-copy { animation: tide-arrive 680ms cubic-bezier(.26,.72,.32,1) both; }
  .tide-hero-window img { animation: tide-drift 1050ms cubic-bezier(.24,.62,.38,1) both; }
  .tide-horizon { animation: tide-horizon-turn 1400ms cubic-bezier(.24,.62,.38,1) both; }
  .tide-products .product-card { animation: tide-arrive 320ms ease-out both; }
  .tide-products .product-card:nth-child(4n+2) { animation-delay: 32ms; }
  .tide-products .product-card:nth-child(4n+3) { animation-delay: 64ms; }
  .tide-products .product-card:nth-child(4n+4) { animation-delay: 96ms; }
  @supports (animation-timeline: view()) {
    .tide-editorial-copy {
      animation: tide-arrive ease-out both;
      animation-timeline: view();
      animation-range: entry 2% entry 70%;
    }
  }
}

@media (max-width: 58rem) {
  .tide-hero h1 { font-size: clamp(4rem, 9.8vw, 6.5rem); }
  .tide-hero-window { aspect-ratio: 0.88; }
  .tide-editorial { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 43rem) {
  .tide-header-inner { min-height: 3.9rem; }
  .tide-nav .tide-about-nav { display: none; }
  .tide-hero { grid-template-columns: 1fr; gap: 2rem; padding-block: 2.35rem 3rem; }
  .tide-hero-copy { padding: 0; text-align: center; }
  .tide-hero h1 { font-size: clamp(3.55rem, 17vw, 6.45rem); }
  .tide-intro { max-width: 31ch; margin: 1.1rem auto 1.25rem; }
  .tide-hero-actions { justify-content: center; gap: 0.25rem 1.15rem; }
  .tide-hero-visual { max-width: min(100%, 29rem); padding-right: 0.65rem; }
  .tide-hero-frame { inset: 0.65rem -0.65rem -0.65rem 0.65rem; }
  .tide-hero-window { aspect-ratio: 1.13; }
  .tide-horizon { right: -0.36rem; }
  .tide-collection-head { gap: 0.55rem; }
  .tide-collection-head h2 { padding-block-end: 0.2rem; }
  .tide-collection-head p { padding-block-end: 0; }
  .tide-catalog-tools { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
  .tide-catalog-sort { grid-area: 1 / 2; }
  .tide-catalog-count { grid-column: 1 / -1; padding-block-end: 0; }
  .tide-home .tide-products { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .tide-editorial { grid-template-columns: 1fr; }
  .tide-editorial-photo { min-height: 0; aspect-ratio: 1.32; }
  .tide-editorial-copy { padding: 2.65rem var(--gutter); }
  .tide-service { grid-template-columns: 1fr; padding: 0.4rem var(--gutter); text-align: start; }
  .tide-service a { justify-items: start; min-height: 4.5rem; padding-inline: 0; }
  .tide-service a + a { border-inline-start: 0; border-top: 1px solid var(--line); }
  .tide-footer-content { grid-template-columns: 1fr 1fr; }
  .tide-footer-brand { grid-column: 1 / -1; }
}

@media (max-width: 23rem) {
  .tide-bag-icon { display: none; }
  .tide-header-inner { gap: 0.48rem; }
  .tide-filters { column-gap: 0.58rem; }
}
