/* angel — myangel.care
   Type carries the design. Ink base, one warm signal accent.
   Newsreader (headlines) · Archivo (body) · IBM Plex Mono (labels) */

:root {
  /* angel brand blues, sampled from the mark:
     #15325c · #1f4471 · #295686 · #3867a2 · #4a7fc3 */
  --ink:      #102A4F;          /* deep brand navy base */
  --ink-2:    #173763;          /* raised dark surface  */
  --paper:    #F1F4F9;          /* cool off-white       */
  --paper-2:  #E2E9F3;          /* slightly deeper paper */
  --fg:       #14233B;          /* text on paper        */
  --fg-soft:  #51607A;          /* muted on paper       */
  --on-ink:   #EAF0F8;          /* text on ink          */
  --on-ink-soft: #9DB1CE;       /* muted on ink         */
  --accent:      #3F74BC;       /* brand signal blue            */
  --accent-bright: #5B93D6;     /* brighter signal, used on navy */
  --accent-soft: rgba(91, 147, 214, 0.16);
  --line-ink:  rgba(234, 240, 248, 0.14);
  --line-paper: rgba(20, 35, 59, 0.12);

  --serif: "Newsreader", Georgia, serif;
  --sans:  "Archivo", system-ui, -apple-system, sans-serif;
  --mono:  "IBM Plex Mono", ui-monospace, "SFMono-Regular", monospace;

  --maxw: 1240px;
  --gutter: clamp(22px, 5vw, 80px);
  --ease: cubic-bezier(0.22, 0.61, 0.36, 1);
}

* { box-sizing: border-box; }

html { -webkit-font-smoothing: antialiased; text-rendering: optimizeLegibility; }

body {
  margin: 0;
  font-family: var(--sans);
  background: var(--paper);
  color: var(--fg);
  font-size: 17px;
  line-height: 1.62;
  font-weight: 400;
  letter-spacing: 0.002em;
}

a { color: inherit; }

/* ---------- shared primitives ---------- */
.wrap { max-width: var(--maxw); margin: 0 auto; padding-inline: var(--gutter); }

.kicker {
  font-family: var(--mono);
  font-size: 0.72rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--accent);
  font-weight: 500;
  display: inline-flex;
  align-items: center;
  gap: 0.6em;
}
.kicker::before {
  content: "";
  width: 7px; height: 7px;
  border-radius: 50%;
  background: var(--accent);
  flex: none;
}

h1, h2, h3 {
  font-family: var(--serif);
  font-weight: 440;
  line-height: 1.04;
  letter-spacing: -0.018em;
  text-wrap: balance;
  margin: 0;
}

p { text-wrap: pretty; }

.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.6em;
  font-family: var(--sans);
  font-size: 0.94rem;
  font-weight: 560;
  letter-spacing: 0.005em;
  padding: 0.82em 1.4em;
  border-radius: 2px;
  text-decoration: none;
  border: 1px solid transparent;
  cursor: pointer;
  transition: background 0.25s var(--ease), color 0.25s var(--ease),
              border-color 0.25s var(--ease), transform 0.25s var(--ease);
}
.btn:active { transform: translateY(1px); }
.btn { white-space: nowrap; }

