@import url('https://fonts.googleapis.com/css2?family=Be+Vietnam+Pro:wght@300;400;500;600;700&family=Noto+Sans:wght@300;400;500;600;700&display=swap');

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

:root {
  --blue: #3bb1ff;
  --red: #ff5252;
  --black: #000000;
  --white: #ffffff;
  --yellow: #ffe566;
  --bg: #f5f5f0;
  --border: 3px solid #000;
  --shadow: 5px 5px 0 #000;
  --shadow-sm: 3px 3px 0 #000;
  --radius: 28px;
  --radius-sm: 12px;
  --font: 'Be Vietnam Pro', 'Noto Sans', system-ui, sans-serif;
  --nav-h: 120px;
}

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

body.nb-body {
  font-family: var(--font);
  background: var(--bg);
  color: var(--black);
  line-height: 1.6;
  overflow-x: hidden;
}

article[id] {
  scroll-margin-top: calc(var(--nav-h) + 16px);
}

/* ===== OVERLAY MENU ===== */
.overlay-menu {
  position: fixed;
  inset: 0;
  background: var(--black);
  z-index: 9999;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  transform: translateX(-100%);
  transition: transform 0.35s cubic-bezier(0.77, 0, 0.175, 1);
}

.overlay-menu.is-open {
  transform: translateX(0);
}

.overlay-close {
  position: absolute;
  top: 24px;
  right: 28px;
  background: var(--red);
  border: var(--border);
  box-shadow: var(--shadow-sm);
  color: var(--white);
  font-size: 1.5rem;
  font-weight: 700;
  width: 52px;
  height: 52px;
  cursor: pointer;
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: box-shadow 0.15s;
}

.overlay-close:hover {
  box-shadow: 2px 2px 0 #fff;
}

.overlay-aside {
  width: 100%;
  max-width: 480px;
  padding: 0 24px;
}

.overlay-nav ul {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.overlay-nav ul li a {
  display: block;
  font-size: 1.75rem;
  font-weight: 700;
  color: var(--white);
  text-decoration: none;
  border: var(--border);
  border-color: var(--blue);
  padding: 14px 24px;
  border-radius: var(--radius-sm);
  box-shadow: 4px 4px 0 var(--blue);
  transition: background 0.15s, color 0.15s, box-shadow 0.15s;
  min-height: 56px;
  line-height: 1.4;
}

.overlay-nav ul li a:hover {
  background: var(--blue);
  color: var(--black);
  box-shadow: 2px 2px 0 var(--blue);
}

/* ===== HEADER ===== */
.site-header {
  position: sticky;
  top: 0;
  z-index: 800;
  background: var(--white);
  border-bottom: var(--border);
}

.header-brand-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 24px;
  border-bottom: 2px solid var(--black);
  background: var(--blue);
}

.brand-wrap {
  display: flex;
  align-items: center;
  gap: 14px;
}

.brand-link {
  text-decoration: none;
  display: flex;
  align-items: center;
}

.brand-logo {
  height: 44px;
  width: auto;
  display: block;
  border: var(--border);
  border-radius: var(--radius-sm);
}

.brand-text {
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--black);
  letter-spacing: -0.03em;
  border: var(--border);
  background: var(--yellow);
  padding: 4px 14px;
  border-radius: var(--radius-sm);
  box-shadow: var(--shadow-sm);
}

.brand-tagline {
  font-size: 0.85rem;
  font-weight: 500;
  color: var(--black);
  max-width: 300px;
  display: none;
}

@media (min-width: 768px) {
  .brand-tagline { display: block; }
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 10px;
}

.btn-contact {
  background: var(--yellow);
  border: var(--border);
  box-shadow: var(--shadow-sm);
  color: var(--black);
  font-family: var(--font);
  font-size: 0.9rem;
  font-weight: 700;
  padding: 10px 18px;
  cursor: pointer;
  border-radius: var(--radius-sm);
  min-height: 44px;
  transition: box-shadow 0.15s, transform 0.15s;
}

.btn-contact:hover {
  box-shadow: 2px 2px 0 #000;
  transform: translate(2px, 2px);
}

.hamburger {
  background: var(--black);
  border: var(--border);
  border-color: var(--black);
  box-shadow: var(--shadow-sm);
  width: 48px;
  height: 48px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 5px;
  cursor: pointer;
  border-radius: var(--radius-sm);
  transition: box-shadow 0.15s, transform 0.15s;
  padding: 0;
}

.hamburger:hover {
  box-shadow: 2px 2px 0 var(--blue);
  transform: translate(2px, 2px);
}

.hamburger span {
  display: block;
  width: 24px;
  height: 3px;
  background: var(--white);
  border-radius: 2px;
  transition: transform 0.3s;
}

.hamburger.is-open span:nth-child(1) { transform: translateY(8px) rotate(45deg); }
.hamburger.is-open span:nth-child(2) { opacity: 0; }
.hamburger.is-open span:nth-child(3) { transform: translateY(-8px) rotate(-45deg); }

