/* ==========================================================
   NipponLink Việt Nam — static homepage (v1)
   Tokens only in :root. Xanh #06B7F4 = heading/tile, vàng #FAE800 = CTA.
   ========================================================== */
:root {
  /* Màu chính của web (theo yêu cầu): xanh = heading & tile, vàng = nút CTA */
  --color-blue: #06B7F4;
  --color-yellow: #FAE800;
  --color-navy: #0A2E4A;         /* chữ đặt trên nền xanh/vàng */
  --color-brand: #06B7F4;        /* heading, tile, icon */
  --color-cta: #FAE800;          /* mọi nút chính */
  --color-cta-hover: #E8D400;
  --color-text: #33465C;         /* chữ nội dung */
  --color-muted: #6B7A90;
  --color-border: #DCEEF8;
  --color-bg: #FFFFFF;
  --color-bg-soft: #F3FBFE;
  --color-placeholder: #D5DCE6;

  --font: 'Be Vietnam Pro', system-ui, -apple-system, 'Segoe UI', sans-serif;
  --container: 1200px;
  --gutter: 32px;
  --radius: 12px;
  --shadow: 0 6px 20px rgba(15, 42, 79, .08);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: var(--font);
  font-size: 16px;
  line-height: 1.6;
  color: var(--color-text);
  background: var(--color-bg);
}
img { display: block; max-width: 100%; height: auto; }
a { color: inherit; text-decoration: none; }
h1, h2, h3, h4 { color: var(--color-brand); margin: 0; line-height: 1.22; letter-spacing: -0.02em; }
h1 { font-size: 46px; font-weight: 800; color: var(--color-brand); }
h2 { font-size: 32px; font-weight: 800; }
h3 { font-size: 20px; font-weight: 700; }
p { margin: 0; }
ul { margin: 0; padding: 0; list-style: none; }

.container { max-width: var(--container); margin: 0 auto; padding: 0 var(--gutter); }
.center { text-align: center; }
.muted { color: var(--color-muted); font-size: 15px; }

