/* Shared styling for the standalone content pages (Services, Terms, Privacy).
   Mirrors the design tokens, nav and footer of the main site (index.html) so
   these pages read as part of hassanhashmi.com. */

:root {
  --c-bg: #ffffff;
  --c-bg-2: #f7f7f5;
  --c-bg-3: #eeeeea;
  --c-surface: #ffffff;
  --c-text: #1a1a1a;
  --c-text-2: #4a4a4a;
  --c-text-3: #7a7a7a;
  --c-border: #e5e5e0;
  --c-border-2: #c9c9c0;
  --c-primary: #2a5a38;
  --c-primary-d: #173a22;
  --c-primary-soft: #eaf0e2;
  --c-accent: #36a200;
  --c-accent-d: #2a8000;
  --c-accent-soft: #e5f2d5;
  --c-dark-bg: #0f1a14;
  --c-dark-text: #f5f0e8;
  --f-body: "Plus Jakarta Sans", ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --f-mono: "JetBrains Mono", ui-monospace, SFMono-Regular, "SF Mono", Menlo, Consolas, monospace;
  --r-sm: 6px;
  --r-md: 10px;
  --r-lg: 14px;
  --container: 1180px;
  --gutter: clamp(20px, 4vw, 40px);
}

* { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; scrollbar-gutter: stable; }

body {
  margin: 0;
  background: var(--c-bg);
  color: var(--c-text);
  font-family: var(--f-body);
  line-height: 1.65;
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
}

.container { width: 100%; max-width: var(--container); margin: 0 auto; padding: 0 var(--gutter); }

