/* =========================================================
   javedsarwar.com — styles.css
   Mobile-first, dark navy + amber, self-hosted Inter
   ========================================================= */

/* ── 1. Self-hosted fonts ─────────────────────────────── */

@font-face {
  font-family: "Inter";
  src: url("/assets/fonts/InterVariable.woff2") format("woff2-variations");
  font-weight: 100 900;
  font-style: normal;
  font-display: swap;
}

/* ── 2. Design tokens ─────────────────────────────────── */

:root {
  /* Base */
  --bg:            #0f172a;
  --bg-elevated:   #1a2436;
  --bg-subtle:     #141d2e;

  /* Text */
  --text:          #e8edf5;
  --text-muted:    #9aa7bd;
  --text-faint:    #6b7891;

  /* Accent */
  --accent:        #f5a623;
  --accent-hover:  #ffb841;
  --accent-deep:   #c8841a;

  /* Borders */
  --border:        rgba(232, 237, 245, 0.10);
  --border-strong: rgba(232, 237, 245, 0.18);

  /* Focus */
  --focus:         #ffb841;

  /* Typography */
  --font-sans:     "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;

  /* Layout */
  --maxw:          1080px;
  --maxw-narrow:   680px;
  --gap:           clamp(1rem, 3vw, 2rem);
  --section-y:     clamp(3.5rem, 9vw, 7rem);
  --radius:        14px;
  --radius-sm:     8px;
}

/* ── 3. Minimal reset ─────────────────────────────────── */

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

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

body {
  font-family: var(--font-sans);
  font-size: 1rem;
  line-height: 1.65;
  color: var(--text);
  background: var(--bg);
  overflow-x: hidden;
}

img, svg {
  display: block;
  max-width: 100%;
}

a {
  color: var(--accent);
  text-decoration: none;
}

a:hover {
  color: var(--accent-hover);
  text-decoration: underline;
}

ul, ol {
  list-style: none;
}

button {
  font-family: inherit;
  cursor: pointer;
  border: none;
  background: none;
}

input, textarea, select {
  font-family: inherit;
  font-size: 1rem;
}

/* ── 4. Focus styles (accessibility) ─────────────────── */

:focus-visible {
  outline: 2px solid var(--focus);
  outline-offset: 3px;
  border-radius: 4px;
}

/* ── 5. Container ─────────────────────────────────────── */

.container {
  width: 100%;
  max-width: var(--maxw);
  margin-inline: auto;
  padding-inline: clamp(1.25rem, 5vw, 3rem);
}

.container--narrow {
  max-width: var(--maxw-narrow);
}

/* ── 6. Header ────────────────────────────────────────── */

.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: transparent;
  transition: background 0.25s ease, border-color 0.25s ease;
  border-bottom: 1px solid transparent;
}

.site-header.header--scrolled {
  background: var(--bg-elevated);
  border-bottom-color: var(--border);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
}

.site-header .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 64px;
  gap: 1rem;
}

.site-wordmark {
  font-size: 1.1rem;
  font-weight: 650;
  color: var(--text);
  letter-spacing: -0.01em;
  white-space: nowrap;
  flex-shrink: 0;
  text-decoration: none;
}

.site-wordmark:hover {
  color: var(--accent);
  text-decoration: none;
}

/* Nav */
.site-nav {
  display: flex;
  align-items: center;
  gap: 0.25rem;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 0.25rem;
}

.nav-links a {
  color: var(--text-muted);
  font-size: 0.9rem;
  font-weight: 500;
  padding: 0.4rem 0.75rem;
  border-radius: var(--radius-sm);
  transition: color 0.15s ease, background 0.15s ease;
  text-decoration: none;
  white-space: nowrap;
}

.nav-links a:hover {
  color: var(--text);
  background: var(--border);
  text-decoration: none;
}

