/*
Theme Name: Aqualine
Description: Trade homepage for Aqualine, wholesale live fish and aquatic plants.
Version: 1.2.1
Text Domain: aqualine
*/

@font-face {
  font-family: "Sofia Sans Condensed";
  src: url("assets/fonts/sofia-sans-condensed-latin-700-normal.woff2") format("woff2");
  font-weight: 700;
  font-display: swap;
}
@font-face {
  font-family: "Sofia Sans Condensed";
  src: url("assets/fonts/sofia-sans-condensed-latin-600-normal.woff2") format("woff2");
  font-weight: 600;
  font-display: swap;
}
@font-face {
  font-family: "Jost";
  src: url("assets/fonts/jost-latin-400-normal.woff2") format("woff2");
  font-weight: 400;
  font-display: swap;
}
@font-face {
  font-family: "Jost";
  src: url("assets/fonts/jost-latin-500-normal.woff2") format("woff2");
  font-weight: 500;
  font-display: swap;
}

:root {
  --teal-ink: #084b5a;
  --teal: #0d6072;
  --teal-soft: #3d7280;
  --burgundy: #6b1530;
  --burgundy-ink: #8a1c40;
  --water: #e2f0f0;
  --line: rgba(122, 170, 180, 0.55);
  --field: rgba(255, 255, 255, 0.6);
  --display: "Sofia Sans Condensed", "Arial Narrow", sans-serif;
  --text: "Jost", "Segoe UI", sans-serif;
}

*, *::before, *::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  background: var(--water);
  color: var(--teal-ink);
  font-family: var(--text);
  font-size: 1rem;
  line-height: 1.45;
}

a { color: inherit; }

.site-page {
  position: relative;
  overflow: hidden;
}

.page-bg,
.page-bg img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}
.page-bg img { object-fit: cover; object-position: center; }

/* ---------- Header ---------- */

.site-header {
  position: relative;
  z-index: 2;
  display: flex;
  align-items: center;
  gap: 1.5rem;
  padding: 1rem 1.25rem;
}

.brand { display: block; flex: 0 0 auto; }
.brand img { display: block; width: 11rem; height: auto; margin: -0.4rem 0 -0.4rem -2rem; }

.site-nav { display: none; }

.site-nav ul {
  display: flex;
  gap: 2.4rem;
  margin: 0;
  padding: 0;
  list-style: none;
}

