/* =========================================================
   CODYNIX LTD — Design System
   Palette: Navy (dominant), Royal Blue, Signal Red, Paper White
   Type: Manrope (display) + Inter (body)
   Signature motif: the "flight-line" — a 12° diagonal cut used
   in the logo, section dividers and hero UI, a quiet nod to the
   Union Jack's diagonals without ever showing the flag itself.
   ========================================================= */

:root{
  --navy: #0B1E3F;
  --navy-2: #10284F;
  --blue: #2451E0;
  --blue-light: #4E76FF;
  --red: #D7263D;
  --white: #FFFFFF;
  --paper: #F5F7FB;
  --paper-2: #ECF0F8;
  --ink: #0E1424;
  --slate: #5B6472;
  --slate-soft: #8791A0;
  --line: #E3E7EF;
  --line-dark: rgba(255,255,255,.12);

  --radius-sm: 10px;
  --radius-md: 16px;
  --radius-lg: 24px;

  --shadow-sm: 0 2px 10px rgba(11,30,63,.06);
  --shadow-md: 0 12px 30px rgba(11,30,63,.10);
  --shadow-lg: 0 24px 60px rgba(11,30,63,.16);

  --ease: cubic-bezier(.16,.84,.44,1);
  --font-display: 'Manrope', 'Inter', sans-serif;
  --font-body: 'Inter', sans-serif;
}