/* Language toggle */
.lang-toggle {
  display: flex;
  align-items: center;
  gap: 0;
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-sm);
  overflow: hidden;
  margin-left: 0.75rem;
  flex-shrink: 0;
}

.lang-toggle button {
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.05em;
  color: var(--text-muted);
  padding: 0.3rem 0.6rem;
  min-height: 32px;
  min-width: 36px;
  transition: color 0.15s ease, background 0.15s ease;
}

.lang-toggle button[aria-pressed="true"] {
  color: var(--bg);
  background: var(--accent);
}

.lang-toggle button:hover:not([aria-pressed="true"]) {
  color: var(--text);
  background: var(--border);
}

/* Hamburger */
.nav-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  padding: 8px;
  min-width: 44px;
  min-height: 44px;
  align-items: center;
  justify-content: center;
  border-radius: var(--radius-sm);
  color: var(--text);
  flex-shrink: 0;
}

.nav-toggle span {
  display: block;
  width: 22px;
  height: 2px;
  background: currentColor;
  border-radius: 2px;
  transition: transform 0.2s ease, opacity 0.2s ease;
}

.nav-toggle[aria-expanded="true"] span:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}
.nav-toggle[aria-expanded="true"] span:nth-child(2) {
  opacity: 0;
}
.nav-toggle[aria-expanded="true"] span:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

/* ── 7. Mobile nav overlay ────────────────────────────── */

@media (max-width: 767px) {
  .nav-toggle {
    display: flex;
  }

  .nav-links {
    display: none;
    position: fixed;
    inset: 64px 0 0 0;
    background: var(--bg-elevated);
    flex-direction: column;
    align-items: stretch;
    padding: 1.5rem 1.25rem;
    gap: 0.25rem;
    border-top: 1px solid var(--border);
    z-index: 99;
  }

  .nav-links.nav--open {
    display: flex;
  }

  .nav-links a {
    font-size: 1.1rem;
    padding: 0.85rem 1rem;
    min-height: 52px;
    display: flex;
    align-items: center;
    border-bottom: 1px solid var(--border);
  }

  .lang-toggle {
    margin-left: auto;
  }
}

/* ── 8. Hero ──────────────────────────────────────────── */

.hero {
  padding-top: clamp(3.5rem, 10vw, 7rem);
  padding-bottom: clamp(3rem, 8vw, 6rem);
  background: var(--bg);
  position: relative;
  overflow: hidden;
}

/* Subtle radial background texture — CSS only, no image */
.hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse 60% 50% at 70% 40%, rgba(245, 166, 35, 0.04) 0%, transparent 70%),
    radial-gradient(ellipse 50% 60% at 20% 80%, rgba(26, 36, 54, 0.8) 0%, transparent 70%);
  pointer-events: none;
}

.hero .container {
  position: relative;
}

.hero-kicker {
  font-family: ui-monospace, "Cascadia Code", "Fira Code", "Courier New", monospace;
  font-size: 0.8rem;
  font-weight: 500;
  color: var(--text-faint);
  letter-spacing: 0.02em;
  margin-bottom: 1.25rem;
}

.hero h1 {
  font-size: clamp(2rem, 5vw + 1rem, 3.25rem);
  font-weight: 700;
  line-height: 1.1;
  letter-spacing: -0.02em;
  color: var(--text);
  max-width: 18ch;
  margin-bottom: 1.25rem;
}

.hero-lead {
  font-size: clamp(1.0625rem, 2vw, 1.25rem);
  font-weight: 400;
  color: var(--text-muted);
  max-width: 52ch;
  line-height: 1.7;
  margin-bottom: 2.25rem;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
}

/* ── 9. Buttons ───────────────────────────────────────── */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  padding: 0 1.5rem;
  font-size: 0.9375rem;
  font-weight: 600;
  border-radius: var(--radius-sm);
  transition: background 0.15s ease, color 0.15s ease, border-color 0.15s ease;
  text-decoration: none;
  white-space: nowrap;
  cursor: pointer;
}

