:root {
  --bg: #ffffff;
  --bg-alt: #f6f8fb;
  --ink: #0b1f3a;
  --ink-2: #1a2f4e;
  --ink-soft: #3a4a63;
  --muted: #6b7a8f;
  --border: #e6eaf0;
  --border-strong: #d5dce6;
  --accent: #2b6cb0;
  --accent-2: #4fbdba;
  --accent-strong: #1e4e8c;
  --warm: #f2c14e;
  --radius: 12px;
  --radius-lg: 18px;
  --shadow-sm: 0 1px 2px rgba(11,31,58,0.05), 0 1px 3px rgba(11,31,58,0.06);
  --shadow-md: 0 6px 20px rgba(11,31,58,0.08), 0 2px 6px rgba(11,31,58,0.05);
  --shadow-lg: 0 20px 60px rgba(11,31,58,0.15), 0 6px 20px rgba(11,31,58,0.08);
  --max: 1160px;
  --sans: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --serif: "Fraunces", Georgia, "Times New Roman", serif;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: var(--sans);
  color: var(--ink);
  background: var(--bg);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}

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

.container {
  max-width: var(--max);
  margin: 0 auto;
  padding: 0 24px;
}

/* ============ HEADER ============ */

.site-header {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  padding: 4px 0;
  background: rgba(255,255,255,0);
  transition: background 0.25s ease, box-shadow 0.25s ease, backdrop-filter 0.25s ease;
}
.site-header.scrolled {
  background: rgba(255,255,255,0.88);
  backdrop-filter: saturate(180%) blur(14px);
  -webkit-backdrop-filter: saturate(180%) blur(14px);
  box-shadow: 0 1px 0 rgba(11,31,58,0.06);
}
.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 72px;
}
.brand { display: flex; align-items: center; gap: 12px; text-decoration: none; color: var(--ink); font-weight: 700; letter-spacing: -0.01em; }
.brand-mark {
  display: inline-flex; align-items: center; justify-content: center;
  width: 36px; height: 36px;
  background: linear-gradient(135deg, var(--ink) 0%, #1e3a66 100%);
  color: #fff; border-radius: 10px;
  font-weight: 800; font-size: 18px;
  box-shadow: 0 4px 12px rgba(11,31,58,0.25);
}
.brand-name { font-size: 16px; }

.site-header:not(.scrolled) .brand,
.site-header:not(.scrolled) .nav-links a {
  color: #fff;
}
.site-header:not(.scrolled) .brand-mark {
  background: rgba(255,255,255,0.14);
  border: 1px solid rgba(255,255,255,0.28);
  box-shadow: none;
}

.nav-links a {
  color: var(--ink-soft); text-decoration: none;
  margin-left: 30px; font-size: 14.5px; font-weight: 500;
  transition: color 0.15s ease;
}
.nav-links a:hover { color: var(--accent); }
.nav-links .nav-cta {
  padding: 8px 16px;
  background: var(--ink); color: #fff !important;
  border-radius: 8px;
  transition: background 0.15s ease;
}
.nav-links .nav-cta:hover { background: var(--accent-strong); }
.site-header:not(.scrolled) .nav-links .nav-cta { background: rgba(255,255,255,0.15); border: 1px solid rgba(255,255,255,0.28); }
.site-header:not(.scrolled) .nav-links .nav-cta:hover { background: rgba(255,255,255,0.25); }

@media (max-width: 720px) {
  .brand-name { display: none; }
  .nav-links a { margin-left: 18px; font-size: 13.5px; }
  .nav-links .nav-cta { padding: 7px 12px; }
}
@media (max-width: 500px) {
  .nav-links a:not(.nav-cta) { display: none; }
}

/* ============ HERO ============ */

.hero {
  position: relative;
  min-height: 100vh;
  color: #fff;
  display: flex;
  align-items: center;
  padding: 100px 0 80px;
  overflow: hidden;
}
.hero-bg { position: absolute; inset: 0; z-index: 0; }
.hero-bg .slide {
  position: absolute; inset: 0;
  background-size: cover; background-position: center;
  opacity: 0;
  animation: heroFade 35s infinite;
  transform: scale(1.08);
}
.hero-bg .slide:nth-child(1) { animation-delay: 0s; }
.hero-bg .slide:nth-child(2) { animation-delay: 7s; }
.hero-bg .slide:nth-child(3) { animation-delay: 14s; }
.hero-bg .slide:nth-child(4) { animation-delay: 21s; }
.hero-bg .slide:nth-child(5) { animation-delay: 28s; }

@keyframes heroFade {
  0%    { opacity: 0; transform: scale(1.08); }
  4%    { opacity: 1; }
  20%   { opacity: 1; transform: scale(1.14); }
  24%   { opacity: 0; }
  100%  { opacity: 0; }
}
@media (prefers-reduced-motion: reduce) {
  .hero-bg .slide { animation: none; }
  .hero-bg .slide:nth-child(1) { opacity: 1; }
}

.hero-overlay {
  position: absolute; inset: 0;
  background:
    linear-gradient(120deg, rgba(11,31,58,0.85) 0%, rgba(11,31,58,0.65) 55%, rgba(11,31,58,0.55) 100%),
    radial-gradient(ellipse at 80% 20%, rgba(43,108,176,0.35), transparent 55%);
}
.hero-inner { position: relative; z-index: 2; max-width: 860px; }

.eyebrow {
  display: inline-flex; align-items: center; gap: 10px;
  color: #cfe1ff;
  font-weight: 600; font-size: 13.5px;
  letter-spacing: 0.06em; text-transform: uppercase;
  margin: 0 0 26px;
  padding: 8px 14px;
  border-radius: 999px;
  background: rgba(255,255,255,0.08);
  border: 1px solid rgba(255,255,255,0.14);
  backdrop-filter: blur(6px);
}
.pulse {
  width: 8px; height: 8px; border-radius: 50%;
  background: #6fe4a0;
  box-shadow: 0 0 0 0 rgba(111,228,160,0.6);
  animation: pulse 2s infinite;
}
@keyframes pulse {
  0%   { box-shadow: 0 0 0 0 rgba(111,228,160,0.6); }
  70%  { box-shadow: 0 0 0 12px rgba(111,228,160,0); }
  100% { box-shadow: 0 0 0 0 rgba(111,228,160,0); }
}

.hero-title {
  font-family: var(--serif);
  font-weight: 600;
  font-size: clamp(40px, 6.4vw, 74px);
  line-height: 1.03;
  letter-spacing: -0.02em;
  margin: 0 0 22px;
  color: #fff;
}
.hero-title em {
  font-style: italic;
  color: var(--accent-2);
  font-weight: 500;
}

.hero .lede {
  font-size: 18.5px;
  color: #d7dfec;
  max-width: 640px;
  margin: 0 0 34px;
}

.hero-cta { display: flex; gap: 14px; flex-wrap: wrap; align-items: center; margin-bottom: 46px; }

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  padding: 13px 24px;
  font-size: 15px; font-weight: 600;
  border-radius: 10px;
  text-decoration: none;
  border: 1px solid transparent;
  transition: transform 0.08s ease, background 0.18s ease, box-shadow 0.18s ease, border-color 0.18s ease;
  cursor: pointer;
  font-family: inherit;
}
.btn:active { transform: translateY(1px); }
.btn-lg { padding: 15px 28px; font-size: 16px; }