/* Buttons */
.btn {
  display: inline-flex; align-items: center; justify-content: center;
  gap: 6px; padding: 13px 24px; border-radius: 999px;
  font: 600 15px/1 var(--font); border: 1.5px solid transparent;
  transition: background .2s, color .2s, border-color .2s, box-shadow .2s;
  cursor: pointer; white-space: nowrap;
}
.btn--yellow { background: var(--color-cta); color: var(--color-navy); box-shadow: 0 6px 16px rgba(250,232,0,.4); }
.btn--yellow:hover { background: var(--color-cta-hover); }
.btn--outline { background: #fff; color: var(--color-navy); border-color: var(--color-brand); }
.btn--outline:hover { background: var(--color-brand); color: var(--color-navy); }
.btn--white { background: #fff; color: var(--color-navy); }
.btn--sm { padding: 9px 16px; font-size: 14px; }
.btn--block { display: flex; width: 100%; margin-top: 18px; }

.eyebrow {
  font-size: 13px; font-weight: 700; letter-spacing: .06em;
  text-transform: uppercase; color: var(--color-brand); margin-bottom: 14px;
}

/* Topbar + header */
.topbar { background: var(--color-blue); color: var(--color-navy); font-size: 13px; text-align: center; padding: 8px 0; }
.header { background: #fff; border-bottom: 1px solid var(--color-border); }
.header__row { display: flex; align-items: center; justify-content: space-between; padding-top: 14px; padding-bottom: 14px; }
.brand img { height: 52px; width: auto; }
.header__actions { display: flex; gap: 12px; align-items: center; }
.pill-phone {
  background: var(--color-yellow); color: var(--color-navy);
  font-weight: 700; font-size: 15px; padding: 10px 18px; border-radius: 999px;
}
.nav { border-top: 1px solid var(--color-border); }
.nav .container { display: flex; gap: 26px; padding-top: 12px; padding-bottom: 12px; font-size: 15px; font-weight: 500; color: var(--color-navy); }
.nav a:hover { color: var(--color-brand); }

/* Hero */
.hero { background: var(--color-bg-soft); padding: 52px 0 40px; }
.hero__grid { display: grid; grid-template-columns: 1fr 1fr; gap: 40px; align-items: center; }
.hero__text .lead { margin-top: 18px; font-size: 18px; color: var(--color-muted); max-width: 520px; }
.hero__ctas { display: flex; gap: 14px; margin-top: 28px; flex-wrap: wrap; }
.hero__trust { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; margin-top: 34px; text-align: center; font-size: 14px; font-weight: 600; color: var(--color-navy); }
.hero__trust .ico { display: flex; align-items: center; justify-content: center; width: 44px; height: 44px; margin: 0 auto 8px; font-size: 22px; }
.hero__media img { width: 100%; height: 420px; object-fit: cover; border-radius: var(--radius); }

/* Entry cards */
.entry { background: var(--color-bg-soft); padding: 0 0 56px; }
.entry__grid { display: grid; grid-template-columns: 1fr 1fr; gap: 28px; margin-top: -40px; position: relative; }
.card { background: #fff; border: 1px solid var(--color-border); border-radius: var(--radius); box-shadow: var(--shadow); overflow: hidden; }
.entry__card { padding: 22px; }
.entry__card h3 { margin: 16px 0 14px; }
.entry__pair img { width: 100%; height: 150px; object-fit: cover; border-radius: 8px; }
.placeholder-lines { display: grid; gap: 10px; }
.placeholder-lines li { height: 9px; border-radius: 6px; background: var(--color-placeholder); width: 78%; }
.placeholder-lines li:nth-child(2) { width: 90%; }
.placeholder-lines li:nth-child(3) { width: 62%; }
.placeholder-lines--sm li { height: 8px; }

/* Stats */
.stats { background: #fff; border-bottom: 1px solid var(--color-border); }
.stats__row { display: grid; grid-template-columns: repeat(4, 1fr); padding-top: 26px; padding-bottom: 26px; }
.stat { text-align: center; padding: 0 14px; }
.stat + .stat { border-left: 1px solid var(--color-border); }
.stat strong { display: block; font-size: 30px; font-weight: 800; color: var(--color-navy); line-height: 1.2; }
.stat span { font-size: 14px; color: var(--color-muted); }
/* Tile xanh cho khối số liệu */
.stats .stat { background: var(--color-brand); border-radius: var(--radius); padding: 18px 14px; margin: 0 8px; }
.stats .stat + .stat { border-left: none; }
.stats .stat span { color: var(--color-navy); }

/* Sections */
.section { padding: 64px 0; }
.section--soft { background: var(--color-bg-soft); }
.section__head { display: flex; justify-content: space-between; align-items: flex-end; margin-bottom: 28px; gap: 20px; }
.section__desc { color: var(--color-muted); margin-top: 6px; }
.section h2.center { margin-bottom: 28px; }
.link-arrow { color: var(--color-brand); font-weight: 600; white-space: nowrap; }
.link-arrow:hover { text-decoration: underline; }

/* Services */
.services { display: grid; grid-template-columns: repeat(4, 1fr); gap: 22px; }
.svc img { width: 100%; height: 170px; object-fit: cover; }
.card__body { padding: 18px; text-align: center; display: flex; flex-direction: column; align-items: center; gap: 14px; }
.svc h3 { font-size: 17px; }

/* Partners */
.logos { display: grid; grid-template-columns: repeat(6, 1fr); gap: 16px; margin: 28px 0 22px; }
.logo-slot {
  height: 84px; border: 1.5px dashed var(--color-blue); border-radius: 10px; background: #fff;
  display: flex; align-items: center; justify-content: center; color: var(--color-muted); font-size: 13px;
}

/* Process */
.steps { display: grid; grid-template-columns: repeat(4, 1fr); position: relative; margin-top: 30px; }
.steps::before {
  content: ""; position: absolute; top: 44px; left: 12%; right: 12%;
  border-top: 2px dotted var(--color-blue);
}
.steps li { display: flex; flex-direction: column; align-items: center; text-align: center; position: relative; }
.step-num {
  position: absolute; top: -4px; left: calc(50% + 28px);
  width: 26px; height: 26px; border-radius: 50%; background: var(--color-blue); color: var(--color-navy);
  font-size: 13px; font-weight: 700; display: flex; align-items: center; justify-content: center;
}
.step-ico {
  width: 88px; height: 88px; border-radius: 50%; border: 2px solid var(--color-blue);
  display: flex; align-items: center; justify-content: center; font-size: 30px; background: #fff;
}
.steps p { margin-top: 14px; font-weight: 700; color: var(--color-navy); }

/* About */
.about { display: grid; grid-template-columns: 1fr 1fr; gap: 48px; align-items: center; }
.about__media img { width: 100%; height: 300px; object-fit: cover; border-radius: var(--radius); }
.about__text h2 { margin-bottom: 20px; }
.about__text .placeholder-lines { margin-bottom: 26px; }
.about__stats { display: grid; grid-template-columns: repeat(3, 1fr); }
.about__stats .stat strong { font-size: 28px; }
.about__stats .stat { background: var(--color-brand); border-radius: var(--radius); padding: 14px 10px; margin: 0 6px; }
.about__stats .stat + .stat { border-left: none; }
.about__stats .stat span { color: var(--color-navy); }

/* News */
.news { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.card.post img { width: 100%; height: 190px; object-fit: cover; }
.card.post .card__body { text-align: left; align-items: stretch; gap: 16px; }
.post__meta { display: flex; justify-content: space-between; font-size: 14px; color: var(--color-muted); }
.post__meta a { color: var(--color-brand); font-weight: 600; }

/* CTA band */
.cta-band { background: var(--color-blue); padding: 52px 0; color: var(--color-navy); }
.cta-band__inner { text-align: center; }
.cta-band h2 { color: var(--color-navy); font-size: 30px; }
.cta-band__btns { display: flex; justify-content: center; gap: 14px; margin-top: 24px; flex-wrap: wrap; }

/* Footer */
.footer { background: #fff; border-top: 1px solid var(--color-border); padding-top: 48px; }
.footer__grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr 1fr; gap: 32px; padding-bottom: 36px; }
.footer__logo { height: 44px; width: auto; margin-bottom: 16px; }
.footer p { font-size: 14px; margin-bottom: 8px; }
.footer h4 { font-size: 15px; margin-bottom: 14px; color: var(--color-brand); }
.footer a { display: block; font-size: 14px; margin-bottom: 9px; color: var(--color-text); }
.footer a:hover { color: var(--color-brand); }
.copyright { text-align: center; font-size: 13px; color: var(--color-muted); border-top: 1px solid var(--color-border); padding: 18px 0; }

/* Floating buttons */
.floating { position: fixed; right: 18px; bottom: 22px; display: flex; flex-direction: column; gap: 12px; z-index: 50; }
.fab {
  width: 52px; height: 52px; border-radius: 50%; display: flex; align-items: center; justify-content: center;
  box-shadow: 0 6px 16px rgba(15,42,79,.2); font-weight: 700; font-size: 13px; color: #fff; background: var(--color-blue);
}
.fab--zalo { background: #0068FF; }
.fab--phone { background: var(--color-yellow); color: var(--color-navy); font-size: 22px; }
.fab--top { background: #fff; color: var(--color-brand); border: 1px solid var(--color-border); font-size: 20px; }

/* Responsive */
@media (max-width: 1024px) {
  h1 { font-size: 38px; }
  .services, .news { grid-template-columns: repeat(2, 1fr); }
  .logos { grid-template-columns: repeat(3, 1fr); }
  .footer__grid { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 768px) {
  :root { --gutter: 20px; }
  h1 { font-size: 30px; }
  h2 { font-size: 26px; }
  .nav { display: none; }
  .hero__grid, .entry__grid, .about { grid-template-columns: 1fr; }
  .hero__media img { height: 260px; }
  .entry__grid { margin-top: 0; }
  .hero__trust { grid-template-columns: repeat(2, 1fr); }
  .stats__row { grid-template-columns: repeat(2, 1fr); row-gap: 20px; }
  .stat:nth-child(3) { border-left: none; }
  .steps { grid-template-columns: repeat(2, 1fr); row-gap: 30px; }
  .steps::before { display: none; }
  .step-num { left: calc(50% + 26px); }
  .cta-band__btns .btn { width: 100%; }
  .header__actions .btn--outline { display: none; }
  .news { grid-template-columns: 1fr; }
  .section__head { flex-direction: column; align-items: flex-start; }
  .footer__grid { grid-template-columns: 1fr; }
  .floating { bottom: 84px; }
  .logos { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 480px) {
  .services { grid-template-columns: 1fr; }
  .hero__ctas .btn { width: 100%; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  * { transition: none !important; }
}

/* ---- Đối tác ---- */
.partners-sub { text-align: left; margin: 36px 0 16px; font-size: 22px; }
.chips { display: flex; flex-wrap: wrap; gap: 10px; }
.chip {
  border: 1.5px solid var(--color-brand); background: #fff; color: var(--color-navy);
  border-radius: 999px; padding: 9px 16px; font: 600 14px/1 var(--font); cursor: pointer;
}
.chip span { display: inline-block; margin-left: 4px; padding: 2px 8px; border-radius: 999px; background: var(--color-brand); color: var(--color-navy); font-size: 12px; }
.chip.is-active { background: var(--color-cta); border-color: var(--color-cta); }
.chip.is-active span { background: var(--color-navy); color: #fff; }
.school-panels { margin-top: 18px; }
.school-grid { display: none; grid-template-columns: repeat(3, 1fr); gap: 14px; }
.school-grid.is-active { display: grid; }
.school { background: #fff; border: 1px solid var(--color-border); border-radius: var(--radius); padding: 14px; display: flex; align-items: center; gap: 12px; }
.school__logo, .company__logo { width: 56px; height: 56px; flex: 0 0 56px; border-radius: 10px; background: var(--color-bg-soft); display: flex; align-items: center; justify-content: center; overflow: hidden; }
.school__logo img, .company__logo img { max-width: 100%; max-height: 100%; object-fit: contain; }
.school__name { font-size: 14px; font-weight: 600; color: var(--color-navy); line-height: 1.35; }
.company-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; margin-top: 4px; }
.company { background: var(--color-brand); border-radius: var(--radius); padding: 16px; display: flex; align-items: center; gap: 12px; }
.company__logo { background: #fff; }
.company__name { font-size: 14px; font-weight: 700; color: var(--color-navy); line-height: 1.35; }
@media (max-width: 1024px) { .school-grid { grid-template-columns: repeat(2, 1fr); } .company-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 768px) { .chips { flex-wrap: nowrap; overflow-x: auto; padding-bottom: 6px; } .chip { white-space: nowrap; } }
@media (max-width: 480px) { .school-grid, .company-grid { grid-template-columns: 1fr; } }

/* ---- v9: số liệu xanh, đối tác click để mở ---- */
.stats .stat, .about__stats .stat { background: none; border-radius: 0; padding: 0 14px; margin: 0; }
.stats .stat span, .about__stats .stat span { color: var(--color-muted); }
.stats .stat + .stat, .about__stats .stat + .stat { border-left: 1px solid var(--color-border); }
.stat strong, .about__stats .stat strong { color: var(--color-blue); }
.partner-toggle { margin-top: 8px; }
.partner-toggle .chips { justify-content: center; }
.school-panels { display: grid; grid-template-rows: 0fr; transition: grid-template-rows .35s ease; margin-top: 0; }
.partner-toggle.is-open .school-panels { grid-template-rows: 1fr; margin-top: 18px; }
.school-panels__inner { min-height: 0; overflow: hidden; }
.school-grid { display: none; }
.school-grid.is-active { display: grid; }
.chip.is-active { background: var(--color-cta); border-color: var(--color-cta); }
.chip { transition: background .2s, border-color .2s; }
.partners-sub { text-align: center; }
@media (prefers-reduced-motion: reduce) { .school-panels { transition: none; } }

/* ---- Nút liên hệ nổi (style Tripper / Aline) ---- */
.floating { display: none !important; }
.contact-float { position: fixed; right: 18px; bottom: 24px; z-index: 60; display: flex; flex-direction: column; align-items: center; gap: 14px; }
.cf-btn { position: relative; width: 56px; height: 56px; border-radius: 50%; display: flex; align-items: center; justify-content: center; border: 3px solid #fff; box-shadow: 0 6px 18px rgba(10,46,74,.22); font-weight: 800; font-size: 14px; text-decoration: none; }
.cf-btn--zalo { background: #0068FF; color: #fff; }
.cf-btn--call { background: var(--color-cta); color: var(--color-navy); }
.cf-btn--top { background: var(--color-brand); color: var(--color-navy); font-size: 22px; opacity: 0; pointer-events: none; transition: opacity .25s; }
.cf-btn--top.is-visible { opacity: 1; pointer-events: auto; }
.cf-btn--consult { display: none; }
.cf-label { display: none; }
.cf-btn--zalo .cf-label, .cf-btn--call .cf-label { display: none; }
/* Sóng tỏa ra */
.cf-btn--zalo::before, .cf-btn--zalo::after,
.cf-btn--call::before, .cf-btn--call::after {
  content: ""; position: absolute; inset: -3px; border-radius: 50%; z-index: -1;
  animation: cf-wave 2s ease-out infinite;
}
.cf-btn--zalo::before, .cf-btn--zalo::after { background: rgba(0,104,255,.35); }
.cf-btn--call::before, .cf-btn--call::after { background: rgba(250,232,0,.55); }
.cf-btn--zalo::after, .cf-btn--call::after { animation-delay: 1s; }
@keyframes cf-wave { 0% { transform: scale(1); opacity: .9; } 100% { transform: scale(1.9); opacity: 0; } }

@media (max-width: 768px) {
  body { padding-bottom: 76px; }
  .contact-float { left: 0; right: 0; bottom: 0; flex-direction: row; gap: 8px; padding: 10px 12px calc(10px + env(safe-area-inset-bottom)); background: #fff; box-shadow: 0 -4px 16px rgba(10,46,74,.10); }
  .cf-btn { flex: 1; width: auto; height: 48px; border-radius: 12px; border: 0; box-shadow: none; gap: 8px; font-size: 15px; }
  .cf-btn::before, .cf-btn::after { display: none; }
  .cf-btn .cf-label { display: inline; }
  .cf-btn--zalo .cf-ico { display: none; }
  .cf-btn--consult { display: flex; background: #fff; color: var(--color-navy); border: 1.5px solid var(--color-navy); }
  .cf-btn--top { position: fixed; right: 14px; bottom: 84px; flex: none; width: 48px; height: 48px; border-radius: 50%; border: 3px solid #fff; box-shadow: 0 6px 18px rgba(10,46,74,.22); }
}
@media (prefers-reduced-motion: reduce) { .cf-btn::before, .cf-btn::after { animation: none; display: none; } }
