/* AquaFrenzy storefront. Deep-ocean header/hero/footer, bright sandy content in between. */

/* Self-hosted fonts (Latin subset, variable WOFF2 from Google Fonts; SIL OFL, see ../fonts/OFL-*.txt). */
/* Two separate faces (not a 600 800 range) so weight 700 still falls to 800, as it did with Google's CSS. */
@font-face {
  font-family: "Fraunces";
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url("../fonts/fraunces-latin-var.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: "Fraunces";
  font-style: normal;
  font-weight: 800;
  font-display: swap;
  src: url("../fonts/fraunces-latin-var.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: "Plus Jakarta Sans";
  font-style: normal;
  font-weight: 400 700;
  font-display: swap;
  src: url("../fonts/plus-jakarta-sans-latin-var.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

:root {
  --abyss: #031225;
  --deep: #062a4d;
  --ocean: #0b5aa6;
  --lagoon: #19b6d6;
  --lagoon-ink: #0a7690;
  --glow: #5ff2e7;
  --coral: #ff6f59;
  --sun: #ffc845;
  --sand: #f7f3ec;
  --paper: #ffffff;
  --ink: #0b1b2b;
  --ink-soft: #3d5468;
  --muted: #53697d;
  --line: #e3e9ef;
  --ok: #0e7a58;
  --warn: #9a5b00;
  --danger: #d23b3b;
  --radius: 18px;
  --radius-sm: 10px;
  --shadow: 0 10px 30px -12px rgba(3, 18, 37, .25);
  --shadow-lg: 0 30px 60px -20px rgba(3, 18, 37, .45);
  --display: "Fraunces", Georgia, "Times New Roman", serif;
  --body: "Plus Jakarta Sans", system-ui, -apple-system, "Segoe UI", sans-serif;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  margin: 0;
  font: 16px/1.6 var(--body);
  color: var(--ink);
  background: var(--sand);
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; height: auto; display: block; }
a { color: var(--ocean); text-decoration-thickness: 1px; text-underline-offset: 3px; }
a:hover { color: var(--lagoon); }
h1, h2, h3 { font-family: var(--display); line-height: 1.1; letter-spacing: -.01em; margin: 0 0 .5em; }
p { margin: 0 0 1em; }
button, input, select, textarea { font: inherit; color: inherit; }
:focus-visible { outline: 3px solid var(--lagoon); outline-offset: 2px; border-radius: 4px; }
[hidden] { display: none !important; }

.wrap { width: min(1240px, 100% - 32px); margin-inline: auto; }
.narrow { width: min(780px, 100% - 32px); }
.center { text-align: center; }
.muted { color: var(--muted); }
.small { font-size: .875rem; }
.visually-hidden, .hp {
  position: absolute !important; width: 1px; height: 1px; overflow: hidden;
  clip: rect(0 0 0 0); white-space: nowrap; border: 0; padding: 0; margin: -1px;
}
.skip-link { position: absolute; left: -999px; top: 8px; z-index: 100; background: var(--paper); padding: 8px 14px; border-radius: 8px; }
.skip-link:focus { left: 8px; }

/* ---------- Buttons & links ---------- */

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .5em;
  padding: .8em 1.5em; border-radius: 999px; border: 2px solid transparent;
  font-weight: 700; text-decoration: none; cursor: pointer; line-height: 1.2;
  transition: transform .15s ease, box-shadow .2s ease, background .2s ease;
}
.btn:hover { transform: translateY(-2px); }
.btn:active { transform: translateY(0); }
.btn-glow {
  color: var(--abyss);
  background: linear-gradient(120deg, var(--glow), var(--lagoon) 55%, #4f8dff);
  box-shadow: 0 10px 30px -8px rgba(25, 182, 214, .7);
}
.btn-glow:hover { color: var(--abyss); box-shadow: 0 14px 34px -6px rgba(95, 242, 231, .8); }
.btn-ghost { color: #fff; border-color: rgba(255, 255, 255, .5); background: rgba(255, 255, 255, .06); backdrop-filter: blur(6px); }
.btn-ghost:hover { color: #fff; border-color: #fff; }
.btn-dark { color: #fff; background: var(--deep); }
.btn-dark:hover { color: #fff; background: var(--ocean); }
.btn-ghost-dark { color: var(--deep); border-color: var(--deep); background: transparent; }
.btn-lg { font-size: 1.08rem; padding: .95em 1.8em; }
.btn-block { width: 100%; }
.text-link { font-weight: 700; color: var(--ocean); text-decoration: none; }
.text-link:hover { text-decoration: underline; }
button.text-link { padding: 0; border: 0; background: none; cursor: pointer; }
.plan-add { display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 14px; margin: 0 0 14px; }

/* ---------- Top bar & header ---------- */

.topbar {
  display: flex; justify-content: center; align-items: center; gap: 12px; flex-wrap: wrap;
  padding: 7px 16px; font-size: .8rem; font-weight: 600; letter-spacing: .02em;
  color: var(--abyss); background: linear-gradient(90deg, var(--glow), var(--sun));
}
.topbar .dot { width: 4px; height: 4px; border-radius: 50%; background: currentColor; opacity: .5; }
.topbar a { color: inherit; text-decoration: none; }
.topbar a:hover { color: inherit; text-decoration: underline; }
@media (max-width: 900px) { .topbar .topbar-wide { display: none; } }
@media (max-width: 520px) { .topbar .dot, .topbar .topbar-guarantee { display: none; } }

.site-header {
  position: sticky; top: 0; z-index: 50;
  background: rgba(3, 18, 37, .88); backdrop-filter: saturate(160%) blur(14px);
  border-bottom: 1px solid rgba(95, 242, 231, .12);
  color: #e7f4ff;
}
.header-inner { display: flex; align-items: center; gap: 20px; min-height: 70px; }
.brand { display: inline-flex; align-items: center; gap: 10px; color: #fff; text-decoration: none; flex-shrink: 0; }
.brand:hover { color: #fff; }
.brand-name { font-family: var(--display); font-weight: 800; font-size: 1.45rem; letter-spacing: -.02em; }
.brand-name span { background: linear-gradient(90deg, var(--glow), var(--lagoon)); -webkit-background-clip: text; background-clip: text; color: transparent; }

.main-nav { display: flex; align-items: center; gap: 18px; flex: 1; }
.main-nav ul { display: flex; gap: 4px; list-style: none; margin: 0; padding: 0; }
.main-nav a {
  display: block; padding: 8px 12px; border-radius: 999px; color: #cfe3f5;
  font-weight: 600; font-size: .95rem; text-decoration: none; white-space: nowrap;
}
.main-nav a:hover, .main-nav a[aria-current] { color: #fff; background: rgba(95, 242, 231, .12); }
.nav-search { margin-left: auto; }
.nav-search input {
  width: 240px; padding: 9px 16px; border-radius: 999px; border: 1px solid rgba(255, 255, 255, .18);
  background: rgba(255, 255, 255, .08); color: #fff;
}
.nav-search input::placeholder { color: #8fb1cc; }
.nav-search input:focus { outline: none; border-color: var(--glow); background: rgba(255, 255, 255, .14); }

.cart-link {
  position: relative; display: grid; place-items: center; width: 46px; height: 46px; border-radius: 50%;
  color: #fff; background: rgba(255, 255, 255, .08); flex-shrink: 0;
}
.cart-link:hover { color: var(--glow); background: rgba(95, 242, 231, .16); }
.cart-count {
  position: absolute; top: -2px; right: -2px; min-width: 20px; height: 20px; padding: 0 5px;
  border-radius: 999px; font-size: .72rem; font-weight: 800; line-height: 20px; text-align: center;
  color: var(--abyss); background: var(--sun);
}
.cart-count.bump { animation: bump .5s ease; }
@keyframes bump { 30% { transform: scale(1.5); } }

.nav-toggle { display: none; width: 46px; height: 46px; border: 0; border-radius: 50%; background: rgba(255, 255, 255, .08); cursor: pointer; }
.nav-toggle .bars, .nav-toggle .bars::before, .nav-toggle .bars::after {
  display: block; width: 20px; height: 2px; margin: auto; background: #fff; border-radius: 2px; position: relative; transition: .2s;
}
.nav-toggle .bars::before, .nav-toggle .bars::after { content: ""; position: absolute; left: 0; }
.nav-toggle .bars::before { top: -6px; }
.nav-toggle .bars::after { top: 6px; }
.nav-toggle[aria-expanded="true"] .bars { background: transparent; }
.nav-toggle[aria-expanded="true"] .bars::before { top: 0; transform: rotate(45deg); }
.nav-toggle[aria-expanded="true"] .bars::after { top: 0; transform: rotate(-45deg); }

@media (max-width: 1060px) {
  .nav-toggle { display: block; }
  .header-inner { justify-content: space-between; }
  .main-nav {
    position: absolute; top: 100%; left: 0; right: 0; flex-direction: column; align-items: stretch; gap: 12px;
    padding: 16px 16px 24px; background: var(--abyss); box-shadow: var(--shadow-lg); border-bottom: 1px solid rgba(95, 242, 231, .2);
    transform: translateY(-12px); opacity: 0; visibility: hidden; transition: .2s ease; order: 3;
  }
  .main-nav.open { transform: none; opacity: 1; visibility: visible; }
  .main-nav ul { flex-direction: column; }
  .main-nav a { font-size: 1.05rem; padding: 12px 14px; }
  .nav-search { margin: 0; }
  .nav-search input { width: 100%; }
  .cart-link { margin-left: auto; }
}

/* ---------- Flash messages ---------- */

.flashes { margin-top: 16px; }
.alert { padding: 12px 18px; border-radius: var(--radius-sm); margin-bottom: 10px; font-weight: 600; border: 1px solid; }
.alert a { font-weight: 800; }
.alert-success { background: #e4f8f0; border-color: #a9e5cf; color: #0b6e4f; }
.alert-warning { background: #fff5e0; border-color: #ffd98a; color: #8a5300; }
.alert-error { background: #fdeaea; border-color: #f4b4b4; color: #9e1f1f; }

/* ---------- Hero ---------- */

.hero {
  position: relative; overflow: hidden; color: #fff; background: var(--abyss);
  min-height: min(88vh, 820px); display: flex; align-items: center; padding: 60px 0 140px;
}
.hero-bg { position: absolute; inset: 0; }
.hero-bg img { width: 100%; height: 100%; object-fit: cover; transform: scale(1.06); animation: drift 30s ease-in-out infinite alternate; }
/* Shade only behind the text (left): just enough for 4.5:1 on the eyebrow, headline and subtitle
   at every point of the drift; the photo stays clear on the right. Caustics sit under it (z-index 0). */
.hero::before {
  content: ""; position: absolute; inset: 0; z-index: 1;
  background: linear-gradient(90deg, rgba(3, 18, 37, .68), rgba(3, 18, 37, .62) 40%, rgba(3, 18, 37, 0) 64%);
}
@keyframes drift { to { transform: scale(1.14) translate(-1.5%, -1%); } }

.caustics {
  position: absolute; inset: -20%; z-index: 0; opacity: .18; mix-blend-mode: screen; pointer-events: none;
  background:
    radial-gradient(closest-side, rgba(95, 242, 231, .9), transparent) 0 0 / 220px 160px,
    radial-gradient(closest-side, rgba(255, 255, 255, .6), transparent) 110px 80px / 260px 190px;
  filter: blur(18px);
  animation: caustics 18s linear infinite;
}
@keyframes caustics { to { transform: translate(220px, 160px) rotate(8deg); } }

.bubbles { position: absolute; inset: 0; z-index: 1; pointer-events: none; }
.bubbles span {
  position: absolute; bottom: -40px; width: 14px; height: 14px; border-radius: 50%;
  border: 1.5px solid rgba(255, 255, 255, .55); background: rgba(255, 255, 255, .08);
  animation: rise 14s linear infinite;
}
.bubbles span:nth-child(1) { left: 8%;  animation-delay: 0s;   transform: scale(.6); }
.bubbles span:nth-child(2) { left: 22%; animation-delay: 4s;   transform: scale(1.1); }
.bubbles span:nth-child(3) { left: 38%; animation-delay: 7s;   transform: scale(.8); }
.bubbles span:nth-child(4) { left: 55%; animation-delay: 2s;   transform: scale(1.3); }
.bubbles span:nth-child(5) { left: 68%; animation-delay: 9s;   transform: scale(.7); }
.bubbles span:nth-child(6) { left: 80%; animation-delay: 5s;   transform: scale(1); }
.bubbles span:nth-child(7) { left: 90%; animation-delay: 11s;  transform: scale(.5); }
.bubbles span:nth-child(8) { left: 47%; animation-delay: 12.5s; transform: scale(.9); }
@keyframes rise {
  0%   { bottom: -40px; opacity: 0; margin-left: 0; }
  10%  { opacity: 1; }
  50%  { margin-left: 24px; }
  100% { bottom: 110%; opacity: 0; margin-left: -10px; }
}

.hero-inner { position: relative; z-index: 2; display: grid; grid-template-columns: 1.1fr .9fr; gap: 48px; align-items: center; }
.eyebrow {
  margin: 0 0 12px; font-size: .78rem; font-weight: 800; letter-spacing: .16em; text-transform: uppercase; color: var(--lagoon-ink);
}
.eyebrow a { color: inherit; text-decoration: none; }
.eyebrow a:hover { text-decoration: underline; text-underline-offset: 3px; }
.hero .eyebrow { color: var(--glow); }
.section-gallery .eyebrow { color: var(--lagoon); }
.hero h1 { font-size: clamp(2.8rem, 6.4vw, 5.6rem); font-weight: 800; margin-bottom: 28px; text-wrap: balance; }
.hero h1 span {
  display: block; margin-top: 18px; max-width: 30ch;
  font: 500 clamp(1.05rem, 1.6vw, 1.3rem)/1.5 var(--body); letter-spacing: 0; color: #cfe3f5;
}
.hero-actions { display: flex; flex-wrap: wrap; gap: 14px; margin-bottom: 34px; }
.hero-chips { display: flex; flex-wrap: wrap; gap: 10px; list-style: none; padding: 0; margin: 0; }
.hero-chips li {
  display: inline-flex; align-items: center; gap: 8px; padding: 8px 14px; border-radius: 999px;
  font-size: .85rem; font-weight: 600; background: rgba(255, 255, 255, .08);
  border: 1px solid rgba(255, 255, 255, .16); backdrop-filter: blur(8px);
}
.hero-chips svg { width: 18px; height: 18px; fill: none; stroke: var(--glow); stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }

.hero-stack { position: relative; height: 460px; }
.float-card {
  position: absolute; width: 270px; border-radius: 22px; overflow: hidden; color: #fff; text-decoration: none;
  background: rgba(255, 255, 255, .1); border: 1px solid rgba(255, 255, 255, .22);
  box-shadow: var(--shadow-lg); backdrop-filter: blur(12px);
  animation: bob 7s ease-in-out infinite;
  transition: transform .3s ease;
}
.float-card:hover { color: #fff; transform: scale(1.04) rotate(0deg) !important; z-index: 5; }
.float-card img { aspect-ratio: 4 / 3; object-fit: cover; width: 100%; }
.float-card-text { display: flex; justify-content: space-between; gap: 10px; padding: 12px 16px; font-size: .92rem; }
.float-card-text em { font-style: normal; font-weight: 800; color: var(--sun); }
.float-card-1 { top: 0; right: 30px; transform: rotate(4deg); }
.float-card-2 { top: 150px; left: 0; transform: rotate(-6deg); animation-delay: -2.3s; }
.float-card-3 { bottom: 0; right: 0; transform: rotate(2deg); animation-delay: -4.6s; }
@keyframes bob { 50% { translate: 0 -12px; } }

.hero-wave { position: absolute; bottom: -1px; left: 0; width: 100%; height: 110px; z-index: 3; fill: var(--sand); }

@media (max-width: 900px) {
  .hero { min-height: 0; padding: 50px 0 120px; }
  /* One column: the text runs the full width, so shade from the top down instead. */
  .hero::before { background: linear-gradient(180deg, rgba(3, 18, 37, .68), rgba(3, 18, 37, .66) 90px, rgba(3, 18, 37, .5) 300px, rgba(3, 18, 37, 0) 440px); }
  .hero-inner { grid-template-columns: 1fr; }
  .hero-stack { height: 300px; }
  .float-card { width: 190px; }
  .float-card-2 { top: 90px; }
}
@media (max-width: 540px) {
  .hero-stack { display: none; }
}

/* ---------- Sections ---------- */

.section { padding: 72px 0; }
.section-head { margin-bottom: 32px; }
.section-head h2 { font-size: clamp(2rem, 4vw, 3rem); margin: 0; }
.section-head-row { display: flex; justify-content: space-between; align-items: end; gap: 20px; flex-wrap: wrap; }
.section-lede { max-width: 60ch; color: var(--ink-soft); margin-top: 10px; }
.section-categories { padding-top: 24px; }

.category-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 22px; }
.category-tile {
  position: relative; display: block; border-radius: 26px; overflow: hidden; min-height: 320px;
  color: #fff; text-decoration: none; box-shadow: var(--shadow); isolation: isolate;
}
.category-tile img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; z-index: -2; transition: transform .6s ease; }
.category-tile::after { content: ""; position: absolute; inset: 0; z-index: -1; background: linear-gradient(180deg, transparent 30%, rgba(3, 18, 37, .9)); }
.category-tile:hover img { transform: scale(1.08); }
.category-tile:hover { color: #fff; }
.category-text { position: absolute; left: 24px; right: 24px; bottom: 22px; display: grid; gap: 6px; }
.category-text strong { font: 800 2rem/1.05 var(--display); }
.category-text > span { color: #cfe3f5; font-size: .95rem; }
.category-text em { font-style: normal; font-weight: 700; color: var(--glow); }

/* Horizontal rail of cards */
.rail {
  display: grid; grid-auto-flow: column; grid-auto-columns: minmax(260px, 290px); gap: 22px;
  overflow-x: auto; scroll-snap-type: x mandatory; padding: 6px 4px 22px; scrollbar-width: thin;
}
.rail > * { scroll-snap-align: start; }
.rail-controls { display: flex; gap: 10px; }
.rail-btn {
  width: 48px; height: 48px; border-radius: 50%; border: 2px solid var(--deep); background: transparent;
  font-size: 1.2rem; font-weight: 800; color: var(--deep); cursor: pointer; transition: .2s;
}
.rail-btn:hover { background: var(--deep); color: #fff; }

.section-featured { background: linear-gradient(180deg, var(--sand), #eaf6f8); }

/* ---------- Product cards ---------- */

.grid { display: grid; gap: 22px; }
.grid-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.grid-3 { grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); }
.grid-4 { grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); }
@media (max-width: 560px) { .grid-2 { grid-template-columns: 1fr; } }

.card {
  display: flex; flex-direction: column; border-radius: var(--radius); overflow: hidden;
  background: var(--paper); box-shadow: var(--shadow); transition: transform .25s ease, box-shadow .25s ease;
}
.card:hover { transform: translateY(-6px); box-shadow: var(--shadow-lg); }
.card-media { position: relative; display: block; aspect-ratio: 4 / 3; overflow: hidden; background: var(--deep); }
.card-media img { width: 100%; height: 100%; object-fit: cover; transition: transform .5s ease; }
.card:hover .card-media img { transform: scale(1.07); }
.badges { position: absolute; top: 12px; left: 12px; display: flex; flex-wrap: wrap; gap: 6px; }
.badge {
  display: inline-block; padding: 4px 10px; border-radius: 999px; font-size: .72rem; font-weight: 800;
  letter-spacing: .02em; background: rgba(255, 255, 255, .92); color: var(--ink);
}
.badge-sale { background: var(--coral); color: var(--abyss); }
.badge-low { background: var(--sun); color: var(--abyss); }
.badge-out { background: var(--ink); color: #fff; }
.badge-aqua { background: rgba(3, 18, 37, .75); color: var(--glow); backdrop-filter: blur(4px); }

.card-body { position: relative; display: flex; flex-direction: column; flex: 1; padding: 16px 18px 18px; }
.card-title { font: 700 1.12rem/1.25 var(--body); margin: 0 0 2px; }
.card-title a { color: var(--ink); text-decoration: none; }
.card-title a:hover { color: var(--ocean); }
@media (max-width: 640px) { .card-title a { display: inline-block; padding: 12px 0; margin: -12px 0; } }
.sci { margin: 0 0 10px; font-style: italic; font-size: .86rem; color: var(--muted); }
.sci-lg { font-size: 1.1rem; }
.tags { display: flex; flex-wrap: wrap; gap: 6px; list-style: none; padding: 0; margin: 0 0 14px; }
.tag { padding: 3px 10px; border-radius: 999px; font-size: .74rem; font-weight: 700; background: #eef3f7; color: var(--ink-soft); }
.tag-care-easy { background: #e2f7ee; color: #0b6e4f; }
.tag-care-moderate { background: #fff3db; color: #8a5300; }
.tag-care-expert { background: #fde6e3; color: #a3271a; }
.tag-reef { background: #e0f4fb; color: #075b78; }
.tag-caution { background: #fff3db; color: #8a5300; }
.tag-aqua { background: #e9e6ff; color: #4b3cb3; }
.tags-lg .tag { font-size: .85rem; padding: 6px 14px; }
.tag a { color: inherit; text-decoration: none; }
.tag a:hover { text-decoration: underline; text-underline-offset: 2px; }

.card-foot { margin-top: auto; display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.price { margin: 0; font-weight: 800; font-size: 1.2rem; color: var(--ink); }
.price s { margin-left: 6px; font-size: .85em; font-weight: 600; color: var(--muted); }
.btn-add {
  display: inline-flex; align-items: center; gap: 4px; padding: 8px 14px; border: 0; border-radius: 999px;
  font-weight: 800; font-size: .88rem; cursor: pointer; color: #fff; background: var(--deep); transition: .2s;
}
.btn-add:hover { background: var(--lagoon); color: var(--abyss); }
.btn-add.added { background: var(--ok); }
.price-sale { color: #d6342a; }

/* ---------- Banners (diagonal ribbon across the photo corner) ---------- */

/* The band's centre sits the same distance from the top and right edges, so its text is centred on the corner. */
.ribbon {
  position: absolute; top: 50px; right: 50px; z-index: 3; width: 220px; transform: translate(50%, -50%) rotate(45deg);
  display: grid; place-items: center; padding: 9px 0; pointer-events: none;
  font: 800 .8rem/1 var(--body); letter-spacing: .16em; text-transform: uppercase; color: #fff;
  background: linear-gradient(90deg, #ff5a3c, #ff2d55);
  box-shadow: 0 8px 18px -6px rgba(3, 18, 37, .55);
}
.ribbon > span { max-width: 124px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ribbon::before, .ribbon::after { content: ""; position: absolute; inset: 3px 0; border-top: 1px dashed rgba(255, 255, 255, .45); border-bottom: 1px dashed rgba(255, 255, 255, .45); }
.ribbon-hot { background: linear-gradient(90deg, #ff6a00, #ff2d55 70%); }
.ribbon-hot > span::before { content: "🔥 "; letter-spacing: 0; }
.ribbon-sale { background: linear-gradient(90deg, #ffc845, #ff8a00); color: var(--abyss); }
.ribbon-sale::before, .ribbon-sale::after { border-color: rgba(3, 18, 37, .25); }
.ribbon-new { background: linear-gradient(90deg, #19b6d6, #5ff2e7); color: var(--abyss); }
.ribbon-new::before, .ribbon-new::after { border-color: rgba(3, 18, 37, .25); }
.ribbon-limited { background: linear-gradient(90deg, #6d4bff, #b04bff); }
.ribbon-deal { background: linear-gradient(90deg, #ff2d55, #ff7a00, #ffc845); background-size: 200% 100%; animation: ribbon-shine 4s linear infinite; }
@keyframes ribbon-shine { to { background-position: -200% 0; } }
.ribbon-lg { top: 74px; right: 74px; width: 330px; padding: 13px 0; font-size: 1.05rem; }
.ribbon-lg > span { max-width: 184px; }
.ribbon-long { font-size: .62rem; letter-spacing: .07em; }
.ribbon-lg.ribbon-long { font-size: .86rem; letter-spacing: .09em; }
.float-card .ribbon { top: 42px; right: 42px; width: 190px; padding: 7px 0; font-size: .58rem; letter-spacing: .06em; }
.float-card .ribbon > span { max-width: 104px; }
@media (prefers-reduced-motion: reduce) { .ribbon-deal { animation: none; } }

/* ---------- Deal of the day / week ---------- */

.section-deals { position: relative; padding-top: 36px; background: radial-gradient(1200px 400px at 80% 0%, rgba(255, 45, 85, .1), transparent), var(--sand); }
.deal-grid { display: grid; gap: 26px; grid-template-columns: repeat(2, minmax(0, 1fr)); }
.deal-grid-1 { grid-template-columns: 1fr; }
.deal-grid-1 .deal-card { grid-template-columns: 1.2fr 1fr; }
@media (max-width: 980px) { .deal-grid { grid-template-columns: 1fr; } }
.deal-card {
  display: grid; grid-template-columns: 1fr; overflow: hidden; border-radius: 26px; background: var(--abyss); color: #fff;
  box-shadow: var(--shadow-lg); position: relative; isolation: isolate;
}
.deal-card::after {
  content: ""; position: absolute; inset: 0; z-index: -1; pointer-events: none;
  background: radial-gradient(600px 300px at 100% 100%, rgba(95, 242, 231, .18), transparent);
}
@media (max-width: 700px) { .deal-grid-1 .deal-card { grid-template-columns: 1fr; } }
.deal-media { position: relative; display: block; overflow: hidden; aspect-ratio: 16 / 10; background: var(--deep); }
.deal-grid-1 .deal-media { aspect-ratio: auto; min-height: 320px; }
.deal-media img { width: 100%; height: 100%; object-fit: cover; transition: transform .6s ease; }
.deal-card:hover .deal-media img { transform: scale(1.05); }
.deal-off {
  position: absolute; left: 18px; bottom: 18px; z-index: 2; display: grid; place-items: center; width: 84px; height: 84px; border-radius: 50%;
  font: 800 1.45rem/1 var(--display); color: var(--abyss); background: var(--sun); box-shadow: 0 10px 24px -8px rgba(0, 0, 0, .5); transform: rotate(-10deg);
}
.deal-body { padding: 24px 26px 28px; display: flex; flex-direction: column; gap: 6px; }
.deal-label { margin: 0; font-weight: 800; font-size: .8rem; letter-spacing: .16em; text-transform: uppercase; color: var(--coral); }
.deal-body h3 { font-size: clamp(1.5rem, 2.6vw, 2.1rem); margin: 0; }
.deal-body h3 a { color: #fff; text-decoration: none; }
.deal-body h3 a:hover { color: var(--glow); }
.deal-blurb { color: #b9cfe0; margin: 0; }
.deal-price { margin: 6px 0 0; display: flex; flex-wrap: wrap; align-items: baseline; gap: 10px; font: 800 2.3rem/1 var(--display); color: var(--sun); }
.deal-price s { font: 600 1.05rem var(--body); color: #8ea9bf; }
.deal-save { font: 800 .8rem var(--body); letter-spacing: .04em; padding: 5px 10px; border-radius: 999px; background: var(--coral); color: #fff; align-self: center; }
.deal-timer { margin: 8px 0 4px; color: #cfe3f5; font-size: .95rem; }
.deal-timer strong { font-variant-numeric: tabular-nums; color: #fff; font-size: 1.1rem; margin-left: 4px; }
.deal-buy { display: flex; flex-wrap: wrap; align-items: center; gap: 14px; margin-top: 8px; }
.deal-stock { color: var(--sun); font-weight: 700; font-size: .9rem; }
.deal-sold-out { margin: 8px 0 0; font-weight: 700; color: #ffb4a8; }
.deal-strip {
  display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 8px; margin: 0 0 14px;
  padding: 10px 16px; border-radius: 14px; color: #fff; background: linear-gradient(90deg, #ff2d55, #ff7a00);
}
.deal-strip strong { letter-spacing: .12em; text-transform: uppercase; font-size: .82rem; }
.deal-strip b { font-variant-numeric: tabular-nums; }

.section-hot { background: linear-gradient(180deg, #fff4ef, var(--sand)); }
.section-hot .rail-controls { align-items: center; }

/* ---------- Gallery ---------- */

.section-gallery { background: var(--abyss); color: #fff; }
.section-gallery .section-lede { color: #a9c4da; }
.gallery { display: grid; grid-template-columns: repeat(12, 1fr); grid-auto-rows: 160px; gap: 14px; }
.gallery-item { position: relative; margin: 0; border-radius: 20px; overflow: hidden; grid-column: span 4; grid-row: span 2; }
.gallery-item-0 { grid-column: span 7; grid-row: span 3; }
.gallery-item-1 { grid-column: span 5; grid-row: span 3; }
.gallery-item img { width: 100%; height: 100%; object-fit: cover; transition: transform .6s ease; }
.gallery-item:hover img { transform: scale(1.06); }
.gallery-item figcaption {
  position: absolute; left: 14px; bottom: 12px; padding: 5px 12px; border-radius: 999px;
  font-size: .82rem; font-weight: 700; background: rgba(3, 18, 37, .7); backdrop-filter: blur(6px);
}
@media (max-width: 700px) {
  .gallery { grid-template-columns: 1fr; grid-auto-rows: 220px; }
  .gallery-item, .gallery-item-0, .gallery-item-1 { grid-column: auto; grid-row: span 1; }
}

/* Photo strip on the About page */
.tank-photos { display: grid; grid-template-columns: 2fr 1fr; grid-auto-rows: 200px; gap: 14px; margin: 8px 0 40px; }
.tank-photos figure { margin: 0; border-radius: 20px; overflow: hidden; background: var(--deep); }
.tank-photos figure:first-child { grid-row: span 2; }
.tank-photos img { width: 100%; height: 100%; object-fit: cover; }
@media (max-width: 700px) {
  .tank-photos { grid-template-columns: 1fr 1fr; grid-auto-rows: 150px; }
  .tank-photos figure:first-child { grid-column: span 2; grid-row: span 1; }
}

/* Meet the team, and the photo row under it */
.team-card {
  display: grid; grid-template-columns: 1.1fr 1fr; gap: 28px; align-items: center;
  padding: 18px; border-radius: 24px; background: #fff; box-shadow: var(--shadow);
}
.team-card figure { margin: 0; border-radius: 18px; overflow: hidden; }
.team-card img { width: 100%; height: auto; display: block; }
.team-card h3 { font-size: 1.6rem; margin: 0 0 4px; }
.team-card .team-where { margin: 0 0 12px; font-weight: 700; color: var(--lagoon-ink); }
.photo-row { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; margin: 22px 0 8px; }
.photo-row figure { margin: 0; }
.photo-row img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; border-radius: 16px; display: block; }
.photo-row figcaption { margin-top: 6px; font-size: .82rem; color: var(--ink-soft); }
.reach-box { margin: 32px 0 24px; padding: 20px 24px; border-radius: 24px; background: #fff; box-shadow: var(--shadow); }
.reach-box h2 { margin-top: 0; }
.reach-list { list-style: none; margin: 12px 0 0; padding: 0; }
.reach-list li { margin: 4px 0; }
@media (max-width: 700px) {
  .team-card { grid-template-columns: 1fr; gap: 16px; }
  .photo-row { grid-template-columns: 1fr 1fr; }
  .photo-row figure:first-child { grid-column: span 2; }
}

/* ---------- Beginner section ---------- */

.beginner-grid { display: grid; grid-template-columns: .9fr 1.1fr; gap: 48px; align-items: center; }
.beginner-copy h2 { font-size: clamp(2rem, 3.6vw, 2.8rem); }
.beginner-copy > p { color: var(--ink-soft); font-size: 1.05rem; }
.checklist, .beginner-copy ul { list-style: none; padding: 0; margin: 0 0 28px; display: grid; gap: 10px; }
.checklist li, .beginner-copy ul li { position: relative; padding-left: 34px; font-weight: 600; }
.checklist li::before, .beginner-copy ul li::before {
  content: "✓"; position: absolute; left: 0; top: 0; width: 24px; height: 24px; border-radius: 50%;
  display: grid; place-items: center; font-size: .8rem; color: var(--abyss); background: var(--glow);
}
@media (max-width: 900px) { .beginner-grid { grid-template-columns: 1fr; } }

/* ---------- Shipping steps ---------- */

.section-shipping { background: linear-gradient(160deg, var(--deep), var(--abyss)); color: #fff; }
.section-shipping .eyebrow { color: var(--glow); }
.steps { list-style: none; padding: 0; margin: 0 0 30px; display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 22px; }
.steps li { padding: 28px; border-radius: var(--radius); background: rgba(255, 255, 255, .06); border: 1px solid rgba(255, 255, 255, .1); }
.steps h3 { font-size: 1.4rem; margin: 14px 0 8px; }
.steps p { color: #b8d0e4; margin: 0; }
.step-num {
  display: grid; place-items: center; width: 46px; height: 46px; border-radius: 50%;
  font: 800 1.2rem var(--display); color: var(--abyss); background: linear-gradient(135deg, var(--glow), var(--sun));
}
.section-shipping .text-link { color: var(--glow); }

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

.prose-columns { display: grid; grid-template-columns: 1fr 1fr; gap: 48px; }
.prose-columns h2 { font-size: 1.8rem; }
.prose-columns p { color: var(--ink-soft); }
@media (max-width: 800px) { .prose-columns { grid-template-columns: 1fr; } }

.prose { font-size: 1.05rem; }
.prose h2 { font-size: 1.7rem; margin-top: 1.6em; }
.prose p, .prose li { color: var(--ink-soft); }
.prose ul, .prose ol { padding-left: 1.3em; margin: 0 0 1em; }
.prose li { margin-bottom: .4em; }

/* ---------- Page heroes, breadcrumbs ---------- */

.crumbs { padding-top: 18px; font-size: .86rem; }
.crumbs ol { display: flex; flex-wrap: wrap; gap: 6px; list-style: none; margin: 0; padding: 0; color: var(--muted); }
.crumbs li + li::before { content: "/"; margin-right: 6px; opacity: .5; }
.crumbs a { color: var(--ink-soft); text-decoration: none; }
.crumbs a:hover { color: var(--ocean); text-decoration: underline; }

.page-hero { padding: 36px 0 28px; }
.page-hero h1 { font-size: clamp(2.2rem, 5vw, 3.6rem); }
.lede { font-size: 1.15rem; color: var(--ink-soft); max-width: 62ch; }
.page-404 { padding: 90px 0; }
.page-404 .lede { margin-inline: auto; }
.search-big { display: flex; gap: 10px; max-width: 520px; margin: 24px auto; }
.search-big input { flex: 1; padding: 14px 20px; border-radius: 999px; border: 2px solid var(--line); background: #fff; }

/* ---------- Shop ---------- */

.shop-layout { display: grid; grid-template-columns: 260px 1fr; gap: 36px; align-items: start; padding-bottom: 72px; }
.filters { position: sticky; top: 90px; }
.results { min-width: 0; }   /* the phone's one-row type links scroll inside it instead of widening the page */
.filter-box { background: var(--paper); border-radius: var(--radius); padding: 18px 20px; box-shadow: var(--shadow); }
.filter-box summary { font-weight: 800; cursor: pointer; list-style: none; }
.filter-box summary::-webkit-details-marker { display: none; }
.filter-box fieldset { border: 0; padding: 0; margin: 18px 0; }
.filter-box legend { font-weight: 800; font-size: .8rem; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); margin-bottom: 8px; }
.filter-links { list-style: none; padding: 0; margin: 0; }
.filter-links a { display: flex; justify-content: space-between; padding: 6px 10px; border-radius: 8px; color: var(--ink); text-decoration: none; font-weight: 600; }
.filter-links a:hover { background: #eef3f7; }
.filter-links a[aria-current] { background: var(--deep); color: #fff; }
.filter-links small { color: inherit; opacity: .6; }
.check { display: flex; align-items: center; gap: 8px; padding: 4px 0; cursor: pointer; }
.check input { accent-color: var(--ocean); width: 17px; height: 17px; }
.field { display: grid; gap: 6px; margin: 0 0 16px; font-weight: 700; font-size: .92rem; }
.field small { font-weight: 500; color: var(--muted); }
.field input, .field select, .field textarea {
  width: 100%; padding: 11px 14px; border-radius: var(--radius-sm); border: 1.5px solid var(--line);
  background: #fff; font-weight: 500; transition: border-color .2s, box-shadow .2s;
}
.field input:focus, .field select:focus, .field textarea:focus { outline: none; border-color: var(--lagoon); box-shadow: 0 0 0 4px rgba(25, 182, 214, .18); }
.has-error input, .has-error textarea { border-color: var(--danger); }
.field-error { color: var(--danger); font-style: normal; font-size: .85rem; font-weight: 600; }
.result-count { color: var(--muted); font-weight: 600; margin-bottom: 14px; }
.pagination { display: flex; flex-wrap: wrap; gap: 8px; justify-content: center; margin: 36px 0; }
.pagination a, .pagination span { padding: 8px 14px; border-radius: 999px; background: var(--paper); text-decoration: none; font-weight: 700; box-shadow: var(--shadow); }
.pagination span { background: var(--deep); color: #fff; }
.category-intro { margin-top: 56px; padding: 32px; border-radius: var(--radius); background: var(--paper); box-shadow: var(--shadow); }
.category-intro h2 { margin-top: 0; }
.empty-state { text-align: center; padding: 56px 20px; }
.empty-state h2 { font-size: 2rem; }
.empty-guides { margin: 32px auto 0; max-width: 420px; text-align: left; }
.empty-guides h3 { font-size: 1.05rem; margin: 0 0 8px; }
.empty-guides ul { margin: 0; padding-left: 20px; }
.empty-guides i { color: var(--muted); }
.empty-popular { font-size: 1.4rem; margin: 8px 0 18px; }

/* "Shop by type" links above a category's listings */
.type-chips { display: flex; flex-wrap: wrap; gap: 8px; margin: 0 0 18px; }
.type-chips a {
  display: inline-flex; align-items: center; gap: 6px; padding: 7px 14px; border-radius: 999px;
  background: var(--paper); color: var(--ink); font-weight: 700; font-size: .9rem; text-decoration: none;
  box-shadow: inset 0 0 0 1.5px var(--line); white-space: nowrap;
}
.type-chips a:hover { box-shadow: inset 0 0 0 1.5px var(--lagoon); }
.type-chips a[aria-current] { background: var(--deep); color: #fff; box-shadow: none; }
.type-chips small { font-weight: 600; opacity: .6; }

@media (max-width: 860px) {
  .shop-layout { grid-template-columns: 1fr; }
  .filters { position: static; }
  .filter-box:not([open]) { padding: 14px 20px; }
  /* One swipeable row on phones instead of a block of wrapped chips */
  .type-chips { flex-wrap: nowrap; overflow-x: auto; margin-inline: -16px; padding: 2px 16px 6px; scrollbar-width: none; }
  .type-chips::-webkit-scrollbar { display: none; }
}

/* ---------- Product page ---------- */

.product { display: grid; grid-template-columns: 1.05fr .95fr; gap: 48px; padding: 28px 0 40px; align-items: start; }
.product-photo { position: relative; overflow: hidden; border-radius: 26px; box-shadow: var(--shadow-lg); background: var(--deep); }
.product-photo img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; transition: opacity .2s ease; }
.product-photo img.is-swapping { opacity: .35; }
.product-thumbs { display: flex; gap: 10px; list-style: none; padding: 4px 2px; margin: 14px 0 0; overflow-x: auto; scrollbar-width: thin; }
.product-thumbs a { display: block; width: 92px; flex: none; border-radius: 12px; overflow: hidden; border: 3px solid transparent; opacity: .75; transition: .2s; }
.product-thumbs a:hover, .product-thumbs a[aria-current="true"] { border-color: var(--lagoon); opacity: 1; }
.product-thumbs img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; }
.media-note { font-size: .82rem; color: var(--muted); margin-top: 10px; }
.photo-credit { font-size: .75rem; }
.photo-credit a { color: inherit; }
.product-info h1 { font-size: clamp(2.2rem, 4.4vw, 3.4rem); margin-bottom: .15em; }
.product-info .tags { margin: 14px 0 20px; }
.price-lg { font-size: 2rem; display: flex; align-items: center; flex-wrap: wrap; gap: 10px; margin-bottom: 16px; }
.price-lg .badge { font-size: .8rem; }
.buy-box { display: flex; flex-wrap: wrap; gap: 14px; align-items: center; margin: 22px 0 10px; }
.qty { display: inline-flex; align-items: center; border: 2px solid var(--line); border-radius: 999px; background: #fff; overflow: hidden; }
.qty button { width: 44px; height: 48px; border: 0; background: transparent; font-size: 1.3rem; font-weight: 700; cursor: pointer; color: var(--deep); }
.qty button:hover { background: #eef3f7; }
.qty input { width: 52px; height: 48px; border: 0; text-align: center; font-weight: 800; -moz-appearance: textfield; }
.qty input::-webkit-inner-spin-button, .qty input::-webkit-outer-spin-button { -webkit-appearance: none; }
.qty-sm button { width: 34px; height: 38px; }
.qty-sm input { width: 40px; height: 38px; }
.stock-note { font-weight: 700; color: var(--ok); }
.stock-note::before { content: "●"; margin-right: 8px; }
.stock-low { color: var(--warn); }
.stock-out { color: var(--danger); }
.stock-alert { margin: 4px 0 18px; padding: 14px 16px; border: 2px solid var(--line); border-radius: 14px; max-width: 460px; }
.stock-alert-row { display: flex; flex-wrap: wrap; gap: 8px; margin: 8px 0 6px; }
.stock-alert-row input { flex: 1 1 200px; min-width: 0; height: 44px; padding: 0 12px; border: 2px solid var(--line); border-radius: 10px; font: inherit; }
.stock-alert .small { margin: 0; }
.ship-ban { font-weight: 700; color: var(--warn); }
.cart-line-info .ship-ban { font-size: .88rem; }
.assurances { list-style: none; padding: 18px 0 0; margin: 18px 0 0; border-top: 1px solid var(--line); display: grid; gap: 8px; }
.assurances li { padding-left: 28px; position: relative; font-weight: 600; color: var(--ink-soft); }
.assurances li::before { content: "✓"; position: absolute; left: 0; color: var(--ok); font-weight: 800; }

.product-details { display: grid; grid-template-columns: 1.3fr .7fr; gap: 48px; padding: 20px 0 48px; align-items: start; }
.product-details .prose h2 { margin-top: 0; }
.spec-card { padding: 26px; border-radius: var(--radius); background: var(--deep); color: #fff; box-shadow: var(--shadow-lg); }
.spec-card h2 { font-size: 1.5rem; }
.specs { display: grid; grid-template-columns: auto 1fr; gap: 10px 18px; margin: 0; }
.specs dt { color: #8fb1cc; font-size: .88rem; font-weight: 600; }
.specs dd { margin: 0; font-weight: 700; }
.section-related { background: #eaf6f8; }

@media (max-width: 900px) {
  .product, .product-details { grid-template-columns: 1fr; gap: 28px; }
}

/* ---------- Cart & checkout ---------- */

.cart-layout { display: grid; grid-template-columns: 1fr 380px; gap: 36px; align-items: start; padding-bottom: 72px; }
.cart-lines, .checkout-form, .order-card { background: var(--paper); border-radius: var(--radius); padding: 10px 24px 24px; box-shadow: var(--shadow); }
.cart-line { display: grid; grid-template-columns: 96px 1fr auto auto auto; gap: 16px; align-items: center; padding: 18px 0; border-bottom: 1px solid var(--line); }
.cart-thumb img { border-radius: 12px; width: 96px; aspect-ratio: 4 / 3; object-fit: cover; }
.cart-line-info { display: grid; }
.cart-line-info a { color: var(--ink); text-decoration: none; }
.cart-line-info .sci { margin: 0; }
.cart-line-total { font-weight: 800; min-width: 80px; text-align: right; }
.link-remove { border: 0; background: none; color: var(--muted); cursor: pointer; text-decoration: underline; font-size: .85rem; }
.link-remove:hover { color: var(--danger); }
.cart-actions { display: flex; justify-content: space-between; align-items: center; padding-top: 18px; gap: 12px; flex-wrap: wrap; }

.summary { position: sticky; top: 90px; background: var(--paper); border-radius: var(--radius); padding: 24px; box-shadow: var(--shadow); }
.summary h2 { font-size: 1.5rem; }
.totals { display: grid; grid-template-columns: 1fr auto; gap: 10px; margin: 18px 0; }
.totals dt { color: var(--ink-soft); }
.totals dd { margin: 0; font-weight: 700; text-align: right; }
.totals .grand { padding-top: 12px; border-top: 1px solid var(--line); font-size: 1.25rem; font-weight: 800; color: var(--ink); }
.free-ship { padding: 14px; border-radius: 12px; background: #eaf6f8; font-size: .92rem; }
.free-ship p { margin: 0 0 8px; }
.free-ship-done { color: #0b6e4f; background: #e2f7ee; font-weight: 700; margin: 0; }
.meter { height: 8px; border-radius: 999px; background: #d5e6ee; overflow: hidden; }
.meter span { display: block; height: 100%; border-radius: inherit; background: linear-gradient(90deg, var(--lagoon), var(--glow)); }
.summary-lines { list-style: none; padding: 0; margin: 0; }
.summary-lines li { display: grid; grid-template-columns: 64px 1fr auto; gap: 12px; align-items: center; padding: 8px 0; }
.summary-lines img { border-radius: 8px; }
.summary-lines small { color: var(--muted); }

.checkout-form fieldset { border: 0; padding: 0; margin: 18px 0 8px; }
.checkout-form legend { font: 800 1.35rem var(--display); margin-bottom: 14px; }
.field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.field-row-3 { grid-template-columns: 2fr 1fr 1fr; }
.order-table { width: 100%; border-collapse: collapse; margin: 10px 0; }
.order-table th, .order-table td { text-align: left; padding: 10px 6px; border-bottom: 1px solid var(--line); }
.order-table td:last-child, .order-table th:last-child { text-align: right; }
.summary address { font-style: normal; margin-bottom: 14px; line-height: 1.7; }

@media (max-width: 900px) {
  .cart-layout { grid-template-columns: 1fr; }
  .summary { position: static; }
  .cart-line { grid-template-columns: 72px 1fr auto; }
  .cart-thumb img { width: 72px; }
  .cart-line .qty { grid-column: 2; }
  .cart-line-total { grid-column: 3; grid-row: 1; }
  .link-remove { grid-column: 3; justify-self: end; }
}
@media (max-width: 560px) { .field-row, .field-row-3 { grid-template-columns: 1fr; } }

/* ---------- FAQ & contact ---------- */

.faq-list { display: grid; gap: 12px; margin-bottom: 40px; }
.faq { background: var(--paper); border-radius: var(--radius); box-shadow: var(--shadow); padding: 4px 24px; }
.faq summary { list-style: none; cursor: pointer; display: flex; justify-content: space-between; align-items: center; gap: 16px; padding: 16px 0; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary h2 { font: 700 1.1rem/1.4 var(--body); margin: 0; }
.faq summary::after { content: "+"; font-size: 1.6rem; font-weight: 400; color: var(--ocean); transition: transform .2s; }
.faq[open] summary::after { transform: rotate(45deg); }
.faq p { color: var(--ink-soft); padding-bottom: 12px; }
.contact-layout { display: grid; grid-template-columns: 1fr 300px; gap: 28px; align-items: start; padding-bottom: 72px; }
.contact-layout .checkout-form { padding-top: 24px; }
@media (max-width: 800px) { .contact-layout { grid-template-columns: 1fr; } }

/* ---------- Footer ---------- */

.site-footer { position: relative; margin-top: 60px; color: #b8d0e4; background: var(--abyss); padding: 40px 0 24px; }
.footer-wave { position: absolute; top: -79px; left: 0; width: 100%; height: 80px; fill: var(--abyss); }
.footer-grid { display: grid; grid-template-columns: 1.6fr 1fr 1fr 1fr; gap: 36px; padding-bottom: 36px; }
.footer-brand p { max-width: 36ch; margin-top: 14px; }
.site-footer h2 { font: 800 .8rem var(--body); letter-spacing: .14em; text-transform: uppercase; color: var(--glow); }
.site-footer ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.site-footer a { color: #e7f4ff; text-decoration: none; }
.site-footer a:hover { color: var(--glow); }
.site-footer address { font-style: normal; margin-bottom: 1em; }
.footer-bottom { border-top: 1px solid rgba(255, 255, 255, .1); padding-top: 20px; color: #6c8aa3; display: flex; flex-wrap: wrap; align-items: center; gap: 8px 32px; }
.footer-legal { display: flex; flex-wrap: wrap; gap: 4px 20px; font-size: .875rem; }
.footer-legal a { display: inline-block; padding: 6px 0; }
@media (max-width: 800px) { .footer-grid { grid-template-columns: 1fr 1fr; } .footer-brand { grid-column: 1 / -1; } }

/* ---------- Toast ---------- */

.toast {
  position: fixed; left: 50%; bottom: 24px; z-index: 100; transform: translateX(-50%);
  padding: 14px 22px; border-radius: 999px; font-weight: 700; color: #fff; background: var(--deep);
  box-shadow: var(--shadow-lg); animation: toast-in .25s ease;
  max-width: calc(100% - 32px);
}
.toast a { color: var(--glow); margin-left: 8px; }
.toast.error { background: var(--danger); }
@keyframes toast-in { from { opacity: 0; transform: translate(-50%, 12px); } }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; scroll-behavior: auto !important; }
}

/* ==========================================================================
   Species guide, tree of life and compare
   ========================================================================== */

:root {
  --branch-fish: #19b6d6;
  --branch-coral: #ff6f59;
  --branch-invert: #e9a800;
  --branch-plant: #4cbf56;
  --branch-mixed: #7d93a8;
}
.lg-fish, .tnode-fish, .tleaf-fish, .dn-fish { --b: var(--branch-fish); }
.lg-coral, .tnode-coral, .tleaf-coral, .dn-coral { --b: var(--branch-coral); }
.lg-invert, .tnode-invert, .tleaf-invert, .dn-invert { --b: var(--branch-invert); }
.lg-plant, .tnode-plant, .tleaf-plant, .dn-plant { --b: var(--branch-plant); }
.tnode-mixed, .dn-mixed { --b: var(--branch-mixed); }

@media (min-width: 1061px) {
  .main-nav .nav-phone-only { display: none; }
}

/* ---------- "Shop all" menu: kinds of animal per category, and shortcuts ---------- */

.nav-shop { position: relative; display: flex; align-items: center; }
.nav-more {
  display: grid; place-items: center; width: 26px; height: 26px; margin-left: -4px; padding: 0;
  border: 0; border-radius: 50%; background: none; color: #cfe3f5; cursor: pointer;
}
.nav-more:hover, .nav-shop.open .nav-more { color: #fff; background: rgba(95, 242, 231, .12); }
.nav-more svg { transition: transform .2s; }
.nav-shop.open .nav-more svg { transform: rotate(180deg); }
.mega { display: none; }
.main-nav .mega ul { display: block; }
.mega-head { margin: 0 0 6px; font-size: .74rem; font-weight: 800; letter-spacing: .1em; text-transform: uppercase; color: var(--glow); }
.main-nav .mega a { padding: 5px 0; border-radius: 0; background: none; font-size: .93rem; }
.main-nav .mega a:hover { color: #fff; text-decoration: underline; text-underline-offset: 3px; }
.main-nav .mega-head a { padding: 0; color: inherit; font-size: inherit; }

@media (min-width: 1061px) {
  .mega {
    display: grid; position: absolute; top: 100%; left: -12px; z-index: 60; margin-top: 14px;
    grid-template-columns: repeat(4, minmax(140px, auto)); gap: 8px 32px; width: max-content; max-width: min(860px, 92vw);
    padding: 22px 28px; border-radius: var(--radius); background: var(--abyss);
    border: 1px solid rgba(95, 242, 231, .18); box-shadow: var(--shadow-lg);
    visibility: hidden; opacity: 0; transform: translateY(-6px); transition: opacity .15s, transform .15s, visibility 0s .15s;
  }
  .mega::before { content: ""; position: absolute; left: 0; right: 0; top: -16px; height: 16px; }   /* keeps the hover across the gap */
  .nav-shop.open .mega { visibility: visible; opacity: 1; transform: none; transition-delay: 0s; }
}
/* Mouse users get it on hover, after a short pause so passing over "Shop all" doesn't flash it */
@media (min-width: 1061px) and (hover: hover) {
  .nav-shop:hover:not(.hush) .mega { visibility: visible; opacity: 1; transform: none; transition-delay: .12s; }
}
@media (max-width: 1060px) {
  .main-nav { max-height: calc(100dvh - 72px); overflow-y: auto; overscroll-behavior: contain; }
  .nav-shop { flex-wrap: wrap; }
  .nav-shop > a { flex: 1; }
  .nav-more { width: 46px; height: 46px; margin: 0; }
  .nav-shop.open .mega { display: grid; flex-basis: 100%; grid-template-columns: 1fr 1fr; gap: 14px 20px; padding: 6px 14px 14px; }
  .main-nav .mega a { font-size: 1rem; padding: 6px 0; white-space: normal; }
}

/* ---------- Search suggestions (site.js) ---------- */

.has-suggest { position: relative; }
.suggest {
  position: absolute; top: calc(100% + 8px); right: 0; z-index: 70; width: min(420px, calc(100vw - 32px));
  max-height: min(70vh, 560px); overflow-y: auto; padding: 6px; border-radius: var(--radius);
  background: var(--paper); color: var(--ink); border: 1px solid var(--line); box-shadow: var(--shadow-lg); text-align: left;
}
.suggest-head { margin: 8px 10px 4px; font-size: .72rem; font-weight: 800; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); }
.suggest .suggest-item {
  display: flex; align-items: center; gap: 12px; padding: 8px 10px; border-radius: var(--radius-sm);
  color: var(--ink); background: none; font-size: .95rem; font-weight: 500; text-decoration: none; white-space: normal;
}
.suggest .suggest-item:hover, .suggest .suggest-item[aria-selected="true"] { color: var(--ink); background: #e9f4f8; }
.suggest-item img { flex-shrink: 0; width: 48px; height: 36px; object-fit: cover; border-radius: 6px; background: var(--deep); }
.suggest-text { display: grid; flex: 1; min-width: 0; line-height: 1.3; }
.suggest-name, .suggest-sci { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.suggest-name { font-weight: 700; }
.suggest-sci, .suggest-count { color: var(--muted); font-size: .82rem; }
.suggest-price { font-weight: 800; white-space: nowrap; }
.suggest-type .suggest-name, .suggest-guide .suggest-text { flex: 1; }
.suggest .suggest-all { justify-content: center; margin-top: 4px; font-weight: 700; color: var(--lagoon-ink); }
/* Phone menu: search comes first, and its suggestions push the links down (the menu scrolls, so a
   floating list would be cut off) */
@media (max-width: 1060px) {
  .nav-search { order: -1; }
  .nav-search .suggest { position: static; width: auto; max-height: none; margin-top: 8px; box-shadow: none; }
}

/* Header: one more nav item between the desktop breakpoint and full width */
@media (min-width: 1061px) and (max-width: 1320px) {
  .header-inner { gap: 12px; }
  .main-nav { gap: 10px; }
  .main-nav a { padding: 8px 9px; font-size: .9rem; }
  .nav-more { width: 22px; margin-left: -6px; }
  .nav-search input { width: 136px; padding-inline: 14px; }
}

/* ---------- Tones shared by chips and tags ---------- */

.chip-care-easy, .chip-reef-yes, .chip-temper-peaceful, .chip-iucn-least-concern { --tone: #34d399; --tone-ink: #0b6e4f; --tone-bg: #e2f7ee; }
.chip-care-moderate, .chip-reef-with-caution, .chip-temper-semi-aggressive, .chip-iucn-near-threatened, .chip-iucn-data-deficient { --tone: #fbbf24; --tone-ink: #8a5300; --tone-bg: #fff3db; }
.chip-care-expert, .chip-reef-no, .chip-temper-aggressive, .chip-iucn-vulnerable, .chip-iucn-endangered, .chip-iucn-critically-endangered { --tone: #fb7185; --tone-ink: #a3271a; --tone-bg: #fde6e3; }
.tag-danger, .tag-temper-aggressive { background: #fde6e3; color: #a3271a; }
.tag-temper-peaceful { background: #e2f7ee; color: #0b6e4f; }
.tag-temper-semi-aggressive { background: #fff3db; color: #8a5300; }

.chips { display: flex; flex-wrap: wrap; gap: 8px; list-style: none; padding: 0; margin: 20px 0 24px; }
.chip {
  display: inline-grid; gap: 1px; padding: 7px 14px; border-radius: 14px; line-height: 1.3;
  background: rgba(255, 255, 255, .08); border: 1px solid rgba(255, 255, 255, .16);
}
.chip > span { font-size: .66rem; font-weight: 800; letter-spacing: .12em; text-transform: uppercase; color: #8fb1cc; }
.chip > strong { font-size: .95rem; color: #fff; }
.chip[class*=" chip-"] > strong::before {
  content: ""; display: inline-block; width: 8px; height: 8px; margin-right: 7px; border-radius: 50%;
  vertical-align: 1px; background: var(--tone, transparent);
}
.chips-light .chip, .chip-inline { background: var(--tone-bg, #eef3f7); border-color: transparent; }
.chips-light .chip > span, .chip-inline > span { color: var(--muted); }
.chips-light .chip > strong, .chip-inline > strong { color: var(--tone-ink, var(--ink)); }
.chips-light .chip[class*=" chip-"] > strong::before, .chip-inline[class*=" chip-"] > strong::before { display: none; }
/* Small print under a chip value (why the temperament) and a short list value (favorite foods). */
.chip-note { max-width: 24ch; font-size: .76rem; font-weight: 600; line-height: 1.3; color: #b9d0e2; }
.chips-light .chip-note, .chip-inline .chip-note { color: var(--muted); }
.chip-list { margin: 1px 0 0; padding-left: 1.15em; font-size: .9rem; font-weight: 700; line-height: 1.35; color: #fff; }
.chips-light .chip-list { color: var(--ink); }
/* "!" on a care fact outside sources don't settle (fact_flag()); the hover text says why. */
.chip-flagged { position: relative; padding-right: 30px; }
.fact-flag {
  display: inline-grid; place-items: center; width: 17px; height: 17px; border-radius: 50%;
  background: #fbbf24; color: #5c3a00; font-size: .72rem; font-weight: 900; line-height: 1; cursor: help;
}
.chip-flagged > .fact-flag { position: absolute; top: 6px; right: 7px; }
.specs dd .fact-flag { margin-left: 8px; vertical-align: 1px; }
.fact-flag:focus-visible { outline: 2px solid var(--deep, #0b3954); outline-offset: 2px; }
@media (hover: none) {
  .fact-flag { position: relative; }
  .fact-flag:focus::after {
    content: attr(data-tip); position: absolute; z-index: 5; top: 22px; right: 0; width: max-content; max-width: 220px;
    padding: 6px 9px; border-radius: 8px; background: #102a43; color: #fff; font-size: .78rem; font-weight: 600; line-height: 1.35;
    text-align: left; white-space: normal;
  }
  .chip-flagged > .fact-flag { position: absolute; }
}

/* ---------- Guide listing ---------- */

.guide-links { display: flex; flex-wrap: wrap; gap: 10px; list-style: none; padding: 0; margin: 20px 0 0; }
.card-eyebrow { margin: 0 0 4px; font-size: .7rem; font-weight: 800; letter-spacing: .12em; text-transform: uppercase; color: var(--ocean); }
.species-card-coral .card-eyebrow { color: #d2452f; }
.species-card-invert .card-eyebrow { color: #9a6a00; }
.species-card-plant .card-eyebrow { color: #2f8a38; }
.card-text { font-size: .9rem; color: var(--ink-soft); margin: 0 0 12px; }

/* ---------- Species page ---------- */

.admin-strip {
  margin-top: 14px; padding: 10px 16px; border-radius: var(--radius-sm); font-size: .9rem; font-weight: 600;
  background: #fff5e0; border: 1px solid #ffd98a; color: #8a5300;
}
.admin-strip a { font-weight: 800; }

.species-hero {
  margin-top: 16px; padding: 44px 0 48px; color: #e7f4ff;
  background:
    radial-gradient(90% 120% at 90% 0%, rgba(25, 182, 214, .35), transparent 60%),
    linear-gradient(160deg, var(--deep), var(--abyss));
}
.species-hero-coral {
  background:
    radial-gradient(90% 120% at 90% 0%, rgba(255, 111, 89, .3), transparent 60%),
    linear-gradient(160deg, #24195a, var(--abyss));
}
.species-hero-invert {
  background:
    radial-gradient(90% 120% at 90% 0%, rgba(255, 200, 69, .26), transparent 60%),
    linear-gradient(160deg, #10384a, var(--abyss));
}
.species-hero-plant {
  background:
    radial-gradient(90% 120% at 90% 0%, rgba(110, 220, 120, .26), transparent 60%),
    linear-gradient(160deg, #0f3d34, var(--abyss));
}
.species-hero-inner { display: grid; grid-template-columns: 1.15fr .85fr; gap: 44px; align-items: center; }
.species-hero h1 { font-size: clamp(2.3rem, 5.4vw, 4rem); font-weight: 800; color: #fff; margin-bottom: .12em; text-wrap: balance; }
.species-hero .eyebrow, .species-hero .eyebrow a { color: var(--glow); }
.species-sci { margin: 0 0 8px; font-size: 1.25rem; color: #cfe3f5; }
.authority { font-size: .92rem; color: #8fb1cc; }
.aka { margin: 0; color: #a9c4da; font-size: .95rem; }
.reviewed-by { margin-top: 4px; }
.reviewed-by a { color: inherit; text-decoration: underline; }
.species-hero .btn small { font-weight: 600; opacity: .75; }
.species-hero-media { margin: 0; }
.species-hero-media img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; border-radius: 24px; box-shadow: var(--shadow-lg); background: var(--deep); }
.species-hero-media figcaption { margin-top: 8px; font-size: .8rem; color: #8fb1cc; }
@media (max-width: 860px) {
  .species-hero { padding: 28px 0 34px; }
  .species-hero-inner { grid-template-columns: 1fr; gap: 22px; }
  .species-hero-media { order: -1; max-width: 520px; }
}

.species-intro { display: grid; gap: 22px; padding: 30px 0 26px; }
.eli8 {
  padding: 26px 30px 12px; border-radius: var(--radius); box-shadow: var(--shadow);
  border: 2px solid transparent;
  background: linear-gradient(135deg, #fffdf5, #effcfb) padding-box, linear-gradient(120deg, var(--glow), var(--sun)) border-box;
}
.eli8 h2 { display: flex; align-items: center; gap: 10px; font-size: 1.7rem; color: var(--deep); }
.eli8 h2 svg { flex-shrink: 0; color: var(--lagoon); }
.eli8 p { max-width: 68ch; font-size: 1.2rem; line-height: 1.7; color: var(--ink); }
.sci-desc { padding: 26px 30px; border-radius: var(--radius); background: var(--paper); box-shadow: var(--shadow); }
.sci-desc h2 { font-size: 1.7rem; }
.sci-desc .prose { max-width: 78ch; font-size: 1rem; }
.facts {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 14px 30px;
  margin: 18px 0 0; padding-top: 18px; border-top: 1px solid var(--line);
}
.facts dt { margin-bottom: 2px; font-size: .7rem; font-weight: 800; letter-spacing: .12em; text-transform: uppercase; color: var(--ocean); }
.facts dd { margin: 0; font-size: .95rem; color: var(--ink-soft); }
.facts-tight { margin: 4px 0 8px; padding-top: 0; border-top: 0; }

.species-layout { display: grid; grid-template-columns: 230px minmax(0, 1fr); gap: 36px; align-items: start; padding-bottom: 40px; }
.species-toc {
  position: sticky; top: 92px; max-height: calc(100vh - 110px); overflow: auto;
  padding: 18px 14px; border-radius: var(--radius); background: var(--paper); box-shadow: var(--shadow);
}
.species-toc .toc-group { margin: 10px 0 2px 10px; padding-top: 10px; border-top: 1px solid var(--line); font-size: .7rem; font-weight: 800; letter-spacing: .12em; text-transform: uppercase; color: var(--muted); }
.quick-answers { padding: 26px 30px; border-radius: var(--radius); background: var(--paper); box-shadow: var(--shadow); scroll-margin-top: 96px; }
.quick-answers h2 { font-size: 1.7rem; }
.quick-answers dl { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 14px 28px; margin: 0; }
.quick-answers dt { font-weight: 800; color: var(--ink); }
.quick-answers dd { margin: 2px 0 0; color: var(--ink-soft); }
.quick-answers dd ul { margin: 2px 0 0; padding-left: 1.1em; }
.deep-dive-title { margin: 22px 0 -6px; padding-top: 18px; border-top: 2px solid var(--line); font-size: clamp(1.6rem, 3vw, 2.1rem); scroll-margin-top: 96px; }
.deep-dive-title small { display: block; margin-top: 4px; font: 600 .95rem/1.4 var(--body); color: var(--muted); }
.toc-title { margin: 0 0 8px 10px; font-size: .74rem; font-weight: 800; letter-spacing: .14em; text-transform: uppercase; color: var(--muted); }
.species-toc ol { display: grid; gap: 2px; list-style: none; margin: 0; padding: 0; }
.species-toc a { display: block; padding: 6px 10px; border-radius: 8px; font-size: .92rem; font-weight: 600; color: var(--ink-soft); text-decoration: none; }
.species-toc a:hover { background: #eef3f7; color: var(--ink); }
.species-toc a[aria-current] { background: var(--deep); color: #fff; }

.species-sections { display: grid; gap: 22px; min-width: 0; }
.sp-section { padding: 26px 30px; border-radius: var(--radius); background: var(--paper); box-shadow: var(--shadow); scroll-margin-top: 96px; }
.sp-section h2 { font-size: clamp(1.5rem, 3vw, 2rem); }
.sp-section h3 { margin: 20px 0 8px; font: 800 1rem/1.3 var(--body); color: var(--ink); }
.sp-section p, .sp-section li, .sp-section dd { color: var(--ink-soft); }
.sp-section > p:last-child { margin-bottom: 0; }
.note { margin: 12px 0 0; font-size: .88rem; color: var(--muted); }
.section-chip { display: flex; flex-wrap: wrap; gap: 8px; margin: 0 0 12px; }
#shop { scroll-margin-top: 80px; }

@media (max-width: 900px) {
  .species-layout { grid-template-columns: 1fr; gap: 16px; }
  .species-toc {
    top: 70px; z-index: 20; max-height: none; margin: 0 -16px; padding: 8px 16px; border-radius: 0;
    background: rgba(247, 243, 236, .96); backdrop-filter: blur(8px); box-shadow: 0 8px 16px -12px rgba(3, 18, 37, .4);
  }
  .toc-title { display: none; }
  .species-toc ol { display: flex; gap: 6px; overflow-x: auto; scrollbar-width: none; }
  .species-toc ol::-webkit-scrollbar { display: none; }
  .species-toc li { flex: 0 0 auto; }
  .species-toc .toc-group { margin: 0; padding: 6px 2px 6px 8px; border: 0; align-self: center; }
  .quick-answers, .deep-dive-title { scroll-margin-top: 130px; }
  .species-toc a { white-space: nowrap; padding: 6px 12px; border: 1px solid var(--line); border-radius: 999px; background: var(--paper); font-size: .85rem; }
  .sp-section { scroll-margin-top: 130px; }
}
@media (max-width: 560px) {
  .eli8, .quick-answers, .sci-desc, .sp-section { padding: 20px 18px; }
  .eli8 p { font-size: 1.1rem; }
}

/* Water parameter table with range bars */
.params { width: 100%; border-collapse: collapse; margin: 6px 0 4px; }
.params th, .params td { padding: 12px 8px; text-align: left; vertical-align: middle; border-bottom: 1px solid var(--line); }
.params thead th { padding-top: 0; font-size: .72rem; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); }
.params tbody th { font-weight: 700; }
.sp-section .param-value { font-weight: 800; white-space: nowrap; color: var(--ink); }
.param-bar { width: 44%; }
.range { position: relative; display: block; height: 10px; border-radius: 999px; background: linear-gradient(90deg, #e5eef4, #d4e5ef); }
.range-fill {
  position: absolute; top: 0; bottom: 0; min-width: 10px; border-radius: 999px;
  background: linear-gradient(90deg, var(--lagoon), var(--glow));
}
.range-point .range-fill { min-width: 0; }
.range-point .range-fill::after {
  content: ""; position: absolute; left: -6px; top: -4px; width: 12px; height: 18px; border-radius: 4px;
  background: var(--ocean); box-shadow: 0 0 0 2px #fff;
}
.range-scale { display: flex; justify-content: space-between; margin-top: 4px; font-size: .72rem; color: var(--muted); }
@media (max-width: 600px) {
  .params thead { display: none; }
  .params tr { display: grid; grid-template-columns: 1fr auto; border-bottom: 1px solid var(--line); }
  .params th, .params td { border-bottom: 0; }
  .params td.param-bar { grid-column: 1 / -1; width: auto; padding-top: 0; }
}

/* Lists inside sections */
.food-list { display: flex; flex-wrap: wrap; gap: 8px; list-style: none; padding: 0; margin: 0 0 16px; }
.sp-section .food-list li { padding: 7px 14px; border-radius: 999px; font-size: .9rem; font-weight: 700; background: #e6f7f1; color: #0b6e4f; }
.sp-section .checklist { margin-bottom: 0; }
.sp-section .checklist li { font-weight: 500; }

.risk-list { display: grid; gap: 10px; list-style: none; padding: 0; margin: 0; }
.sp-section .risk-list li { position: relative; padding: 12px 14px 12px 46px; border-radius: 12px; background: #fff6ea; color: #6b3d00; }
.risk-list li::before {
  content: "!"; position: absolute; left: 14px; top: 12px; width: 22px; height: 22px; border-radius: 50%;
  display: grid; place-items: center; font-size: .8rem; font-weight: 800; color: #fff; background: var(--warn);
}

.sp-section .faq-list { margin-bottom: 0; }
.ailments .faq { box-shadow: none; border: 1px solid var(--line); }
.sp-section .faq summary h3 { margin: 0; font: 700 1.05rem/1.4 var(--body); }
.ailment { display: grid; gap: 10px; margin: 0 0 16px; }
.ailment div { padding: 10px 14px; border-radius: 10px; background: #f5f8fa; }
.ailment dt { margin-bottom: 2px; font-size: .7rem; font-weight: 800; letter-spacing: .12em; text-transform: uppercase; }
.ailment dd { margin: 0; }
.ailment-signs dt { color: var(--warn); }
.ailment-prevention dt { color: var(--ok); }
.ailment-treatment dt { color: var(--ocean); }

.two-up { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; }
.compat { margin-top: 8px; }
.compat h3 { margin-top: 0; }
.compat ul { display: grid; gap: 6px; list-style: none; padding: 0; margin: 0; }
.compat li { position: relative; padding-left: 26px; }
.compat-good li::before { content: "✓"; position: absolute; left: 3px; font-weight: 800; color: var(--ok); }
.compat-avoid li::before { content: "✕"; position: absolute; left: 3px; font-weight: 800; color: var(--danger); }
.role-card { padding: 18px 20px; border-radius: 14px; background: #edf6fb; }
.role-wild { background: #eef7ee; }
.role-card h3 { margin-top: 0; }
.role-card p:last-child { margin-bottom: 0; }
@media (max-width: 700px) { .two-up { grid-template-columns: 1fr; gap: 14px; } }

.step-list { display: grid; gap: 12px; list-style: none; counter-reset: step; padding: 0; margin: 14px 0 0; }
.step-list li { position: relative; min-height: 30px; padding-left: 44px; counter-increment: step; }
.step-list li::before {
  content: counter(step); position: absolute; left: 0; top: -2px; width: 30px; height: 30px; border-radius: 50%;
  display: grid; place-items: center; font-size: .85rem; font-weight: 800; color: var(--abyss);
  background: linear-gradient(135deg, var(--glow), var(--sun));
}

.lineage-trail { position: relative; list-style: none; margin: 8px 0 22px; padding: 0 0 0 24px; }
.lineage-trail::before {
  content: ""; position: absolute; left: 7px; top: 12px; bottom: 12px; width: 2px; border-radius: 2px;
  background: linear-gradient(var(--lagoon), var(--glow));
}
.lineage-trail li { position: relative; display: flex; flex-wrap: wrap; align-items: baseline; gap: 2px 10px; padding: 6px 0; }
.lineage-trail li::before {
  content: ""; position: absolute; left: -22px; top: 12px; width: 12px; height: 12px; border-radius: 50%;
  background: var(--paper); border: 2px solid var(--lagoon);
}
.lineage-trail .is-minor { padding: 1px 0; font-size: .84rem; }
.lineage-trail .is-minor::before { left: -20px; top: 7px; width: 8px; height: 8px; border-color: #b7cddb; }
.lineage-trail .is-minor .lt-name { font-weight: 500; color: var(--muted); }
.lt-rank { min-width: 96px; font-size: .68rem; font-weight: 800; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); }
.lt-name { font-weight: 700; color: var(--ink); }
.lt-common { color: var(--ink-soft); }
.lt-blurb { flex-basis: 100%; padding-left: 106px; font-size: .88rem; color: var(--muted); }
.lineage-trail .is-self::before { background: var(--glow); border-color: var(--ocean); }
.lineage-trail .is-self .lt-name { font-size: 1.1rem; color: var(--ocean); }
@media (max-width: 560px) {
  .lt-rank { min-width: 0; flex-basis: 100%; }
  .lt-blurb { padding-left: 0; }
}
.tree-links { display: flex; flex-wrap: wrap; gap: 10px; margin: 6px 0 8px; }

.relatives { display: grid; gap: 10px; list-style: none; padding: 0; margin: 0; }
.relatives li { display: grid; gap: 2px; padding: 12px 16px; border-radius: 12px; background: #f5f8fa; }
.rel-name i { font-weight: 700; color: var(--ink); }
.rel-relation { font-size: .9rem; color: var(--muted); }
.rel-links { font-size: .9rem; font-weight: 700; }

.fun-facts { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 14px; list-style: none; counter-reset: fact; padding: 0; margin: 0; }
.sp-section .fun-facts li {
  position: relative; padding: 46px 18px 18px; border-radius: 14px; counter-increment: fact;
  font-weight: 600; color: var(--ink); background: linear-gradient(160deg, #e8faf9, #fff6df);
}
.fun-facts li::before { content: counter(fact); position: absolute; top: 10px; left: 18px; font: 800 1.5rem var(--display); color: var(--lagoon); }

.link-list, .source-list { display: grid; gap: 8px; margin: 0; padding-left: 1.3em; }
.link-list small, .source-list small { margin-left: 4px; color: var(--muted); }
.source-list { font-size: .92rem; }

/* ---------- Care at a glance (product page) ---------- */

.care-glance { padding-bottom: 24px; }
.glance-card {
  display: grid; grid-template-columns: 210px minmax(0, 1fr); gap: 12px 28px; align-items: start;
  padding: 24px 26px; border-radius: var(--radius); border: 1px solid #d6edf1;
  background: linear-gradient(135deg, #fff, #eefaf9); box-shadow: var(--shadow);
}
.glance-head h2 { margin: 0; font-size: 1.6rem; }
.glance-card .chips { margin: 0; }
.glance-eli8, .glance-card > p:last-child { grid-column: 2; }
.glance-eli8 { margin: 0; padding: 12px 16px; border-left: 4px solid var(--sun); border-radius: 0 10px 10px 0; background: #fffaeb; }
.glance-eli8 p { margin: 0; color: var(--ink); }
.glance-label { font-weight: 800; color: var(--deep); }
.glance-card > p:last-child { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 18px; margin: 0; }
@media (max-width: 800px) {
  .glance-card { grid-template-columns: 1fr; padding: 20px 18px; }
  .glance-eli8, .glance-card > p:last-child { grid-column: auto; }
}

/* ---------- Tree of life ---------- */

.tree-hero .lede { max-width: 72ch; }
.tree-legend { display: flex; flex-wrap: wrap; gap: 8px 20px; list-style: none; padding: 0; margin: 16px 0 0; font-size: .92rem; font-weight: 700; }
.tree-legend li::before {
  content: ""; display: inline-block; width: 12px; height: 12px; margin-right: 8px; border-radius: 50%;
  vertical-align: -1px; background: var(--b);
}
.tree-legend small { color: var(--muted); font-weight: 600; }
.tree-wrap { padding-bottom: 40px; }
.tree-focus a { font-weight: 800; }

.tree-outline { margin-top: 22px; padding: 20px 22px; border-radius: var(--radius); background: var(--paper); box-shadow: var(--shadow); }
.tree-outline-title { margin-bottom: 12px; font: 800 1.15rem var(--body); }
.tree-outline-title small { font-weight: 500; font-size: .85rem; color: var(--muted); }
.t-root, .t-children { list-style: none; margin: 0; padding: 0; }
.t-children { margin-left: 13px; padding-left: 12px; border-left: 2px solid var(--b, var(--line)); }
.tnode > summary {
  display: flex; flex-wrap: wrap; align-items: baseline; gap: 2px 8px; padding: 6px 8px; border-radius: 8px;
  list-style: none; cursor: pointer;
}
.tnode > summary::-webkit-details-marker { display: none; }
.tnode > summary::before { content: "▸"; display: inline-block; width: 12px; color: var(--b); transition: transform .15s; }
.tnode[open] > summary::before { transform: rotate(90deg); }
.tnode > summary:hover { background: #f0f5f8; }
.tnode.on-path > summary { background: #fff7de; }
.t-rank { font-size: .64rem; font-weight: 800; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); }
.t-name { font-weight: 800; }
.t-common { font-size: .92rem; color: var(--ink-soft); }
.t-count {
  margin-left: auto; min-width: 28px; padding: 1px 8px; border-radius: 999px; text-align: center;
  font-size: .74rem; font-weight: 800; background: #eef3f7; color: var(--ink-soft);
}
.t-blurb { max-width: 72ch; margin: 0 0 6px 28px; font-size: .88rem; color: var(--muted); }
.t-via { display: block; font-size: .8rem; font-style: italic; }
.tleaf {
  display: flex; flex-wrap: wrap; align-items: baseline; gap: 0 8px; margin: 3px 0; padding: 6px 10px;
  border-left: 4px solid var(--b); border-radius: 8px; background: #f7f9fb; color: var(--ink); text-decoration: none;
}
.tleaf:hover { background: #ecf5fa; color: var(--ink); }
.tl-common { font-weight: 700; }
.tl-sci { font-size: .86rem; color: var(--muted); }
.tleaf.is-highlight { background: #fff4cc; box-shadow: 0 0 0 2px var(--sun); }
@media (max-width: 560px) {
  .tree-outline { padding: 16px 12px; }
  .t-children { margin-left: 6px; padding-left: 8px; }
  .t-blurb { margin-left: 10px; }
}

.tree-help { margin-top: 22px; max-width: 78ch; }
.tree-help h2 { font-size: 1.5rem; }
.tree-help p { color: var(--ink-soft); }

/* Interactive dendrogram (added by species-tree.js) */
.tree-app {
  margin-top: 18px; overflow: hidden; border-radius: var(--radius); color: #e7f4ff; box-shadow: var(--shadow-lg);
  background: radial-gradient(120% 80% at 0% 0%, #0b3a66, var(--abyss) 70%);
}
/* With JavaScript on, the empty diagram box takes its room before species-tree.js fills it (no layout shift). */
@media (scripting: enabled) {
  .tree-app[data-tree-app][hidden] { display: block !important; height: 467px; }
}
@media (scripting: enabled) and (max-width: 640px) {
  .tree-app[data-tree-app][hidden] { height: 530px; }
}
.tree-toolbar { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; padding: 14px 16px; border-bottom: 1px solid rgba(255, 255, 255, .1); }
.tree-toolbar input[type=search] {
  flex: 1 1 220px; min-width: 0; padding: 9px 16px; border-radius: 999px; color: #fff;
  border: 1px solid rgba(255, 255, 255, .2); background: rgba(255, 255, 255, .08);
}
.tree-toolbar input[type=search]::placeholder { color: #8fb1cc; }
.tree-toolbar input[type=search]:focus { outline: none; border-color: var(--glow); }
.tree-toolbar button {
  padding: 8px 14px; border-radius: 999px; font-size: .85rem; font-weight: 700; color: #e7f4ff; cursor: pointer;
  border: 1px solid rgba(255, 255, 255, .22); background: rgba(255, 255, 255, .06);
}
.tree-toolbar button:hover { border-color: var(--glow); background: rgba(95, 242, 231, .16); }
.tree-status { flex-basis: 100%; margin: 0; font-size: .85rem; color: #8fb1cc; min-height: 1.3em; }
.tree-canvas { max-height: 78vh; overflow: auto; overscroll-behavior: contain; -webkit-overflow-scrolling: touch; }
.tree-canvas svg { display: block; }
.dn-link { fill: none; stroke: var(--b); stroke-width: 2; opacity: .5; transition: opacity .2s; }
.dn-link.is-path { opacity: 1; stroke-width: 3.5; }
.dn-node, .dn-leaf { transition: opacity .2s; }
.dn-node { cursor: pointer; }
.dn-node circle { fill: var(--abyss); stroke: var(--b); stroke-width: 2.5; }
.dn-node.is-collapsed circle { fill: var(--b); }
.dn-leaf circle { fill: var(--b); }
.dn-node text, .dn-leaf text {
  font: 600 12px var(--body); fill: #e7f4ff;
  paint-order: stroke; stroke: #041a33; stroke-width: 4px; stroke-linejoin: round;
}
.dn-node .dn-sub, .dn-leaf .dn-sub { font-size: 11px; font-weight: 500; fill: #8fb1cc; }
.dn-leaf .dn-sub { font-style: italic; }
.dn-node .dn-badge { font-size: 10px; font-weight: 800; fill: #8fb1cc; }
.dn-leaf:hover .dn-main, .dn-leaf:focus .dn-main { fill: var(--glow); text-decoration: underline; }
.dn-node:focus, .dn-leaf:focus { outline: none; }
.dn-node:focus-visible circle, .dn-leaf:focus-visible circle { stroke: #fff; stroke-width: 4; }
.is-dim { opacity: .22; }
.is-match .dn-main { fill: var(--sun); }
.dn-leaf.is-hl circle, .dn-node.is-hl circle { stroke: var(--sun); stroke-width: 4; }
.dn-leaf.is-hl .dn-main { fill: var(--sun); }
.tree-info { padding: 14px 18px; border-top: 1px solid rgba(255, 255, 255, .1); font-size: .92rem; color: #cfe3f5; }
.tree-info p { margin: 0; }
.tree-info strong { color: #fff; }
.tree-info a { color: var(--glow); }

/* ---------- Compare ---------- */

.compare-hero h1 .vs { margin: 0 .15em; font: 600 .5em var(--body); color: var(--muted); vertical-align: middle; }
.compare-form { display: grid; grid-template-columns: 1fr 1fr auto; gap: 12px 16px; align-items: end; max-width: 860px; margin-top: 18px; }
.compare-form .field { margin: 0; }
@media (max-width: 640px) { .compare-form { grid-template-columns: 1fr; } }
.compare-wrap { padding-bottom: 40px; }
.compare-empty h2 { font-size: 1.5rem; margin-top: 1.4em; }
.suggest-list { display: grid; gap: 10px; max-width: 640px; list-style: none; padding: 0; margin: 0; }
.suggest-list li { padding: 14px 18px; border-radius: 14px; background: var(--paper); box-shadow: var(--shadow); }
.suggest-list a { color: var(--ink); text-decoration: none; }
.suggest-list a:hover { color: var(--ocean); }
.suggest-list small { display: block; color: var(--muted); }

.split-card { margin: 8px 0 28px; padding: 26px 30px; border-radius: var(--radius); color: #e7f4ff; box-shadow: var(--shadow-lg); background: linear-gradient(150deg, var(--deep), var(--abyss)); }
.split-card .eyebrow { color: var(--glow); }
.split-card h2 { font-size: clamp(1.45rem, 3.4vw, 2.2rem); color: #fff; text-wrap: balance; }
.split-card p { color: #cfe3f5; }
.split-card a { color: var(--glow); }
.compare-section { margin-bottom: 30px; }
.compare-section h2 { font-size: 1.7rem; }
.table-scroll { overflow-x: auto; border-radius: var(--radius); background: var(--paper); box-shadow: var(--shadow); }
.compare-table { width: 100%; border-collapse: collapse; }
.compare-table th, .compare-table td { padding: 10px 14px; text-align: left; vertical-align: top; border-bottom: 1px solid var(--line); }
.compare-table thead th { font-size: .78rem; letter-spacing: .06em; text-transform: uppercase; color: var(--ink-soft); background: #f1f6f9; }
.compare-table tbody th { font-size: .74rem; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); white-space: nowrap; }
.lineage-table .is-shared td { background: #e5f8f5; }
.lineage-table .shared-cell { text-align: center; }
.lineage-table .is-split th, .lineage-table .is-split td { border-top: 3px solid var(--coral); }
.lineage-table .is-minor th, .lineage-table .is-minor td { padding-top: 6px; padding-bottom: 6px; font-size: .86rem; }
.split-flag { display: inline-block; margin-left: 6px; padding: 1px 8px; border-radius: 999px; font-size: .62rem; color: #fff; background: #c4321f; }
.compare-swap a { display: inline-block; padding: 6px 0; }
.cmp-name { font-weight: 700; overflow-wrap: anywhere; }
.cmp-common { font-size: .86rem; color: var(--muted); }
.care-table .is-different td { background: #fffaee; }
.compare-links { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 16px; }
@media (max-width: 560px) {
  .compare-table th, .compare-table td { padding: 8px; font-size: .86rem; }
  .compare-table tbody th { white-space: normal; font-size: .62rem; }
  .split-card { padding: 20px 18px; }
}

/* ==========================================================================
   Contact options and live chat
   ========================================================================== */

.contact-ways { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 16px; margin-bottom: 8px; }
.contact-card {
  display: grid; justify-items: start; gap: 2px; padding: 22px 24px; text-align: left;
  border: 0; border-radius: var(--radius); background: var(--paper); box-shadow: var(--shadow);
  color: var(--ink); text-decoration: none; cursor: pointer; font: inherit;
  transition: transform .15s ease, box-shadow .2s ease;
}
.contact-card:hover { color: var(--ink); transform: translateY(-3px); box-shadow: var(--shadow-lg); }
.contact-icon {
  display: grid; place-items: center; width: 48px; height: 48px; margin-bottom: 10px; border-radius: 14px;
  color: var(--abyss); background: linear-gradient(135deg, var(--glow), var(--lagoon));
}
.contact-label { font-size: .8rem; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: var(--muted); }
.contact-value { font: 800 1.3rem/1.3 var(--display); }
.contact-card .muted { font-size: .9rem; }
.contact-layout h2 { font-size: 1.6rem; }

.chat { position: fixed; right: 20px; bottom: 20px; z-index: 90; font-size: .95rem; }
.chat-launcher {
  position: relative; display: flex; align-items: center; gap: 10px; margin-left: auto; width: max-content;
  padding: 12px 20px 12px 14px; border-radius: 999px; text-decoration: none; font-weight: 800;
  color: var(--abyss); background: linear-gradient(120deg, var(--glow), var(--lagoon) 60%, #4f8dff);
  box-shadow: 0 14px 34px -10px rgba(3, 18, 37, .55), 0 0 0 0 rgba(95, 242, 231, .6);
  transition: transform .15s ease, box-shadow .2s ease;
}
.chat-launcher:hover { color: var(--abyss); transform: translateY(-2px); }
.chat.is-online .chat-launcher { animation: chat-pulse 2.8s ease-out 3; }
@keyframes chat-pulse { 70% { box-shadow: 0 14px 34px -10px rgba(3, 18, 37, .55), 0 0 0 14px rgba(95, 242, 231, 0); } }
.chat-launcher::after {
  content: ""; position: absolute; left: 34px; top: 9px; width: 11px; height: 11px; border-radius: 50%;
  background: #9aa9b6; border: 2px solid #fff;
}
.chat.is-online .chat-launcher::after { background: #22c55e; }
.chat-launcher-close { display: none; }
.chat.is-open .chat-launcher-icon, .chat.is-open .chat-launcher-text, .chat.is-open .chat-launcher::after { display: none; }
.chat.is-open .chat-launcher-close { display: block; }
.chat.is-open .chat-launcher { padding: 15px; }
.chat-badge {
  position: absolute; top: -6px; right: -4px; min-width: 22px; height: 22px; padding: 0 6px; border-radius: 999px;
  display: grid; place-items: center; font-size: .75rem; color: #fff; background: var(--coral); border: 2px solid #fff;
}

.chat-panel {
  position: absolute; right: 0; bottom: calc(100% + 14px);
  width: min(380px, calc(100vw - 32px)); height: min(560px, calc(100vh - 120px));
  display: flex; flex-direction: column; overflow: hidden;
  border-radius: 22px; background: var(--sand); box-shadow: 0 30px 70px -20px rgba(3, 18, 37, .6);
  animation: chat-in .22s ease;
}
@keyframes chat-in { from { opacity: 0; transform: translateY(14px) scale(.98); } }
.chat-head {
  display: flex; align-items: center; gap: 12px; padding: 16px 18px; color: #fff;
  background: radial-gradient(circle at 15% 0, rgba(95, 242, 231, .35), transparent 60%), linear-gradient(135deg, var(--deep), var(--abyss));
}
.chat-head > div { display: grid; flex: 1; line-height: 1.3; }
.chat-head strong { font: 800 1.15rem var(--display); }
.chat-avatar .logo { width: 42px; height: 42px; }
.chat-presence { font-size: .82rem; color: #b9cfe3; display: flex; align-items: center; gap: 6px; }
.chat-presence::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: #9aa9b6; }
.chat.is-online .chat-presence::before { background: #22c55e; box-shadow: 0 0 0 3px rgba(34, 197, 94, .25); }
.chat-close { border: 0; background: rgba(255, 255, 255, .1); color: #fff; width: 36px; height: 36px; border-radius: 50%; display: grid; place-items: center; cursor: pointer; }
.chat-close:hover { background: rgba(255, 255, 255, .2); }

.chat-scroll { flex: 1; overflow-y: auto; padding: 16px; overscroll-behavior: contain; }
.chat-intro { background: var(--paper); border-radius: 16px 16px 16px 4px; padding: 12px 14px; box-shadow: 0 2px 8px -4px rgba(3, 18, 37, .2); color: var(--ink-soft); margin-bottom: 14px; }
.chat-intro span { display: block; margin-top: 6px; }
.chat-log { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.chat-msg { display: grid; max-width: 85%; }
.chat-msg p { margin: 0; padding: 10px 14px; white-space: pre-wrap; overflow-wrap: anywhere; border-radius: 16px; }
.chat-msg small { font-size: .72rem; color: var(--muted); margin: 3px 6px 0; }
.chat-msg.from-visitor { justify-self: end; justify-items: end; }
.chat-msg.from-visitor p { color: var(--abyss); background: linear-gradient(120deg, var(--glow), #8be3f1); border-bottom-right-radius: 4px; }
.chat-msg.from-staff p { background: var(--paper); border-bottom-left-radius: 4px; box-shadow: 0 2px 8px -4px rgba(3, 18, 37, .2); }

.chat-start { display: grid; gap: 8px; margin-top: 4px; }
.chat-start-row { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.chat-start input, .chat-start textarea, .chat-compose textarea {
  width: 100%; padding: 10px 12px; border: 1.5px solid var(--line); border-radius: 12px; background: #fff; resize: none;
}
.chat-start input:focus, .chat-start textarea:focus, .chat-compose textarea:focus { outline: none; border-color: var(--lagoon); box-shadow: 0 0 0 3px rgba(25, 182, 214, .18); }
.chat-error { margin: 0 16px 8px; padding: 8px 12px; border-radius: 10px; font-size: .85rem; font-weight: 600; color: #9e1f1f; background: #fdeaea; }

.chat-compose { display: flex; align-items: flex-end; gap: 8px; padding: 10px 12px; background: var(--paper); border-top: 1px solid var(--line); }
.chat-compose textarea { max-height: 120px; }
.chat-compose button {
  flex: none; width: 42px; height: 42px; border: 0; border-radius: 50%; cursor: pointer; display: grid; place-items: center;
  color: var(--abyss); background: linear-gradient(135deg, var(--glow), var(--lagoon));
}
.chat-compose button:disabled { opacity: .5; }
.chat-foot { margin: 0; padding: 8px 14px 10px; font-size: .8rem; text-align: center; color: var(--muted); background: var(--paper); }
.chat-compose[hidden] + .chat-foot { border-top: 1px solid var(--line); }

@media (max-width: 600px) {
  .chat { right: 12px; bottom: 12px; }
  .chat-launcher-text { display: none; }
  .chat-launcher { padding: 15px; }
  .chat-launcher::after { left: auto; right: 4px; top: 4px; }
  .chat.is-open { left: 0; right: 0; top: 0; bottom: 0; }
  .chat.is-open .chat-launcher { display: none; }
  .chat-panel { position: fixed; inset: 0; width: auto; height: auto; border-radius: 0; }
  .chat-start-row { grid-template-columns: 1fr; }
}

/* ---------- Phone tap targets and small text ---------- */
@media (max-width: 640px) {
  .btn-add { min-height: 44px; }
  .crumbs a { display: inline-block; padding: 13px 0; margin: -13px 0; }
  .filter-box summary { display: flex; align-items: center; min-height: 44px; }
  .check { min-height: 44px; }
  .t-rank { font-size: .72rem; }
  .tnode > summary, .tleaf { min-height: 44px; }
}

/* ---------- Care guides (/guides) ---------- */

.guide-hero h1 { max-width: 22ch; }
.guide-lede { max-width: 62ch; margin: 0 0 10px; font-size: 1.15rem; color: #cfe3f5; }
.guide-layout { padding-top: 30px; }
.guide-intro p { font-size: 1.1rem; }
.page-guide .sp-section h2 + p { margin-top: 0; }
.page-guide .sp-section ul, .page-guide .sp-section ol:not(.source-list) { padding-left: 1.3em; }
.page-guide .sp-section li { margin-bottom: .45em; }
.page-guide .sp-section a:not(.btn) { color: var(--ocean); font-weight: 600; }
.link-draft { outline: 2px dashed var(--warn); outline-offset: 2px; }

.guides-list { padding: 10px 0 56px; }
.guide-cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 22px; list-style: none; margin: 0; padding: 0; }
.guide-card { display: flex; }
.guide-card-link { display: flex; flex-direction: column; gap: 8px; width: 100%; padding: 24px 24px 20px; color: inherit; text-decoration: none; }
.guide-card .card-title { margin: 0; font-size: 1.3rem; }
.guide-card .card-text { flex: 1; margin: 0; }
.guide-card .badge { align-self: flex-start; }
.guide-card-link:hover .card-title { color: var(--ocean); }
.section-related .guide-cards { margin-top: 18px; }

.reef-list { display: grid; gap: 18px; margin: 16px 0 4px; }
.reef-group h3 { display: flex; align-items: center; gap: 8px; margin: 0 0 10px; }
.reef-group h3 span { padding: 1px 9px; border-radius: 999px; font-size: .78rem; background: #eef3f7; color: var(--ink-soft); }
.reef-group-reef h3 span { background: #e0f4fb; color: #075b78; }
.reef-group-caution h3 span { background: #fff3db; color: #8a5300; }
.reef-group-danger h3 span { background: #fde6e3; color: #a3271a; }
.reef-entries { display: grid; gap: 10px; list-style: none; margin: 0; padding: 0 !important; }
.reef-entries li { margin: 0 !important; padding: 12px 16px; border-radius: 12px; background: #f5f8fa; border-left: 4px solid #8fd8ea; }
.reef-group-caution .reef-entries li { border-left-color: #ffc845; }
.reef-group-danger .reef-entries li { border-left-color: #e5533f; }
.reef-entries p { margin: 0; font-size: .95rem; }
.reef-entries .reef-entry-name { display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 8px; margin-bottom: 4px; }
.reef-entry-name a { font-weight: 800 !important; }
.reef-entry-name i { font-size: .88rem; color: var(--muted); }
.reef-entry-name .tag { font-size: .7rem; }
.reef-more { margin-left: 4px; font-size: .88rem; white-space: nowrap; }

/* Guide pictures: tank photos, diagrams and species cards placed with [[...]] lines */
.guide-photos { display: grid; gap: 14px; margin: 18px 0; }
.guide-photos-2, .guide-photos-4 { grid-template-columns: 1fr 1fr; }
.guide-photos-3 { grid-template-columns: repeat(3, 1fr); }
.guide-photo { margin: 0; }
.guide-photo img { display: block; width: 100%; height: auto; aspect-ratio: 3 / 2; object-fit: cover; border-radius: 14px; background: var(--deep); box-shadow: var(--shadow); }
.guide-photos-1 .guide-photo img { aspect-ratio: 16 / 9; max-height: 420px; }
.guide-photo figcaption, .guide-diagram figcaption { margin-top: 6px; font-size: .86rem; line-height: 1.4; color: var(--muted); }
.guide-diagram { margin: 18px 0; }
.guide-diagram img { display: block; width: 100%; height: auto; border-radius: 16px; }
@media (max-width: 600px) { .guide-photos-3 { grid-template-columns: 1fr 1fr; } }

.guide-species { display: grid; grid-template-columns: repeat(auto-fill, minmax(165px, 1fr)); gap: 12px; margin: 18px 0; }
.guide-sp {
  display: flex; flex-direction: column; overflow: hidden; border-radius: 14px; background: #f5f8fa;
  border: 1px solid var(--line); color: inherit; text-decoration: none !important; transition: transform .15s, box-shadow .15s;
}
.guide-sp:hover { transform: translateY(-2px); box-shadow: var(--shadow); }
.guide-sp-img { position: relative; display: block; }
.guide-sp-img img { display: block; width: 100%; height: auto; aspect-ratio: 4 / 3; object-fit: cover; background: var(--deep); }
.guide-sp-img small { position: absolute; right: 6px; bottom: 6px; padding: 1px 7px; border-radius: 999px; font-size: .66rem; font-weight: 700; background: rgba(3, 18, 37, .6); color: #fff; }
.guide-sp-body { display: grid; gap: 2px; padding: 10px 12px 12px; }
.guide-sp-body strong { font-size: .95rem; line-height: 1.25; color: var(--ink); }
.guide-sp:hover strong { color: var(--ocean); }
.guide-sp-body i { font-size: .8rem; color: var(--muted); }
.guide-sp-body .tags { margin: 6px 0 0; gap: 4px; }
.guide-sp-body .tag { font-size: .68rem; }
/* A lone card (one fish per subsection) sits beside the text on wide screens */
.guide-species:has(> .guide-sp:only-child) { float: right; width: 210px; margin: 0 0 12px 22px; grid-template-columns: 1fr; }
.page-guide .sp-section h3 { clear: both; }
.page-guide .sp-section::after { content: ""; display: block; clear: both; }
@media (max-width: 600px) {
  .guide-species { grid-template-columns: 1fr 1fr; }
  .guide-species:has(> .guide-sp:only-child) { float: none; width: auto; margin: 12px 0; grid-template-columns: 1fr 1fr; }
}

.guide-photo-wanted { margin: 16px 0; padding: 14px 16px; border: 2px dashed #f2c873; border-radius: 14px; background: #fffaf0; font-size: .9rem; color: #6b4300; }
.guide-photo-wanted code { padding: 1px 6px; border-radius: 6px; background: #fff3db; font-weight: 700; }

.reef-entries li { display: grid; grid-template-columns: 96px 1fr; column-gap: 14px; align-items: start; }
.reef-entries li > p { grid-column: 2; }
.reef-thumb { grid-row: 1 / span 2; width: 96px; height: 72px; object-fit: cover; border-radius: 10px; background: var(--deep); }
@media (max-width: 480px) {
  .reef-entries li { grid-template-columns: 64px 1fr; column-gap: 10px; }
  .reef-thumb { width: 64px; height: 48px; }
}

/* ---------- Customer accounts ---------- */

.account-link svg { display: block; }
.account-link.is-signed-in { color: var(--glow); }
@media (max-width: 1060px) {
  .account-link { margin-left: auto; }
  .account-link + .cart-link { margin-left: 0; }
}
/* Phones: logo, account, cart and menu on one row */
@media (max-width: 420px) {
  .header-inner { gap: 8px; }
  .cart-link, .nav-toggle { width: 42px; height: 42px; flex-shrink: 0; }
}
@media (max-width: 359px) {
  .brand-name { font-size: 1.15rem; }
  .brand .logo { width: 34px; height: 34px; }
}
.account-signin { display: grid; grid-template-columns: 1fr 1fr; gap: 28px; align-items: start; padding-bottom: 72px; }
.account-signin .checkout-form, .account-single .checkout-form { padding-top: 20px; }
.account-single { padding-bottom: 72px; }
@media (max-width: 800px) { .account-signin { grid-template-columns: 1fr; } }
.account-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 28px; align-items: start; padding-bottom: 72px; }
.account-grid > * { min-width: 0; padding-top: 20px; }
.account-grid .account-wide { grid-column: 1 / -1; }
.account-stack { display: grid; gap: 28px; padding-top: 0; }
.account-stack .checkout-form { padding-top: 20px; }
@media (max-width: 900px) { .account-grid { grid-template-columns: 1fr; } }
.account-orders { font-size: .95rem; }
@media (max-width: 560px) { .account-orders th:nth-child(3), .account-orders td:nth-child(3) { display: none; } }
.account-chats { list-style: none; margin: 0 0 12px; padding: 0; }
.account-chats li + li { border-top: 1px solid var(--line); }
.account-chats a { display: grid; gap: 2px; padding: 12px 4px; color: var(--ink); text-decoration: none; }
.account-chats a:hover .account-chat-last { color: var(--ocean); }
.account-chat-last { color: var(--ink-soft); overflow-wrap: anywhere; }
.account-chat .chat-log { padding: 14px 0; }
.account-delete { padding-bottom: 20px; }
.account-delete summary { cursor: pointer; font-weight: 700; color: var(--danger); padding-bottom: 4px; }
.account-delete form { max-width: 520px; padding-top: 10px; }
.btn-danger { color: #fff; background: var(--danger); }
.btn-danger:hover { color: #fff; background: #a92424; }

/* ---------- Tank service (Huntsville) ---------- */

.topbar-service { font-weight: 800; }
.main-nav .nav-service a { color: var(--glow); }
.btn-emergency { color: #fff; background: var(--danger); }
.btn-emergency:hover { color: #fff; background: #b02a2a; }
.btn-sm { font-size: .85rem; padding: .45em 1em; }

.services-hero {
  padding: 56px 0 44px; color: #fff;
  background: radial-gradient(900px 380px at 85% 0%, rgba(95, 242, 231, .18), transparent), linear-gradient(160deg, var(--deep), var(--abyss));
}
.services-hero .eyebrow { color: var(--glow); }
.services-hero h1 { font-size: clamp(2.3rem, 5.4vw, 4.2rem); max-width: 18ch; margin: 0 0 14px; text-wrap: balance; }
.services-hero .lede { max-width: 60ch; color: #cfe3f5; font-size: 1.12rem; margin: 0 0 26px; }
@media (max-width: 520px) { .services-hero .btn-lg { font-size: 1rem; padding: .85em 1.3em; } }

.service-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 20px; }
@media (max-width: 960px) { .service-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 600px) { .service-grid { grid-template-columns: 1fr; } }
.service-card {
  display: flex; flex-direction: column; gap: 6px; padding: 24px; border-radius: var(--radius);
  background: var(--paper); box-shadow: var(--shadow); border-top: 4px solid var(--lagoon);
}
.service-card h3 { font-size: 1.35rem; margin: 6px 0 0; }
.service-card p { margin: 0; color: var(--ink-soft); }
.service-card .service-meta { font-weight: 700; font-size: .9rem; color: var(--ocean); }
.service-card .text-link { margin-top: auto; padding-top: 8px; }
.service-icon {
  display: inline-grid; place-items: center; width: 48px; height: 48px; border-radius: 14px;
  color: var(--ocean); background: rgba(25, 182, 214, .12);
}
.service-emergency { border-top-color: var(--danger); }
.service-emergency .service-icon { color: var(--danger); background: rgba(210, 59, 59, .1); }

.services-book { background: linear-gradient(180deg, var(--sand), #eaf6f8); }
.service-tabs { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 22px; }
.service-tabs a {
  padding: 8px 16px; border-radius: 999px; font-weight: 700; font-size: .92rem; text-decoration: none;
  color: var(--deep); background: var(--paper); box-shadow: var(--shadow);
}
.service-tabs a[aria-current] { background: var(--deep); color: #fff; box-shadow: none; }
.book-layout { display: grid; grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr); gap: 24px; align-items: start; }
@media (max-width: 860px) { .book-layout { grid-template-columns: 1fr; } }
.calendar, .times, .your-visits { padding: 22px; border-radius: var(--radius); background: var(--paper); box-shadow: var(--shadow); }
.calendar-head { display: grid; grid-template-columns: 40px 1fr 40px; align-items: center; text-align: center; margin-bottom: 12px; }
.calendar-head h3 { margin: 0; font-size: 1.3rem; }
.calendar-head a {
  display: grid; place-items: center; width: 40px; height: 40px; border-radius: 50%;
  font-size: 1.5rem; text-decoration: none; color: var(--deep); background: rgba(25, 182, 214, .12);
}
.calendar-grid { list-style: none; padding: 0; margin: 0; display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 6px; }
.calendar-wd { text-align: center; font-size: .75rem; font-weight: 800; text-transform: uppercase; letter-spacing: .06em; color: var(--muted); }
.calendar-day {
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px; min-height: 58px;
  border-radius: var(--radius-sm); text-decoration: none; color: var(--deep);
  background: rgba(25, 182, 214, .1); border: 2px solid transparent;
}
.calendar-day strong { font-size: 1.05rem; }
.calendar-day span { font-size: .7rem; font-weight: 700; color: var(--ocean); }
a.calendar-day:hover { border-color: var(--lagoon); }
.calendar-day.is-picked { background: var(--deep); color: #fff; }
.calendar-day.is-picked span { color: var(--glow); }
.calendar-day.is-off { background: transparent; color: var(--muted); }
.calendar-day.is-off span { color: var(--muted); font-weight: 600; }
@media (max-width: 520px) {
  .calendar, .times, .your-visits { padding: 14px; }
  .calendar-grid { gap: 3px; }
  .calendar-day { min-height: 46px; }
  .calendar-day span { font-size: .6rem; }
}
.times h3, .your-visits h3 { margin: 0 0 4px; font-size: 1.3rem; }
.time-list { list-style: none; padding: 0; margin: 14px 0 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(96px, 1fr)); gap: 8px; }
.time-btn {
  display: block; padding: 10px 6px; text-align: center; border-radius: var(--radius-sm); font-weight: 700; text-decoration: none;
  color: var(--deep); border: 2px solid var(--lagoon); background: #fff;
}
.time-btn:hover { color: var(--abyss); background: var(--glow); border-color: var(--glow); }
.times-note { margin: 16px 0 0; font-size: .9rem; color: var(--ink-soft); }
.times-urgent { padding: 10px 12px; border-radius: var(--radius-sm); background: #fdeaea; color: #9e1f1f; font-weight: 600; }
.your-visits { margin-top: 24px; scroll-margin-top: 90px; }
.times { scroll-margin-top: 90px; }
.visit-list { list-style: none; padding: 0; margin: 12px 0 0; display: grid; gap: 10px; }
.visit { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 18px; padding: 12px 14px; border-radius: var(--radius-sm); background: var(--sand); }
.visit > div { display: flex; flex-direction: column; flex: 1 1 240px; }
.visit .muted { font-size: .88rem; }
.visit-status { font-size: .8rem; font-weight: 800; padding: 4px 10px; border-radius: 999px; background: #fff5e0; color: #8a5300; }
.visit-confirmed .visit-status { background: #e4f8f0; color: #0b6e4f; }
.visit-cancelled .visit-status, .visit-completed .visit-status { background: #eef1f4; color: var(--muted); }
.visit.is-past { opacity: .7; }
.visit form { margin: 0; }
.book-form .field-row { align-items: end; }

.section-service-band { padding: 32px 0; background: linear-gradient(160deg, var(--deep), var(--abyss)); color: #fff; }
.service-band { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.1fr); gap: 28px; align-items: center; }
.service-band .eyebrow { color: var(--glow); }
.service-band h2 { font-size: clamp(1.8rem, 3.6vw, 2.6rem); margin: 0 0 10px; }
.service-band p { color: #cfe3f5; margin: 0 0 18px; max-width: 52ch; }
.service-band .hero-actions { margin: 0; }
.service-band-list { list-style: none; padding: 0; margin: 0; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.service-band-list a {
  display: flex; align-items: center; gap: 12px; padding: 10px 14px; border-radius: var(--radius-sm); font-weight: 700;
  color: #fff; text-decoration: none; background: rgba(255, 255, 255, .07); border: 1px solid rgba(255, 255, 255, .14);
}
.service-band-list a:hover { background: rgba(95, 242, 231, .14); border-color: var(--glow); color: #fff; }
.service-band-list .service-icon { width: 40px; height: 40px; color: var(--glow); background: rgba(95, 242, 231, .12); flex: none; }
.service-band-list .service-emergency .service-icon { color: #ff9b9b; background: rgba(210, 59, 59, .22); }
@media (max-width: 860px) { .service-band { grid-template-columns: 1fr; } }
@media (max-width: 420px) { .service-band-list { grid-template-columns: 1fr; } }
/* The category links only fit on wide screens; below that they live in the Shop all menu,
   so the header (with Tank service, sign-in and cart) never runs off the side of a laptop screen. */
@media (min-width: 1061px) and (max-width: 1719px) { .main-nav .nav-cat { display: none; } }
