/* ═══════════════════════════════════════════════════
   HAR WEB-APP SOLUTION — Design System
   Aesthetic: Architectural Bauhaus × Modern Tech
   ═══════════════════════════════════════════════════ */

:root {
  /* Palette */
  --bg:           #F5F1EA;          /* warm off-white */
  --bg-alt:       #ECE6DC;          /* slightly deeper */
  --ink:          #14213D;          /* deep navy */
  --ink-soft:     #2C3651;
  --muted:        #6B7280;
  --line:         #2C3651;
  --accent:       #C84B31;          /* terracotta */
  --accent-soft:  #E07856;
  --paper:        #FFFFFF;
  --gold:         #D4A24C;
  --green:        #4F7942;

  /* Type */
  --serif: "Fraunces", "Cormorant Garamond", Georgia, serif;
  --sans:  "Space Grotesk", "Inter", -apple-system, BlinkMacSystemFont, sans-serif;
  --mono:  "JetBrains Mono", ui-monospace, monospace;

  /* Layout */
  --max:   1280px;
  --gutter: clamp(20px, 4vw, 48px);
  --radius: 4px;
}

* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  font-family: var(--sans);
  background: var(--bg);
  color: var(--ink);
  line-height: 1.55;
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
button { font-family: inherit; cursor: pointer; border: none; background: none; color: inherit; }

/* Decorative grain overlay (very subtle) */
body::before {
  content: '';
  position: fixed; inset: 0; pointer-events: none; z-index: 100;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='2'/%3E%3CfeColorMatrix values='0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0.04 0'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
  opacity: 0.6;
  mix-blend-mode: multiply;
}

/* ─── Typography ─── */
.serif    { font-family: var(--serif); font-weight: 400; }
.mono     { font-family: var(--mono); }
.eyebrow  { font-size: 0.75rem; letter-spacing: 0.18em; text-transform: uppercase; font-weight: 600; color: var(--accent); font-family: var(--sans); }
h1, h2, h3, h4 { font-family: var(--serif); font-weight: 400; line-height: 1.05; letter-spacing: -0.02em; color: var(--ink); }
h1 { font-size: clamp(2.4rem, 6vw, 5.2rem); }
h2 { font-size: clamp(2rem, 4.5vw, 3.6rem); }
h3 { font-size: clamp(1.4rem, 2.6vw, 2rem); }
h4 { font-size: 1.2rem; font-family: var(--sans); font-weight: 600; letter-spacing: -0.01em; }
p  { color: var(--ink-soft); }
.italic { font-style: italic; }

/* ─── Header / Nav ─── */
.nav {
  position: sticky; top: 0; z-index: 50;
  background: rgba(245, 241, 234, 0.92);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid rgba(20, 33, 61, 0.12);
}
.nav-inner {
  max-width: var(--max);
  margin: 0 auto;
  padding: 18px var(--gutter);
  display: flex; align-items: center; justify-content: space-between; gap: 24px;
}
.logo {
  font-family: var(--serif); font-size: 1.4rem; font-weight: 500;
  display: flex; align-items: center; gap: 10px; letter-spacing: -0.02em;
}
.logo-mark {
  width: 28px; height: 28px; border-radius: 50%;
  background: var(--ink); position: relative; flex-shrink: 0;
}
.logo-mark::after {
  content: ''; position: absolute; inset: 6px;
  background: var(--accent); border-radius: 50%;
}
.nav-links { display: flex; gap: 28px; align-items: center; }
.nav-links a { font-size: 0.92rem; color: var(--ink-soft); transition: color 0.2s; font-weight: 500; position: relative; }
.nav-links a:hover, .nav-links a.active { color: var(--ink); }
.nav-links a.active::after { content: ''; position: absolute; left: 0; right: 0; bottom: -4px; height: 2px; background: var(--accent); }
.nav-cta {
  padding: 9px 18px; background: var(--ink); color: var(--bg);
  border-radius: var(--radius); font-size: 0.88rem; font-weight: 600;
  transition: background 0.2s;
}
.nav-cta:hover { background: var(--accent); color: var(--bg); }
.nav-toggle { display: none; font-size: 1.4rem; }
@media (max-width: 820px) {
  .nav-links { position: fixed; top: 72px; left: 0; right: 0; background: var(--bg); flex-direction: column; padding: 24px var(--gutter); border-bottom: 1px solid var(--line); display: none; }
  .nav-links.open { display: flex; }
  .nav-toggle { display: block; }
}

