/* ============================================================
   NaiYao Systems — homepage stylesheet
   Theme: deep forest green on a light mist surface
   ============================================================ */

:root {
  --bg: #F2F6F2;
  --bg-soft: #E8EFE8;
  --surface: #FFFFFF;
  --ink: #14211B;
  --muted: #45594D;
  --primary: #1D5C42;
  --primary-dark: #113B2A;
  --primary-deep: #0B2B1E;
  --accent: #2F8A63;
  --accent-soft: #DCEBE0;
  --line: #D5E1D6;
  --white: #FFFFFF;
  --shadow-sm: 0 2px 8px rgba(17, 59, 42, 0.08);
  --shadow-md: 0 10px 30px rgba(17, 59, 42, 0.12);
  --radius: 16px;
  --radius-pill: 999px;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  font-size: 16px;
  scroll-behavior: smooth;
}

body {
  font-size: 16px;
  font-family: "Inter", "Segoe UI", "Helvetica Neue", Arial, sans-serif;
  line-height: 1.7;
  color: var(--ink);
  background-color: var(--bg);
  overflow-x: hidden;
}

a {
  color: inherit;
  text-decoration: none;
}

img {
  max-width: 100%;
  display: block;
}

/* ---------- Floating pill navigation ---------- */

.site-nav {
  position: fixed;
  top: 18px;
  left: 0;
  right: 0;
  z-index: 1000;
  display: flex;
  justify-content: center;
  padding: 0 20px;
}

.nav-pill {
  display: flex;
  align-items: center;
  gap: 26px;
  width: 100%;
  max-width: 1080px;
  padding: 10px 12px 10px 22px;
  background-color: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius-pill);
  box-shadow: var(--shadow-md);
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 800;
  font-size: 1.15rem;
  letter-spacing: -0.02em;
  color: var(--primary-dark);
}

.brand-mark {
  width: 26px;
  height: 26px;
  border-radius: 50%;
  background-color: var(--primary);
  position: relative;
  flex: none;
}

.brand-mark::after {
  content: "";
  position: absolute;
  inset: 7px;
  border-radius: 50%;
  background-color: var(--white);
}

.brand-name em {
  font-style: normal;
  color: var(--accent);
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 22px;
  margin-left: auto;
}

.nav-links a {
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--muted);
  padding: 6px 2px;
  transition: color 0.2s ease;
}

.nav-links a:hover {
  color: var(--primary);
}

.nav-cta {
  font-size: 0.9rem;
  font-weight: 700;
  color: var(--white);
  background-color: var(--primary);
  padding: 11px 22px;
  border-radius: var(--radius-pill);
  transition: background-color 0.2s ease;
  white-space: nowrap;
}

.nav-cta:hover {
  background-color: var(--primary-dark);
}

.nav-toggle {
  display: none;
  flex: none;
  width: 44px;
  height: 44px;
  background: var(--accent-soft);
  border: none;
  border-radius: 50%;
  cursor: pointer;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 5px;
}

.nav-toggle span {
  display: block;
  width: 20px;
  height: 2px;
  background-color: var(--primary-dark);
  transition: transform 0.2s ease, opacity 0.2s ease;
}

/* ---------- Hero band ---------- */

.hero-band {
  position: relative;
  padding: 190px 24px 110px;
  color: var(--white);
  background-color: var(--primary-deep);
  background-image:
    linear-gradient(135deg, #0B2B1E 0%, #113B2A 34%, #1D5C42 68%, #2F8A63 100%);
  overflow: hidden;
}

.hero-band::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.05) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.05) 1px, transparent 1px);
  background-size: 56px 56px;
  pointer-events: none;
}

.hero-band::after {
  content: "";
  position: absolute;
  width: 520px;
  height: 520px;
  right: -140px;
  bottom: -220px;
  border-radius: 50%;
  background: rgba(47,138,99,0.55);
  pointer-events: none;
}

.hero-inner {
  position: relative;
  z-index: 1;
  max-width: 900px;
  margin: 0 auto;
  text-align: center;
}

.hero-eyebrow {
  display: inline-block;
  font-size: 0.85rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: #B9E3CF;
  background-color: var(--primary-dark);
  padding: 8px 18px;
  border-radius: var(--radius-pill);
  margin-bottom: 26px;
}

.hero-band h1 {
  font-size: clamp(2.2rem, 5.2vw, 3.9rem);
  line-height: 1.08;
  font-weight: 800;
  letter-spacing: -0.03em;
  margin-bottom: 26px;
  color: var(--white);
}

.hero-lede {
  font-size: 1.15rem;
  color: #D7EBDD;
  max-width: 720px;
  margin: 0 auto 34px;
}

.hero-actions {
  display: flex;
  justify-content: center;
  gap: 16px;
  flex-wrap: wrap;
}

.btn {
  display: inline-block;
  font-size: 1rem;
  font-weight: 700;
  padding: 14px 30px;
  border-radius: var(--radius-pill);
  transition: transform 0.15s ease, background-color 0.2s ease, color 0.2s ease;
}

