/*
 * =========================================================
 * OLYTIC SOLUTIONS - Footer Styles
 * footer.css
 *
 * Brand spec applied:
 *   - Obsidian (#1A1A1A) background (dark block)
 *   - 2px Gold rule across the very top
 *   - DM Mono for labels, section identifiers, legal line
 *   - Muted (#667085) for body text + links at rest
 *   - Gold (#C8A96E) hover state on footer links
 *   - White body text
 *
 * Requires: tokens.css, typography.css, buttons.css
 * =========================================================
 */

/* ─── Footer Shell ──────────────────────────────────────── */

.site-footer {
  background-color: var(--color-obsidian);
  color: rgba(255, 255, 255, 0.75);
  position: relative;
}

/* 2px Gold rule across the top - brand header/footer spec */
.site-footer::before {
  content: '';
  display: block;
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 2px;
  background-color: var(--color-gold);
}

/* ─── Top Grid Section ───────────────────────────────────── */

.footer-top {
  padding: var(--space-12) 0 var(--space-10);
}

.footer-inner {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr;
  gap: var(--space-10) var(--space-8);
  max-width: var(--max-width-xl);
  margin: 0 auto;
  padding: 0 var(--space-8);
  align-items: start;
}

/* ─── Brand Column ──────────────────────────────────────── */

.footer-brand {
  display: flex;
  flex-direction: column;
  gap: var(--space-5);
}

.footer-logo {
  display: flex;
  flex-direction: row;
  align-items: center;
  gap: 12px;
  text-decoration: none;
  width: fit-content;
}

/* SVG mark (white variant) inside footer */
.footer-logo__mark {
  display: block;
  width: 26px;
  height: 26px;
  flex-shrink: 0;
}

/* Text block - stacks label + sub vertically */
.footer-logo__text {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.footer-logo__label {
  font-family: var(--font-sans);
  font-weight: var(--weight-bold);
  font-size: var(--text-base);
  color: #FFFFFF;
  letter-spacing: 0.08em;
  line-height: 1;
  transition: color var(--transition-fast);
}

.footer-logo__sub {
  font-family: var(--font-mono);
  font-size: 0.625rem;
  font-weight: var(--weight-medium);
  color: var(--color-gold);
  letter-spacing: var(--tracking-label);
  text-transform: uppercase;
  line-height: 1;
}

.footer-logo:hover .footer-logo__label {
  color: var(--color-gold);
}

.footer-tagline {
  font-family: var(--font-sans);
  font-size: var(--text-sm);
  line-height: var(--leading-body);
  color: rgba(255, 255, 255, 0.55);
  max-width: 30ch;
  margin-bottom: 0;
}

/* ─── Social Icons ──────────────────────────────────────── */

.footer-social {
  display: flex;
  gap: var(--space-3);
  align-items: center;
}

.footer-social__link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border-radius: var(--radius-md);
  color: rgba(255, 255, 255, 0.45);
  border: 1px solid rgba(255, 255, 255, 0.12);
  text-decoration: none;
  transition:
    color            var(--transition-fast),
    border-color     var(--transition-fast),
    background-color var(--transition-fast);
}

.footer-social__link:hover {
  color: var(--color-gold);
  border-color: var(--color-gold);
  background-color: rgba(200, 169, 110, 0.08);
}

.footer-social__link:focus-visible {
  outline: 2px solid var(--color-gold);
  outline-offset: 2px;
}

/* ─── Link Columns ──────────────────────────────────────── */

.footer-col {
  display: flex;
  flex-direction: column;
  gap: var(--space-4);
}

/* Column heading uses the .label / .eyebrow DM Mono style */
.footer-col__heading {
  font-size: inherit;     /* Reset - label class handles sizing */
  font-weight: inherit;
  margin: 0;
}

.footer-col__links {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: var(--space-3);
}

.footer-col__links a {
  font-family: var(--font-sans);
  font-size: var(--text-sm);
  font-weight: var(--weight-regular);
  color: rgba(255, 255, 255, 0.55);
  text-decoration: none;
  transition: color var(--transition-fast);
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
}

.footer-col__links a:hover {
  color: var(--color-gold);
}

.footer-col__links a:focus-visible {
  outline: 2px solid var(--color-gold);
  outline-offset: 2px;
  border-radius: 2px;
}

/* Teal highlight for Your Roadmap in footer */
.footer-link--teal {
  color: var(--color-teal) !important;
  font-weight: var(--weight-medium) !important;
}

.footer-link--teal:hover {
  color: var(--color-gold) !important;
}

