/* ============================================================
   Sections: collection (#earrings), giving + newsletter, about
   (#about), footer
   Owner: Agent H (Wave-3 rebuild). Nobody else edits this file.
   Class prefixes: .collection-, .giving-, .about-, .footer-
   Colours: var(--token) from css/tokens.css ONLY.
   ============================================================ */

/* ---- footer ----
   Compact, two rows, no column grid (Jody, 2026-08-09): a wide flex id+links
   row, then a rule and a meta line. Ink ground, bookending the page against
   the giving band. */
.footer {
  background: var(--ink);
  color: var(--on-dark);
  padding: clamp(34px, 3.6vw, 48px) var(--pad-x) clamp(20px, 2.2vw, 28px);
  display: grid;
  gap: clamp(22px, 2.6vw, 32px);
}

.footer-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 22px 48px;
}

.footer-id {
  display: flex;
  align-items: center;
  gap: 16px;
}

.footer-mark {
  width: 56px;
  height: 56px;
  flex: 0 0 auto;
  object-fit: contain;
}

.footer-wordmark {
  font-family: var(--font-display);
  font-size: clamp(32px, 3.4vw, 44px);
  letter-spacing: 0.01em;
  line-height: 1;
}

.footer-links {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 14px 34px;
}

/* Icon-only, no boxes, no borders — all five read as one visual set at the
   same size. Caption sits beside the icon, not under it. */
.footer-link {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  color: var(--on-dark);
  text-decoration: none;
  transition: color 160ms, transform 160ms;
}

.footer-link svg {
  width: 26px;
  height: 26px;
  flex: 0 0 auto;
}

.footer-link-caption {
  font-family: var(--font-meta);
  font-size: 10px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.footer-link:hover {
  color: var(--aqua-light);
  transform: translateY(-3px);
}

.footer-meta {
  border-top: 1px solid var(--ink-border);
  padding-top: 16px;
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 6px 24px;
  font-family: var(--font-meta);
  font-size: var(--size-meta-sm);
  letter-spacing: 0.08em;
  color: var(--meta);
}

/* ---- collection (#earrings) ---- */

.collection {
  padding: var(--pad-band);
  background: var(--paper);
}

.collection-header {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 8px 20px;
  margin-bottom: 24px;
}

.collection-title {
  font-family: var(--font-display);
  font-weight: 400;
  font-size: var(--size-section);
  letter-spacing: 0.02em;
  margin: 0;
}

.collection-all-link {
  margin-left: auto;
  font-size: var(--size-ui);
  font-weight: 600;
  color: var(--turquoise);
  text-decoration: none;
  border-bottom: 1px solid var(--line-strong);
  padding-bottom: 2px;
}

.collection-all-link:hover { border-color: var(--aqua); }

.collection-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 28px;
}

.collection-chip {
  font-family: var(--font-meta);
  font-size: var(--size-meta-sm);
  letter-spacing: 0.1em;
  text-transform: uppercase;
  padding: 9px 14px;
  background: var(--mist);
  color: var(--body-soft);
  text-decoration: none;
}

.collection-chip:hover { background: var(--line); }

.collection-chip-active {
  background: var(--ink);
  color: var(--paper);
}

.collection-chip-active:hover { background: var(--ink); }

/* Filter status line — quiet, mono, only ever visible once a chip filter
   (other than "All") has hidden at least one card. Hidden by default via the
   `hidden` attribute in the markup; collection.js's inline script unhides
   and fills it in. */
.collection-filter-note {
  font-family: var(--font-meta);
  font-size: var(--size-meta);
  color: var(--meta);
  margin: -16px 0 24px;
}

/* Zero-match state — same quiet tone, but with a live link out to Etsy so a
   filter that empties the grid still leaves the visitor somewhere to go. */
.collection-empty {
  font-family: var(--font-meta);
  font-size: var(--size-meta);
  color: var(--meta);
  margin: -16px 0 24px;
}

.collection-empty a {
  color: var(--turquoise);
  text-decoration: underline;
}

.collection-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(230px, 1fr));
  gap: 26px;
}

.collection-card {
  display: grid;
  align-content: start;
  gap: 12px;
  color: var(--ink);
}

/* The chip filter script hides a non-matching card by setting its `hidden`
   IDL property. Without this rule the [hidden] UA-stylesheet default loses
   to the author `.collection-card { display: grid }` rule above (equal
   specificity, later author rule wins over the UA origin) and the card
   stays visually laid out with an empty box. */
.collection-card[hidden] {
  display: none;
}

/* Per-card photo carousel stage. Layers are absolutely-positioned
   background-image divs cross-fading on opacity — photo 1 is visible with
   JS disabled since every layer already exists in the markup. */
.collection-card-stage {
  position: relative;
  aspect-ratio: 1;
  background: var(--mist);
  overflow: hidden;
}

.collection-card-layer {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;
  transition: opacity 320ms;
}

/* A video layer is a replaced element — inset:0 alone doesn't size it the
   way it sizes a div, so object-fit needs an explicit box to fit into. */
video.collection-card-layer {
  width: 100%;
  height: 100%;
  object-fit: cover;
  background: var(--mist);
}

.collection-card-placeholder {
  background-image: repeating-linear-gradient(45deg, var(--mist) 0 8px, var(--stripe) 8px 16px);
}

/* Placeholder scaffolding only — never rendered once a real photo exists. */
.collection-card-caption {
  position: absolute;
  left: 12px;
  top: 12px;
  font-family: var(--font-meta);
  font-size: 10px;
  color: var(--meta-placeholder);
}

.collection-card-controls {
  position: absolute;
  inset: auto 0 0 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px;
}

