/* ============================================================
   KAIBE, landing
   Editorial & institutional. Fraunces + Geist. Paper + navy.
   Thin rules, generous space, one warm accent (sun) used sparingly.
   ============================================================ */

:root {
  --paper:      #f6f1e5;
  --paper-deep: #efe8d5;
  --surface:    #fffdf8;
  --line:       #e3dcc7;
  --line-2:     #d8cfb6;

  --ink:        #14182b;
  --ink-2:      #192035;   /* the mark's navy, dark sections */
  --ink-soft:   rgba(20, 24, 43, 0.66);
  --ink-faint:  rgba(20, 24, 43, 0.40);

  --sun:        #b45309;   /* the one warm accent */
  --mound:      #15803d;   /* used only inside product mocks */

  --font-display: "Fraunces", Georgia, "Times New Roman", serif;
  --font-body:    "Geist", system-ui, -apple-system, "Helvetica Neue", sans-serif;

  --gutter: clamp(1.25rem, 0.7rem + 2.2vw, 3rem);
  --section-y: clamp(5rem, 3.5rem + 7vw, 9.5rem);
  --maxw: 70rem;

  --ease: cubic-bezier(0.22, 1, 0.36, 1);
}

*, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
ul { list-style: none; }
a { color: inherit; text-decoration: none; }
img { display: block; max-width: 100%; }
button { font: inherit; color: inherit; background: none; border: none; cursor: pointer; }

body {
  font-family: var(--font-body);
  font-size: clamp(1rem, 0.97rem + 0.15vw, 1.1rem);
  line-height: 1.65;
  font-weight: 400;
  color: var(--ink);
  background: var(--paper);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
  position: relative;
}