.btn:hover {
  transform: translateY(-2px);
}

.btn-light {
  background-color: var(--white);
  color: var(--primary-dark);
}

.btn-light:hover {
  background-color: #EAF5EE;
}

.btn-ghost {
  background-color: transparent;
  color: var(--white);
  border: 1px solid rgba(255, 255, 255, 0.5);
}

.btn-ghost:hover {
  border-color: var(--white);
}

.btn-dark {
  background-color: var(--primary);
  color: var(--white);
  border: none;
  cursor: pointer;
}

.btn-dark:hover {
  background-color: var(--primary-dark);
}

.hero-note {
  margin-top: 30px;
  font-size: 0.9rem;
  color: #B9E3CF;
}

/* ---------- Shared kicker / headings ---------- */

.kicker {
  font-size: 0.85rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 12px;
}

h2 {
  font-size: clamp(1.7rem, 3.4vw, 2.5rem);
  line-height: 1.15;
  letter-spacing: -0.02em;
  color: var(--primary-dark);
}

/* ---------- Asymmetric two-column (about + contact) ---------- */

.about-section {
  padding: 96px 24px;
  background-color: var(--bg);
}

.about-grid {
  max-width: 1160px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1.7fr 1fr;
  gap: 56px;
  align-items: start;
}

.about-copy h2 {
  margin-bottom: 22px;
}

.about-copy > p {
  color: var(--muted);
  font-size: 1.05rem;
  margin-bottom: 18px;
  max-width: 640px;
}

.about-list {
  list-style: none;
  margin: 26px 0 34px;
}

.about-list li {
  position: relative;
  padding: 12px 0 12px 34px;
  color: var(--ink);
  font-size: 1rem;
  border-bottom: 1px solid var(--line);
}

.about-list li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 19px;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background-color: var(--accent-soft);
  border: 4px solid var(--accent);
}

.about-list strong {
  color: var(--primary-dark);
}

.about-stats {
  display: flex;
  flex-wrap: wrap;
  gap: 34px;
}

.stat {
  display: flex;
  flex-direction: column;
}

.stat-value {
  font-size: 2.1rem;
  font-weight: 800;
  letter-spacing: -0.02em;
  color: var(--primary);
  line-height: 1;
}

.stat-label {
  font-size: 0.85rem;
  color: var(--muted);
  margin-top: 6px;
}

/* Contact card */

.contact-card {
  background-color: var(--white);
  border: 1px solid var(--line);
  border-radius: 22px;
  padding: 34px 30px;
  box-shadow: var(--shadow-md);
}

.contact-card h3 {
  font-size: 1.4rem;
  color: var(--primary-dark);
  margin-bottom: 10px;
}

.contact-card > p {
  color: var(--muted);
  font-size: 0.98rem;
  margin-bottom: 22px;
}

.contact-form label {
  display: block;
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--primary-dark);
  margin: 0 0 6px;
}

.contact-form input,
.contact-form textarea {
  width: 100%;
  font-size: 1rem;
  font-family: inherit;
  color: var(--ink);
  background-color: var(--bg);
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 12px 14px;
  margin-bottom: 16px;
}

.contact-form input:focus,
.contact-form textarea:focus {
  outline: 2px solid var(--accent);
  outline-offset: 0;
  border-color: var(--accent);
}

.contact-form textarea {
  resize: vertical;
}

.contact-form .btn {
  width: 100%;
  border: none;
  font-family: inherit;
}

.form-status {
  min-height: 22px;
  font-size: 0.9rem;
  margin-top: 12px;
  color: var(--accent);
}

.form-status.error {
  color: #B23A2F;
}

.contact-direct {
  margin-top: 18px;
  font-size: 0.9rem;
  color: var(--muted);
}

.contact-direct a {
  color: var(--primary);
  font-weight: 600;
}

/* ---------- Card carousel ---------- */

.carousel-section {
  padding: 96px 0;
  background-color: var(--bg-soft);
}

.carousel-head {
  max-width: 1160px;
  margin: 0 auto 36px;
  padding: 0 24px;
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 24px;
}

.carousel-head h2 {
  max-width: 560px;
}

.carousel-controls {
  display: flex;
  gap: 10px;
}

.car-btn {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  border: 1px solid var(--line);
  background-color: var(--white);
  color: var(--primary-dark);
  font-size: 1.2rem;
  cursor: pointer;
  transition: background-color 0.2s ease, color 0.2s ease;
}

.car-btn:hover {
  background-color: var(--primary);
  color: var(--white);
}

.card-track {
  display: flex;
  gap: 22px;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  padding: 8px 24px 28px;
  scrollbar-width: thin;
  scrollbar-color: var(--accent) var(--line);
}

.card-track::-webkit-scrollbar {
  height: 8px;
}

.card-track::-webkit-scrollbar-thumb {
  background-color: var(--accent);
  border-radius: 999px;
}