.site-nav a {
  color: var(--teal);
  text-decoration: none;
}
.site-nav a:hover { color: var(--teal-ink); text-decoration: underline; text-underline-offset: 0.25em; }

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 0;
  border-radius: 999px;
  background: var(--burgundy);
  color: #fff;
  font-family: var(--display);
  font-weight: 700;
  text-decoration: none;
  cursor: pointer;
  transition: background-color 160ms ease-out;
}
.btn:hover { background: #55102a; }
.btn:focus-visible,
.site-nav a:focus-visible,
.hero-link:focus-visible { outline: 3px solid var(--teal); outline-offset: 3px; }

.btn-login {
  margin-left: auto;
  padding: 0.55rem 1.4rem;
  font-size: 1.05rem;
}

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

.hero {
  position: relative;
  z-index: 1;
  display: grid;
  gap: 2rem;
  padding: 2rem 1.25rem 3rem;
}

.hero h1 {
  margin: 0;
  max-width: 12ch;
  font-family: var(--display);
  font-weight: 700;
  font-size: clamp(2.75rem, 11vw, 4.5rem);
  line-height: 0.88;
  letter-spacing: -0.005em;
  color: var(--teal-ink);
}

.hero-note {
  display: inline-block;
  max-width: 100%;
  margin-top: 1.25rem;
  padding: 1rem 1.25rem 1.05rem;
  border-radius: 0.9rem;
  background: rgba(255, 255, 255, 0.92);
  box-shadow: 0 0.6rem 1.8rem rgba(6, 51, 61, 0.1);
}

.hero-intro {
  margin: 0;
  color: var(--teal-ink);
  font-size: 1.1rem;
  font-weight: 500;
  line-height: 1.35;
}
.hero-intro span { display: block; }
.hero-intro span + span { color: var(--teal); font-weight: 400; }

.hero-link {
  display: block;
  margin-top: 0.8rem;
  padding-top: 0.8rem;
  border-top: 1px solid #d4e4e6;
  color: var(--teal-ink);
  font-size: 1rem;
  line-height: 1.3;
  text-decoration: none;
}
.hero-link span {
  color: var(--burgundy-ink);
  font-weight: 600;
  text-decoration: underline;
  text-decoration-thickness: 1.5px;
  text-underline-offset: 0.22em;
  white-space: nowrap;
}
.hero-link:hover span { color: var(--burgundy); text-decoration-thickness: 2.5px; }

/* ---------- Application card ---------- */

.apply {
  padding: 1.5rem 1.25rem 1.75rem;
  border: 1px solid rgba(255, 255, 255, 0.7);
  border-radius: 1.25rem;
  background: rgba(240, 249, 249, 0.42);
  -webkit-backdrop-filter: blur(18px) saturate(1.1);
  backdrop-filter: blur(18px) saturate(1.1);
  box-shadow: 0 1.5rem 3rem rgba(0, 0, 0, 0.06);
}

.apply h2 {
  margin: 0 0 1rem;
  font-family: var(--display);
  font-weight: 700;
  font-size: 2rem;
  line-height: 1;
  color: var(--teal);
}

.apply-grid {
  display: grid;
  gap: 1.5rem 1.6rem;
}

.group {
  margin: 0;
  padding: 0;
  border: 0;
  min-width: 0;
}

.group > legend {
  padding: 0;
  margin-bottom: 0.4rem;
  font-family: var(--display);
  font-weight: 600;
  font-size: 1.35rem;
  color: var(--teal);
}

.group-licence {
  padding: 0.75rem 0.9rem 0.9rem;
  border: 1px solid rgba(13, 96, 114, 0.35);
  border-radius: 0.6rem;
}
.group-licence { transition: border-color 200ms ease-out, background-color 200ms ease-out; }
.group-licence.is-active { border-color: rgba(13, 96, 114, 0.7); background: rgba(255, 255, 255, 0.28); }
.group-licence > legend { float: left; width: 100%; }
.group-licence > legend + * { clear: both; }

.apply label {
  display: block;
  margin-top: 0.55rem;
  font-size: 0.9rem;
  line-height: 1.3;
  color: var(--teal-ink);
}

.apply input:not([type="radio"]),
.apply select {
  display: block;
  width: 100%;
  margin-top: 0.3rem;
  padding: 0.5rem 0.7rem;
  border: 1px solid var(--line);
  border-radius: 0.35rem;
  background: var(--field);
  color: var(--teal-ink);
  font: inherit;
  font-size: 0.9rem;
}
.apply input::placeholder { color: #5d8791; }
.apply input:not([type="radio"]), .apply select { transition: background-color 160ms ease-out, border-color 160ms ease-out; }
html { scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }
.apply select { appearance: none; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='6'%3E%3Cpath d='M1 1l4 4 4-4' fill='none' stroke='%230d6072' stroke-width='1.5'/%3E%3C/svg%3E"); background-position: right 0.8rem center; background-size: 10px 6px; background-repeat: no-repeat; color: var(--teal-ink); }
.apply input:focus,
.apply select:focus { outline: 2px solid var(--teal); outline-offset: 1px; background: rgba(255, 255, 255, 0.85); }

.pair {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.75rem;
}

.choice {
  margin: 0.55rem 0 0;
  padding: 0;
  border: 0;
}
.choice > legend {
  padding: 0;
  font-size: 0.9rem;
  color: var(--teal-ink);
}
.choice-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.35rem 1rem;
  margin-top: 0.35rem;
}
.choice-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem 1.4rem;
  margin-top: 0.35rem;
}

.apply label.radio {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  margin: 0;
  cursor: pointer;
}
.apply input[type="radio"] {
  width: 1.05rem;
  height: 1.05rem;
  margin: 0;
  accent-color: var(--teal);
}

.btn-submit {
  margin-top: 1.5rem;
  padding: 0.8rem 2.2rem;
  font-size: 1.2rem;
}

/* ---------- Desktop: the measured comp, scaled with the viewport ---------- */

@media (min-width: 1100px) {
  .site-page { min-height: 56.55vw; }

  .site-header {
    position: absolute;
    inset: 0 0 auto 0;
    height: 5.65vw;
    padding: 0;
  }
  .brand img { position: absolute; left: 0; top: 0; width: 30vw; margin: 0; }
  .brand { position: absolute; left: 4.4vw; top: 1.2vw; width: 16vw; height: 3.3vw; }
  .brand img { left: -4.4vw; top: -1.2vw; }

  .site-nav { display: block; position: absolute; left: 43.4vw; top: 2.45vw; }
  .site-nav ul { gap: 2.6vw; }
  .site-nav a { font-size: 1vw; }

  .btn-login {
    position: absolute;
    left: 83.6vw;
    top: 2.25vw;
    width: 11.7vw;
    height: 2.5vw;
    margin: 0;
    padding: 0;
    font-size: 1.15vw;
  }

  .hero {
    display: grid;
    grid-template-columns: 38vw 43.9vw;
    column-gap: 0.3vw;
    align-items: start;
    padding: 7.6vw 0 4.5vw 5vw;
    min-height: 56.55vw;
  }

  .hero-copy { padding-top: 6.6vw; }

  .hero h1 {
    max-width: 32vw;
    font-size: 5.3vw;
    line-height: 0.88;
    letter-spacing: -0.012em;
  }

  .hero-note {
    margin-top: 2.1vw;
    padding: 1.15vw 1.6vw 1.2vw;
    border-radius: 0.9vw;
  }
  .hero-intro { font-size: max(1.38vw, 17px); }
  .hero-link { margin-top: 0.9vw; padding-top: 0.9vw; font-size: max(1.1vw, 15px); }

  .apply {
    position: relative;
    min-height: 44.1vw;
    padding: 1.45vw 2.75vw 2vw;
    border-radius: 1.3vw;
  }

  .apply h2 { font-size: 2.53vw; margin-bottom: 0.55vw; }

  .apply-grid {
    grid-template-columns: 55fr 45fr;
    column-gap: 1.75vw;
    row-gap: 0.85vw;
  }

  .group > legend { font-size: max(1.33vw, 17px); margin-bottom: 0; line-height: 1.1; }
  .group-licence { padding: max(0.75vw, 10px); border-radius: max(0.55vw, 8px); margin-top: -0.9vw; }

  .apply label { margin-top: max(0.5vw, 5px); font-size: max(0.76vw, 12.5px); }
  .apply input:not([type="radio"]),
  .apply select {
    height: max(1.68vw, 28px);
    margin-top: max(0.3vw, 3px);
    padding: 0 max(0.55vw, 9px);
    font-size: max(0.62vw, 13px);
    border-radius: max(0.28vw, 5px);
  }
  .pair { gap: 0.9vw; }
  .pair label { margin-top: max(0.5vw, 5px); }

  .choice { margin-top: max(0.4vw, 7px); }
  .choice > legend { font-size: max(0.76vw, 13px); }
  .choice-grid { gap: max(0.45vw, 5px) 1vw; margin-top: max(0.45vw, 5px); }
  .choice-row { gap: 0.4vw 1.2vw; margin-top: max(0.5vw, 6px); }
  .apply label.radio { gap: max(0.55vw, 8px); font-size: max(0.76vw, 13px); }
  .apply input[type="radio"] { width: max(0.9vw, 15px); height: max(0.9vw, 15px); }

  .btn-submit {
    width: max(15vw, 220px);
    height: max(2.35vw, 40px);
    margin-top: 0.9vw;
    padding: 0;
    font-size: max(1.12vw, 17px);
  }

  .site-nav a { font-size: max(1vw, 15px); }
  .btn-login { font-size: max(1.15vw, 16px); height: max(2.5vw, 40px); }
}

@media (prefers-reduced-motion: reduce) {
  * { transition: none !important; }
}

/* ---------- Content sections ---------- */

.content {
  background: #f4fafa;
  color: var(--teal-ink);
}

.content h2 {
  margin: 0;
  font-family: var(--display);
  font-weight: 700;
  font-size: clamp(2.25rem, 5vw, 4rem);
  line-height: 0.95;
  color: var(--teal-ink);
}

.content p { max-width: 62ch; }

.lead {
  margin: 1rem 0 0;
  font-size: clamp(1.05rem, 1.4vw, 1.3rem);
  line-height: 1.45;
  color: #2f6b78;
}

.supply {
  display: grid;
  gap: 2rem;
  padding: 4rem 1.25rem;
}

.supply-photo { margin: 0; }
.supply-photo img {
  display: block;
  width: 100%;
  height: 100%;
  min-height: 16rem;
  object-fit: cover;
  border-radius: 1rem;
}

.formats {
  display: grid;
  margin: 2rem 0 0;
  border-top: 1px solid rgba(8, 75, 90, 0.18);
}
.formats div {
  display: grid;
  grid-template-columns: minmax(8rem, 45%) 1fr;
  gap: 1rem;
  padding: 0.8rem 0;
  border-bottom: 1px solid rgba(8, 75, 90, 0.18);
}
.formats dt {
  font-family: var(--display);
  font-weight: 600;
  font-size: 1.25rem;
  line-height: 1.2;
}
.formats dd { margin: 0; color: #36707d; align-self: center; }

.facts {
  margin: 2rem 0 0;
  padding: 0;
  list-style: none;
  border-top: 1px solid rgba(8, 75, 90, 0.18);
}
.facts li {
  max-width: 60ch;
  padding: 0.85rem 0;
  border-bottom: 1px solid rgba(8, 75, 90, 0.18);
  font-size: 1.05rem;
}

.ruinemans {
  display: grid;
  gap: 1.5rem;
  padding: 4.5rem 1.25rem;
  background: var(--teal-ink);
  color: #e6f3f3;
}
.ruinemans h2 { color: #fff; max-width: 16ch; }
.ruinemans p { margin: 0 0 1rem; font-size: 1.1rem; line-height: 1.5; color: #cfe6e8; }
.text-link {
  color: #fff;
  font-weight: 500;
  text-underline-offset: 0.25em;
}
.text-link:focus-visible { outline: 3px solid #fff; outline-offset: 3px; }

.ordering { padding: 4.5rem 1.25rem; }

.steps {
  display: grid;
  gap: 0;
  margin: 2.5rem 0 0;
  padding: 0;
  list-style: none;
  border-top: 1px solid rgba(8, 75, 90, 0.18);
}
.steps li {
  padding: 1.1rem 0;
  border-bottom: 1px solid rgba(8, 75, 90, 0.18);
}
.steps h3 {
  margin: 0;
  font-family: var(--display);
  font-weight: 600;
  font-size: 1.45rem;
  line-height: 1.15;
}
.steps p { margin: 0.3rem 0 0; color: #3f7480; }

.btn-cta {
  margin-top: 2.5rem;
  padding: 0.9rem 2.4rem;
  font-size: 1.25rem;
}

.site-footer {
  padding: 3.5rem 1.25rem 3rem;
  background: #06333d;
  color: #b9d6da;
}
.footer-inner {
  display: grid;
  gap: 2rem;
}
.footer-logo {
  display: block;
  width: 14rem;
  height: auto;
  margin: -0.4rem 0 1rem -2.6rem;
  filter: brightness(0) invert(1);
  opacity: 0.92;
}
.site-footer p, .site-footer address { margin: 0; font-style: normal; line-height: 1.6; max-width: 40ch; }
.site-footer strong { color: #fff; font-weight: 500; }
.site-footer a { color: #fff; text-underline-offset: 0.25em; }

@media (min-width: 900px) {
  .supply {
    grid-template-columns: 1fr 1fr;
    align-items: center;
    gap: 5vw;
    padding: 7rem 5vw;
  }
  .supply-fish .supply-text { order: 0; }
  .supply-photo img { min-height: 30rem; }

  .ruinemans {
    grid-template-columns: 1fr 1fr;
    gap: 5vw;
    padding: 7rem 5vw;
  }

  .ordering { padding: 7rem 5vw; }
  .steps {
    grid-template-columns: repeat(5, 1fr);
    gap: 2.5vw;
    padding: 0;
    border-top: 0;
  }
  .steps li { padding: 1.2rem 0 0.4rem; border-bottom: 0; border-top: 2px solid var(--teal); }

  .site-footer { padding: 4rem 5vw 3.5rem; }
  .footer-inner { grid-template-columns: 2fr 1fr 1fr; gap: 5vw; }
}

.hp { position: absolute; left: -9999px; }
.apply-notice {
  margin: 0 0 0.8rem;
  padding: 0.6rem 0.8rem;
  border-radius: 0.4rem;
  background: rgba(255, 255, 255, 0.85);
  color: var(--teal-ink);
  font-size: 0.95rem;
}

/* ---------- Inner pages: stock list, catalogue, basket, checkout ---------- */

body.inner { background: #f6fafa; }

.trade-header {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.75rem 2rem;
  padding: 0.9rem 1.25rem;
  border-bottom: 1px solid #d4e4e6;
  background: #fff;
}
.trade-header .brand { position: static; flex: 0 0 auto; width: auto; height: auto; }
.trade-header .brand img { position: static; display: block; width: 9.5rem; height: auto; margin: 0; }

.trade-nav ul {
  display: flex;
  flex-wrap: wrap;
  gap: 0.25rem 1.6rem;
  margin: 0;
  padding: 0;
  list-style: none;
}
.trade-nav a {
  display: inline-block;
  padding: 0.35rem 0;
  color: var(--teal);
  font: 600 1.15rem/1.2 var(--display);
  text-decoration: none;
}
.trade-nav a:hover { color: var(--teal-ink); text-decoration: underline; text-underline-offset: 0.3em; }
.trade-nav a[aria-current="page"] { color: var(--teal-ink); text-decoration: underline; text-decoration-thickness: 3px; text-underline-offset: 0.45em; }
.trade-nav a:focus-visible,
.trade-user:focus-visible { outline: 3px solid var(--teal); outline-offset: 3px; }

.trade-account {
  display: flex;
  align-items: center;
  gap: 1.25rem;
  margin-left: auto;
}
.trade-account .btn { padding: 0.55rem 1.3rem; font-size: 1.05rem; white-space: nowrap; }
.aqt-basket { gap: 0.4em; }
.aqt-basket-count { font-weight: 600; opacity: 0.85; }
.trade-user { color: var(--teal-ink); font-weight: 500; text-decoration: none; }
.trade-user:hover { text-decoration: underline; text-underline-offset: 0.25em; }
.trade-header .btn-login { margin-left: 0; }

.trade-main {
  padding: 2rem 1.25rem 3rem;
  min-height: 60vh;
}
.trade-title {
  margin: 0 0 1.5rem;
  font-family: var(--display);
  font-size: clamp(2rem, 3.2vw, 3rem);
  line-height: 1.05;
}
.trade-content > p { max-width: 70ch; }

/* WooCommerce basket, checkout and account in the Aqualine type and colours. */
.trade-content .wc-block-components-button:not(.is-link),
.trade-content .woocommerce .button,
.trade-content .woocommerce button.button {
  border-radius: 999px;
  background: var(--burgundy);
  color: #fff;
  font-family: var(--display);
  font-weight: 700;
}
.trade-content .wc-block-components-button:not(.is-link):hover,
.trade-content .woocommerce .button:hover { background: #55102a; color: #fff; }
.trade-content a { color: var(--teal); }

@media (min-width: 1100px) {
  .trade-header { padding: 0.9rem 4vw; flex-wrap: nowrap; }
  .trade-main { padding: 2.5rem 4vw 4rem; }
}

/* ---------- Mobile header: basket, account and menu ---------- */

.header-tools {
  display: flex;
  align-items: center;
  gap: 0.25rem;
  margin-left: auto;
}
.icon-link {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2.75rem;
  height: 2.75rem;
  padding: 0;
  border: 0;
  border-radius: 999px;
  background: transparent;
  color: var(--teal-ink);
  cursor: pointer;
}
.icon-link:hover { background: rgba(13, 96, 114, 0.08); }
.icon-link:focus-visible { outline: 3px solid var(--teal); outline-offset: 1px; }
.aqt-basket-badge {
  position: absolute;
  top: 0.2rem;
  right: 0.05rem;
  min-width: 1.15rem;
  height: 1.15rem;
  padding: 0 0.3rem;
  border-radius: 999px;
  background: var(--burgundy);
  color: #fff;
  font-size: 0.7rem;
  font-weight: 600;
  line-height: 1.15rem;
  text-align: center;
}
.menu-toggle .menu-close { display: none; }
.menu-toggle[aria-expanded="true"] .menu-bars { display: none; }
.menu-toggle[aria-expanded="true"] .menu-close { display: inline; }

.nav-mobile-only { display: none; }

/* Homepage: the full nav and button appear at 1100px, below that the icons and menu. */
@media (max-width: 1099px) {
  .site-header .btn-login { display: none; }
  .site-header .header-tools { margin-left: auto; }
  .site-nav.is-open {
    display: block;
    position: absolute;
    top: 100%;
    left: 1rem;
    right: 1rem;
    padding: 0.5rem 0;
    border-radius: 0.6rem;
    background: #fff;
    box-shadow: 0 0.75rem 2rem rgba(6, 51, 61, 0.18);
  }
  .site-nav.is-open ul { flex-direction: column; gap: 0; }
  .site-nav.is-open a { display: block; padding: 0.8rem 1.25rem; font-size: 1.1rem; }
  .site-nav.is-open .nav-mobile-only { display: block; }
}
@media (min-width: 1100px) {
  .site-header .header-tools { display: none; }
}

/* Inner pages: icons and menu below 900px. */
.trade-header { position: relative; z-index: 5; }
@media (max-width: 899px) {
  .trade-header { flex-wrap: nowrap; gap: 0.5rem; padding: 0.6rem 0.75rem 0.6rem 1rem; }
  .trade-header .brand img { width: 8rem; }
  .trade-account { display: none; }
  .trade-nav { display: none; }
  .trade-nav.is-open {
    display: block;
    position: absolute;
    top: 100%;
    left: 0.75rem;
    right: 0.75rem;
    padding: 0.5rem 0;
    border-radius: 0.6rem;
    background: #fff;
    box-shadow: 0 0.75rem 2rem rgba(6, 51, 61, 0.18);
  }
  .trade-nav.is-open ul { flex-direction: column; gap: 0; }
  .trade-nav.is-open a { display: block; padding: 0.8rem 1.25rem; }
  .trade-main { padding: 1.25rem 0.75rem 2.5rem; }
}
@media (min-width: 900px) {
  .trade-header .header-tools { display: none; }
}

/* The fish photo keeps its own frame so the whole fish stays visible. */
.supply-fish .supply-photo img { min-height: 0 !important; height: auto; aspect-ratio: 1600 / 920; }

/* ---------- Phones and tablets: centred hero on its own portrait background ---------- */

@media (max-width: 1099px) {
  .site-page { background: #cfe9ec; }
  .page-bg { bottom: auto; height: auto; }
  .page-bg img {
    position: relative;
    height: auto;
    aspect-ratio: 9 / 16;
    object-position: center top;
    -webkit-mask-image: linear-gradient(to bottom, #000 72%, transparent 100%);
    mask-image: linear-gradient(to bottom, #000 72%, transparent 100%);
  }

  .hero-copy {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
  }
  .hero h1 {
    max-width: 11ch;
    margin-inline: auto;
    font-size: clamp(2.7rem, 12.5vw, 4.6rem);
    line-height: 0.9;
    text-wrap: balance;
  }
  .hero-title-sub {
    display: block;
    margin-top: 0.45em;
    color: var(--teal);
    font-size: 0.5em;
    font-weight: 600;
    line-height: 1.05;
    letter-spacing: 0.01em;
  }
  .hero-note { text-align: center; }
  .hero-intro span { text-wrap: balance; }
  .hero-link { text-align: center; }
}