.btn-accent { background: var(--accent); color: #fff; }
.btn-accent:hover { background: var(--accent-bright); }

.btn-ghost { background: transparent; border-color: var(--line-paper); color: var(--fg); }
.btn-ghost:hover { border-color: var(--fg); }

/* on dark surfaces */
.on-dark .btn-ghost { border-color: var(--line-ink); color: var(--on-ink); }
.on-dark .btn-ghost:hover { border-color: var(--on-ink); }

/* ---------- header ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: color-mix(in srgb, var(--paper) 86%, transparent);
  backdrop-filter: saturate(1.2) blur(14px);
  border-bottom: 1px solid var(--line-paper);
}
.header-inner {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 0 var(--gutter);
  height: 70px;
  display: flex;
  align-items: center;
  gap: clamp(18px, 4vw, 52px);
}
.brand {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  font-family: var(--serif);
  font-size: 1.5rem;
  font-weight: 500;
  letter-spacing: -0.02em;
  text-decoration: none;
  color: var(--fg);
  line-height: 1;
}
.brand-mark { height: 30px; width: auto; display: block; }
.nav {
  display: flex;
  align-items: center;
  gap: clamp(16px, 2.4vw, 34px);
  margin-right: auto;
}
.nav a {
  text-decoration: none;
  color: var(--fg-soft);
  font-size: 0.92rem;
  font-weight: 500;
  letter-spacing: 0.005em;
  position: relative;
  padding: 4px 0;
  transition: color 0.2s var(--ease);
}
.nav a:hover { color: var(--fg); }
.nav a[aria-current="page"] { color: var(--fg); }
.nav a[aria-current="page"]::after {
  content: "";
  position: absolute;
  left: 0; bottom: -2px;
  width: 100%; height: 1.5px;
  background: var(--accent);
}
.header-right { display: flex; align-items: center; gap: clamp(14px, 2vw, 26px); }

.lang { position: relative; }
.lang-toggle {
  display: flex;
  align-items: center;
  gap: 7px;
  background: none;
  border: 1px solid var(--line-paper);
  border-radius: 2px;
  padding: 7px 10px;
  cursor: pointer;
  color: var(--fg);
  font-family: var(--mono);
  font-size: 0.72rem;
  letter-spacing: 0.06em;
  transition: border-color 0.2s var(--ease), color 0.2s var(--ease);
}
.lang-toggle:hover { border-color: var(--fg); }
.lang-toggle .globe { width: 15px; height: 15px; flex: none; }
.lang-toggle .caret { width: 10px; height: 10px; opacity: 0.55; transition: transform 0.2s var(--ease); }
.lang[data-open="true"] .lang-toggle { border-color: var(--accent); color: var(--accent); }
.lang[data-open="true"] .lang-toggle .caret { transform: rotate(180deg); }
.lang-menu {
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  min-width: 186px;
  background: var(--paper);
  border: 1px solid var(--line-paper);
  border-radius: 4px;
  padding: 6px;
  display: flex;
  flex-direction: column;
  gap: 2px;
  box-shadow: 0 16px 44px rgba(16, 42, 79, 0.18);
  opacity: 0;
  visibility: hidden;
  transform: translateY(-5px);
  transition: opacity 0.18s var(--ease), transform 0.18s var(--ease), visibility 0.18s;
  z-index: 60;
}
.lang[data-open="true"] .lang-menu { opacity: 1; visibility: visible; transform: none; }
.lang-menu button {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  text-align: left;
  background: none;
  border: none;
  cursor: pointer;
  font-family: var(--sans);
  font-size: 0.92rem;
  font-weight: 500;
  color: var(--fg-soft);
  padding: 9px 12px;
  border-radius: 2px;
  transition: background 0.15s var(--ease), color 0.15s var(--ease);
}
.lang-menu button:hover { background: var(--paper-2); color: var(--fg); }
.lang-menu button[aria-pressed="true"] { color: var(--accent); }
.lang-menu button[aria-pressed="true"]::after {
  content: "";
  width: 6px; height: 6px;
  border-radius: 50%;
  background: var(--accent);
}

.menu-toggle {
  display: none;
  background: none;
  border: 1px solid var(--line-paper);
  border-radius: 2px;
  width: 40px; height: 38px;
  cursor: pointer;
  color: var(--fg);
  align-items: center;
  justify-content: center;
}
.menu-toggle svg { width: 18px; height: 18px; }

/* ---------- footer ---------- */
.site-footer {
  background: var(--ink);
  color: var(--on-ink);
  padding: clamp(54px, 8vw, 92px) 0 44px;
  margin-top: auto;
}
.footer-inner {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 0 var(--gutter);
  display: grid;
  gap: 18px;
}
.footer-top { display: flex; align-items: center; gap: 22px; flex-wrap: wrap; }
.foot-mark { height: 58px; width: auto; display: block; }
.foot-brand {
  font-family: var(--serif);
  font-size: clamp(2.4rem, 7vw, 4rem);
  font-weight: 460;
  letter-spacing: -0.025em;
  line-height: 0.9;
  margin-right: auto;
}
.foot-mail {
  font-family: var(--mono);
  font-size: 0.92rem;
  color: var(--on-ink);
  text-decoration: none;
  border-bottom: 1px solid var(--line-ink);
  padding-bottom: 2px;
  transition: border-color 0.2s var(--ease), color 0.2s var(--ease);
}
.foot-mail:hover { color: var(--accent); border-color: var(--accent); }
.footer-meta {
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: clamp(30px, 5vw, 56px);
  padding-top: 22px;
  border-top: 1px solid var(--line-ink);
  font-family: var(--mono);
  font-size: 0.74rem;
  letter-spacing: 0.04em;
  color: var(--on-ink-soft);
}

/* ---------- page scaffold ---------- */
.page { display: flex; flex-direction: column; min-height: 100vh; }
main { flex: 1; }

/* ---------- reveal motion ---------- */
.reveal {
  opacity: 0;
  transform: translateY(18px);
  transition: opacity 0.8s var(--ease), transform 0.8s var(--ease);
}
.reveal.in { opacity: 1; transform: none; }
.reveal.d1 { transition-delay: 0.08s; }
.reveal.d2 { transition-delay: 0.16s; }
.reveal.d3 { transition-delay: 0.24s; }
.reveal.d4 { transition-delay: 0.32s; }
@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1; transform: none; transition: none; }
  .pulse * { animation: none !important; }
}