*, *::before, *::after{ box-sizing: border-box; }
html{ scroll-behavior: smooth; }
body{
  margin:0;
  font-family: var(--font-body);
  color: var(--ink);
  background: var(--paper);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
img{ max-width:100%; display:block; }
a{ color: inherit; text-decoration:none; }
ul{ margin:0; padding:0; list-style:none; }
button{ font-family: inherit; cursor:pointer; }
h1,h2,h3,h4{ font-family: var(--font-display); color: var(--navy); margin:0 0 .5em; line-height:1.1; letter-spacing:-0.02em; }
p{ margin:0 0 1em; color: var(--slate); line-height:1.65; }

.container{ max-width: 1180px; margin:0 auto; padding: 0 24px; }
.eyebrow{
  display:inline-flex; align-items:center; gap:8px;
  font-family: var(--font-display); font-weight:800; font-size:12px;
  letter-spacing:.14em; text-transform:uppercase; color: var(--blue);
  margin-bottom:14px;
}
.eyebrow::before{
  content:""; width:16px; height:2px; background: var(--red);
  transform: skewX(-20deg);
}

section{ padding: 96px 0; position:relative; }
@media (max-width: 720px){ section{ padding: 64px 0; } }

.section-head{ max-width: 640px; margin-bottom: 56px; }
.section-head h2{ font-size: clamp(28px, 4vw, 40px); }
.section-head p{ font-size: 17px; }
.section-head.center{ margin-left:auto; margin-right:auto; text-align:center; }

/* ============ Buttons ============ */
.btn{
  display:inline-flex; align-items:center; justify-content:center; gap:10px;
  padding: 14px 26px; border-radius: 100px; font-weight:700; font-size:15px;
  border: 1px solid transparent; transition: transform .25s var(--ease), box-shadow .25s var(--ease), background .25s var(--ease), color .25s var(--ease);
  white-space: nowrap;
}
.btn-primary{ background: var(--blue); color:#fff; box-shadow: 0 10px 24px rgba(36,81,224,.30); }
.btn-primary:hover{ transform: translateY(-2px); box-shadow: 0 16px 32px rgba(36,81,224,.38); background: var(--blue-light); }
.btn-ghost{ background: transparent; color: var(--navy); border-color: var(--line); }
.btn-ghost:hover{ border-color: var(--navy); transform: translateY(-2px); }
.btn-on-dark{ background: rgba(255,255,255,.08); color:#fff; border-color: rgba(255,255,255,.28); }
.btn-on-dark:hover{ background: rgba(255,255,255,.16); transform: translateY(-2px); }
.btn-red{ background: var(--red); color:#fff; box-shadow: 0 10px 24px rgba(215,38,61,.30); }
.btn-red:hover{ transform: translateY(-2px); background:#c31f35; }
.btn-block{ width:100%; }

/* ============ Header ============ */
.site-header{
  position: fixed; top:0; left:0; right:0; z-index: 999;
  background: rgba(245,247,251,.78);
  backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid rgba(11,30,63,.06);
  transition: background .3s var(--ease);
}
.site-header .container{ display:flex; align-items:center; justify-content:space-between; height:76px; }

.logo{ display:flex; align-items:center; gap:10px; }
.logo-mark{ width:38px; height:38px; flex-shrink:0; }
.logo-word{ font-family: var(--font-display); font-weight:800; font-size:19px; letter-spacing:-0.01em; color: var(--navy); }
.logo-word span{ color: var(--blue); }

.nav-links{ display:flex; align-items:center; gap:6px; }
.nav-links a{
  padding: 10px 16px; border-radius: 100px; font-weight:600; font-size:14.5px; color: var(--navy);
  position: relative; transition: background .25s var(--ease), color .25s var(--ease);
}
.nav-links a:hover{ background: rgba(36,81,224,.08); color: var(--blue); }
.nav-links a.active{ background: var(--navy); color:#fff; }

.nav-actions{ display:flex; align-items:center; gap:12px; }

.nav-toggle{
  display:none; flex-direction:column; gap:5px; background:none; border:none; padding:8px;
}
.nav-toggle span{ width:24px; height:2px; background: var(--navy); border-radius:2px; transition: all .3s var(--ease); }
.nav-toggle.open span:nth-child(1){ transform: translateY(7px) rotate(45deg); }
.nav-toggle.open span:nth-child(2){ opacity:0; }
.nav-toggle.open span:nth-child(3){ transform: translateY(-7px) rotate(-45deg); }

@media (max-width: 940px){
  .nav-links{
    position: fixed; top:76px; left:0; right:0; bottom:0;
    background: var(--paper); flex-direction:column; align-items:stretch;
    padding: 20px 24px; gap:4px; transform: translateX(100%); transition: transform .35s var(--ease);
    overflow-y:auto;
  }
  .nav-links.open{ transform: translateX(0); }
  .nav-links a{ padding:16px 18px; font-size:17px; }
  .nav-toggle{ display:flex; }
  .nav-actions .btn-primary{ display:none; }
  .nav-links .mobile-cta{ display:block; margin-top:12px; }
}
.nav-links .mobile-cta{ display:none; }

/* ============ Hero ============ */
.hero{
  padding: 168px 0 100px;
  background: linear-gradient(180deg, var(--navy) 0%, var(--navy-2) 100%);
  color:#fff; position:relative; overflow:hidden;
}
.hero::before{
  content:""; position:absolute; inset:0;
  background-image:
    linear-gradient(115deg, transparent 46%, rgba(215,38,61,.14) 46%, rgba(215,38,61,.14) 47.4%, transparent 47.4%),
    linear-gradient(115deg, transparent 51%, rgba(255,255,255,.08) 51%, rgba(255,255,255,.08) 52%, transparent 52%);
  pointer-events:none;
}
.hero .container{ display:grid; grid-template-columns: 1.05fr .95fr; gap:56px; align-items:center; position:relative; z-index:2; }
@media (max-width: 940px){ .hero .container{ grid-template-columns: 1fr; } .hero{ padding-top:140px; } }

.hero-copy h1{ color:#fff; font-size: clamp(34px, 5vw, 58px); font-weight:800; }
.hero-copy .lede{ color: rgba(255,255,255,.72); font-size:18px; max-width:520px; }
.hero-cta{ display:flex; gap:14px; margin-top:32px; flex-wrap:wrap; }
.hero-stats{ display:flex; gap:36px; margin-top:52px; flex-wrap:wrap; }
.hero-stat b{ display:block; font-family: var(--font-display); font-size:28px; color:#fff; }
.hero-stat span{ font-size:13px; color: rgba(255,255,255,.56); }

.hero-eyebrow{
  display:inline-flex; align-items:center; gap:8px; padding:7px 14px 7px 10px;
  background: rgba(255,255,255,.08); border:1px solid rgba(255,255,255,.16);
  border-radius:100px; font-size:12.5px; font-weight:700; color: rgba(255,255,255,.85); margin-bottom:22px;
}
.hero-eyebrow .dot{ width:8px; height:8px; border-radius:50%; background: var(--red); }

/* ---- Phone mockup (signature element) ---- */
.phone-stage{ position:relative; display:flex; justify-content:center; }
.phone{
  width: 268px; height: 546px; border-radius: 42px; background: #0A1730;
  border: 8px solid #16203C; box-shadow: var(--shadow-lg), 0 0 0 1px rgba(255,255,255,.06);
  position:relative; overflow:hidden; z-index:2;
}
.phone::before{
  content:""; position:absolute; top:14px; left:50%; transform: translateX(-50%);
  width:88px; height:22px; background:#0A1730; border-radius:14px; z-index:5;
}
.phone-screen{ position:absolute; inset:0; background: var(--paper); }
.app-frame{ position:absolute; inset:0; opacity:0; transform: translateY(14px); transition: opacity .5s var(--ease), transform .5s var(--ease); padding-top:54px; }
.app-frame.active{ opacity:1; transform: translateY(0); }
.app-topbar{ padding: 0 20px 14px; display:flex; align-items:center; justify-content:space-between; }
.app-topbar b{ font-family: var(--font-display); font-size:15px; color: var(--navy); }
.app-dot{ width:26px; height:26px; border-radius:50%; background: var(--blue); }
.app-card{ margin:0 20px 12px; background:#fff; border-radius:14px; padding:14px; box-shadow: var(--shadow-sm); }
.app-card .bar{ height:8px; border-radius:6px; background: var(--paper-2); margin-bottom:8px; }
.app-card .bar.short{ width:60%; }
.app-card .bar.blue{ background: var(--blue); width:40%; }
.app-chip-row{ display:flex; gap:8px; padding:0 20px 14px; }
.app-chip{ padding:8px 14px; border-radius:100px; font-size:11px; font-weight:700; background: var(--paper-2); color: var(--slate); }
.app-chip.active{ background: var(--navy); color:#fff; }
.app-graph{ margin:0 20px; height:104px; background: linear-gradient(180deg, rgba(36,81,224,.14), transparent); border-radius:14px; position:relative; overflow:hidden; }
.app-graph svg{ position:absolute; inset:0; }
.app-fab{ position:absolute; bottom:26px; right:26px; width:52px; height:52px; border-radius:50%; background: var(--red); box-shadow: 0 10px 20px rgba(215,38,61,.4); display:flex; align-items:center; justify-content:center; }

.phone-glow{
  position:absolute; width:420px; height:420px; border-radius:50%;
  background: radial-gradient(circle, rgba(36,81,224,.35), transparent 70%);
  filter: blur(10px); z-index:1;
}
.float-card{
  position:absolute; background:#fff; border-radius: var(--radius-md); box-shadow: var(--shadow-lg);
  padding:14px 16px; display:flex; align-items:center; gap:10px; z-index:3; animation: floaty 5s ease-in-out infinite;
}
.float-card.f1{ top:8%; left:-8%; }
.float-card.f2{ bottom:12%; right:-10%; animation-delay: 1.2s; }
.float-card b{ font-family: var(--font-display); font-size:14px; color: var(--navy); display:block; }
.float-card span{ font-size:11px; color: var(--slate-soft); }
.float-icon{ width:34px; height:34px; border-radius:10px; display:flex; align-items:center; justify-content:center; flex-shrink:0; }
.float-icon.ios{ background: rgba(36,81,224,.12); }
.float-icon.android{ background: rgba(215,38,61,.12); }
@keyframes floaty{ 0%,100%{ transform: translateY(0); } 50%{ transform: translateY(-10px); } }

@media (max-width: 940px){
  .phone{ width:220px; height:448px; }
  .float-card{ display:none; }
}

/* ============ Logo strip ============ */
.logo-strip{ background:#fff; border-bottom:1px solid var(--line); padding:36px 0; }
.logo-strip .container{ display:flex; align-items:center; justify-content:space-between; flex-wrap:wrap; gap:24px; }
.logo-strip .label{ font-size:12.5px; font-weight:700; letter-spacing:.1em; text-transform:uppercase; color: var(--slate-soft); }
.strip-items{ display:flex; gap:36px; flex-wrap:wrap; align-items:center; }
.strip-items span{ font-family: var(--font-display); font-weight:800; color: var(--slate-soft); font-size:15px; opacity:.7; }

/* ============ Cards: services ============ */
.grid{ display:grid; gap:24px; }
.grid-3{ grid-template-columns: repeat(3, 1fr); }
.grid-2{ grid-template-columns: repeat(2, 1fr); }
@media (max-width: 940px){ .grid-3{ grid-template-columns: 1fr 1fr; } }
@media (max-width: 640px){ .grid-3, .grid-2{ grid-template-columns: 1fr; } }

.card{
  background:#fff; border:1px solid var(--line); border-radius: var(--radius-lg);
  padding: 32px; transition: transform .3s var(--ease), box-shadow .3s var(--ease), border-color .3s var(--ease);
  position:relative; overflow:hidden;
}
.card:hover{ transform: translateY(-6px); box-shadow: var(--shadow-md); border-color: transparent; }
.card::after{
  content:""; position:absolute; top:0; right:0; width:70px; height:70px;
  background: linear-gradient(135deg, rgba(36,81,224,.10), transparent 70%);
  opacity:0; transition: opacity .3s var(--ease);
}
.card:hover::after{ opacity:1; }
.card-icon{
  width:52px; height:52px; border-radius:14px; background: var(--navy);
  display:flex; align-items:center; justify-content:center; margin-bottom:20px;
}
.card h3{ font-size:19px; margin-bottom:10px; }
.card p{ font-size:15px; margin-bottom:0; }
.card-list{ margin-top:14px; display:flex; flex-direction:column; gap:8px; }
.card-list li{ font-size:13.5px; color: var(--slate); display:flex; align-items:center; gap:8px; }
.card-list li::before{ content:""; width:6px; height:6px; border-radius:50%; background: var(--red); flex-shrink:0; }

/* ============ Team ============ */
.team-card{ background:#fff; border-radius: var(--radius-lg); overflow:hidden; border:1px solid var(--line); transition: transform .3s var(--ease), box-shadow .3s var(--ease); }
.team-card:hover{ transform: translateY(-6px); box-shadow: var(--shadow-md); }
.team-avatar{ aspect-ratio: 4/3.4; width:100%; }
.team-body{ padding:22px 22px 26px; }
.team-body h3{ font-size:17px; margin-bottom:2px; }
.team-role{ color: var(--blue); font-weight:700; font-size:13px; margin-bottom:10px; display:block; }
.team-body p{ font-size:14px; margin-bottom:0; }

/* ============ Diagonal divider (signature motif) ============ */
.flight-divider{ height:64px; position:relative; overflow:hidden; }
.flight-divider svg{ width:100%; height:100%; display:block; }

/* ============ Steps / process ============ */
.steps{ display:grid; grid-template-columns: repeat(4,1fr); gap:0; counter-reset: step; }
@media (max-width: 940px){ .steps{ grid-template-columns: repeat(2,1fr); } }
@media (max-width: 560px){ .steps{ grid-template-columns: 1fr; } }
.step{ padding: 0 24px 0 0; position:relative; }
.step-num{ font-family: var(--font-display); font-weight:800; font-size:44px; color: var(--paper-2); -webkit-text-stroke: 1.5px var(--line); display:block; margin-bottom:10px; }
.step h4{ font-size:16px; margin-bottom:8px; }
.step p{ font-size:14px; }

/* ============ Dark band / CTA ============ */
.band{ background: var(--navy); color:#fff; }
.band h2, .band h3{ color:#fff; }
.band p{ color: rgba(255,255,255,.68); }
.cta-band{ padding: 80px 0; text-align:center; }
.cta-band h2{ font-size: clamp(26px,4vw,38px); max-width:640px; margin:0 auto 16px; }
.cta-band p{ max-width:520px; margin:0 auto 28px; }
.cta-band .hero-cta{ justify-content:center; }

/* ============ Footer ============ */
.site-footer{ background: var(--navy); color: rgba(255,255,255,.7); padding: 72px 0 28px; }
.footer-grid{ display:grid; grid-template-columns: 1.4fr 1fr 1fr 1.2fr; gap:40px; padding-bottom:48px; border-bottom:1px solid rgba(255,255,255,.1); }
@media (max-width: 820px){ .footer-grid{ grid-template-columns: 1fr 1fr; } }
@media (max-width: 520px){ .footer-grid{ grid-template-columns: 1fr; } }
.footer-grid h4{ color:#fff; font-size:13px; letter-spacing:.08em; text-transform:uppercase; margin-bottom:18px; }
.footer-grid ul{ display:flex; flex-direction:column; gap:11px; }
.footer-grid a{ font-size:14.5px; transition: color .2s var(--ease); }
.footer-grid a:hover{ color:#fff; }
.footer-brand p{ color: rgba(255,255,255,.6); font-size:14.5px; max-width:280px; }
.footer-bottom{ display:flex; justify-content:space-between; align-items:center; padding-top:24px; flex-wrap:wrap; gap:12px; font-size:13px; color: rgba(255,255,255,.45); }

/* ============ Forms ============ */
.form-group{ margin-bottom:20px; }
.form-group label{ display:block; font-size:13.5px; font-weight:700; color: var(--navy); margin-bottom:8px; }
.form-group input, .form-group textarea{
  width:100%; padding:14px 16px; border-radius: var(--radius-sm); border:1.5px solid var(--line);
  font-family: inherit; font-size:15px; color: var(--ink); background:#fff; transition: border-color .2s var(--ease), box-shadow .2s var(--ease);
}
.form-group input:focus, .form-group textarea:focus{ outline:none; border-color: var(--blue); box-shadow: 0 0 0 4px rgba(36,81,224,.12); }
.form-group textarea{ resize: vertical; min-height:140px; }
.form-note{ font-size:13px; color: var(--slate-soft); margin-top:10px; }
.form-success{ display:none; background: rgba(36,81,224,.08); border:1px solid rgba(36,81,224,.25); color: var(--navy); padding:16px 18px; border-radius: var(--radius-sm); font-size:14.5px; font-weight:600; margin-bottom:20px; }
.form-success.show{ display:flex; align-items:center; gap:10px; }

/* ============ Page hero (inner pages) ============ */
.page-hero{ padding: 154px 0 76px; background: var(--navy); color:#fff; position:relative; overflow:hidden; }
.page-hero::before{
  content:""; position:absolute; inset:0;
  background-image: linear-gradient(115deg, transparent 62%, rgba(215,38,61,.12) 62%, rgba(215,38,61,.12) 63.4%, transparent 63.4%);
}
.page-hero .container{ position:relative; z-index:2; max-width:760px; }
.page-hero h1{ color:#fff; font-size: clamp(32px,4.6vw,48px); }
.page-hero p{ color: rgba(255,255,255,.72); font-size:17px; max-width:560px; }
.breadcrumb{ font-size:13px; color: rgba(255,255,255,.5); margin-bottom:18px; font-weight:600; }
.breadcrumb a:hover{ color:#fff; }

/* ============ Utility ============ */
.two-col{ display:grid; grid-template-columns: 1fr 1fr; gap:64px; align-items:center; }
@media (max-width: 860px){ .two-col{ grid-template-columns: 1fr; gap:36px; } }
.tag-pill{ display:inline-block; padding:6px 14px; border-radius:100px; background: rgba(36,81,224,.1); color: var(--blue); font-size:12.5px; font-weight:700; margin: 4px 6px 0 0; }
.stat-row{ display:flex; gap:40px; flex-wrap:wrap; margin-top:28px; }
.stat b{ font-family: var(--font-display); font-size:32px; color: var(--navy); display:block; }
.stat span{ font-size:13px; color: var(--slate-soft); }

.check-list{ display:flex; flex-direction:column; gap:16px; margin-top:24px; }
.check-item{ display:flex; gap:14px; align-items:flex-start; }
.check-ico{ width:26px; height:26px; border-radius:50%; background: var(--blue); flex-shrink:0; display:flex; align-items:center; justify-content:center; margin-top:2px; }
.check-item div h4{ font-size:15.5px; margin-bottom:2px; }
.check-item div p{ font-size:14px; margin-bottom:0; }

/* ============ Reveal-on-scroll ============ */
.reveal{ opacity:0; transform: translateY(28px); transition: opacity .7s var(--ease), transform .7s var(--ease); }
.reveal.in{ opacity:1; transform: translateY(0); }
.reveal-stagger > *{ opacity:0; transform: translateY(24px); transition: opacity .6s var(--ease), transform .6s var(--ease); }
.reveal-stagger.in > *{ opacity:1; transform: translateY(0); }
.reveal-stagger.in > *:nth-child(1){ transition-delay: .04s; }
.reveal-stagger.in > *:nth-child(2){ transition-delay: .12s; }
.reveal-stagger.in > *:nth-child(3){ transition-delay: .2s; }
.reveal-stagger.in > *:nth-child(4){ transition-delay: .28s; }
.reveal-stagger.in > *:nth-child(5){ transition-delay: .36s; }
.reveal-stagger.in > *:nth-child(6){ transition-delay: .44s; }

@media (prefers-reduced-motion: reduce){
  .reveal, .reveal-stagger > *, .float-card, .app-frame{ transition: none !important; animation: none !important; opacity:1 !important; transform:none !important; }
}

/* ============ Portfolio ============ */
.app-store-banner{
  background: linear-gradient(120deg, var(--navy), var(--navy-2));
  border-radius: var(--radius-lg); padding: 48px; color:#fff; display:flex; align-items:center; justify-content:space-between; gap:32px; flex-wrap:wrap; position:relative; overflow:hidden;
}
.app-store-banner::before{
  content:""; position:absolute; inset:0;
  background-image: linear-gradient(115deg, transparent 70%, rgba(215,38,61,.18) 70%, rgba(215,38,61,.18) 71.6%, transparent 71.6%);
}
.app-store-banner > *{ position:relative; z-index:2; }
.app-store-banner h3{ color:#fff; font-size:22px; margin-bottom:8px; }
.app-store-banner p{ color: rgba(255,255,255,.7); margin-bottom:0; max-width:420px; }

.portfolio-card{ background:#fff; border:1px solid var(--line); border-radius: var(--radius-lg); overflow:hidden; transition: transform .3s var(--ease), box-shadow .3s var(--ease); }
.portfolio-card:hover{ transform: translateY(-6px); box-shadow: var(--shadow-md); }
.portfolio-thumb{ aspect-ratio: 16/11; width:100%; position:relative; }
.portfolio-body{ padding:22px; }
.portfolio-body h3{ font-size:17px; margin-bottom:6px; }
.portfolio-body p{ font-size:14px; }
.portfolio-tags{ display:flex; gap:6px; flex-wrap:wrap; margin-top:12px; }
.portfolio-tags span{ font-size:11px; font-weight:700; padding:5px 10px; border-radius:100px; background: var(--paper-2); color: var(--slate); }

/* Contact page */
.contact-info-card{ background:#fff; border:1px solid var(--line); border-radius: var(--radius-lg); padding:26px; display:flex; gap:16px; align-items:flex-start; }
.contact-info-card .icon{ width:44px; height:44px; border-radius:12px; background: var(--navy); flex-shrink:0; display:flex; align-items:center; justify-content:center; }
.contact-info-card h4{ font-size:15px; margin-bottom:4px; }
.contact-info-card p{ font-size:14px; margin-bottom:0; }
.contact-info-card a{ color: var(--blue); font-weight:600; }

.map-frame{ border-radius: var(--radius-lg); overflow:hidden; border:1px solid var(--line); height:100%; min-height:260px; }