/* ─── Containers ─── */
.container { max-width: var(--max); margin: 0 auto; padding: 0 var(--gutter); }
section { padding: clamp(60px, 9vw, 120px) 0; position: relative; }
.section-alt { background: var(--bg-alt); }
.section-dark { background: var(--ink); color: var(--bg); }
.section-dark h1, .section-dark h2, .section-dark h3, .section-dark h4 { color: var(--bg); }
.section-dark p { color: rgba(245, 241, 234, 0.75); }

/* ─── Buttons ─── */
.btn {
  display: inline-flex; align-items: center; gap: 10px;
  padding: 14px 26px; border-radius: var(--radius);
  font-size: 0.92rem; font-weight: 600; transition: all 0.25s;
  border: 1px solid transparent; cursor: pointer; font-family: var(--sans);
}
.btn-primary { background: var(--ink); color: var(--bg); }
.btn-primary:hover { background: var(--accent); transform: translateY(-1px); }
.btn-outline { background: transparent; color: var(--ink); border-color: var(--ink); }
.btn-outline:hover { background: var(--ink); color: var(--bg); }
.btn-accent  { background: var(--accent); color: var(--bg); }
.btn-accent:hover { background: var(--ink); }

/* Arrow that translates on hover */
.btn .arrow { display: inline-block; transition: transform 0.25s; }
.btn:hover .arrow { transform: translateX(4px); }

/* ─── Hero (custom per page) ─── */
.hero { padding: clamp(80px, 14vw, 180px) 0 clamp(60px, 8vw, 100px); position: relative; overflow: hidden; }
.hero h1 .accent-word { color: var(--accent); font-style: italic; }

/* ─── Grids ─── */
.grid-2 { display: grid; grid-template-columns: repeat(2, 1fr); gap: clamp(24px, 5vw, 60px); }
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 32px; }
.grid-4 { display: grid; grid-template-columns: repeat(4, 1fr); gap: 24px; }
@media (max-width: 820px) {
  .grid-2, .grid-3, .grid-4 { grid-template-columns: 1fr; }
}

/* ─── Cards ─── */
.card {
  background: var(--paper); border: 1px solid rgba(20,33,61,0.08);
  padding: 32px; border-radius: var(--radius); transition: all 0.3s;
}
.card:hover { transform: translateY(-3px); box-shadow: 0 12px 40px rgba(20,33,61,0.08); border-color: var(--accent); }
.card .num { font-family: var(--serif); font-size: 2.4rem; color: var(--accent); font-style: italic; margin-bottom: 12px; display: block; line-height: 1; }
.card h3 { margin-bottom: 10px; font-size: 1.25rem; }
.card h4 { margin-bottom: 8px; }
.card p { font-size: 0.92rem; }

/* Service cards (homepage) */
.svc-card {
  background: var(--paper); padding: 36px;
  border: 1px solid rgba(20,33,61,0.1);
  position: relative; overflow: hidden;
  transition: all 0.35s cubic-bezier(0.22, 1, 0.36, 1);
}
.svc-card::before {
  content: ''; position: absolute; inset: 0; background: var(--ink);
  transform: translateY(100%); transition: transform 0.35s cubic-bezier(0.22, 1, 0.36, 1);
  z-index: 0;
}
.svc-card:hover::before { transform: translateY(0); }
.svc-card:hover { color: var(--bg); }
.svc-card:hover h3, .svc-card:hover p, .svc-card:hover .icon-wrap { color: var(--bg); }
.svc-card:hover .icon-wrap { background: var(--accent); border-color: var(--accent); }
.svc-card > * { position: relative; z-index: 1; transition: color 0.35s; }
.svc-card .icon-wrap {
  width: 56px; height: 56px; border: 1.5px solid var(--ink);
  display: flex; align-items: center; justify-content: center;
  margin-bottom: 24px; transition: all 0.35s;
}
.svc-card .icon-wrap svg { width: 28px; height: 28px; }
.svc-card h3 { margin-bottom: 12px; }
.svc-card .desc { font-size: 0.93rem; margin-bottom: 16px; }
.svc-card .features { list-style: none; font-size: 0.85rem; }
.svc-card .features li { padding: 4px 0; display: flex; align-items: center; gap: 8px; }
.svc-card .features li::before { content: '→'; color: var(--accent); font-weight: 700; }