/* ================= HOME HERO ================= */
.hero {
  background: var(--ink);
  color: var(--on-ink);
  position: relative;
  overflow: hidden;
  flex: 1 0 auto;
  min-height: calc(100svh - 70px);
  display: flex;
  align-items: center;
}
.hero-grid-bg {
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(var(--line-ink) 1px, transparent 1px),
    linear-gradient(90deg, var(--line-ink) 1px, transparent 1px);
  background-size: 64px 64px;
  background-position: center;
  mask-image: radial-gradient(120% 90% at 78% 42%, #000 8%, transparent 70%);
  opacity: 0.6;
  pointer-events: none;
}
.hero-inner {
  position: relative;
  max-width: var(--maxw);
  margin: 0 auto;
  padding: clamp(64px, 10vh, 120px) var(--gutter);
  width: 100%;
  display: grid;
  grid-template-columns: 1.15fr 0.85fr;
  align-items: center;
  gap: clamp(40px, 6vw, 90px);
}
.hero-copy { max-width: 41ch; }
.hero h1 {
  font-size: clamp(2.6rem, 6.4vw, 5.3rem);
  margin: 24px 0 0;
  color: #fff;
}
/* brighter signal on dark surfaces */
.on-dark .kicker { color: var(--accent-bright); }
.on-dark .kicker::before { background: var(--accent-bright); }

.hero h1 .em { color: var(--accent-bright); font-style: italic; }
.hero-sub {
  margin: 28px 0 0;
  font-size: clamp(1.02rem, 1.5vw, 1.18rem);
  color: var(--on-ink-soft);
  max-width: 46ch;
  line-height: 1.66;
}
.hero-anchor {
  margin: 22px 0 0;
  font-family: var(--mono);
  font-size: 0.78rem;
  letter-spacing: 0.06em;
  color: var(--on-ink);
}
.hero-cta {
  display: flex;
  gap: 14px;
  margin-top: 38px;
  flex-wrap: wrap;
}

/* detection motif */
.pulse-wrap {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 320px;
}
.pulse {
  position: relative;
  width: 260px;
  height: 260px;
  display: grid;
  place-items: center;
}
.pulse-field {
  position: absolute;
  inset: 0;
  border: 1px solid var(--line-ink);
  background-image:
    linear-gradient(var(--line-ink) 1px, transparent 1px),
    linear-gradient(90deg, var(--line-ink) 1px, transparent 1px);
  background-size: 52px 52px;
  background-position: center;
}
.pulse-cross {
  position: absolute;
  width: 38px; height: 38px;
  border: 1px solid var(--accent-bright);
  opacity: 0;
  animation: lock 6s var(--ease) infinite;
}
.pulse-dot {
  position: relative;
  width: 12px; height: 12px;
  border-radius: 50%;
  background: var(--accent-bright);
  z-index: 2;
  box-shadow: 0 0 0 0 var(--accent-soft);
}
.pulse-ring {
  position: absolute;
  width: 12px; height: 12px;
  border-radius: 50%;
  border: 1.5px solid var(--accent-bright);
  opacity: 0;
  animation: ping 6s var(--ease) infinite;
}
.pulse-ring.r2 { animation-delay: 0.5s; }
.pulse-ring.r3 { animation-delay: 1s; }
.pulse-label {
  position: absolute;
  bottom: -30px;
  left: 0;
  font-family: var(--mono);
  font-size: 0.66rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--on-ink-soft);
}
@keyframes ping {
  0%   { width: 12px; height: 12px; opacity: 0.9; }
  16%  { opacity: 0.55; }
  40%  { width: 220px; height: 220px; opacity: 0; }
  100% { width: 220px; height: 220px; opacity: 0; }
}
@keyframes lock {
  0%, 8%   { opacity: 0; transform: scale(2.4); }
  18%      { opacity: 1; transform: scale(1); }
  34%      { opacity: 1; transform: scale(1); }
  46%, 100% { opacity: 0; transform: scale(1); }
}