.collection-card-arrow {
  width: 30px;
  height: 30px;
  border: 0;
  padding: 0;
  cursor: pointer;
  background: rgba(43, 49, 52, 0.72);
  color: var(--paper);
  font-size: 14px;
  line-height: 1;
}

.collection-card-dots {
  display: flex;
  gap: 5px;
}

.collection-card-dot {
  width: 8px;
  height: 8px;
  padding: 0;
  border: 0;
  cursor: pointer;
  background: rgba(248, 248, 247, 0.45);
}

.collection-card-dot.is-active { background: var(--paper); }

.collection-card-body {
  display: grid;
  gap: 4px;
}

.collection-card-name {
  font-size: var(--size-body);
  font-weight: 600;
  line-height: 1.35;
  text-decoration: none;
  color: var(--ink);
}

.collection-card-name:hover { color: var(--turquoise); }

.collection-card-meta {
  font-family: var(--font-meta);
  font-size: var(--size-meta);
  color: var(--meta);
}

.collection-cta {
  aspect-ratio: 1;
  background: var(--ink);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 14px;
  padding: 20px;
  text-align: center;
}

.collection-cta-mark {
  width: 86px;   /* measured on the design file; the 72px in the brief was
                    carried over from v1's placeholder square */
  height: 86px;
  object-fit: contain;
}

.collection-cta-link {
  font-family: var(--font-display);
  font-size: 20px;
  color: var(--paper);
  text-decoration: none;
  line-height: 1.2;
}

.collection-cta-link:hover { color: var(--aqua-light); }

.collection-cta-icon {
  margin-left: 7px;
  vertical-align: -2px;
}

/* ---- giving-back + newsletter band ---- */

.giving {
  background: var(--ink);
  color: var(--on-dark);
  padding: clamp(48px, 6vw, 80px) var(--pad-x);
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: clamp(28px, 4vw, 56px);
  align-items: center;
}

.giving-main {
  display: grid;
  gap: 14px;
  justify-items: start;
  max-width: 520px;
}

.giving-title {
  font-family: var(--font-display);
  font-weight: 400;
  font-size: var(--size-section-sm);
  letter-spacing: 0.02em;
  margin: 0;
}

.giving-body {
  text-wrap: pretty;
  margin: 0;
  font-size: var(--size-body-lg);
  line-height: 1.65;
  color: var(--on-dark-soft);
  max-width: 46ch;
}

.giving-link {
  margin-top: 6px;
  font-size: 14px;
  font-weight: 600;
  color: var(--aqua-light);
  text-decoration: none;
  border-bottom: 1px solid var(--ink-line);
  padding-bottom: 3px;
}

.giving-link:hover { border-color: var(--aqua-light); }

.giving-newsletter {
  display: grid;
  gap: 14px;
  justify-items: start;
  max-width: 460px;
}

.giving-newsletter-heading {
  font-family: var(--font-display);
  font-weight: 400;
  font-size: 26px;
  letter-spacing: 0.02em;
  margin: 0;
}

.giving-newsletter-body {
  margin: 0;
  font-size: var(--size-ui);
  line-height: 1.6;
  color: var(--on-dark-soft);
}

.giving-newsletter-form {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  width: 100%;
}

.giving-newsletter-input {
  flex: 1 1 180px;
  min-width: 0;
  min-height: 48px;
  padding: 0 14px;
  border: 1px solid var(--ink-border);
  background: var(--ink-well);
  color: var(--on-dark);
  font-family: var(--font-text);
  font-size: var(--size-ui);
}

.giving-newsletter-submit {
  min-height: 48px;
  padding: 0 22px;
  background: var(--mist);
  color: var(--ink);
  border: 0;
  font-family: var(--font-text);
  font-size: var(--size-ui);
  font-weight: 600;
  cursor: pointer;
}

.giving-newsletter-submit:hover { background: var(--paper); }

/* ---- about (#about) ---- */

.about {
  background: var(--paper);
  padding: var(--pad-band);
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: clamp(32px, 5vw, 64px);
  align-items: center;
}

/* Ratio and object-position come from the about record as an inline style
   (about.js); these are just sane fallbacks if that's ever missing. */
.about-photo {
  width: 100%;
  aspect-ratio: 4 / 5;
  object-fit: cover;
  object-position: 50% 50%;
  background: var(--mist);
  min-width: 0;
}

.about-content {
  display: grid;
  gap: 18px;
  justify-items: start;
  max-width: 520px;
}

.about-eyebrow {
  font-family: var(--font-meta);
  font-size: var(--size-meta-sm);
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--turquoise);
}

.about-title {
  font-family: var(--font-display);
  font-weight: 400;
  font-size: var(--size-section);
  letter-spacing: 0.02em;
  margin: 0;
}

.about-paragraph-1 {
  text-wrap: pretty;
  margin: 0;
  font-size: var(--size-body-lg);
  line-height: 1.65;
  color: var(--body);
  max-width: 46ch;
}

.about-paragraph-2 {
  text-wrap: pretty;
  margin: 0;
  font-size: var(--size-body);
  line-height: 1.65;
  color: var(--body-softer);
  max-width: 46ch;
}

.about-hello {
  margin-top: 4px;
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  padding: 0 22px;
  border: 1px solid var(--turquoise);
  color: var(--turquoise);
  text-decoration: none;
  font-size: var(--size-ui);
  font-weight: 600;
  letter-spacing: 0.03em;
}

.about-hello:hover { background: var(--turquoise-tint); }

/* A layer at opacity 0 is still on top of the stack — it must not intercept
   clicks meant for the visible one (bit us with reduced-motion video controls). */
.collection-card-layer[style*="opacity: 0"] { pointer-events: none; }
