/* SiyanLife - shared styles. Colors are sampled from the logo. */

/* Self-hosted fonts (SIL Open Font License, see /assets/fonts/LICENSE.txt). */
@font-face {
  font-family: "DM Sans";
  font-style: normal;
  font-weight: 400 700;
  font-display: swap;
  src: url("/assets/fonts/dm-sans-latin.woff2") format("woff2");
}

@font-face {
  font-family: "Cormorant Garamond";
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url("/assets/fonts/cormorant-garamond-normal-latin.woff2") format("woff2");
}

@font-face {
  font-family: "Cormorant Garamond";
  font-style: italic;
  font-weight: 500 600;
  font-display: swap;
  src: url("/assets/fonts/cormorant-garamond-italic-latin.woff2") format("woff2");
}
:root {
  --crimson: #bb1247;
  --crimson-dark: #960e39;
  --navy: #183551;
  --navy-soft: #2c4d6e;
  --leaf: #5e9e35;
  --leaf-tint: #e9f1e1;
  --leaf-text: #3f6e22;
  --paper: #faf8f3;
  --surface: #ffffff;
  --sand: #f1ede3;
  --ink: #1d2733;
  --muted: #5b6672;
  --line: #e2ddd1;

  --serif: "Cormorant Garamond", Georgia, "Times New Roman", serif;
  --sans: "DM Sans", system-ui, -apple-system, "Segoe UI", sans-serif;

  --radius: 10px;
  --wrap: 1120px;
  --gutter: 16px;
}

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

html {
  scroll-behavior: smooth;
  color-scheme: light;
}

[id] {
  scroll-margin-top: 90px;
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  * {
    transition: none !important;
  }
}

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font: 16px/1.65 var(--sans);
  -webkit-font-smoothing: antialiased;
}

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

a {
  color: var(--navy);
}

a:hover {
  color: var(--crimson);
}

button,
input {
  font: inherit;
}

h1,
h2,
h3 {
  font-family: var(--serif);
  font-weight: 600;
  color: var(--navy);
  line-height: 1.1;
  margin: 0 0 0.5em;
}

h1 {
  font-size: clamp(2.6rem, 6vw, 4.4rem);
  letter-spacing: -0.01em;
}

h2 {
  font-size: clamp(2rem, 4vw, 2.8rem);
}

h3,
.h3 {
  font-size: 1.5rem;
}

p {
  margin: 0 0 1em;
}

:focus-visible {
  outline: 3px solid var(--leaf);
  outline-offset: 2px;
}

.wrap {
  max-width: var(--wrap);
  margin: 0 auto;
  padding: 0 var(--gutter);
}

.skip-link {
  position: absolute;
  left: -9999px;
}

.skip-link:focus {
  left: var(--gutter);
  top: 8px;
  background: var(--surface);
  padding: 8px 12px;
  z-index: 20;
}

/* ---------- Header ---------- */
.site-header {
  background: var(--paper);
  border-bottom: 1px solid var(--line);
  position: sticky;
  top: 0;
  z-index: 10;
}

.site-header .wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  min-height: 72px;
}

.brand img {
  width: 170px;
}

.nav-toggle {
  display: none;
  background: none;
  border: 1px solid var(--line);
  border-radius: 6px;
  padding: 10px 16px;
  min-height: 44px;
  color: var(--navy);
  cursor: pointer;
}

.site-nav ul {
  list-style: none;
  display: flex;
  align-items: center;
  gap: 28px;
  margin: 0;
  padding: 0;
}

.site-nav a {
  text-decoration: none;
  font-size: 0.95rem;
  font-weight: 500;
  color: var(--ink);
}

.site-nav a:hover,
.site-nav a[aria-current="page"] {
  color: var(--crimson);
}

.site-nav a[aria-current="page"] {
  text-decoration: underline;
  text-underline-offset: 6px;
}

.site-nav .btn,
.site-nav a.btn[aria-current="page"] {
  color: #fff;
  text-decoration: none;
}

.site-nav .btn:hover {
  color: #fff;
}

