/* ============================================================
   Khởi nghiệp 0 đồng — campaign / story page
   ============================================================ */

.kn-badge { display:inline-flex; align-items:center; gap:8px; font-size:12.5px; font-weight:800; letter-spacing:.06em; text-transform:uppercase; padding:8px 15px; border-radius:var(--r-pill); background:var(--blue); color:#fff; box-shadow:var(--sh-blue); }
.kn-badge.light { background:rgba(255,255,255,.14); border:1px solid rgba(255,255,255,.3); color:#fff; box-shadow:none; backdrop-filter:blur(4px); }

/* promo offer bar — rendered inside the sticky site header (see
   layouts/application.html.erb's :promo_bar slot), so it scrolls and
   collapses together with the header as one rigid box, no gap. The slot
   itself collapses to 0 height once .kn-hero (its boundary) has scrolled
   out from under the header — see promo_bar_controller.js */
.kn-promo-bar-slot { display:grid; grid-template-rows:1fr; transition:grid-template-rows .3s ease; overflow:hidden; }
.kn-promo-bar-slot.is-past-boundary { grid-template-rows:0fr; }
/* padding/border live on -inner, not .kn-promo-bar itself: the grid
   collapse above forces .kn-promo-bar to 0 height, and a box's own
   padding/border can't shrink past their own size — only a
   zero-padding child clipped by overflow:hidden can go fully to 0 */
.kn-promo-bar { overflow:hidden; background:#fff; box-shadow:0 2px 8px rgba(11,27,43,.06); }
.kn-promo-bar-inner { display:flex; align-items:center; justify-content:center; gap:16px; flex-wrap:wrap; padding:12px 24px; border-bottom:1px solid var(--line); }
.kn-promo-bar-inner > span { font-size:14px; color:var(--ink-2); font-weight:600; }
.kn-promo-bar-countdown { display:flex; align-items:center; gap:6px; }
.kn-promo-bar-countdown span[data-countdown-target] { background:var(--ink); color:#fff; font-weight:700; font-size:16px; padding:6px 12px; border-radius:6px; min-width:34px; text-align:center; }
.kn-promo-bar-countdown b { color:var(--ink); font-weight:700; }
.kn-promo-bar .btn { padding:10px 22px; font-size:13px; }
@media (max-width:560px) { .kn-promo-bar-inner > span { display:none; } }

/* hero */
.kn-hero {
  position:relative; overflow:hidden;
  background:linear-gradient(115deg,#0B1B2B 0%,#123859 55%,#1E5C8A 100%);
  color:#fff;

  .wrap {
    display:grid; grid-template-columns:1.08fr .92fr; gap:56px; align-items:center;
    /* padding-top is hero-specific (gap under the sticky header/promo bar,
       a one-off relationship with nothing else to be consistent with);
       padding-bottom is the gap before the next section, so it uses the
       same rhythm as .sec/.kn-final instead of its own nearby number */
    padding-top:74px; padding-bottom:var(--sp-section); position:relative; z-index:2;

    @media (max-width:960px) {
      grid-template-columns:1fr;
      gap:0;
      padding-top:36px;
      padding-bottom:var(--sp-section-sm);
    }
  }

  .deco { position:absolute; border-radius:50%; z-index:1; }
  .deco.d1 { width:520px; height:520px; right:-150px; top:-190px; background:rgba(95,199,240,.13); }
  .deco.d2 { width:340px; height:340px; left:-130px; bottom:-200px; background:rgba(255,255,255,.05); }

  h1 {
    font-size:clamp(34px,4.6vw,58px); line-height:1.05; letter-spacing:-.025em; margin-bottom:20px;

    .hl { color:#FF6A3D; }

    @media (max-width:960px) {
      font-size:var(--fs-xl);
    }
  }

  p {
    font-size:clamp(16px,1.35vw,19px); color:rgba(255,255,255,.9); max-width:520px; margin-bottom:32px; line-height:1.65;

    @media (max-width:960px) {
      font-size:var(--fs-sm);
    }
  }
}

.kn-hero-copy {
  > .kn-badge { margin-bottom:24px; }

  @media (max-width:960px) {
    display:contents;
  }
}

.kn-hero-btns {
  display:flex; gap:14px; flex-wrap:wrap; margin-bottom:40px;

  @media (max-width:960px) {
    gap:10px;

    .btn {
      padding:12px 14px;
      font-size:var(--fs-sm);
    }
  }
}
.kn-btn-glass { background:rgba(255,255,255,.1); color:#fff; border:1.5px solid rgba(255,255,255,.32); backdrop-filter:blur(4px); }
.kn-btn-glass:hover { background:rgba(255,255,255,.18); transform:translateY(-2px); }

.kn-hero-stats {
  display:flex; gap:36px; flex-wrap:wrap;

  div { display:flex; flex-direction:column; gap:3px; }
  b { font-size:27px; font-weight:900; color:#fff; letter-spacing:-.02em; line-height:1; }
  span { font-size:13.5px; color:rgba(255,255,255,.72); font-weight:600; }

  /* plain grid directly on the hero background — no card treatment, per
     the mock design (no background/padding on this component itself) */
  @media (max-width:960px) {
    order:1;
    display:grid;
    grid-template-columns:1fr 1fr;
    gap:14px;

    div { gap:2px; }
    b { font-size:19px; font-weight:800; }
    span { font-size:11px; color:#AFC4EE; font-weight:400; }
  }
}

.kn-hero-shot {
  border-radius:var(--r-lg); min-height:400px; align-self:stretch; overflow:hidden;

  img { width:100%; height:100%; object-fit:cover; }

  /* standalone rounded image on mobile — not merged with .kn-hero-stats
     below it, per the mock design's own margin-bottom + full radius */
  @media (max-width:960px) {
    height:200px; min-height:0; margin-bottom:20px;
    border-radius:14px;
  }
}

/* gradient section head (team / hỗ trợ toàn diện) */
.sec-head.gradient { max-width:none; margin-left:auto; margin-right:auto; background:linear-gradient(120deg,var(--blue) 0%,#4338CA 100%); border-radius:16px; padding:34px 28px; }
.sec-head.gradient .eyebrow { color:#DCE7FF; }
.sec-head.gradient .eyebrow::before { background:#fff; }
.sec-head.gradient h2 {
  color:#fff;

  @media (max-width:960px) {
    font-size:var(--fs-xl);
  }
}
.sec-head.gradient p {
  color:#DCE7FF;

  @media (max-width:960px) {
    font-size:var(--fs-sm);
  }
}

/* photo grids (team / fabric / name-number) */
.kn-photogrid-3 { display:grid; grid-template-columns:repeat(3,1fr); gap:16px; margin-bottom:40px; }
.kn-photogrid-4 { display:grid; grid-template-columns:repeat(4,1fr); gap:10px; }
.kn-photogrid-3 img, .kn-photogrid-4 img { width:100%; aspect-ratio:1/1; object-fit:cover; border-radius:12px; }
.kn-techgrid { display:grid; grid-template-columns:1fr 1fr; gap:14px; aspect-ratio:2/1; }
.kn-techgrid img { width:100%; height:100%; object-fit:cover; border-radius:16px; }

/* feature rows */
.kn-feature { display:grid; grid-template-columns:1fr 1fr; gap:56px; align-items:center; }
.kn-feature-media { border-radius:var(--r-lg); min-height:380px; align-self:stretch; position:relative; overflow:hidden; }
.kn-feature-media img { width:100%; height:100%; object-fit:cover; }
.kn-feature-copy .tag { margin-bottom:16px; }
.kn-feature-copy h2 { font-size:clamp(26px,3vw,38px); line-height:1.12; margin-bottom:16px; }
.kn-feature-copy > p {
  font-size:17px; color:var(--ink-2); line-height:1.72; margin-bottom:24px;

  @media (max-width:960px) {
    font-size:var(--fs-sm);
  }
}
.kn-check { list-style:none; padding:0; margin:0; display:grid; gap:14px; }
.kn-check li {
  display:flex; align-items:flex-start; gap:12px; font-size:15.5px; font-weight:600; color:var(--ink); line-height:1.5;

  @media (max-width:960px) {
    font-size:var(--fs-sm);
  }
}
.kn-check li svg { width:22px; height:22px; flex:none; color:var(--green); margin-top:1px; }

/* support grid */
.kn-grid {
  display:grid; grid-template-columns:repeat(3,1fr); gap:20px;

  @media (max-width:960px) {
    gap:12px;
  }
}
.kn-gcard {
  background:#fff; border:1px solid var(--line); border-radius:var(--r); padding:30px 28px; transition:.18s ease;

  @media (max-width:960px) {
    padding:10px 9px;
  }
}
.kn-gcard:hover { transform:translateY(-4px); box-shadow:var(--sh-lg); border-color:transparent; }
.kn-gcard .ic { width:54px; height:54px; border-radius:15px; background:var(--sky); color:var(--blue-600); display:grid; place-items:center; margin-bottom:18px; transition:.18s; }
.kn-gcard:hover .ic { background:var(--blue); color:#fff; }
.kn-gcard .ic svg { width:26px; height:26px; }
.kn-gcard h3 {
  font-size:18px; margin-bottom:9px;

  @media (max-width:960px) {
    font-size:16px;
  }
}
.kn-gcard p {
  font-size:14.5px; color:var(--ink-2); line-height:1.6;

  @media (max-width:960px) {
    font-size:var(--fs-sm);
  }
}
.kn-grid-note { text-align:center; margin-top:34px; font-size:16.5px; font-weight:700; color:var(--blue-700); }

/* final cta */
.kn-final {
  position:relative; overflow:hidden;
  background:linear-gradient(120deg,#0B1B2B 0%,#0E3A5E 58%,#0091E6 130%);
  color:#fff; padding:var(--sp-section) 0; text-align:center;

  @media (max-width:920px) {
    padding:var(--sp-section-sm) 0;
  }
}
.kn-final .deco { position:absolute; width:500px; height:500px; border-radius:50%; background:rgba(95,199,240,.12); right:-130px; top:-170px; z-index:1; }
.kn-final .wrap { position:relative; z-index:2; max-width:920px; }
.kn-final .kn-badge { margin-bottom:24px; }
.kn-final h2 {
  font-size:clamp(28px,3.4vw,44px); line-height:1.14; margin-bottom:32px; letter-spacing:-.02em;

  @media (max-width:960px) {
    font-size:var(--fs-xl);
  }
}
.kn-chips { display:flex; flex-wrap:wrap; justify-content:center; gap:12px; margin-bottom:32px; }
.kn-chips span { display:inline-flex; align-items:center; gap:9px; font-size:14.5px; font-weight:700; padding:11px 18px; border-radius:var(--r-pill); background:rgba(255,255,255,.1); border:1px solid rgba(255,255,255,.2); }
.kn-chips span svg { width:16px; height:16px; color:#5FC7F0; flex:none; }
.kn-final-line {
  font-size:17px; color:rgba(255,255,255,.86); max-width:700px; margin:0 auto 34px; line-height:1.72;

  @media (max-width:960px) {
    font-size:var(--fs-sm);
  }
}
.kn-final-btns { display:flex; gap:14px; justify-content:center; flex-wrap:wrap; }

/* promo popup modal */
.kn-promo-modal {
  background:linear-gradient(135deg,#0B1B2B 0%,#123859 55%,#1E5C8A 100%); max-width:520px; overflow:hidden; position:relative;

  /* the generic mobile modal (header.css) goes full-screen and forces
     .modal-form onto a light card (var(--sky-2)) — both fine for the
     site's light/dark-text forms, but this modal is a compact
     dark-gradient/white-text design: the light card painted over the
     gradient left white text with ~0 contrast, and full-screen turned a
     short form into a mostly-empty sheet. Keep it a centered card
     instead, scoped to this modal only. */
  @media (max-width:720px) {
    height:auto; max-height:88vh; align-self:center;
    max-width:calc(100vw - 32px); border-radius:20px;

    .modal-form {
      background:transparent;
      border:none;
      margin:0;
    }
  }
}
.kn-promo-deco { position:absolute; width:280px; height:280px; border-radius:50%; background:rgba(95,199,240,.16); right:-100px; top:-120px; pointer-events:none; }
.kn-promo-modal .modal-close { background:rgba(255,255,255,.14); color:#fff; z-index:3; }
.kn-promo-modal .modal-close:hover { background:rgba(255,255,255,.24); }
.kn-promo-head { text-align:center; }
.kn-promo-head .kn-badge { margin-bottom:20px; }
.kn-promo-head h2 { color:#fff; font-size:24px; line-height:1.3; margin-bottom:20px; }
.kn-promo-countdown { display:flex; align-items:center; justify-content:center; gap:10px; margin-bottom:4px; font-size:13.5px; color:rgba(255,255,255,.8); }
.kn-promo-countdown span[data-countdown-target] { background:rgba(255,255,255,.14); color:#fff; font-weight:700; font-size:18px; padding:6px 12px; border-radius:6px; min-width:36px; text-align:center; }
.kn-promo-countdown b { color:#fff; font-weight:700; }
.kn-promo-modal .field label { color:#fff; }
.kn-promo-modal .field input { background:rgba(255,255,255,.08); border-color:rgba(255,255,255,.25); color:#fff; }
.kn-promo-modal .field input::placeholder { color:rgba(255,255,255,.55); }
.kn-promo-modal .modal-success { position:relative; z-index:2; }
.kn-promo-modal .modal-success h2 { color:#fff; }
.kn-promo-modal .modal-success p { color:rgba(255,255,255,.8); }
.kn-promo-modal .modal-success .btn-ghost { background:rgba(255,255,255,.12); color:#fff; }

/* responsive */
@media (max-width:960px) {
  .kn-feature { grid-template-columns:1fr; }
  .kn-feature-media { min-height:300px; }
  .kn-feature.reverse .kn-feature-copy { order:-1; }
  .kn-grid { grid-template-columns:1fr 1fr; }
  .kn-techgrid { aspect-ratio:auto; }
}
@media (max-width:620px) {
  .kn-grid { grid-template-columns:1fr; }
  .kn-grid-support { grid-template-columns:1fr 1fr; }
  .kn-photogrid-3, .kn-photogrid-4, .kn-techgrid { grid-template-columns:repeat(2,1fr); }
}