.btn-primary { background: #fff; color: var(--ink); }
.btn-primary:hover { background: #f0f5ff; box-shadow: var(--shadow-md); }

.btn-ghost {
  background: transparent; color: #fff;
  border-color: rgba(255,255,255,0.35);
}
.btn-ghost:hover { border-color: #fff; background: rgba(255,255,255,0.08); }

/* When inside light sections (e.g. app-card) the primary should be dark */
.section .btn-primary { background: var(--ink); color: #fff; }
.section .btn-primary:hover { background: #17325a; }

/* Hero badges */
.hero-badges {
  display: flex; gap: 12px; flex-wrap: wrap;
}
.badge {
  display: flex; flex-direction: column;
  padding: 12px 18px;
  border-radius: 12px;
  background: rgba(255,255,255,0.06);
  border: 1px solid rgba(255,255,255,0.14);
  backdrop-filter: blur(6px);
  min-width: 140px;
}
.badge strong { font-size: 15px; color: #fff; letter-spacing: -0.005em; }
.badge span { font-size: 12.5px; color: #b7c2d6; margin-top: 2px; }

/* Scroll hint */
.scroll-hint {
  position: absolute;
  bottom: 26px; left: 50%; transform: translateX(-50%);
  width: 26px; height: 42px;
  border: 1.5px solid rgba(255,255,255,0.55);
  border-radius: 15px;
  z-index: 2;
  display: block;
}
.scroll-hint span {
  display: block;
  width: 3px; height: 8px;
  background: #fff;
  border-radius: 2px;
  margin: 8px auto;
  animation: scrollDot 1.7s infinite;
}
@keyframes scrollDot {
  0% { transform: translateY(0); opacity: 1; }
  70% { transform: translateY(14px); opacity: 0; }
  100% { transform: translateY(0); opacity: 0; }
}
@media (max-width: 600px) { .scroll-hint { display: none; } }

/* ============ SECTIONS ============ */

.section { padding: 110px 0; position: relative; }
.section-alt { background: var(--bg-alt); }

.section-head { max-width: 720px; margin: 0 0 60px; }
.section-head.reveal { transition-delay: 0s; }
.section-label {
  color: var(--accent);
  text-transform: uppercase;
  letter-spacing: 0.1em;
  font-size: 12px;
  font-weight: 700;
  margin: 0 0 14px;
}
.section-title {
  font-family: var(--serif);
  font-weight: 600;
  font-size: clamp(30px, 4vw, 46px);
  line-height: 1.1;
  letter-spacing: -0.015em;
  margin: 0 0 18px;
}
.section-sub {
  font-size: 17.5px;
  color: var(--ink-soft);
  margin: 0;
  max-width: 640px;
}

/* Reveal on scroll */
.reveal {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.7s ease, transform 0.7s cubic-bezier(0.2, 0.8, 0.2, 1);
}
.reveal.in { opacity: 1; transform: translateY(0); }

/* ============ SERVICES ============ */

.cards { display: grid; gap: 22px; }
.services-grid { grid-template-columns: repeat(4, 1fr); }
@media (max-width: 1000px) { .services-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 560px) { .services-grid { grid-template-columns: 1fr; } }

.card {
  background: #fff;
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 28px 24px;
  transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
}
.card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-md);
  border-color: var(--border-strong);
}
.card-icon {
  width: 44px; height: 44px;
  display: flex; align-items: center; justify-content: center;
  color: var(--accent);
  background: rgba(43,108,176,0.08);
  border-radius: 10px;
  margin-bottom: 18px;
}
.card-icon svg { width: 22px; height: 22px; }
.card h3 { font-size: 18px; margin: 0 0 8px; letter-spacing: -0.01em; }
.card p { font-size: 15px; color: var(--ink-soft); margin: 0; line-height: 1.6; }

/* ============ APPROACH ============ */

.approach-wrap {}
.steps {
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 22px;
  counter-reset: step;
}
@media (max-width: 780px) { .steps { grid-template-columns: 1fr; } }
.steps li {
  background: #fff;
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 32px 28px;
  position: relative;
  overflow: hidden;
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}
.steps li:hover { transform: translateY(-3px); box-shadow: var(--shadow-md); }
.steps li::before {
  content: '';
  position: absolute; inset: 0 auto 0 0;
  width: 3px;
  background: linear-gradient(180deg, var(--accent) 0%, var(--accent-2) 100%);
}
.step-num {
  font-family: var(--serif);
  font-weight: 500;
  font-size: 42px;
  color: var(--accent);
  opacity: 0.35;
  line-height: 1;
  margin-bottom: 12px;
  letter-spacing: -0.01em;
}
.steps h3 { font-size: 19px; margin: 0 0 8px; letter-spacing: -0.01em; }
.steps p { color: var(--ink-soft); font-size: 15.5px; margin: 0; }

/* ============ PORTFOLIO ============ */

.app-card {
  background: linear-gradient(135deg, #ffffff 0%, #f6f9ff 100%);
  border: 1px solid var(--border);
  border-radius: 22px;
  padding: 48px;
  display: grid;
  grid-template-columns: 1fr 1.2fr;
  gap: 48px;
  align-items: center;
  box-shadow: var(--shadow-sm);
}
@media (max-width: 900px) { .app-card { grid-template-columns: 1fr; padding: 32px; gap: 32px; } }

.app-tag {
  display: inline-block;
  padding: 6px 12px;
  border-radius: 999px;
  background: rgba(111,228,160,0.15);
  color: #1f7a4a;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  margin-bottom: 14px;
}
.app-meta h3 {
  font-family: var(--serif);
  font-weight: 600;
  font-size: 32px;
  letter-spacing: -0.015em;
  margin: 0 0 12px;
  line-height: 1.15;
}
.app-tagline { color: var(--ink-soft); font-size: 17px; margin: 0 0 22px; }
.app-features { padding-left: 20px; margin: 0 0 26px; color: var(--ink-soft); font-size: 15.5px; }
.app-features li { margin-bottom: 7px; }

.app-gallery {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
  align-items: center;
}
@media (max-width: 900px) { .app-gallery { grid-template-columns: 1fr 1fr; } }

.phone-frame {
  padding: 10px;
  background: linear-gradient(160deg, #1a2f4e 0%, #0b1f3a 100%);
  border-radius: 32px;
  box-shadow: var(--shadow-lg);
  transform: rotate(-3deg);
  transition: transform 0.3s ease;
}
.phone-frame:hover { transform: rotate(0deg) scale(1.02); }
.phone-frame img {
  border-radius: 22px;
  width: 100%;
  display: block;
}
.thumbs {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 12px;
}
.thumbs img {
  border-radius: 14px;
  background: #0b1f3a;
  box-shadow: 0 6px 18px rgba(11,31,58,0.14);
  transition: transform 0.25s ease;
}
.thumbs img:hover { transform: translateY(-4px); }

.portfolio-note {
  margin: 40px 0 0;
  color: var(--muted);
  font-size: 15px;
  text-align: center;
}

/* ============ ABOUT ============ */

.about-grid {
  display: grid;
  grid-template-columns: 1.35fr 1fr;
  gap: 56px;
  align-items: start;
}
@media (max-width: 900px) { .about-grid { grid-template-columns: 1fr; gap: 32px; } }

.about-copy p { font-size: 17px; color: var(--ink-soft); margin: 0 0 18px; }
.about-copy strong { color: var(--ink); }

.about-copy blockquote {
  margin: 30px 0 0;
  padding: 22px 26px;
  border-left: 3px solid var(--accent-2);
  background: #fff;
  border-radius: 0 12px 12px 0;
  font-family: var(--serif);
  font-size: 20px;
  font-style: italic;
  color: var(--ink);
  line-height: 1.45;
  font-weight: 500;
  box-shadow: var(--shadow-sm);
}
.about-copy blockquote cite {
  display: block;
  margin-top: 10px;
  font-family: var(--sans);
  font-style: normal;
  font-size: 14px;
  color: var(--muted);
  font-weight: 500;
}

.about-facts {
  background: #fff;
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 30px 32px;
  box-shadow: var(--shadow-sm);
}
.about-facts dl { margin: 0; }
.about-facts dt {
  font-size: 11.5px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--muted);
  font-weight: 700;
  margin-top: 18px;
}
.about-facts dt:first-child { margin-top: 0; }
.about-facts dd {
  margin: 5px 0 0;
  font-size: 15.5px;
  color: var(--ink);
  font-weight: 500;
}

/* ============ CTA BANNER ============ */

.cta-banner {
  background: linear-gradient(135deg, #0b1f3a 0%, #1e3a66 55%, #2b6cb0 100%);
  color: #fff;
  padding: 60px 0;
  position: relative;
  overflow: hidden;
}
.cta-banner::before {
  content: '';
  position: absolute; inset: 0;
  background: radial-gradient(ellipse at 15% 40%, rgba(79,189,186,0.22), transparent 55%),
              radial-gradient(ellipse at 85% 60%, rgba(255,255,255,0.08), transparent 55%);
  pointer-events: none;
}
.cta-inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 32px;
  flex-wrap: wrap;
  position: relative;
}
.cta-banner h2 {
  font-family: var(--serif);
  font-weight: 600;
  font-size: clamp(26px, 3.4vw, 36px);
  margin: 0 0 8px;
  letter-spacing: -0.01em;
  line-height: 1.15;
}
.cta-banner p { color: #cfdcef; margin: 0; max-width: 500px; font-size: 16px; }

/* ============ CONTACT ============ */

.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 22px;
}
@media (max-width: 720px) { .contact-grid { grid-template-columns: 1fr; } }
.contact-card {
  background: #fff;
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 32px;
  transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
}
.contact-card:hover { transform: translateY(-3px); box-shadow: var(--shadow-md); border-color: var(--border-strong); }
.contact-icon {
  width: 44px; height: 44px;
  display: flex; align-items: center; justify-content: center;
  color: var(--accent);
  background: rgba(43,108,176,0.08);
  border-radius: 10px;
  margin-bottom: 18px;
}
.contact-icon svg { width: 22px; height: 22px; }
.contact-card h3 { font-size: 19px; margin: 0 0 8px; letter-spacing: -0.01em; }
.contact-card p, .contact-card address {
  font-size: 15.5px;
  color: var(--ink-soft);
  font-style: normal;
  margin: 0 0 10px;
  line-height: 1.65;
}
.email-link {
  color: var(--accent);
  text-decoration: none;
  font-weight: 600;
  font-size: 16px;
  border-bottom: 1px solid rgba(43,108,176,0.3);
  padding-bottom: 1px;
  transition: border-color 0.15s ease;
}
.email-link:hover { border-bottom-color: var(--accent); }

/* ============ FOOTER ============ */

.site-footer {
  background: #0b1f3a;
  color: #cfd8e4;
  padding: 70px 0 30px;
}
.footer-inner {
  display: grid;
  grid-template-columns: 1.2fr 2fr;
  gap: 60px;
  padding-bottom: 40px;
  border-bottom: 1px solid rgba(255,255,255,0.08);
}
@media (max-width: 820px) { .footer-inner { grid-template-columns: 1fr; gap: 40px; } }

.footer-brand-block .brand { color: #fff; }
.footer-brand-block .brand-mark {
  background: rgba(255,255,255,0.12);
  border: 1px solid rgba(255,255,255,0.2);
  box-shadow: none;
}
.footer-brand-block .brand-name { color: #fff; }
.footer-sub {
  margin: 14px 0 0;
  font-size: 14px;
  color: #98a7bd;
  max-width: 320px;
}
.footer-links {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 30px;
}
@media (max-width: 640px) { .footer-links { grid-template-columns: repeat(2, 1fr); } }
.footer-links h4 {
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: #8797ae;
  margin: 0 0 14px;
  font-weight: 700;
}
.footer-links a {
  display: block;
  color: #cfd8e4;
  text-decoration: none;
  font-size: 14.5px;
  margin-bottom: 8px;
  transition: color 0.15s ease;
}
.footer-links a:hover { color: #fff; }

.footer-bottom {
  padding-top: 24px;
  color: #7c8ba3;
  font-size: 13px;
  text-align: center;
}

/* ============ LEGAL PAGES ============ */

.legal-wrap { max-width: 760px; margin: 0 auto; padding: 130px 24px 100px; }
.legal-wrap h1 {
  font-family: var(--serif);
  font-weight: 600;
  font-size: 40px; letter-spacing: -0.01em; margin: 0 0 8px;
}
.legal-wrap .updated { color: var(--muted); font-size: 14px; margin: 0 0 40px; }
.legal-wrap h2 { font-size: 20px; margin: 36px 0 12px; letter-spacing: -0.01em; }
.legal-wrap p, .legal-wrap li { color: var(--ink-soft); font-size: 16px; line-height: 1.7; }
.legal-wrap a { color: var(--accent); }

/* Legal-page header sits on white bg (no hero), so keep it opaque from start */
body:has(.legal-wrap) .site-header {
  background: rgba(255,255,255,0.9);
  backdrop-filter: saturate(180%) blur(14px);
  -webkit-backdrop-filter: saturate(180%) blur(14px);
  border-bottom: 1px solid var(--border);
}
body:has(.legal-wrap) .site-header .brand,
body:has(.legal-wrap) .site-header .nav-links a { color: var(--ink-soft); }
body:has(.legal-wrap) .site-header .brand { color: var(--ink); }
body:has(.legal-wrap) .site-header .brand-mark {
  background: linear-gradient(135deg, var(--ink) 0%, #1e3a66 100%);
  border: none;
  box-shadow: 0 4px 12px rgba(11,31,58,0.25);
}
body:has(.legal-wrap) .site-header .nav-links .nav-cta { background: var(--ink); color: #fff !important; border: none; }