.footer-link__badge {
  font-family: var(--font-mono);
  font-size: 0.625rem;
  letter-spacing: var(--tracking-wide);
  text-transform: uppercase;
  color: var(--color-teal);
  background-color: rgba(13, 107, 110, 0.15);
  border: 1px solid rgba(13, 107, 110, 0.35);
  padding: 2px 5px;
  border-radius: var(--radius-pill);
  line-height: 1.4;
}

/* ─── Newsletter Column ─────────────────────────────────── */

.footer-newsletter__desc {
  font-size: var(--text-sm);
  color: rgba(255, 255, 255, 0.45);
  line-height: var(--leading-body);
  margin-bottom: var(--space-4);
}

.footer-newsletter__row {
  display: flex;
  gap: var(--space-2);
  align-items: stretch;
}

.footer-newsletter__input {
  flex: 1;
  min-width: 0;

  font-family: var(--font-sans);
  font-size: var(--text-sm);
  color: #FFFFFF;
  background-color: rgba(255, 255, 255, 0.07);
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: var(--radius-md);
  padding: 0.5625rem var(--space-4);
  outline: none;
  transition:
    border-color     var(--transition-fast),
    background-color var(--transition-fast);
}

.footer-newsletter__input::placeholder {
  color: rgba(255, 255, 255, 0.30);
}

.footer-newsletter__input:focus {
  border-color: var(--color-gold);
  background-color: rgba(255, 255, 255, 0.10);
}

/* ─── Newsletter Status & Success ─────────────────────── */

.footer-newsletter__status {
  margin-top: var(--space-2);
  font-size: var(--text-xs);
  color: rgba(255, 255, 255, 0.50);
}

.footer-newsletter__status--error {
  color: #E87C6E;
}

.footer-newsletter__success {
  font-size: var(--text-sm);
  color: var(--color-gold);
  margin: 0;
}

/* ─── Bottom Legal Bar ──────────────────────────────────── */

.footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  padding: var(--space-5) 0;
}

.footer-bottom__inner {
  max-width: var(--max-width-xl);
  margin: 0 auto;
  padding: 0 var(--space-8);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-4);
  flex-wrap: wrap;
}

/* DM Mono brand identifier - left side */
.footer-bottom__copy {
  font-family: var(--font-sans);
  font-size: var(--text-xs);
  color: rgba(255, 255, 255, 0.30);
  display: flex;
  align-items: center;
  gap: var(--space-2);
  margin: 0;
  max-width: 100%;
}

.footer-mono {
  font-family: var(--font-mono);
  letter-spacing: var(--tracking-wide);
  color: rgba(255, 255, 255, 0.40);
}

.footer-bottom__sep {
  color: rgba(255, 255, 255, 0.20);
  padding: 0 var(--space-1);
}

/* Legal links - right side */
.footer-bottom__legal {
  display: flex;
  align-items: center;
  gap: var(--space-3);
}

.footer-bottom__legal a {
  font-family: var(--font-sans);
  font-size: var(--text-xs);
  color: rgba(255, 255, 255, 0.30);
  text-decoration: none;
  transition: color var(--transition-fast);
}

.footer-bottom__legal a:hover {
  color: rgba(255, 255, 255, 0.70);
}

.footer-bottom__legal span {
  color: rgba(255, 255, 255, 0.15);
}

/* ─── Responsive ────────────────────────────────────────── */

@media (max-width: 1024px) {
  .footer-inner {
    grid-template-columns: 1fr 1fr;
    gap: var(--space-10) var(--space-8);
  }

  .footer-brand {
    grid-column: 1 / -1;
    flex-direction: row;
    flex-wrap: wrap;
    gap: var(--space-8);
    align-items: flex-start;
  }

  .footer-tagline {
    max-width: 50ch;
  }
}

@media (max-width: 640px) {
  .footer-top {
    padding: var(--space-12) 0 var(--space-8);
  }

  .footer-inner {
    grid-template-columns: 1fr 1fr;
    gap: var(--space-8) var(--space-6);
    padding: 0 var(--space-5);
  }

  .footer-brand {
    grid-column: 1 / -1;
    flex-direction: column;
  }

  .footer-tagline {
    max-width: 100%;
  }

  .footer-col--newsletter {
    grid-column: 1 / -1;
  }

  .footer-newsletter__row {
    flex-direction: column;
  }

  .footer-newsletter__row .btn {
    width: 100%;
    justify-content: center;
  }

  .footer-bottom__inner {
    flex-direction: column;
    align-items: flex-start;
    padding: 0 var(--space-5);
    gap: var(--space-3);
  }
}

@media (max-width: 360px) {
  .footer-inner {
    grid-template-columns: 1fr;
  }
}

/* ─── Screen-reader only utility ────────────────────────── */
/* (Shared with other components - defined once here if
    not already in a global utilities file) */

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border-width: 0;
}
