/* ==========================================================================
   DAAMRI Deals — Base styles
   Reset, typography, layout primitives, header, footer
   ========================================================================== */

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

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

body {
  background: var(--paper);
  color: var(--ink);
  font-family: var(--body);
  font-size: 17px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

img {
  display: block;
  max-width: 100%;
  object-fit: cover;
}

a {
  color: inherit;
}

ul[role="list"],
ol[role="list"] {
  list-style: none;
}

/* Accessible skip link */
.skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
  z-index: 100;
  background: var(--ink);
  color: var(--paper);
  font-family: var(--ui);
  font-size: 13px;
  padding: 12px 20px;
}

.skip-link:focus {
  left: 0;
}

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

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

/* --------------------------------------------------------------------------
   Typography
   -------------------------------------------------------------------------- */

h1, h2, h3, h4 {
  font-family: var(--disp);
  font-weight: 500;
  letter-spacing: -.01em;
  line-height: 1.15;
}

h3, h4 {
  font-weight: 600;
}

.t-display { font-size: clamp(44px, 7vw, 88px); line-height: .98; }
.t-h2      { font-size: clamp(28px, 3.2vw, 40px); }
.t-h3      { font-size: 26px; }
.t-h4      { font-size: 19px; }

.t-body    { font-family: var(--body); font-size: 17px; }
.t-italic  { font-family: var(--body); font-style: italic; font-size: 19px; color: var(--forest); }
.t-small   { font-family: var(--ui); font-size: 13px; color: var(--muted); }

.t-caption,
.kicker {
  font-family: var(--ui);
  font-size: 11px;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--muted);
}

.kicker {
  font-size: 12px;
  letter-spacing: .15em;
  color: var(--oxblood);
}

.doc-label {
  font-family: var(--ui);
  font-size: 11.5px;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--oxblood);
}

/* Prose links */
.prose a {
  color: var(--oxblood);
  text-decoration: underline;
  text-underline-offset: 3px;
  text-decoration-thickness: 1px;
}

.prose a:hover {
  color: var(--ink);
}

/* --------------------------------------------------------------------------
   Layout primitives
   -------------------------------------------------------------------------- */

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

.section {
  padding: 76px 0;
}

.section--divided {
  border-bottom: 1px solid var(--stone);
}

.section-head {
  margin-bottom: var(--sp-12);
}

.section-head .doc-label {
  margin-bottom: 14px;
}

.section-head h2 {
  font-size: clamp(28px, 3.2vw, 40px);
  margin-bottom: var(--sp-4);
}

.section-head .desc {
  color: var(--muted);
  max-width: 560px;
  font-size: 16px;
}

.section-head--row {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  gap: var(--sp-6);
  flex-wrap: wrap;
}

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

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  border-bottom: 1px solid var(--stone);
}

/* Frosted-glass backdrop lives on a pseudo-element, not on .site-header
   itself — a `backdrop-filter` on the header would make it the containing
   block for any `position: fixed` descendant (the mobile nav flyout lives
   inside the header), breaking the flyout's full-viewport coverage. */
.site-header::before {
  content: '';
  position: absolute;
  inset: 0;
  z-index: -1;
  background: rgba(243, 238, 226, .92);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
}

.site-header .wrap {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: var(--sp-6);
  padding-top: 18px;
  padding-bottom: 18px;
}

.site-logo {
  display: inline-flex;
  align-items: center;
  flex-shrink: 0;
}

.site-logo img {
  height: 44px;
  width: auto;
}

.site-nav {
  display: flex;
  align-items: center;
  gap: 28px;
  font-family: var(--ui);
  font-size: 13px;
}

.site-nav a {
  color: var(--muted);
  text-decoration: none;
  transition: var(--ease);
}

.site-nav a:hover {
  color: var(--ink);
}

.site-nav a[aria-current="page"] {
  color: var(--ink);
  border-bottom: 1px solid var(--oxblood);
  padding-bottom: 3px;
}

.nav-toggle {
  display: none;
  background: none;
  border: none;
  font-size: 20px;
  color: var(--ink);
  cursor: pointer;
  padding: 12px;
  margin: -12px -12px -12px 0;
}

.nav-phone {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 9px 18px;
  border-radius: var(--radius-pill);
  background: var(--forest);
  color: var(--white) !important;
  font-family: var(--ui);
  font-size: 13px;
  font-weight: 600;
  white-space: nowrap;
  transition: var(--ease);
}

.nav-phone i {
  font-size: 12px;
}

.nav-phone:hover {
  background: var(--ink);
}

/* --------------------------------------------------------------------------
   Footer
   -------------------------------------------------------------------------- */

.site-footer {
  background: var(--paper-2);
  border-top: 1px solid var(--stone);
  padding: 64px 0 40px;
}

.site-footer .footer-grid {
  display: flex;
  justify-content: space-between;
  gap: var(--sp-12);
  flex-wrap: wrap;
}

.site-footer .footer-brand {
  max-width: 320px;
}

.site-footer .footer-brand img {
  height: 40px;
  width: auto;
  margin-bottom: 14px;
}

.site-footer .fcols {
  display: flex;
  gap: 56px;
  flex-wrap: wrap;
}

.site-footer .fcols h2 {
  font-family: var(--ui);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 12px;
}

.site-footer .fcols a {
  display: block;
  font-family: var(--ui);
  font-size: 13px;
  margin-bottom: 9px;
  color: var(--ink);
  text-decoration: none;
}

.site-footer .fcols a:hover {
  color: var(--oxblood);
}

.site-footer .footer-legal {
  margin-top: var(--sp-12);
  padding-top: var(--sp-6);
  border-top: 1px solid var(--stone);
  display: flex;
  justify-content: space-between;
  gap: var(--sp-4);
  flex-wrap: wrap;
  font-family: var(--ui);
  font-size: 12px;
  color: var(--muted);
}

/* --------------------------------------------------------------------------
   Responsive
   -------------------------------------------------------------------------- */

@media (max-width: 1000px) {
  .site-nav {
    position: fixed;
    inset: 0;
    top: 81px;
    z-index: 40;
    flex-direction: column;
    align-items: flex-start;
    gap: 0;
    background: var(--paper);
    padding: var(--sp-8) var(--wrap-pad);
    transform: translateX(100%);
    transition: transform .3s ease;
  }

  .site-nav.is-open {
    transform: translateX(0);
  }

  .site-nav a {
    font-size: 17px;
    padding: 14px 0;
    width: 100%;
    border-bottom: 1px solid var(--stone);
  }

  .site-nav .btn {
    margin-top: var(--sp-6);
  }

  .site-nav .nav-phone {
    justify-content: center;
    width: 100%;
    margin-top: var(--sp-4);
    padding: 12px 0;
    border-bottom: none;
  }

  .nav-toggle {
    display: block;
  }
}

@media (max-width: 640px) {
  .wrap {
    padding-left: 22px;
    padding-right: 22px;
  }

  .section {
    padding: 56px 0;
  }

  .site-logo img {
    height: 36px;
  }

  .site-nav {
    top: 73px;
    padding-left: 22px;
    padding-right: 22px;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: .01ms !important;
    transition-duration: .01ms !important;
  }

  html {
    scroll-behavior: auto;
  }
}