/* ─── Footer ─── */
footer.site-footer {
  background: var(--ink); color: var(--bg);
  padding: 80px 0 30px; margin-top: 0;
}
.foot-grid { display: grid; grid-template-columns: 2fr 1fr 1fr 1fr; gap: 48px; margin-bottom: 60px; }
@media (max-width: 820px) { .foot-grid { grid-template-columns: 1fr 1fr; gap: 32px; } }
@media (max-width: 480px) { .foot-grid { grid-template-columns: 1fr; } }
.foot-grid h4 { color: var(--bg); margin-bottom: 18px; font-size: 0.8rem; letter-spacing: 0.18em; text-transform: uppercase; opacity: 0.6; }
.foot-grid a { color: rgba(245, 241, 234, 0.75); display: block; padding: 5px 0; font-size: 0.92rem; transition: color 0.2s; }
.foot-grid a:hover { color: var(--accent-soft); }
.foot-brand .logo { color: var(--bg); margin-bottom: 16px; }
.foot-brand .logo-mark { background: var(--bg); }
.foot-brand .logo-mark::after { background: var(--accent); }
.foot-brand p { color: rgba(245, 241, 234, 0.65); font-size: 0.92rem; max-width: 320px; }
.foot-bottom {
  border-top: 1px solid rgba(245, 241, 234, 0.12);
  padding-top: 24px;
  display: flex; justify-content: space-between; gap: 16px;
  font-size: 0.82rem; color: rgba(245, 241, 234, 0.5);
  flex-wrap: wrap;
}
.foot-bottom a { color: rgba(245, 241, 234, 0.6); }
.foot-bottom a:hover { color: var(--accent-soft); }

/* ─── Animations (page load) ─── */
.reveal { opacity: 0; transform: translateY(20px); animation: rise 0.8s cubic-bezier(0.22, 1, 0.36, 1) forwards; }
.reveal-d1 { animation-delay: 0.1s; }
.reveal-d2 { animation-delay: 0.2s; }
.reveal-d3 { animation-delay: 0.3s; }
.reveal-d4 { animation-delay: 0.4s; }
.reveal-d5 { animation-delay: 0.5s; }
@keyframes rise { to { opacity: 1; transform: translateY(0); } }

/* Decorative element used in heroes */
.deco-grid {
  position: absolute; opacity: 0.08; pointer-events: none;
  background-image: linear-gradient(var(--ink) 1px, transparent 1px), linear-gradient(90deg, var(--ink) 1px, transparent 1px);
  background-size: 40px 40px;
}
.deco-circle {
  position: absolute; border-radius: 50%;
  border: 1px solid var(--ink); opacity: 0.1; pointer-events: none;
}

/* ─── Forms ─── */
.form-field { margin-bottom: 22px; }
.form-field label { display: block; font-size: 0.82rem; font-weight: 600; margin-bottom: 8px; letter-spacing: 0.04em; }
.form-field input, .form-field textarea, .form-field select {
  width: 100%; padding: 14px 16px;
  background: var(--paper); border: 1px solid rgba(20,33,61,0.18);
  font-family: var(--sans); font-size: 0.95rem; color: var(--ink);
  border-radius: var(--radius); outline: none; transition: border-color 0.2s;
}
.form-field input:focus, .form-field textarea:focus, .form-field select:focus { border-color: var(--accent); }
.form-field textarea { min-height: 140px; resize: vertical; }

/* ─── Tags / Pills ─── */
.tag {
  display: inline-block; padding: 4px 10px; font-size: 0.72rem;
  letter-spacing: 0.08em; text-transform: uppercase; font-weight: 600;
  background: rgba(20,33,61,0.06); color: var(--ink-soft); border-radius: 20px;
}

/* ─── Stats ─── */
.stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 40px; }
@media (max-width: 700px) { .stats { grid-template-columns: repeat(2, 1fr); } }
.stat .num-big { font-family: var(--serif); font-size: clamp(2.4rem, 5vw, 4rem); color: var(--accent); font-style: italic; line-height: 1; display: block; margin-bottom: 4px; }
.stat .lbl { font-size: 0.85rem; color: var(--muted); }

/* ─── Process timeline ─── */
.timeline { position: relative; padding-left: 36px; }
.timeline::before { content: ''; position: absolute; left: 12px; top: 6px; bottom: 6px; width: 1px; background: var(--ink); opacity: 0.2; }
.timeline-item { position: relative; padding-bottom: 36px; }
.timeline-item:last-child { padding-bottom: 0; }
.timeline-item::before {
  content: ''; position: absolute; left: -30px; top: 6px;
  width: 13px; height: 13px; border-radius: 50%;
  background: var(--bg); border: 2px solid var(--accent);
}
.timeline-item .step-label { font-family: var(--mono); font-size: 0.78rem; color: var(--accent); margin-bottom: 6px; letter-spacing: 0.05em; }
.timeline-item h3 { font-size: 1.4rem; margin-bottom: 8px; }