/* ================= FEATURES ================= */
.feat-head {
  padding: clamp(70px, 12vh, 150px) 0 clamp(20px, 4vw, 40px);
}
.feat-head h1 {
  font-size: clamp(2.2rem, 4.6vw, 3.4rem);
  max-width: 14ch;
  margin-top: 18px;
}
.feature {
  padding: clamp(54px, 8vw, 104px) 0;
  border-top: 1px solid var(--line-paper);
}
.feature-grid {
  display: grid;
  grid-template-columns: 0.42fr 0.58fr;
  gap: clamp(28px, 5vw, 80px);
  align-items: start;
}
.feature-num {
  font-family: var(--mono);
  font-size: 0.78rem;
  letter-spacing: 0.1em;
  color: var(--fg-soft);
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.feature-num .n {
  font-size: clamp(2.4rem, 4vw, 3.2rem);
  font-family: var(--serif);
  color: var(--accent);
  line-height: 1;
  font-weight: 460;
}
.feature h2 {
  font-size: clamp(1.7rem, 3.2vw, 2.5rem);
  max-width: 18ch;
}
.feature-body {
  margin: 22px 0 0;
  font-size: clamp(1.02rem, 1.4vw, 1.16rem);
  color: var(--fg-soft);
  max-width: 56ch;
  line-height: 1.66;
}
.feature-body strong { color: var(--fg); font-weight: 560; }

/* extend section: two directions */
.directions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 18px;
  margin-top: 30px;
}
.direction {
  border: 1px solid var(--line-paper);
  padding: 22px 24px;
  border-radius: 3px;
}
.direction .dlabel {
  font-family: var(--mono);
  font-size: 0.7rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--accent);
}
.direction .dtext { margin: 10px 0 0; font-size: 0.98rem; color: var(--fg-soft); }

/* closing band */
.band {
  background: var(--ink);
  color: var(--on-ink);
  position: relative;
  overflow: hidden;
}
.band-inner {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: clamp(70px, 12vw, 130px) var(--gutter);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 40px;
  flex-wrap: wrap;
  position: relative;
  z-index: 1;
}
.band h2 {
  font-size: clamp(2rem, 4.5vw, 3.4rem);
  color: #fff;
  max-width: 16ch;
}
.band-grid-bg {
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(90deg, var(--line-ink) 1px, transparent 1px);
  background-size: 64px 64px;
  mask-image: linear-gradient(90deg, transparent, #000 60%);
  opacity: 0.5;
}

/* ================= ABOUT ================= */
.about {
  padding: clamp(70px, 13vh, 160px) 0 clamp(60px, 10vw, 130px);
}
.about h1 {
  font-size: clamp(2.6rem, 6vw, 4.6rem);
}
.about-body {
  margin-top: clamp(34px, 5vw, 60px);
  max-width: 62ch;
  display: grid;
  gap: 26px;
}
.about-body p {
  font-size: clamp(1.08rem, 1.6vw, 1.32rem);
  color: var(--fg);
  line-height: 1.62;
}
.pullquote {
  margin: clamp(46px, 7vw, 80px) 0 0;
  border-top: 1px solid var(--line-paper);
  padding-top: clamp(34px, 5vw, 54px);
}
.pullquote blockquote {
  margin: 0;
  font-family: var(--serif);
  font-style: italic;
  font-size: clamp(1.8rem, 4.4vw, 3.1rem);
  line-height: 1.12;
  letter-spacing: -0.015em;
  max-width: 20ch;
  color: var(--fg);
}
.pullquote blockquote .accent { color: var(--accent); }

/* ================= CONTACT ================= */
.contact {
  padding: clamp(70px, 12vh, 150px) 0 clamp(60px, 10vw, 120px);
}
.contact-grid {
  display: grid;
  grid-template-columns: 0.85fr 1.15fr;
  gap: clamp(40px, 7vw, 100px);
  align-items: start;
}
.contact h1 { font-size: clamp(2.4rem, 5.2vw, 4rem); }
.contact-intro {
  margin: 26px 0 0;
  font-size: 1.12rem;
  color: var(--fg-soft);
  max-width: 40ch;
  line-height: 1.62;
}
.contact-mail {
  margin-top: 34px;
  font-family: var(--mono);
  font-size: 0.84rem;
  letter-spacing: 0.04em;
  color: var(--fg-soft);
}
.contact-mail a {
  color: var(--fg);
  text-decoration: none;
  border-bottom: 1px solid var(--accent);
  padding-bottom: 2px;
}
.form { display: grid; gap: 22px; }
.field { display: grid; gap: 8px; }
.field label {
  font-family: var(--mono);
  font-size: 0.72rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--fg-soft);
}
.field input,
.field textarea {
  font-family: var(--sans);
  font-size: 1rem;
  color: var(--fg);
  background: transparent;
  border: none;
  border-bottom: 1.5px solid var(--line-paper);
  padding: 10px 2px;
  border-radius: 0;
  transition: border-color 0.2s var(--ease);
  resize: vertical;
}
.field input:focus,
.field textarea:focus {
  outline: none;
  border-color: var(--accent);
}
.field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 22px; }
.form-actions { display: flex; align-items: center; gap: 18px; margin-top: 8px; }
.form-note { font-size: 0.84rem; color: var(--fg-soft); }
.form-note.ok { color: var(--accent); }