.btn-primary {
  background: var(--accent);
  color: #1a1005;
  border: 1px solid transparent;
}

.btn-primary:hover {
  background: var(--accent-hover);
  color: #1a1005;
  text-decoration: none;
}

.btn-secondary {
  background: transparent;
  color: var(--text);
  border: 1px solid var(--border-strong);
}

.btn-secondary:hover {
  background: var(--border);
  color: var(--text);
  text-decoration: none;
}

/* ── 10. Trust strip ──────────────────────────────────── */

.trust {
  background: var(--bg-subtle);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  padding: 1.5rem 0;
}

.trust-list {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem 0.5rem;
}

.trust-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  padding: 0.75rem 0.75rem;
  position: relative;
}

.trust-strong {
  font-size: 1rem;
  font-weight: 600;
  color: var(--text);
  line-height: 1.3;
}

.trust-desc {
  font-size: 0.75rem;
  color: var(--text-faint);
  letter-spacing: 0.02em;
  line-height: 1.4;
  margin-top: 0.2rem;
}

/* ── 11. Section common ───────────────────────────────── */

.section {
  padding-top: var(--section-y);
  padding-bottom: var(--section-y);
}

.section--alt {
  background: var(--bg-subtle);
}

.section-eyebrow {
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--accent);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  margin-bottom: 0.6rem;
}

.section h2 {
  font-size: clamp(1.5rem, 3vw, 2rem);
  font-weight: 650;
  line-height: 1.2;
  letter-spacing: -0.015em;
  color: var(--text);
  margin-bottom: 0.75rem;
}

.section-intro {
  font-size: 1rem;
  color: var(--text-muted);
  max-width: 56ch;
  margin-bottom: var(--gap);
}

/* ── 12. Service cards (bento grid) ──────────────────── */

.services-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1rem;
}

.service-card {
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: clamp(1.25rem, 4vw, 1.75rem);
  transition: border-color 0.2s ease;
}

.service-card:hover {
  border-color: var(--border-strong);
}

.service-card--lead {
  border-color: rgba(245, 166, 35, 0.2);
}

.service-card--lead:hover {
  border-color: rgba(245, 166, 35, 0.4);
}

.service-card h3 {
  font-size: 1.1rem;
  font-weight: 600;
  color: var(--text);
  margin-bottom: 0.5rem;
  line-height: 1.3;
}

.service-card--lead h3 {
  color: var(--accent);
}

.service-card p {
  font-size: 0.9375rem;
  color: var(--text-muted);
  line-height: 1.65;
}

/* ── 13. About section ────────────────────────────────── */

.about-inner {
  display: flex;
  flex-direction: column;
  gap: clamp(2rem, 5vw, 3.5rem);
}

.about-photo-wrap {
  width: 100%;
  max-width: 320px;
  margin: 0 auto;
}

.about-photo {
  width: 100%;
  aspect-ratio: 4 / 5;
  object-fit: cover;
  object-position: top;
  border-radius: var(--radius);
  border: 1px solid var(--border);
  background: var(--bg-elevated);
}

.about-photo-placeholder {
  width: 100%;
  aspect-ratio: 4 / 5;
  border-radius: var(--radius);
  border: 1px solid var(--border);
  background: var(--bg-elevated);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  gap: 0.5rem;
  color: var(--text-faint);
  font-size: 0.8rem;
  text-align: center;
  padding: 1rem;
}

.about-text {
  max-width: 60ch;
}

.about-text p {
  color: var(--text-muted);
  margin-bottom: 1rem;
  font-size: 1rem;
}

.about-text p:last-child {
  margin-bottom: 0;
}

.about-stack {
  margin-top: 1.5rem;
  padding-top: 1.5rem;
  border-top: 1px solid var(--border);
  font-size: 0.875rem;
  color: var(--text-faint);
  line-height: 1.8;
}

.about-anchors {
  margin-top: 1rem;
  display: flex;
  flex-direction: column;
  gap: 0.3rem;
}

