/* =========================================================================
   Shared page footer — REQ-271
   Self-contained: uses hard-coded v2.0 tokens so the footer renders
   identically regardless of which page stylesheet is loaded
   (tarotscope-base.css v1.0, dashboard.css v2.0, or none).
   ========================================================================= */

.ts-footer-v2 {
  /* Audit P1-C: include safe-area-inset on the bottom so footer links
     stay above the iOS home-indicator strip in landscape. */
  padding: 2.5rem 1.5rem calc(2rem + env(safe-area-inset-bottom, 0px));
  margin-top: 3rem;
  text-align: center;
  border-top: 1px solid rgba(201, 168, 109, 0.12);
  background: transparent;
  font-family: 'Cormorant Garamond', 'Times New Roman', serif;
  color: #7a7466;
}

.ts-footer-logo {
  /* REQ-499: official SVG wordmark replaces the text wordmark.
     UX-audit X1: 44px hit-area floor preserved. */
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  padding: 6px 0;
  margin-bottom: 0.6rem;
  transition: opacity 180ms cubic-bezier(.2,.7,.2,1);
}

.ts-footer-logo img {
  height: 26px;
  width: auto;
  display: block;
}

.ts-footer-logo:hover,
.ts-footer-logo:focus-visible {
  opacity: 0.82;
}

.ts-footer-tagline {
  font-size: 0.9rem;
  font-style: italic;
  color: #b8ae99;
  margin: 0 auto 1rem;
  max-width: 36rem;
  line-height: 1.5;
}

.ts-footer-links {
  /* Reset page-level bare `nav { position: fixed; top: 0; width: 100%; ... }` rules
     present in home.css / auth.css / profile.css, which would otherwise glue the
     footer-links nav to the top of the viewport. */
  position: static;
  top: auto;
  width: auto;
  z-index: auto;
  background: transparent;
  backdrop-filter: none;
  -webkit-backdrop-filter: none;

  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  gap: 0.5rem 1.5rem;
  margin: 0 auto 1.25rem;
  max-width: 44rem;
  padding: 0 0.5rem;
}
.ts-footer-links a {
  font-family: 'JetBrains Mono', ui-monospace, monospace;
  /* Audit P1-B: was 0.72rem (~11.5px) — bumped to 12px label floor. */
  font-size: 0.75rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: #b8ae99;
  text-decoration: none;
  /* Audit P1-A: clear 44px hit-area for footer links via padding +
     min-height (links can't use min-height alone — wrap inline-block). */
  /* P1-A tap-area: padding 14×2 + 12px font + 1.4 line-height ≈ 45px tall */
  padding: 14px 2px;
  display: inline-block;
  border-bottom: 1px solid transparent;
  transition: color 180ms cubic-bezier(.2,.7,.2,1),
              border-color 180ms cubic-bezier(.2,.7,.2,1);
}
.ts-footer-links a:hover,
.ts-footer-links a:focus-visible {
  color: #c9a86d;
  border-bottom-color: rgba(201, 168, 109, 0.4);
  outline: none;
}

.ts-footer-copy {
  font-family: 'JetBrains Mono', ui-monospace, monospace;
  /* Audit P1-B: was 0.7rem (~11.2px) opacity 0.7 → contrast ~3.4:1
     (fail WCAG AA). 0.75rem + opacity 1 + slightly stronger color. */
  font-size: 0.75rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: #908a7c;
  margin: 0;
  opacity: 1;
}

@media (max-width: 640px) {
  /* Audit P1-C: keep safe-area-inset on the mobile override too. */
  .ts-footer-v2 { padding: 2rem 1rem calc(1.5rem + env(safe-area-inset-bottom, 0px)); margin-top: 2rem; }
  .ts-footer-logo img { height: 22px; }
  .ts-footer-tagline { font-size: 0.85rem; }
  .ts-footer-links { gap: 0.4rem 1rem; margin-bottom: 1rem; }
  /* Audit P1-B: was 0.68rem (~10.88px) on mobile — keep 12px floor and
     ≥44px tap area. */
  .ts-footer-links a { font-size: 0.75rem; letter-spacing: 0.18em; padding: 14px 2px; }
}