/* ================= 404 ================= */
.notfound {
  background: var(--ink);
  color: var(--on-ink);
  position: relative;
  overflow: hidden;
  flex: 1 0 auto;
  min-height: calc(100svh - 70px);
  display: flex;
  align-items: center;
}
.notfound-inner {
  position: relative;
  z-index: 1;
  max-width: var(--maxw);
  margin: 0 auto;
  padding: clamp(64px, 10vh, 120px) var(--gutter);
  width: 100%;
}
.notfound-code {
  font-family: var(--serif);
  font-size: clamp(5rem, 18vw, 12rem);
  line-height: 0.86;
  font-weight: 460;
  color: #fff;
  letter-spacing: -0.03em;
}
.notfound-code .dot { color: var(--accent-bright); }
.notfound h1 {
  font-size: clamp(1.9rem, 4.4vw, 3rem);
  color: #fff;
  margin-top: 26px;
  max-width: 18ch;
}
.notfound p {
  margin: 22px 0 0;
  color: var(--on-ink-soft);
  font-size: clamp(1rem, 1.4vw, 1.14rem);
  max-width: 46ch;
  line-height: 1.66;
}
.notfound .btn { margin-top: 38px; }

/* ================= RESPONSIVE ================= */
@media (max-width: 860px) {
  .hero-inner { grid-template-columns: 1fr; gap: 36px; }
  .pulse-wrap { order: -1; justify-content: flex-start; min-height: 220px; }
  .pulse { width: 200px; height: 200px; }
  .feature-grid { grid-template-columns: 1fr; gap: 14px; }
  .feature-num { flex-direction: row; align-items: baseline; gap: 14px; }
  .contact-grid { grid-template-columns: 1fr; }
  .directions { grid-template-columns: 1fr; }
}

@media (max-width: 720px) {
  .menu-toggle { display: inline-flex; order: 3; margin-left: auto; }
  .nav {
    position: absolute;
    top: 70px; left: 0; right: 0;
    flex-direction: column;
    align-items: flex-start;
    gap: 0;
    background: var(--paper);
    border-bottom: 1px solid var(--line-paper);
    padding: 6px var(--gutter) 16px;
    margin: 0;
    display: none;
  }
  .nav.open { display: flex; }
  .nav a { padding: 12px 0; width: 100%; border-bottom: 1px solid var(--line-paper); }
  .nav a[aria-current="page"]::after { display: none; }
  .header-inner { gap: 16px; position: relative; }
  .header-right { margin-left: 0; }
  .header-right .btn { display: none; }   /* CTA lives in mobile nav / hero */
  .field-row { grid-template-columns: 1fr; }
  .footer-meta { flex-direction: column; }
}

@media (max-width: 420px) {
  .lang-toggle { padding: 6px 8px; }
}