/* ─── Prose (blog/legal pages) ─── */
.prose { max-width: 780px; margin: 0 auto; font-size: 1.05rem; line-height: 1.75; }
.prose p { margin-bottom: 22px; color: var(--ink-soft); }
.prose h2 { font-size: 2rem; margin: 50px 0 18px; }
.prose h3 { font-size: 1.4rem; margin: 36px 0 12px; }
.prose ul, .prose ol { margin: 0 0 22px 24px; }
.prose li { margin-bottom: 8px; color: var(--ink-soft); }
.prose strong { color: var(--ink); }
.prose a { color: var(--accent); text-decoration: underline; text-underline-offset: 4px; }
.prose blockquote { border-left: 3px solid var(--accent); padding: 8px 0 8px 24px; font-family: var(--serif); font-style: italic; font-size: 1.3rem; color: var(--ink); margin: 28px 0; }
.prose hr { border: none; border-top: 1px solid rgba(20,33,61,0.15); margin: 40px 0; }

/* Asymmetric grid showpiece */
.feature-split { display: grid; grid-template-columns: 5fr 7fr; gap: 60px; align-items: center; }
@media (max-width: 820px) { .feature-split { grid-template-columns: 1fr; gap: 32px; } }
.feature-split img { width: 100%; aspect-ratio: 4/5; object-fit: cover; }

/* Page title block (for inner pages) */
.page-head { padding: clamp(70px, 12vw, 140px) 0 clamp(40px, 6vw, 80px); border-bottom: 1px solid rgba(20,33,61,0.12); position: relative; overflow: hidden; }
.page-head h1 { max-width: 900px; }
.page-head .lede { font-size: clamp(1.05rem, 1.4vw, 1.25rem); color: var(--ink-soft); max-width: 640px; margin-top: 24px; }

/* Pricing */
.price-card { background: var(--paper); padding: 40px 32px; border: 1px solid rgba(20,33,61,0.1); position: relative; transition: all 0.3s; }
.price-card.featured { border: 2px solid var(--ink); transform: scale(1.02); }
.price-card.featured .ribbon { position: absolute; top: -12px; left: 32px; background: var(--accent); color: var(--bg); padding: 4px 12px; font-size: 0.72rem; font-weight: 700; letter-spacing: 0.1em; text-transform: uppercase; }
.price-card h3 { font-size: 1.4rem; margin-bottom: 8px; }
.price-card .price { font-family: var(--serif); font-size: 3rem; color: var(--ink); display: block; margin: 20px 0 6px; line-height: 1; }
.price-card .price-sub { color: var(--muted); font-size: 0.85rem; margin-bottom: 24px; }
.price-card ul { list-style: none; margin-bottom: 28px; }
.price-card li { padding: 8px 0; font-size: 0.92rem; color: var(--ink-soft); display: flex; gap: 10px; align-items: flex-start; }
.price-card li::before { content: '✓'; color: var(--accent); font-weight: 700; flex-shrink: 0; }

/* Portfolio item */
.work-item { position: relative; overflow: hidden; aspect-ratio: 4/3; cursor: pointer; }
.work-item img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.6s; }
.work-item:hover img { transform: scale(1.05); }
.work-item .overlay {
  position: absolute; inset: 0; background: linear-gradient(180deg, transparent 0%, rgba(20,33,61,0.85) 80%);
  display: flex; flex-direction: column; justify-content: flex-end; padding: 28px;
  color: var(--bg); opacity: 0; transition: opacity 0.3s;
}
.work-item:hover .overlay { opacity: 1; }
.work-item .overlay .tag-row { display: flex; gap: 8px; margin-bottom: 10px; }
.work-item .overlay .tag { background: rgba(255,255,255,0.18); color: var(--bg); }
.work-item .overlay h3 { color: var(--bg); font-size: 1.4rem; }

/* Quote */
.quote-block { font-family: var(--serif); font-style: italic; font-size: clamp(1.4rem, 2.6vw, 2rem); line-height: 1.4; color: var(--ink); max-width: 900px; }
.quote-block::before { content: '"'; font-size: 4rem; color: var(--accent); display: block; line-height: 0.5; margin-top: 30px; }

/* Utility */
.text-center { text-align: center; }
.mb-s { margin-bottom: 16px; }
.mb-m { margin-bottom: 32px; }
.mb-l { margin-bottom: 56px; }
.mt-l { margin-top: 56px; }
.flex-wrap-cta { display: flex; gap: 14px; flex-wrap: wrap; margin-top: 32px; }
.maxw-700 { max-width: 700px; }