/* ambient paper grain (not decoration) */
body::before {
  content: "";
  position: fixed; inset: 0; z-index: 0; pointer-events: none; opacity: 0.4;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='180' height='180'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='0.5'/%3E%3C/svg%3E");
}
.nav, main, .footer { position: relative; z-index: 1; }
::selection { background: var(--sun); color: #fff; }

/* ============================================================
   typography
   ============================================================ */
.display {
  font-family: var(--font-display);
  font-weight: 420;
  line-height: 1.0;
  letter-spacing: -0.018em;
  font-optical-sizing: auto;
  font-variation-settings: "opsz" 144, "SOFT" 28;
}
.display em { font-style: italic; font-weight: 380; color: var(--sun); }

.kicker {
  font-family: var(--font-display);
  font-style: italic;
  font-weight: 380;
  font-size: clamp(1.02rem, 0.95rem + 0.4vw, 1.22rem);
  color: var(--ink-soft);
  letter-spacing: 0;
}
.kicker--light { color: rgba(246, 241, 229, 0.72); }

/* ============================================================
   layout
   ============================================================ */
.shell { width: min(100% - calc(var(--gutter) * 2), var(--maxw)); margin-inline: auto; }
.section { padding-block: var(--section-y); }
/* anchored sections clear the fixed nav when jumped to */
.section, .cta { scroll-margin-top: 5.5rem; }

.lead { max-width: 44rem; margin-bottom: clamp(2.75rem, 5vw, 4.5rem); }
.lead__title { font-size: clamp(2rem, 1.35rem + 3.1vw, 3.7rem); margin-top: 0.9rem; }

/* ============================================================
   buttons & links
   ============================================================ */
.btn {
  display: inline-flex; align-items: center; gap: 0.5em;
  font-weight: 500; font-size: 0.98rem;
  padding: 0.85em 1.7em; border-radius: 999px;
  background: var(--ink-2); color: var(--paper);
  border: 1px solid var(--ink-2);
  transition: background 0.3s var(--ease), transform 0.3s var(--ease), box-shadow 0.3s var(--ease);
}
.btn:hover { background: #232c4a; transform: translateY(-1px); box-shadow: 0 14px 30px -18px rgba(19, 26, 46, 0.6); }
.btn--sm { padding: 0.58em 1.2em; font-size: 0.92rem; }
.btn--light { background: var(--paper); color: var(--ink-2); border-color: var(--paper); }
.btn--light:hover { background: #fff; }

.textlink { font-weight: 500; color: var(--ink); transition: color 0.3s var(--ease); }
.textlink:hover { color: var(--sun); }
.textlink--light { color: var(--paper); }
.textlink--light:hover { color: #fff; }

.navlink { color: var(--ink-soft); font-size: 0.96rem; position: relative; transition: color 0.3s var(--ease); }
.navlink::after {
  content: ""; position: absolute; left: 0; bottom: -4px; height: 1.5px; width: 100%;
  background: var(--sun); transform: scaleX(0); transform-origin: right; transition: transform 0.4s var(--ease);
}
.navlink:hover { color: var(--ink); }
.navlink:hover::after { transform: scaleX(1); transform-origin: left; }

/* ============================================================
   reveal
   ============================================================ */
.reveal { opacity: 0; transform: translateY(20px); transition: opacity 0.8s var(--ease), transform 0.8s var(--ease); }
.reveal.in { opacity: 1; transform: none; }
.reveal[data-delay="1"] { transition-delay: 0.09s; }
.reveal[data-delay="2"] { transition-delay: 0.18s; }
.reveal[data-delay="3"] { transition-delay: 0.27s; }

/* ============================================================
   nav
   ============================================================ */
.nav { position: fixed; top: 0.85rem; left: 0; right: 0; z-index: 50; pointer-events: none; }
.nav__inner {
  position: relative; pointer-events: auto;
  width: min(100% - 1.5rem, 64rem); margin-inline: auto;
  display: flex; align-items: center; gap: 1.5rem;
  padding: 0.4rem 0.5rem 0.4rem 1.5rem;
  background: rgba(246, 241, 229, 0.82);
  -webkit-backdrop-filter: blur(14px); backdrop-filter: blur(14px);
  border-radius: 999px;
}
.nav__logo { height: 30px; width: auto; }
.nav__links { display: flex; gap: 2rem; margin-left: auto; }
.nav__menu { display: none; flex-direction: column; gap: 5px; padding: 8px; margin-left: auto; }
.nav__menu span { width: 22px; height: 1.5px; background: var(--ink); }

/* ============================================================
   hero
   ============================================================ */
.hero { position: relative; overflow: hidden; padding-top: clamp(5.5rem, 4rem + 4vw, 8.5rem); padding-bottom: clamp(4rem, 8vw, 7rem); }
.hero__wash {
  position: absolute; top: -25%; right: -15%; width: 65vw; height: 65vw; max-width: 760px; max-height: 760px;
  background: radial-gradient(circle, rgba(180, 83, 9, 0.10), transparent 60%); pointer-events: none;
}
.hero__grid { position: relative; display: grid; gap: clamp(2.5rem, 5vw, 4rem); }
.hero__copy { max-width: 46rem; }
.hero__panel { width: 100%; max-width: 64rem; margin-inline: auto; }
.hero__title { font-size: clamp(2.7rem, 1.7rem + 4.6vw, 5.4rem); margin-top: 1.3rem; }
.hero__lede { font-size: clamp(1.12rem, 1rem + 0.45vw, 1.32rem); color: var(--ink-soft); max-width: 40ch; margin-top: 1.7rem; }
.hero__lede em { font-style: normal; color: var(--ink); }
.hero__actions { display: flex; align-items: center; gap: 1.6rem; margin-top: 2.3rem; flex-wrap: wrap; }

/* ============================================================
   soft product panel (no browser chrome)
   ============================================================ */
.panel {
  background: var(--surface); border: 1px solid var(--line); border-radius: 18px;
  overflow: hidden;
  box-shadow: 0 44px 90px -58px rgba(19, 26, 46, 0.5), 0 14px 34px -26px rgba(19, 26, 46, 0.28);
}
.hero__panel .panel { transition: transform 0.5s var(--ease); }
.hero__panel:hover .panel { transform: translateY(-4px); }
.panel--doc { max-width: 360px; margin-inline: auto; }
.shot { display: block; width: 100%; height: auto; }
.prose__media img { max-width: 30rem; margin-inline: auto; }

/* -- mini app (faithful KAIBE UI, clean placeholder data) -- */
.m-app { display: flex; min-height: 340px; font-size: 12px; }
.m-rail { flex: 0 0 130px; background: var(--surface); border-right: 1px solid var(--line); padding: 12px 10px; display: flex; flex-direction: column; gap: 2px; }
.m-rail__logo { width: 26px; height: 26px; margin: 2px 0 12px 4px; }
.m-rail__logo img { width: 26px; height: 26px; }
.m-nav { display: flex; align-items: center; gap: 9px; padding: 7px 9px; border-radius: 9px; color: var(--ink-soft); font-weight: 500; }
.m-nav i { width: 14px; height: 14px; flex: 0 0 auto; opacity: 0.7; }
.m-nav.is-active { background: var(--ink-2); color: #fff; }
.m-nav.is-active i { opacity: 1; }
.m-main { flex: 1; display: flex; flex-direction: column; min-width: 0; }
.m-top { display: flex; align-items: center; gap: 9px; padding: 11px 16px; border-bottom: 1px solid var(--line); }
.m-crest { width: 26px; height: 26px; border-radius: 50%; background: var(--mound); color: #fff; display: grid; place-items: center; font-family: var(--font-display); font-weight: 600; font-size: 9px; }
.m-top__name strong { display: block; font-size: 12px; letter-spacing: -0.01em; }
.m-top__name small { color: var(--ink-faint); font-size: 10px; }
.m-avatar { margin-left: auto; width: 26px; height: 26px; border-radius: 50%; border: 1px solid var(--line); display: grid; place-items: center; font-size: 10px; font-weight: 600; color: var(--ink-soft); }
.m-body { padding: 16px; display: flex; flex-direction: column; gap: 13px; }
.m-greet { font-family: var(--font-display); font-size: 22px; font-weight: 480; letter-spacing: -0.02em; }
.m-greet--sm { font-size: 18px; }
.m-date { color: var(--ink-faint); font-size: 11px; margin-top: -9px; }
.m-cards { display: grid; grid-template-columns: 1.2fr 1fr; gap: 12px; }
.m-card { background: var(--surface); border: 1px solid var(--line); border-radius: 12px; padding: 13px; }
.m-card__h { display: flex; align-items: center; gap: 6px; font-weight: 600; margin-bottom: 11px; font-size: 11.5px; }
.m-att { display: flex; align-items: center; gap: 14px; }
.m-ring { width: 62px; height: 62px; border-radius: 50%; flex: 0 0 auto; background: conic-gradient(var(--mound) 0 88%, var(--sun) 88% 94%, var(--line) 94% 100%); display: grid; place-items: center; position: relative; }
.m-ring::before { content: ""; position: absolute; inset: 8px; background: var(--surface); border-radius: 50%; }
.m-ring span { position: relative; font-family: var(--font-display); font-weight: 600; font-size: 14px; }
.m-legend { display: flex; flex-direction: column; gap: 5px; font-size: 11px; flex: 1; }
.m-legend li { display: flex; align-items: center; gap: 7px; }
.m-legend b { margin-left: auto; }
.dot { width: 7px; height: 7px; border-radius: 50%; }
.dot--g { background: var(--mound); } .dot--s { background: var(--sun); } .dot--c { background: #b91c1c; }
.m-note { padding: 7px 0; border-top: 1px solid var(--line); }
.m-note:first-of-type { border-top: 0; }
.m-note b { display: block; font-size: 11.5px; font-weight: 600; }
.m-note small { color: var(--ink-faint); font-size: 10px; }
.m-hwrow { display: flex; align-items: center; gap: 9px; padding: 8px 0; border-top: 1px solid var(--line); font-size: 11.5px; }
.m-hwrow em { margin-left: auto; font-style: normal; color: var(--ink-faint); font-size: 10.5px; }
.m-tag { font-size: 9.5px; padding: 2px 7px; border-radius: 99px; background: var(--paper-deep); color: var(--ink-soft); font-weight: 500; }

.m-tabs { display: flex; gap: 6px; flex-wrap: wrap; }
.m-tabs span { font-size: 10px; padding: 5px 9px; border-radius: 8px; border: 1px solid var(--line); color: var(--ink-soft); }
.m-tabs span.is-active { background: var(--ink-2); color: #fff; border-color: var(--ink-2); }
.m-table { width: 100%; border-collapse: collapse; font-size: 11px; }
.m-table th { text-align: left; font-weight: 600; color: var(--ink-faint); font-size: 9.5px; letter-spacing: 0.04em; padding: 7px 6px; border-bottom: 1px solid var(--line); }
.m-table th:not(:first-child), .m-table td:not(:first-child) { text-align: center; }
.m-table td { padding: 9px 6px; border-bottom: 1px solid var(--line); }
.m-final { color: var(--mound); font-weight: 700; }

/* -- report card document mock -- */
.rc { padding: 1.5rem 1.6rem; font-size: 12.5px; }
.rc__head { display: flex; align-items: center; gap: 0.8rem; padding-bottom: 1rem; border-bottom: 1px solid var(--line); }
.rc__crest { width: 38px; height: 38px; border-radius: 50%; background: var(--mound); color: #fff; display: grid; place-items: center; font-family: var(--font-display); font-weight: 600; font-size: 11px; }
.rc__head strong { display: block; font-family: var(--font-display); font-size: 15px; letter-spacing: -0.01em; }
.rc__head small { color: var(--ink-faint); font-size: 11px; }
.rc__student { display: flex; justify-content: space-between; align-items: baseline; padding: 0.9rem 0 0.4rem; }
.rc__student strong { font-size: 13px; }
.rc__student span { color: var(--ink-faint); font-size: 11px; }
.rc__table { width: 100%; border-collapse: collapse; }
.rc__table tr { border-top: 1px solid var(--line); }
.rc__table td { padding: 0.62rem 0; vertical-align: top; }
.rc__subj { font-weight: 500; white-space: nowrap; }
.rc__remark { color: var(--ink-soft); font-style: italic; padding-left: 1rem; font-size: 11.5px; }
.rc__mark { text-align: right; font-family: var(--font-display); font-weight: 600; color: var(--mound); white-space: nowrap; }
.rc__foot { margin-top: 1rem; padding-top: 0.8rem; border-top: 1px solid var(--line); color: var(--ink-faint); font-size: 11px; display: flex; align-items: center; gap: 0.45rem; }
.rc__foot::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: var(--sun); }

/* ============================================================
   roles, editorial ledger (rules, not cards)
   ============================================================ */
.role-rows { display: flex; flex-direction: column; gap: clamp(3.5rem, 7vw, 6rem); }
.role-row { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(2rem, 5vw, 4.5rem); align-items: center; }
.role-row:nth-child(even) .role-row__media { order: 2; }
.role-row__name { font-family: var(--font-display); font-weight: 460; font-size: clamp(1.7rem, 1.1rem + 2vw, 2.5rem); letter-spacing: -0.015em; }
.role-row__lede { color: var(--ink-soft); font-size: clamp(1.1rem, 1rem + 0.4vw, 1.28rem); margin-top: 0.5rem; }
.role-row__feats { margin-top: 1.5rem; display: flex; flex-direction: column; gap: 0.7rem; }
.role-row__feats li { position: relative; padding-left: 1.5rem; color: var(--ink); font-size: clamp(1rem, 0.97rem + 0.2vw, 1.1rem); }
.role-row__feats li::before { content: ""; position: absolute; left: 0; top: 0.62em; width: 0.7rem; height: 2px; background: var(--sun); }
/* "Mobile ready" row, a phone-shaped screenshot instead of a wide panel */
.role-row__media--phone { display: flex; justify-content: center; }
.phone {
  display: block; width: 100%; max-width: 14rem; height: auto;
  border-radius: 1.75rem; border: 1px solid var(--line);
  box-shadow: 0 40px 80px -50px rgba(19, 26, 46, 0.5), 0 12px 30px -24px rgba(19, 26, 46, 0.28);
}

/* ============================================================
   why, editorial prose
   ============================================================ */
.prose { display: flex; flex-direction: column; gap: clamp(2.75rem, 5vw, 4.5rem); }
.prose__row--media { display: grid; grid-template-columns: 1fr 0.9fr; gap: clamp(2rem, 5vw, 4rem); align-items: center; }
.prose__h { font-family: var(--font-display); font-weight: 440; font-size: clamp(1.5rem, 1.1rem + 1.4vw, 2.1rem); letter-spacing: -0.01em; }
.prose__p { color: var(--ink-soft); margin-top: 0.9rem; max-width: 48ch; font-size: clamp(1.05rem, 1rem + 0.3vw, 1.2rem); }
.prose__p em { font-style: normal; color: var(--ink); }
.aside {
  margin-top: clamp(3rem, 6vw, 5rem); padding-top: 2.2rem; border-top: 1px solid var(--line);
  color: var(--ink-soft); font-size: clamp(1.05rem, 1rem + 0.3vw, 1.22rem); max-width: 60ch;
}

/* ============================================================
   inside / showcase
   ============================================================ */
.showcase { display: flex; flex-direction: column; gap: 1.4rem; align-items: center; }
.showcase .panel { width: 100%; max-width: 60rem; }
.showcase figcaption { color: var(--ink-soft); max-width: 48ch; text-align: center; }

/* ============================================================
   pricing
   ============================================================ */
.pricing__inner { max-width: 40rem; }
.pricing__title { font-size: clamp(2rem, 1.4rem + 2.8vw, 3.4rem); margin-top: 0.9rem; }
.pricing__body { color: var(--ink-soft); margin-top: 1.3rem; max-width: 46ch; font-size: clamp(1.05rem, 1rem + 0.3vw, 1.2rem); }
.pricing .btn { margin-top: 2.1rem; }

/* ============================================================
   cta
   ============================================================ */
.cta { background: var(--ink-2); color: var(--paper); padding-block: clamp(5rem, 9vw, 8.5rem); position: relative; overflow: hidden; }
.cta::after {
  content: ""; position: absolute; bottom: -45%; left: 50%; transform: translateX(-50%);
  width: 80vw; height: 80vw; max-width: 850px; max-height: 850px;
  background: radial-gradient(circle, rgba(180, 83, 9, 0.18), transparent 62%); pointer-events: none;
}
.cta__inner { position: relative; z-index: 1; text-align: center; }
.cta__title { font-size: clamp(2.2rem, 1.5rem + 3.2vw, 4rem); margin-top: 1rem; }
.cta__sub { color: rgba(246, 241, 229, 0.72); margin-top: 1.3rem; font-size: clamp(1.1rem, 1rem + 0.4vw, 1.3rem); }
.cta__actions { display: flex; gap: 1.6rem; align-items: center; justify-content: center; flex-wrap: wrap; margin-top: 2.4rem; }

/* ============================================================
   footer
   ============================================================ */
.footer { background: var(--ink-2); color: var(--paper); padding-top: clamp(3rem, 6vw, 5rem); padding-bottom: 2rem; border-top: 1px solid rgba(246, 241, 229, 0.1); }
.footer__inner { display: grid; grid-template-columns: 1.5fr 1fr; gap: 2.5rem; padding-bottom: 3rem; }
.footer__logo { height: 25px; width: auto; margin-bottom: 1.1rem; }
.footer__tag { color: rgba(246, 241, 229, 0.6); max-width: 30ch; }
.footer__cols { display: grid; grid-template-columns: 1fr 1fr; gap: 2rem; }
.footer__col { display: flex; flex-direction: column; gap: 0.7rem; }
.footer__h { font-family: var(--font-display); font-style: italic; color: rgba(246, 241, 229, 0.5); margin-bottom: 0.25rem; }
.footlink { color: rgba(246, 241, 229, 0.82); transition: color 0.3s var(--ease); }
.footlink:hover { color: var(--sun); }
.footer__muted { color: rgba(246, 241, 229, 0.45); }
.footer__base { display: flex; justify-content: space-between; align-items: center; padding-top: 1.6rem; border-top: 1px solid rgba(246, 241, 229, 0.12); color: rgba(246, 241, 229, 0.5); gap: 1rem; flex-wrap: wrap; font-size: 0.92rem; }

/* ============================================================
   responsive
   ============================================================ */
@media (max-width: 900px) {
  .prose__row--media { grid-template-columns: 1fr; }
  .role-row { grid-template-columns: 1fr; }
  .role-row:nth-child(even) .role-row__media { order: 0; }
  .nav__inner { gap: 0.85rem; }
  .nav__links { display: none; }
  .nav__menu { display: flex; margin-left: 0; }
  .nav__inner > .btn { margin-left: auto; }
}
@media (max-width: 540px) {
  .footer__inner { grid-template-columns: 1fr; }
  .m-rail { flex-basis: 44px; }
  .m-rail .m-nav span { display: none; }
  .m-cards { grid-template-columns: 1fr; }
  .footer__base { flex-direction: column; align-items: flex-start; }
}

.nav__links.is-open {
  display: flex; position: absolute; top: calc(100% + 0.6rem); left: 0; right: 0;
  flex-direction: column; gap: 1.1rem; padding: 1.3rem 1.6rem;
  background: rgba(246, 241, 229, 0.97);
  -webkit-backdrop-filter: blur(14px); backdrop-filter: blur(14px);
  border-radius: 22px; box-shadow: 0 22px 50px -26px rgba(19, 26, 46, 0.4);
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: 0.001ms !important; transition-duration: 0.001ms !important; }
  .reveal { opacity: 1; transform: none; }
}