/* ---------- Buttons, chips, cards ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 20px;
  min-height: 44px;
  border: 1px solid var(--crimson);
  border-radius: 999px;
  background: var(--crimson);
  color: #fff;
  font-weight: 600;
  font-size: 0.95rem;
  text-decoration: none;
  cursor: pointer;
  transition: background 0.15s;
}

.btn:hover {
  background: var(--crimson-dark);
  color: #fff;
}

.btn-outline {
  background: transparent;
  color: var(--navy);
  border-color: var(--navy);
}

.btn-outline:hover {
  background: var(--navy);
  color: #fff;
}

.chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  list-style: none;
  padding: 0;
  margin: 0 0 24px;
}

.chips li {
  background: var(--leaf-tint);
  color: var(--navy);
  border-radius: 999px;
  padding: 6px 14px;
  font-size: 0.875rem;
}

.badge {
  display: inline-block;
  background: var(--leaf-tint);
  color: var(--leaf-text);
  border-radius: 999px;
  padding: 4px 12px;
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.eyebrow {
  font-family: var(--sans);
  font-size: 0.8rem;
  line-height: 1.4;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--leaf-text);
  margin: 0 0 12px;
}

.card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 24px;
}

.card h3 {
  margin-bottom: 8px;
}

.card p:last-child {
  margin-bottom: 0;
}

.grid {
  display: grid;
  gap: 16px;
}

.grid-2 {
  grid-template-columns: repeat(2, 1fr);
}

.grid-3 {
  grid-template-columns: repeat(3, 1fr);
}

.grid-4 {
  grid-template-columns: repeat(4, 1fr);
}

.muted {
  color: var(--muted);
}

.note {
  border-left: 3px solid var(--leaf);
  background: var(--leaf-tint);
  padding: 12px 16px;
  border-radius: 0 6px 6px 0;
  font-size: 0.925rem;
  color: var(--ink);
}

.text-link {
  font-weight: 600;
  text-decoration: none;
  border-bottom: 1px solid currentColor;
}

/* ---------- Sections ---------- */
.section {
  padding: 80px 0;
}

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

.section-head {
  max-width: 640px;
  margin-bottom: 36px;
}

.section-head p {
  color: var(--muted);
}

.page-head {
  padding: 72px 0 24px;
  max-width: 720px;
}

.page-head p {
  font-size: 1.125rem;
  color: var(--muted);
}

/* ---------- Home ---------- */
.hero {
  padding: 96px 0 80px;
  text-align: center;
}

.hero h1 {
  max-width: 820px;
  margin: 0 auto 20px;
}

.hero h1 em {
  color: var(--crimson);
}

.hero .lead {
  font-size: 1.2rem;
  color: var(--muted);
  margin-bottom: 32px;
}

.actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.hero .actions {
  justify-content: center;
}

.offering .icon {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: var(--leaf-tint);
  color: var(--leaf);
  margin-bottom: 16px;
}

.offering .icon svg {
  width: 22px;
  height: 22px;
}

.offering a {
  margin-top: 12px;
  display: inline-block;
}

.companion {
  background: var(--navy);
  color: #e4ebf2;
}

.companion h2 {
  color: #fff;
}

.companion .eyebrow {
  color: #9ccb7a;
}

.companion .badge {
  margin-bottom: 16px;
}

.companion ul {
  margin: 0;
  padding-left: 1.2em;
  font-size: 1.05rem;
}

.companion li {
  margin-bottom: 8px;
}

.split {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 48px;
  align-items: center;
}

.horizon {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 32px;
  background: var(--surface);
}

.newsletter {
  text-align: center;
}

.newsletter .section-head {
  margin: 0 auto 24px;
}

.field input {
  flex: 1;
  min-width: 0;
  padding: 12px 16px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--surface);
  color: var(--ink);
}

/* ---------- Compare ---------- */
.compare-panel {
  max-width: 720px;
}

.field label {
  display: block;
  font-weight: 600;
  margin-bottom: 8px;
}

.field .row {
  display: flex;
  gap: 8px;
}

.field .hint {
  font-size: 0.875rem;
  color: var(--muted);
  margin-top: 8px;
}

.field-error {
  color: var(--crimson);
  font-size: 0.9rem;
  min-height: 1.4em;
  margin-top: 6px;
}

.status {
  margin-top: 20px;
}

.status[hidden] {
  display: none;
}

.status dl {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 4px 16px;
  margin: 8px 0 0;
}

.status dt {
  font-weight: 600;
}

.status dd {
  margin: 0;
  overflow-wrap: anywhere;
}

/* ---------- Compare results ---------- */
.results {
  margin-top: 32px;
  min-width: 0;
}

.results > * + * {
  margin-top: 40px;
}

.results .note {
  margin-bottom: 0;
}

.link-btn {
  background: none;
  border: 0;
  padding: 4px 0;
  color: var(--navy);
  font-weight: 600;
  text-decoration: underline;
  cursor: pointer;
}

.link-btn:hover {
  color: var(--crimson);
}

.product-card {
  display: flex;
  gap: 20px;
  align-items: center;
}

.product-card .product-title {
  font-weight: 600;
  font-size: 1.1rem;
  margin-bottom: 4px;
}

.product-card img,
.alt img,
.no-image {
  width: 96px;
  height: 96px;
  object-fit: contain;
  flex: none;
  border-radius: 6px;
  background: var(--surface);
}

.no-image {
  background: var(--sand);
}

.table-scroll {
  overflow-x: auto;
  max-width: 100%;
  border-radius: var(--radius);
}

.data-table {
  width: 100%;
  border-collapse: collapse;
  background: var(--surface);
  border: 1px solid var(--line);
}

.data-table th,
.data-table td {
  text-align: left;
  vertical-align: top;
  padding: 10px 14px;
  border-bottom: 1px solid var(--line);
}

.data-table thead th {
  font-size: 0.8rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--muted);
  background: var(--sand);
}

