/* ─── Dyuti Shared Styles ─── */
/* Used across all pages: landing, blog, legal, about, compare */

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

:root {
  /* ─── Canonical Dyuti design tokens (matches homepage index.html) ─── */
  /* Surfaces */
  --ivory: #FFF9F9;
  --ivory-warm: #F6E5E5;
  --paper: #FFFFFF;

  /* Accent — terracotta family */
  --terracotta: #9E0D0D;
  --terracotta-deep: #760606;
  --terracotta-light: #C24A4A;
  --terracotta-soft: rgba(158,13,13,0.10);
  --terracotta-glow: rgba(158,13,13,0.22);

  /* Functional / semantic */
  --whatsapp: #1FB957;
  --whatsapp-deep: #0B6E37;
  --green: #2D6A4F;       /* success */
  --plum: #713661;        /* supporting accent (blog categories) */

  /* Ink (text) */
  --ink: #18120E;
  --ink-2: #36302C;
  --ink-3: #6B6157;
  --ink-4: #776D62;  /* darkened from #9C9388 for AA contrast */

  /* Rules / hairlines */
  --rule: #EFDADA;
  --rule-soft: #F6E8E8;

  /* Type */
  --serif: 'Libre Baskerville', Georgia, 'Times New Roman', serif;
  --sans: 'Figtree', system-ui, -apple-system, 'Segoe UI', sans-serif;
  --mono: ui-monospace, 'SF Mono', Menlo, monospace;

  /* Radius */
  --radius-sm: 10px;
  --radius: 16px;
  --radius-lg: 24px;
  --radius-xl: 32px;
  --radius-pill: 9999px;

  /* Shadows (warm ink-tinted) */
  --shadow-xs: 0 1px 2px rgba(24,18,14,0.05);
  --shadow-sm: 0 1px 2px rgba(24,18,14,0.04), 0 2px 4px rgba(24,18,14,0.04);
  --shadow-md: 0 2px 4px rgba(24,18,14,0.04), 0 8px 24px rgba(24,18,14,0.06), 0 16px 48px rgba(24,18,14,0.04);
  --shadow-lg: 0 4px 8px rgba(24,18,14,0.05), 0 16px 40px rgba(24,18,14,0.08), 0 32px 80px rgba(24,18,14,0.06);
}

html { font-size: 16px; -webkit-font-smoothing: antialiased; }

body {
  background: var(--ivory);
  color: var(--ink);
  font-family: var(--sans);
  overflow-x: hidden;
}

a { color: inherit; }

/* Libre Baskerville headings read best at regular weight (matches the homepage) */
h1, h2 { font-weight: 400; }
.blog-related h2 { font-weight: 600; }

/* ─── Nav: the site header now lives in /header.css ─── */

.logo {
  font-family: var(--serif);
  font-style: italic;
  font-size: 1.625rem;
  color: var(--terracotta);
  letter-spacing: -0.02em;
  text-decoration: none;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 28px;
}

.nav-links a {
  font-family: var(--sans);
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--ink-2);
  text-decoration: none;
  letter-spacing: 0.01em;
  transition: color 0.3s ease;
}

.nav-links a:hover {
  color: var(--terracotta);
}

.nav-cta {
  font-family: var(--sans);
  font-size: 0.8125rem;
  font-weight: 600;
  color: var(--paper);
  background: var(--terracotta-deep);
  border: none;
  padding: 10px 24px;
  border-radius: var(--radius-pill);
  cursor: pointer;
  letter-spacing: 0.01em;
  transition: all 0.3s ease;
  text-decoration: none;
  display: inline-block;
}

.nav-cta:hover {
  background: #5E0505;
  box-shadow: 0 4px 16px var(--terracotta-glow);
}

/* ─── Footer ─── */
.site-footer {
  padding: 60px 24px 32px;
  background: var(--paper);
  border-top: 1px solid var(--rule);
}