.about-anchors a {
  font-size: 0.875rem;
  color: var(--text-muted);
}

.about-anchors a:hover {
  color: var(--accent);
}

/* ── 14. Process steps ────────────────────────────────── */

.process-steps {
  display: flex;
  flex-direction: column;
  gap: 0;
}

.process-step {
  display: flex;
  gap: 1.25rem;
  padding: 1.5rem 0;
  border-bottom: 1px solid var(--border);
}

.process-step:last-child {
  border-bottom: none;
}

.step-number {
  font-family: ui-monospace, "Cascadia Code", "Courier New", monospace;
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--accent);
  letter-spacing: 0.06em;
  flex-shrink: 0;
  padding-top: 0.2rem;
  min-width: 2.5rem;
}

.step-content h3 {
  font-size: 1.05rem;
  font-weight: 600;
  color: var(--text);
  margin-bottom: 0.35rem;
  line-height: 1.3;
}

.step-content p {
  font-size: 0.9375rem;
  color: var(--text-muted);
  line-height: 1.65;
}

/* ── 15. Contact section ──────────────────────────────── */

.contact-inner {
  display: flex;
  flex-direction: column;
  gap: clamp(2rem, 5vw, 3rem);
}

.contact-email-line {
  font-size: 0.9rem;
  color: var(--text-muted);
  margin-top: 1.25rem;
}

.contact-email-line a {
  color: var(--text-muted);
  text-decoration: underline;
  text-underline-offset: 3px;
}

.contact-email-line a:hover {
  color: var(--accent);
}

/* Form */
.contact-form {
  display: flex;
  flex-direction: column;
  gap: 1.1rem;
  max-width: 520px;
}

/* Honeypot — off-screen, not display:none */
.hp {
  position: absolute;
  left: -9999px;
  width: 1px;
  height: 1px;
  overflow: hidden;
  opacity: 0;
  pointer-events: none;
  tab-size: 0;
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
}

.contact-form label {
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--text-muted);
}

.contact-form input,
.contact-form textarea {
  background: var(--bg-elevated);
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-sm);
  color: var(--text);
  padding: 0.7rem 0.9rem;
  font-size: 1rem;
  line-height: 1.5;
  width: 100%;
  transition: border-color 0.15s ease;
  -webkit-appearance: none;
}

.contact-form input::placeholder,
.contact-form textarea::placeholder {
  color: var(--text-faint);
}

.contact-form input:focus,
.contact-form textarea:focus {
  border-color: var(--accent);
  outline: none;
  box-shadow: 0 0 0 2px rgba(245, 166, 35, 0.2);
}

.contact-form textarea {
  resize: vertical;
  min-height: 120px;
}

/* Consent row */
.consent-label {
  display: flex;
  gap: 0.6rem;
  align-items: flex-start;
  font-size: 0.875rem;
  color: var(--text-muted);
  cursor: pointer;
}

.consent-label input[type="checkbox"] {
  width: 18px;
  height: 18px;
  min-width: 18px;
  margin-top: 0.1rem;
  accent-color: var(--accent);
  cursor: pointer;
  border-radius: 4px;
}

.consent-label a {
  color: var(--text-muted);
  text-decoration: underline;
  text-underline-offset: 2px;
}

.consent-label a:hover {
  color: var(--accent);
}

/* Form status */
#form-status {
  font-size: 0.9rem;
  line-height: 1.5;
  min-height: 1.4rem;
  border-radius: var(--radius-sm);
  padding: 0;
  transition: all 0.2s ease;
}

#form-status.status--success {
  color: #4ade80;
  background: rgba(74, 222, 128, 0.08);
  padding: 0.75rem 1rem;
  border: 1px solid rgba(74, 222, 128, 0.2);
}

#form-status.status--error {
  color: #f87171;
  background: rgba(248, 113, 113, 0.08);
  padding: 0.75rem 1rem;
  border: 1px solid rgba(248, 113, 113, 0.2);
}