.data-table tbody th {
  font-weight: 600;
}

.data-table .best {
  background: var(--leaf-tint);
}

.data-table .price {
  font-weight: 700;
  white-space: nowrap;
}

.tag {
  display: inline-block;
  font-size: 0.75rem;
  font-weight: 700;
  padding: 2px 8px;
  border-radius: 999px;
  background: var(--leaf-text);
  color: #fff;
  margin-left: 6px;
}

.store-tag {
  display: block;
  color: var(--muted);
  font-size: 0.8rem;
  text-transform: none;
  letter-spacing: 0;
  font-weight: 400;
}

td .store-tag {
  display: inline;
}

.not-listed {
  color: var(--muted);
  font-size: 0.875rem;
}

.spec-table th,
.spec-table td {
  min-width: 150px;
}

.spec-table .col-head {
  max-width: 220px;
}

.spec-table .col-name {
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 3;
  overflow: hidden;
  color: var(--ink);
  text-transform: none;
  letter-spacing: 0;
  font-size: 0.85rem;
  font-weight: 600;
}

.spec-table tbody th[scope="row"],
.spec-table thead th:first-child {
  position: sticky;
  left: 0;
  z-index: 1;
  background: var(--surface);
}

.spec-table thead th:first-child {
  background: var(--sand);
}

.spec-table .section-row th {
  position: sticky;
  left: 0;
  background: var(--sand);
  color: var(--navy);
  font-family: var(--serif);
  font-size: 1.15rem;
}

.alt-list {
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  gap: 12px;
}

.alt {
  display: grid;
  grid-template-columns: 2ch 72px minmax(0, 1fr);
  gap: 16px;
  align-items: start;
}

.alt img,
.alt .no-image {
  width: 72px;
  height: 72px;
}

.alt .rank {
  font-family: var(--serif);
  font-size: 1.6rem;
  line-height: 1;
  color: var(--crimson);
}

.alt h3 {
  font-family: var(--sans);
  font-size: 1rem;
  color: var(--ink);
  line-height: 1.4;
  margin-bottom: 4px;
}

.alt p {
  margin-bottom: 4px;
}

.alt .reason {
  font-size: 0.9rem;
}

/* ---------- Journal ---------- */
.guide .meta {
  font-size: 0.8rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 8px;
}

/* ---------- About ---------- */
.prose {
  max-width: 720px;
}

.prose h2 {
  margin-top: 48px;
}

.motto {
  font-family: var(--serif);
  font-size: clamp(1.8rem, 4vw, 2.4rem);
  color: var(--crimson);
  font-style: italic;
  font-weight: 500;
  margin: 0 0 16px;
}

/* ---------- 404 ---------- */
.notfound {
  padding: 120px 0;
  text-align: center;
}

.notfound .actions {
  justify-content: center;
}

/* ---------- Footer ---------- */
.site-footer {
  border-top: 1px solid var(--line);
  padding: 40px 0 28px;
  font-size: 0.925rem;
}

.site-footer .top {
  display: flex;
  justify-content: space-between;
  gap: 24px;
  flex-wrap: wrap;
  align-items: flex-start;
}

.site-footer .brand img {
  width: 140px;
  margin-bottom: 8px;
}

.site-footer ul {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: 20px;
  margin: 0;
  padding: 0;
}

.site-footer a {
  text-decoration: none;
  display: inline-block;
  padding: 8px 0;
}

.site-version {
  white-space: nowrap;
}

.site-version::before {
  content: "\00b7";
  margin: 0 6px;
}

.site-footer .legal {
  color: var(--muted);
  font-size: 0.85rem;
  margin-top: 28px;
}

/* ---------- Responsive ---------- */
@media (max-width: 900px) {
  .grid-4 {
    grid-template-columns: repeat(2, 1fr);
  }

  .grid-3 {
    grid-template-columns: 1fr;
  }

  .split {
    grid-template-columns: 1fr;
    gap: 24px;
  }
}

@media (max-width: 760px) {
  .nav-toggle {
    display: inline-block;
  }

  .site-nav {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: var(--paper);
    border-bottom: 1px solid var(--line);
  }

  .site-nav.open {
    display: block;
  }

  .site-nav ul {
    flex-direction: column;
    align-items: flex-start;
    gap: 4px;
    padding: 12px var(--gutter) 20px;
  }

  .site-nav li {
    width: 100%;
  }

  .site-nav a {
    display: block;
    padding: 8px 0;
  }

  .site-nav .btn {
    display: inline-flex;
    margin-top: 8px;
    padding: 10px 20px;
  }

  .brand img {
    width: 140px;
  }

  .section {
    padding: 56px 0;
  }

  .hero {
    padding: 64px 0 56px;
  }

  .page-head {
    padding: 48px 0 16px;
  }
}

@media (max-width: 560px) {
  .grid-2,
  .grid-4 {
    grid-template-columns: 1fr;
  }

  .field .row {
    flex-direction: column;
  }

  .horizon {
    padding: 24px;
  }
}