/* ===== HEADER NAV ROW ===== */
.header-nav-row {
  background: var(--white);
  padding: 0 24px;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}

.header-aside {
  display: block;
}

.header-aside nav ul {
  list-style: none;
  display: flex;
  gap: 4px;
  padding: 8px 0;
  flex-wrap: nowrap;
}

.header-aside nav ul li a {
  display: flex;
  align-items: center;
  white-space: nowrap;
  text-decoration: none;
  font-weight: 600;
  font-size: 0.88rem;
  color: var(--black);
  border: 2px solid var(--black);
  padding: 8px 14px;
  border-radius: var(--radius-sm);
  min-height: 40px;
  background: var(--bg);
  box-shadow: 2px 2px 0 #000;
  transition: background 0.15s, box-shadow 0.15s, transform 0.15s;
}

.header-aside nav ul li a:hover {
  background: var(--blue);
  box-shadow: 1px 1px 0 #000;
  transform: translate(1px, 1px);
}

/* ===== HERO ===== */
.hero {
  position: relative;
  min-height: 70vh;
  background: var(--black);
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  text-align: center;
}

.hero-inner {
  position: relative;
  z-index: 2;
  padding: 60px 24px 100px;
  max-width: 720px;
  margin: 0 auto;
}

.hero-h1 {
  font-size: clamp(2rem, 6vw, 4rem);
  font-weight: 700;
  color: var(--white);
  line-height: 1.15;
  letter-spacing: -0.02em;
  margin-bottom: 20px;
  border-bottom: 4px solid var(--blue);
  display: inline-block;
  padding-bottom: 8px;
}

.hero-sub {
  font-size: 1.1rem;
  color: rgba(255,255,255,0.85);
  margin-bottom: 32px;
  font-weight: 400;
  line-height: 1.6;
}

.btn-hero {
  display: inline-flex;
  align-items: center;
  background: var(--blue);
  color: var(--black);
  font-family: var(--font);
  font-weight: 700;
  font-size: 1.1rem;
  padding: 14px 36px;
  border: var(--border);
  border-radius: var(--radius-sm);
  box-shadow: var(--shadow);
  text-decoration: none;
  min-height: 52px;
  transition: box-shadow 0.15s, transform 0.15s;
}

.btn-hero:hover {
  box-shadow: 2px 2px 0 #000;
  transform: translate(3px, 3px);
}

.hero-arc {
  position: absolute;
  bottom: -2px;
  left: 0;
  right: 0;
  height: 80px;
  background: var(--bg);
  clip-path: ellipse(55% 100% at 50% 100%);
  z-index: 3;
}

/* ===== MAIN CONTENT ===== */
main {
  padding: 48px 0 64px;
}

.wrap {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 24px;
}

.content-section {
  display: grid;
  grid-template-columns: 1fr 300px;
  gap: 32px;
  align-items: start;
}

@media (max-width: 900px) {
  .content-section {
    grid-template-columns: 1fr;
  }
  .content-aside {
    order: -1;
  }
}

.content-article {
  min-width: 0;
}

/* ===== PAGE CONTENT (injected HTML) ===== */
.page-content {
  line-height: 1.7;
  font-size: 1rem;
}

.page-content h2 {
  font-size: 1.6rem;
  font-weight: 700;
  margin: 48px 0 8px;
  padding: 12px 18px;
  background: var(--blue);
  border: var(--border);
  border-radius: var(--radius-sm);
  box-shadow: var(--shadow-sm);
  display: inline-block;
}

.page-content h2:first-child {
  margin-top: 0;
}

.page-content h3 {
  font-size: 1.2rem;
  font-weight: 700;
  margin: 28px 0 10px;
  border-left: 5px solid var(--red);
  padding-left: 12px;
}

.page-content p {
  margin-bottom: 16px;
  font-size: 1rem;
}

.page-content ul,
.page-content ol {
  margin: 12px 0 20px 24px;
}

.page-content li {
  margin-bottom: 8px;
}

.page-content a {
  color: var(--black);
  text-decoration: underline;
  text-decoration-color: var(--blue);
  text-decoration-thickness: 2px;
  font-weight: 600;
  transition: color 0.15s;
}

.page-content a:hover {
  color: var(--red);
}

.page-content article {
  margin-bottom: 56px;
  padding: 32px;
  background: var(--white);
  border: var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}

.page-content article + article {
  margin-top: 0;
}

/* ===== ASIDE ===== */
.content-aside {
  position: sticky;
  top: calc(var(--nav-h) + 16px);
}

.aside-inner {
  background: var(--white);
  border: var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 24px;
}

.aside-title {
  font-size: 1.1rem;
  font-weight: 700;
  background: var(--black);
  color: var(--white);
  padding: 8px 14px;
  border-radius: var(--radius-sm);
  margin-bottom: 6px;
  display: block;
}

.aside-inner > .subtitle {
  font-size: 0.85rem;
  color: #555;
  margin-bottom: 16px;
}

.aside-nav-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-bottom: 20px;
}