/* ── 16. Footer ───────────────────────────────────────── */

.site-footer {
  background: var(--bg-subtle);
  border-top: 1px solid var(--border);
  padding: 2rem 0;
}

.site-footer .container {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  align-items: center;
  text-align: center;
}

.footer-copy {
  font-size: 0.8rem;
  color: var(--text-faint);
}

.footer-links {
  display: flex;
  gap: 1.5rem;
  flex-wrap: wrap;
  justify-content: center;
}

.footer-links a {
  font-size: 0.8rem;
  color: var(--text-faint);
  text-decoration: none;
}

.footer-links a:hover {
  color: var(--text-muted);
  text-decoration: underline;
}

/* ── 17. Legal pages ──────────────────────────────────── */

.legal-back {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.875rem;
  color: var(--text-muted);
  margin-bottom: 2rem;
  text-decoration: none;
}

.legal-back:hover {
  color: var(--accent);
  text-decoration: none;
}

.legal-content {
  padding-top: clamp(2rem, 5vw, 3.5rem);
  padding-bottom: clamp(3rem, 7vw, 5rem);
}

.legal-content h1 {
  font-size: clamp(1.75rem, 4vw, 2.5rem);
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--text);
  margin-bottom: 2rem;
  line-height: 1.2;
}

.legal-body h2 {
  font-size: 1.1rem;
  font-weight: 600;
  color: var(--text);
  margin-top: 2rem;
  margin-bottom: 0.5rem;
}

.legal-body p {
  font-size: 0.9375rem;
  color: var(--text-muted);
  line-height: 1.7;
  margin-bottom: 0.75rem;
}

.legal-body a {
  color: var(--text-muted);
  text-decoration: underline;
  text-underline-offset: 2px;
}

.legal-body a:hover {
  color: var(--accent);
}

/* ── 18. Scroll fade-up animation ────────────────────── */

.fade-up {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.5s ease, transform 0.5s ease;
}

.fade-up.visible {
  opacity: 1;
  transform: translateY(0);
}

/* ── 19. Reduced motion ───────────────────────────────── */

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }

  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }

  .fade-up {
    opacity: 1;
    transform: none;
    transition: none;
  }
}

/* ── 20. Tablet (≥ 768px) ─────────────────────────────── */

@media (min-width: 768px) {
  /* Trust: 4 columns with vertical separators */
  .trust-list {
    grid-template-columns: repeat(4, 1fr);
  }

  .trust-item:not(:last-child)::after {
    content: "";
    position: absolute;
    right: 0;
    top: 20%;
    height: 60%;
    width: 1px;
    background: var(--border);
  }

  /* Services: 2 columns */
  .services-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  /* About: side-by-side */
  .about-inner {
    flex-direction: row;
    align-items: flex-start;
  }

  .about-photo-wrap {
    max-width: 240px;
    flex-shrink: 0;
    margin: 0;
  }

  /* Footer: row */
  .site-footer .container {
    flex-direction: row;
    justify-content: space-between;
    text-align: left;
  }

  .footer-links {
    justify-content: flex-end;
  }

  /* Contact: intro beside form */
  .contact-inner {
    flex-direction: row;
    align-items: flex-start;
  }

  .contact-intro-col {
    flex: 0 0 260px;
    padding-top: 0.25rem;
  }

  .contact-form-col {
    flex: 1;
  }
}

/* ── 21. Desktop (≥ 1024px) ──────────────────────────── */

@media (min-width: 1024px) {
  /* Services: 3 columns */
  .services-grid {
    grid-template-columns: repeat(3, 1fr);
  }

  /* About photo a bit larger */
  .about-photo-wrap {
    max-width: 280px;
  }

  /* Hero max width */
  .hero h1 {
    max-width: 16ch;
  }
}

/* ── 22. Utility ──────────────────────────────────────── */

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