.footer-inner {
  max-width: 1100px;
  margin: 0 auto;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.5fr repeat(3, 1fr);
  gap: 40px;
  margin-bottom: 48px;
}

.footer-brand .logo {
  display: inline-block;
  margin-bottom: 14px;
}

.footer-brand p {
  font-size: 0.875rem;
  line-height: 1.6;
  color: var(--ink-4);
  max-width: 260px;
}

.footer-col h4 {
  font-family: var(--sans);
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--ink-2);
  margin-bottom: 16px;
}

.footer-col ul {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.footer-col a {
  font-family: var(--sans);
  font-size: 0.875rem;
  color: var(--ink-4);
  text-decoration: none;
  transition: color 0.3s ease;
}

.footer-col a:hover {
  color: var(--terracotta);
}

.footer-bottom {
  padding-top: 24px;
  border-top: 1px solid var(--rule-soft);
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.footer-copyright {
  font-size: 0.8125rem;
  color: var(--ink-4);
}

.footer-legal {
  display: flex;
  gap: 20px;
}

.footer-legal a {
  font-size: 0.8125rem;
  color: var(--ink-4);
  text-decoration: none;
  transition: color 0.3s ease;
}

.footer-legal a:hover {
  color: var(--terracotta);
}

/* ─── Entrance animations ─── */
.reveal {
  opacity: 0;
  transform: translateY(24px);
  animation: fadeUp 0.8s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

.reveal-d1 { animation-delay: 0.15s; }
.reveal-d2 { animation-delay: 0.35s; }
.reveal-d3 { animation-delay: 0.5s; }
.reveal-d4 { animation-delay: 0.65s; }
.reveal-d5 { animation-delay: 0.8s; }
.reveal-d6 { animation-delay: 1s; }

@keyframes fadeUp {
  to { opacity: 1; transform: translateY(0); }
}

@keyframes fadeDown {
  from { opacity: 0; transform: translateY(-12px); }
  to { opacity: 1; transform: translateY(0); }
}

/* ─── Scroll reveal ─── */
/* hidden only when JS runs (html.js), so content shows if JS fails */
.js .scroll-reveal {
  opacity: 0;
  transform: translateY(30px);
  transition: all 0.7s cubic-bezier(0.16, 1, 0.3, 1);
}

.js .scroll-reveal.visible {
  opacity: 1;
  transform: translateY(0);
}

/* ─── CTA (shared) ─── */
.cta-button {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--sans);
  font-size: 1.0625rem;
  font-weight: 600;
  color: var(--paper);
  background: var(--terracotta-deep);
  border: none;
  padding: 18px 38px;
  border-radius: var(--radius-pill);
  cursor: pointer;
  letter-spacing: 0.01em;
  transition: all 0.35s cubic-bezier(0.25, 0.46, 0.45, 0.94);
  box-shadow: 0 4px 24px var(--terracotta-glow);
  text-decoration: none;
}

.cta-button:hover {
  background: #5E0505;
  box-shadow: 0 6px 32px rgba(158,13,13,0.45);
  transform: translateY(-2px);
}

.cta-button .arrow {
  transition: transform 0.3s ease;
}

.cta-button:hover .arrow {
  transform: translateX(4px);
}

.cta-meta {
  font-family: var(--sans);
  font-size: 0.875rem;
  color: var(--ink-4);
  letter-spacing: 0.02em;
}

.cta-meta .green {
  color: var(--whatsapp-deep);
  font-weight: 500;
}

.cta-meta .bold {
  color: var(--ink);
  font-weight: 500;
}

/* ─── Utilities ─── */
.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;
}

/* ─── Hamburger Button (mobile only) ─── */
.nav-hamburger {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  padding: 8px;
  margin-right: -8px;
  z-index: 110;
}

.nav-hamburger-icon {
  display: block;
  width: 20px;
  height: 2px;
  background: var(--ink);
  position: relative;
  transition: background 0.2s ease;
}

.nav-hamburger-icon::before,
.nav-hamburger-icon::after {
  content: '';
  position: absolute;
  left: 0;
  width: 20px;
  height: 2px;
  background: var(--ink);
  transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.nav-hamburger-icon::before { top: -6px; }
.nav-hamburger-icon::after { top: 6px; }

.nav-hamburger.open .nav-hamburger-icon { background: transparent; }
.nav-hamburger.open .nav-hamburger-icon::before { top: 0; transform: rotate(45deg); }
.nav-hamburger.open .nav-hamburger-icon::after { top: 0; transform: rotate(-45deg); }

/* ─── Mobile Menu Panel ─── */
.mobile-menu {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 99;
  background: rgba(255,249,249,0.97);
  backdrop-filter: saturate(160%) blur(24px);
  -webkit-backdrop-filter: saturate(160%) blur(24px);
  padding: 90px 28px 40px;
  opacity: 0;
  transform: translateY(-10px);
  transition: opacity 0.3s cubic-bezier(0.16, 1, 0.3, 1),
              transform 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  pointer-events: none;
  overflow-y: auto;
}

.mobile-menu.open {
  opacity: 1;
  transform: translateY(0);
  pointer-events: auto;
}

.mobile-menu-links {
  display: flex;
  flex-direction: column;
}

.mobile-menu-link {
  font-family: var(--sans);
  font-size: 1.125rem;
  font-weight: 500;
  color: var(--ink-2);
  text-decoration: none;
  padding: 16px 0;
  border-bottom: 1px solid var(--rule);
  transition: color 0.2s ease;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.mobile-menu-link:first-child { border-top: 1px solid var(--rule); }
.mobile-menu-link:hover { color: var(--terracotta); }

.mobile-menu-link .mm-arrow {
  font-size: 0.8125rem;
  color: var(--ink-4);
  transition: transform 0.2s ease, color 0.2s ease;
}

.mobile-menu-link:hover .mm-arrow {
  transform: translateX(4px);
  color: var(--terracotta);
}

.mobile-menu-section {
  margin-top: 24px;
}

.mobile-menu-section-label {
  font-family: var(--sans);
  font-size: 0.6875rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--ink-4);
  margin-bottom: 4px;
}

.mobile-menu-cta {
  display: block;
  text-align: center;
  font-family: var(--sans);
  font-size: 1rem;
  font-weight: 600;
  color: var(--paper);
  background: var(--terracotta-deep);
  padding: 16px 32px;
  border-radius: var(--radius-pill);
  text-decoration: none;
  margin-top: 32px;
  transition: all 0.3s ease;
  box-shadow: 0 4px 24px var(--terracotta-glow);
}

.mobile-menu-cta:hover { background: #5E0505; }

.mobile-menu-meta {
  text-align: center;
  margin-top: 12px;
  font-family: var(--sans);
  font-size: 0.8125rem;
  color: var(--ink-4);
}

.mobile-menu-meta .bold { color: var(--ink); font-weight: 500; }
.mobile-menu-meta .green { color: var(--whatsapp); font-weight: 500; }

/* ─── Desktop responsive ─── */
@media (min-width: 768px) {
}

@media (max-width: 767px) {
  .footer-grid {
    grid-template-columns: 1fr 1fr;
    gap: 32px;
  }

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

  .footer-bottom {
    flex-direction: column;
    gap: 12px;
    text-align: center;
  }

  .nav-links a.nav-link-desktop {
    display: none;
  }

  .nav-hamburger {
    display: block;
  }

  .mobile-menu {
    display: block;
  }

  .nav-links .nav-cta {
    font-size: 0.75rem;
    padding: 8px 16px;
  }

  .nav-links {
    gap: 14px;
  }
}

.logo img {
  display: block;
  height: 24px;
  width: auto;
}