.aside-nav-list li a {
  display: block;
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--black);
  text-decoration: none;
  border: 2px solid var(--black);
  padding: 8px 14px;
  border-radius: var(--radius-sm);
  background: var(--bg);
  box-shadow: 2px 2px 0 #000;
  min-height: 40px;
  line-height: 1.4;
  transition: background 0.15s, box-shadow 0.15s, transform 0.15s;
}

.aside-nav-list li a:hover {
  background: var(--blue);
  box-shadow: 1px 1px 0 #000;
  transform: translate(1px, 1px);
}

.aside-card {
  background: var(--yellow);
  border: var(--border);
  border-radius: var(--radius-sm);
  box-shadow: var(--shadow-sm);
  padding: 14px;
}

.aside-brand-name {
  font-weight: 700;
  font-size: 1rem;
  margin-bottom: 4px;
}

.aside-brand-desc {
  font-size: 0.82rem;
  color: #333;
  line-height: 1.5;
}

/* ===== FOOTER ===== */
.site-footer {
  background: var(--black);
  color: var(--white);
  border-top: var(--border);
  padding: 48px 24px 24px;
}

.footer-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 32px;
  max-width: 1200px;
  margin: 0 auto 40px;
}

@media (max-width: 900px) {
  .footer-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 480px) {
  .footer-grid {
    grid-template-columns: 1fr;
  }
}

.footer-col-title {
  font-size: 1rem;
  font-weight: 700;
  background: var(--blue);
  color: var(--black);
  padding: 6px 12px;
  border-radius: var(--radius-sm);
  border: 2px solid var(--white);
  margin-bottom: 6px;
  display: inline-block;
}

.footer-col > .subtitle {
  font-size: 0.8rem;
  color: rgba(255,255,255,0.6);
  margin-bottom: 12px;
}

.footer-desc {
  font-size: 0.88rem;
  color: rgba(255,255,255,0.75);
  line-height: 1.6;
}

.footer-col ul {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.footer-col ul li a {
  color: rgba(255,255,255,0.8);
  text-decoration: none;
  font-size: 0.9rem;
  font-weight: 500;
  display: inline-flex;
  align-items: center;
  min-height: 40px;
  padding: 4px 0;
  border-bottom: 1px solid rgba(255,255,255,0.15);
  width: 100%;
  transition: color 0.15s;
}

.footer-col ul li a:hover {
  color: var(--blue);
}

.footer-col address {
  font-style: normal;
}

.footer-bottom {
  border-top: 1px solid rgba(255,255,255,0.15);
  padding-top: 20px;
  text-align: center;
  max-width: 1200px;
  margin: 0 auto;
}

.footer-copy {
  font-size: 0.9rem;
  font-weight: 600;
  color: rgba(255,255,255,0.9);
  margin-bottom: 6px;
}

.footer-note {
  font-size: 0.8rem;
  color: rgba(255,255,255,0.5);
}

/* ===== SUBTITLE CLASS ===== */
p.subtitle,
p.subhead,
p.desc,
p.lead {
  font-size: 0.95rem;
  color: #555;
  margin-bottom: 20px;
  font-weight: 400;
  line-height: 1.6;
}

/* ===== SCROLL REVEAL ANIMATION ===== */
@media (prefers-reduced-motion: no-preference) {
  .reveal {
    opacity: 0;
    transform: translateY(28px);
    transition: opacity 0.55s ease, transform 0.55s ease;
  }

  .reveal.is-visible {
    opacity: 1;
    transform: translateY(0);
  }

  .stagger-item {
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.4s ease, transform 0.4s ease;
  }

  .stagger-item.is-visible {
    opacity: 1;
    transform: translateY(0);
  }

  .stagger-item:nth-child(1) { transition-delay: 0.05s; }
  .stagger-item:nth-child(2) { transition-delay: 0.12s; }
  .stagger-item:nth-child(3) { transition-delay: 0.19s; }
  .stagger-item:nth-child(4) { transition-delay: 0.26s; }
  .stagger-item:nth-child(5) { transition-delay: 0.33s; }
  .stagger-item:nth-child(6) { transition-delay: 0.40s; }
  .stagger-item:nth-child(7) { transition-delay: 0.47s; }
}

/* ===== UTILITY ===== */
img {
  max-width: 100%;
  height: auto;
  display: block;
}

a:focus-visible {
  outline: 3px solid var(--blue);
  outline-offset: 2px;
  border-radius: 4px;
}

button:focus-visible {
  outline: 3px solid var(--blue);
  outline-offset: 2px;
}

/* ===== RESPONSIVE ===== */
@media (max-width: 600px) {
  .hero-inner {
    padding: 48px 16px 90px;
  }

  .page-content article {
    padding: 20px 16px;
  }

  .aside-inner {
    padding: 16px;
  }

  .wrap {
    padding: 0 16px;
  }

  .header-brand-row {
    padding: 10px 16px;
  }

  .header-nav-row {
    padding: 0 8px;
  }

  .overlay-nav ul li a {
    font-size: 1.3rem;
    padding: 12px 18px;
  }
}