a { color: var(--c-primary-d); text-decoration: none; }
a:hover { color: var(--c-accent-d); }
::selection { background: var(--c-accent); color: #fff; }

/* ---------- Nav ---------- */
.nav {
  position: sticky; top: 0; z-index: 50;
  background: color-mix(in srgb, var(--c-bg) 80%, transparent);
  backdrop-filter: saturate(140%) blur(14px);
  -webkit-backdrop-filter: saturate(140%) blur(14px);
  border-bottom: 1px solid transparent;
  transition: border-color 220ms ease, background-color 220ms ease;
}
.nav.is-stuck { border-bottom-color: var(--c-border); background: color-mix(in srgb, var(--c-bg) 96%, transparent); }
.nav__inner { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 16px 0; }
.nav__brand { display: flex; align-items: center; gap: 12px; font-weight: 600; font-size: 0.96rem; color: var(--c-text); }
.nav__brand .dot { width: 9px; height: 9px; border-radius: 999px; background: var(--c-accent); box-shadow: 0 0 0 4px color-mix(in srgb, var(--c-accent) 24%, transparent); }
.nav__links { display: none; gap: 28px; align-items: center; }
@media (min-width: 820px) { .nav__links { display: flex; } }
.nav__links a { color: var(--c-text-2); font-size: 0.9rem; font-weight: 500; }
.nav__links a:hover { color: var(--c-text); }
.nav__links a[aria-current="page"] { color: var(--c-primary); font-weight: 600; }
.nav__cta {
  display: inline-flex; align-items: center; gap: 8px;
  background: var(--c-primary); color: #fff;
  padding: 10px 18px; border-radius: 999px;
  font-size: 0.86rem; font-weight: 600; border: 1px solid var(--c-primary);
  transition: transform 120ms ease, background 200ms ease;
}
.nav__cta:hover { background: var(--c-primary-d); transform: translateY(-1px); color: #fff; }

/* "Explore" dropdown (desktop) */
.nav__group { position: relative; display: flex; align-items: center; }
.nav__group-btn {
  display: inline-flex; align-items: center; gap: 5px;
  background: none; border: 0; padding: 0; margin: 0; cursor: pointer;
  font-family: inherit; font-size: 0.9rem; font-weight: 500; color: var(--c-text-2);
}
.nav__group-btn:hover { color: var(--c-text); }
.nav__group-btn svg { width: 14px; height: 14px; transition: transform .2s ease; }
.nav__group.is-open .nav__group-btn svg { transform: rotate(180deg); }
.nav__dropdown {
  position: absolute; top: calc(100% + 12px); left: 50%;
  transform: translateX(-50%) translateY(-6px);
  min-width: 190px; display: flex; flex-direction: column; gap: 2px;
  background: var(--c-bg); border: 1px solid var(--c-border);
  border-radius: var(--r-md); box-shadow: 0 24px 48px -16px rgba(0, 0, 0, 0.18); padding: 6px;
  opacity: 0; visibility: hidden; z-index: 60;
  transition: opacity .18s ease, transform .18s ease, visibility .18s;
}
.nav__group.is-open .nav__dropdown { opacity: 1; visibility: visible; transform: translateX(-50%) translateY(0); }
.nav__dropdown a { padding: 9px 12px; border-radius: var(--r-sm); font-size: 0.9rem; color: var(--c-text-2); white-space: nowrap; }
.nav__dropdown a:hover { background: var(--c-bg-2); color: var(--c-primary); }

/* Mobile menu toggle (hidden on desktop) */
.nav__toggle { display: none; }
@media (max-width: 819px) {
  .nav__inner { position: relative; }
  .nav__cta { display: none; }
  .nav__toggle {
    display: inline-flex; flex-direction: column; justify-content: center; gap: 5px;
    width: 44px; height: 44px; padding: 0 11px;
    background: var(--c-surface); border: 1px solid var(--c-border-2);
    border-radius: 12px; cursor: pointer;
  }
  .nav__toggle-bar { display: block; width: 100%; height: 2px; border-radius: 2px; background: var(--c-text); transition: transform .22s ease, opacity .18s ease; }
  .nav.is-open .nav__toggle-bar:nth-child(1) { transform: translateY(7px) rotate(45deg); }
  .nav.is-open .nav__toggle-bar:nth-child(2) { opacity: 0; }
  .nav.is-open .nav__toggle-bar:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

  .nav__links {
    display: flex; flex-direction: column; align-items: stretch; gap: 0;
    position: absolute; top: calc(100% + 1px); left: 0; right: 0;
    background: var(--c-bg); border-top: 1px solid var(--c-border);
    box-shadow: 0 24px 48px -16px rgba(0, 0, 0, 0.18); padding: 6px 0;
    opacity: 0; visibility: hidden; transform: translateY(-10px);
    transition: opacity .2s ease, transform .2s ease, visibility .2s;
  }
  .nav.is-open .nav__links { opacity: 1; visibility: visible; transform: translateY(0); }
  .nav__links a {
    padding: 14px var(--gutter); font-size: 1rem; font-weight: 500; color: var(--c-text);
    border-bottom: 1px solid var(--c-border);
  }
  .nav__links a:last-child { border-bottom: 0; }
  .nav__links a:hover { background: var(--c-bg-2); color: var(--c-primary); }

  /* Explore group collapses to a flat list inside the mobile panel */
  .nav__group { position: static; display: block; }
  .nav__group-btn { display: none; }
  .nav__dropdown {
    position: static; transform: none; opacity: 1; visibility: visible;
    min-width: 0; padding: 0; gap: 0; border: 0; border-radius: 0; box-shadow: none;
  }
  .nav__dropdown a { padding: 14px var(--gutter); border-radius: 0; font-size: 1rem; color: var(--c-text); white-space: normal; }
  .nav__dropdown a:last-child { border-bottom: 1px solid var(--c-border); }
}

/* ---------- Page header ---------- */
.page-hero { background: var(--c-bg-2); border-bottom: 1px solid var(--c-border); padding: clamp(40px, 7vw, 72px) 0 clamp(28px, 5vw, 44px); }
.page-hero__eyebrow { font-family: var(--f-mono); font-size: 0.74rem; text-transform: uppercase; letter-spacing: 0.16em; color: var(--c-primary); margin: 0 0 12px; }
.page-hero h1 { margin: 0 0 10px; font-size: clamp(1.7rem, 4vw, 2.4rem); font-weight: 700; letter-spacing: -0.02em; line-height: 1.1; }
.page-hero p { margin: 0; color: var(--c-text-2); max-width: 60ch; }

/* ---------- Content ---------- */
main { padding: clamp(32px, 6vw, 56px) 0 clamp(48px, 8vw, 72px); }
main .container > p:first-child { margin-top: 0; }
/* Keep running text at a comfortable measure within the wide (1180px) frame,
   left-aligned so it lines up with the page-hero heading (as on the home page). */
main > .container > p,
main > .container > ul,
main > .container > h2,
main > .container > h3 { max-width: 74ch; }
.card, .how { max-width: 820px; }
.page-hero p { max-width: 68ch; }

h2 { color: var(--c-primary-d); font-size: 1.3rem; font-weight: 700; letter-spacing: -0.01em; margin: 40px 0 12px; }
h2:first-of-type { margin-top: 0; }
h3 { font-size: 1.05rem; font-weight: 600; margin: 24px 0 8px; }
p { margin: 0 0 1em; color: var(--c-text-2); }
ul { padding-left: 1.3rem; margin: 0 0 1em; }
li { margin: 7px 0; color: var(--c-text-2); }
strong { color: var(--c-text); font-weight: 600; }
.mono { font-family: var(--f-mono); }

.meta {
  background: var(--c-primary-soft); border-left: 3px solid var(--c-primary);
  border-radius: var(--r-sm); padding: 12px 16px; font-size: 0.92rem;
  color: var(--c-text-2); margin: 0 0 8px;
}

/* Service cards */
.lede { font-size: 1.05rem; color: var(--c-text-2); max-width: 62ch; }
.card {
  background: var(--c-surface); border: 1px solid var(--c-border);
  border-left: 3px solid var(--c-primary); border-radius: var(--r-md);
  padding: 22px 24px; margin: 16px 0;
}
.card h2 { margin-top: 0; }
.price {
  display: inline-block; background: var(--c-primary); color: #fff;
  border-radius: 999px; padding: 4px 14px; font-size: 0.8rem; font-weight: 600;
  font-family: var(--f-mono); letter-spacing: 0.01em; margin-bottom: 12px;
}
.card ul { margin-bottom: 0; }

.how { border: 1px solid var(--c-border); background: var(--c-bg-2); border-radius: var(--r-md); padding: 20px 24px; margin-top: 32px; }
.how strong { color: var(--c-primary-d); }

/* Call-to-action buttons */
.btn-row { display: flex; flex-wrap: wrap; gap: 12px; margin: 18px 0 0; }
.btn {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 12px 22px; border-radius: 999px; font-weight: 600; font-size: 0.92rem;
  border: 1px solid var(--c-primary); transition: transform 120ms ease, background 200ms ease;
}
.btn--primary { background: var(--c-primary); color: #fff; }
.btn--primary:hover { background: var(--c-primary-d); color: #fff; transform: translateY(-1px); }
.btn--ghost { background: transparent; color: var(--c-primary-d); }
.btn--ghost:hover { background: var(--c-primary-soft); color: var(--c-primary-d); }

.back-link { display: inline-block; margin-top: 32px; font-family: var(--f-mono); font-size: 0.85rem; }

/* ---------- Footer ---------- */
.site-footer { background: var(--c-dark-bg); color: var(--c-dark-text); padding: 48px 0 28px; margin-top: 24px; }
.site-footer a { color: #cfe0d3; }
.site-footer a:hover { color: #fff; }
.footer__grid { display: grid; gap: 32px; grid-template-columns: 1fr; }
@media (min-width: 720px) { .footer__grid { grid-template-columns: 1.5fr 1fr 1fr; } }
.footer__grid h4 { font-family: var(--f-mono); font-size: 0.72rem; text-transform: uppercase; letter-spacing: 0.14em; color: #9db3a2; margin: 0 0 14px; font-weight: 500; }
.footer__grid ul { list-style: none; padding: 0; margin: 0; display: grid; gap: 10px; }
.footer__grid li { margin: 0; color: #cfe0d3; }
.footer__brand { display: flex; align-items: center; gap: 10px; font-weight: 600; color: #fff; margin-bottom: 12px; }
.footer__brand .dot { width: 9px; height: 9px; border-radius: 999px; background: var(--c-accent); }
.footer__blurb { color: #a9bdad; font-size: 0.92rem; max-width: 40ch; margin: 0 0 10px; }
.footer__contact { font-family: var(--f-mono); font-size: 0.85rem; }
.footer__bottom { display: flex; flex-wrap: wrap; gap: 10px; justify-content: space-between; align-items: center; border-top: 1px solid rgba(255,255,255,0.1); margin-top: 36px; padding-top: 18px; color: #8ea394; font-size: 0.82rem; }