.card-track::-webkit-scrollbar-track {
  background-color: var(--line);
}

.card {
  scroll-snap-align: start;
  flex: 0 0 340px;
  background-color: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 30px 28px;
  min-height: 240px;
  display: flex;
  flex-direction: column;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.card:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow-md);
}

.card-index {
  font-size: 0.85rem;
  font-weight: 800;
  letter-spacing: 0.1em;
  color: var(--accent);
  margin-bottom: 18px;
}

.card h3 {
  font-size: 1.25rem;
  color: var(--primary-dark);
  margin-bottom: 12px;
}

.card p {
  color: var(--muted);
  font-size: 0.98rem;
}

/* ---------- FAQ accordion ---------- */

.faq-section {
  padding: 96px 24px;
  background-color: var(--bg);
}

.faq-inner {
  max-width: 900px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 0.9fr 1.4fr;
  gap: 48px;
  align-items: start;
}

.faq-intro h2 {
  margin-bottom: 16px;
}

.faq-intro p {
  color: var(--muted);
}

.faq-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.faq-item {
  background-color: var(--white);
  border: 1px solid var(--line);
  border-radius: 14px;
  overflow: hidden;
}

.faq-item summary {
  list-style: none;
  cursor: pointer;
  font-weight: 700;
  font-size: 1.02rem;
  color: var(--primary-dark);
  padding: 20px 24px;
  position: relative;
  padding-right: 60px;
}

.faq-item summary::-webkit-details-marker {
  display: none;
}

.faq-item summary::after {
  content: "+";
  position: absolute;
  right: 22px;
  top: 50%;
  transform: translateY(-50%);
  font-size: 1.5rem;
  color: var(--accent);
  font-weight: 700;
  transition: transform 0.2s ease;
}

.faq-item[open] summary::after {
  content: "−";
}

.faq-item[open] summary {
  background-color: var(--accent-soft);
}

.faq-body {
  padding: 0 24px 22px;
}

.faq-body p {
  color: var(--muted);
  font-size: 0.98rem;
}

/* ---------- Compact footer ---------- */

.site-footer {
  background-color: var(--primary-deep);
  color: #D7EBDD;
  padding: 26px 24px;
}

.footer-row {
  max-width: 1160px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  flex-wrap: wrap;
}

.footer-brand {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 800;
  color: var(--white);
}

.footer-brand .brand-mark {
  background-color: var(--accent);
}

.footer-brand em {
  font-style: normal;
  color: #B9E3CF;
}

.footer-links {
  display: flex;
  gap: 22px;
}

.footer-links a {
  font-size: 0.92rem;
  font-weight: 600;
  color: #B9E3CF;
  transition: color 0.2s ease;
}

.footer-links a:hover {
  color: var(--white);
}

.footer-contact {
  display: flex;
  gap: 10px;
  align-items: center;
  font-size: 0.92rem;
}

.footer-contact a {
  color: #B9E3CF;
}

.footer-contact a:hover {
  color: var(--white);
}

.footer-copy {
  font-size: 0.82rem;
  color: #8FB3A0;
}

/* ---------- Scroll reveal ---------- */

.fade-up {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

.fade-up.visible {
  opacity: 1;
  transform: none;
}

/* ---------- Responsive ---------- */

@media (max-width: 900px) {
  .about-grid {
    grid-template-columns: 1fr;
    gap: 40px;
  }

  .faq-inner {
    grid-template-columns: 1fr;
    gap: 28px;
  }
}

@media (max-width: 820px) {
  .nav-links,
  .nav-cta {
    display: none;
  }

  .nav-toggle {
    display: flex;
    margin-left: auto;
  }

  .nav-pill {
    gap: 12px;
  }

  .site-nav.open .nav-pill {
    border-radius: 26px;
    flex-wrap: wrap;
    align-items: flex-start;
  }

  .site-nav.open .nav-links {
    display: flex;
    flex-direction: column;
    align-items: stretch;
    width: 100%;
    gap: 6px;
    padding: 12px 6px 6px;
    order: 3;
  }

  .site-nav.open .nav-links a {
    padding: 12px 10px;
    border-radius: 12px;
  }

  .site-nav.open .nav-links a:hover {
    background-color: var(--accent-soft);
  }

  .site-nav.open .nav-cta {
    display: inline-block;
    order: 2;
  }

  .site-nav.open .nav-toggle span:nth-child(1) {
    transform: translateY(7px) rotate(45deg);
  }

  .site-nav.open .nav-toggle span:nth-child(2) {
    opacity: 0;
  }

  .site-nav.open .nav-toggle span:nth-child(3) {
    transform: translateY(-7px) rotate(-45deg);
  }

  .hero-band {
    padding-top: 150px;
  }

  .card {
    flex-basis: 280px;
  }

  .footer-row {
    flex-direction: column;
    align-items: flex-start;
    gap: 12px;
  }
}
