@import url('https://fonts.googleapis.com/css2?family=DM+Sans:ital,wght@0,400;0,500;0,700;1,400&family=Nunito:ital,wght@0,700;0,800;0,900;1,700&display=swap');

/* ============================================================
   RESET & BASE
   ============================================================ */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --green: #80ff00;
  --green2: #00ff00;
  --dark: #1f2617;
  --dark2: #161c0f;
  --dark3: #2a3520;
  --white: #f5ffea;
  --muted: #a8c87a;
  --accent: #ff4fd8;
  --accent2: #ffcf00;
  --rad: 18px;
  --sidebar-w: 220px;
  --font-head: 'Nunito', 'DM Sans', system-ui, sans-serif;
  --font-body: 'DM Sans', 'Nunito', system-ui, sans-serif;
  scroll-behavior: smooth;
}

html { font-size: 16px; line-height: 1.6; }

body {
  background: var(--dark);
  color: var(--white);
  font-family: var(--font-body);
  min-height: 100vh;
  overflow-x: hidden;
  max-width: 100vw;
}

.body-home { display: block; }

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

a { color: var(--green); text-decoration: none; }
a:hover { color: var(--green2); }

ul, menu { list-style: none; }

.sr-only {
  position: absolute; width: 1px; height: 1px;
  padding: 0; margin: -1px; overflow: hidden;
  clip: rect(0,0,0,0); white-space: nowrap; border: 0;
}

/* ============================================================
   PAGE SHELL (sidebar + main area)
   ============================================================ */
.page-shell {
  display: flex;
  min-height: 100vh;
  overflow-x: hidden;
  max-width: 100%;
}

/* ============================================================
   SIDEBAR NAV
   details > summary + menu > li > a
   ============================================================ */
.sidebar-nav {
  position: fixed;
  top: 0; left: 0;
  width: var(--sidebar-w);
  height: 100vh;
  background: var(--dark2);
  border-right: 3px solid var(--green);
  display: flex;
  flex-direction: column;
  z-index: 200;
  overflow-y: auto;
  overflow-x: hidden;
  padding-bottom: 1rem;
}

.sidebar-nav > summary { list-style: none; }
.sidebar-nav > summary::-webkit-details-marker { display: none; }

.sidebar-summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1.2rem 1rem 1rem;
  cursor: pointer;
  border-bottom: 2px dashed var(--dark3);
  background: var(--dark2);
  position: sticky;
  top: 0;
  z-index: 10;
  gap: 0.5rem;
}

.sidebar-brand {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  flex: 1;
  min-width: 0;
}

.brand-logo { width: 36px; height: 36px; object-fit: contain; border-radius: 8px; flex-shrink: 0; }

.brand-text {
  font-family: var(--font-head);
  font-weight: 900;
  font-size: 1rem;
  color: var(--green);
  letter-spacing: -0.03em;
  line-height: 1.1;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.nav-toggle-label {
  font-size: 1.3rem;
  color: var(--muted);
  flex-shrink: 0;
}

.nav-menu {
  display: flex;
  flex-direction: column;
  padding: 0.8rem 0;
  flex: 1;
}

.nav-menu li { width: 100%; }

.nav-link {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  padding: 0.75rem 1rem;
  font-family: var(--font-head);
  font-weight: 700;
  font-size: 0.92rem;
  color: var(--white);
  transition: background 0.18s, color 0.18s;
  border-left: 3px solid transparent;
  min-height: 44px;
  position: relative;
  word-break: keep-all;
}

.nav-link:hover, .nav-link:focus {
  background: var(--dark3);
  color: var(--green);
  border-left-color: var(--green);
}

.nav-num {
  font-family: var(--font-head);
  font-weight: 900;
  font-size: 0.75rem;
  color: var(--green);
  opacity: 0.7;
  min-width: 22px;
  flex-shrink: 0;
  letter-spacing: 0.02em;
}

/* Sidebar search */
.sidebar-search {
  display: flex;
  gap: 0.3rem;
  padding: 0.8rem 1rem;
  border-top: 2px dashed var(--dark3);
}

.search-input {
  flex: 1;
  min-width: 0;
  background: var(--dark3);
  border: 2px solid var(--green);
  border-radius: 10px;
  color: var(--white);
  font-family: var(--font-body);
  font-size: 0.85rem;
  padding: 0.4rem 0.7rem;
  outline: none;
  min-height: 40px;
}

.search-input::placeholder { color: var(--muted); }
.search-input:focus { border-color: var(--green2); box-shadow: 0 0 0 3px rgba(128,255,0,0.18); }

.search-btn {
  background: var(--green);
  border: none;
  border-radius: 10px;
  color: var(--dark);
  font-size: 1rem;
  padding: 0 0.6rem;
  cursor: pointer;
  min-height: 40px;
  min-width: 40px;
  flex-shrink: 0;
  transition: background 0.15s;
}
.search-btn:hover { background: var(--green2); }

/* Sidebar sticker */
.sidebar-sticker {
  position: absolute;
  bottom: 5rem;
  right: -10px;
  background: var(--accent);
  color: #fff;
  font-family: var(--font-head);
  font-weight: 900;
  font-size: 0.7rem;
  padding: 0.25rem 0.5rem;
  border-radius: 6px;
  transform: rotate(12deg);
  letter-spacing: 0.08em;
  pointer-events: none;
  z-index: 5;
}

/* ============================================================
   MAIN AREA
   ============================================================ */
.main-area {
  margin-left: var(--sidebar-w);
  flex: 1;
  min-width: 0;
  max-width: calc(100% - var(--sidebar-w));
  display: flex;
  flex-direction: column;
  overflow-x: hidden;
}

/* ============================================================
   HERO
   ============================================================ */
.hero-wrap {
  display: flex;
  align-items: center;
  gap: 2rem;
  min-height: 45vh;
  padding: 2rem 2.5rem;
  background: linear-gradient(135deg, var(--dark2) 0%, var(--dark3) 100%);
  position: relative;
  overflow: hidden;
  border-bottom: 3px solid var(--green);
}

.hero-bg-text {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  font-family: var(--font-head);
  font-weight: 900;
  font-size: clamp(6rem, 18vw, 18rem);
  color: rgba(128,255,0,0.04);
  pointer-events: none;
  white-space: nowrap;
  z-index: 0;
  letter-spacing: -0.05em;
  user-select: none;
}

.hero-media {
  position: relative;
  flex: 0 0 40%;
  max-width: 40%;
  z-index: 1;
}

.hero-img {
  width: 100%;
  border-radius: var(--rad);
  border: 3px solid var(--green);
  display: block;
  filter: saturate(1.3);
}

.hero-placeholder {
  width: 100%;
  aspect-ratio: 4/3;
  background: var(--dark3);
  border-radius: var(--rad);
  border: 3px dashed var(--green);
  display: flex;
  align-items: center;
  justify-content: center;
}

.hero-icon { font-size: 5rem; }

.hero-sticker {
  position: absolute;
  font-family: var(--font-head);
  font-weight: 900;
  font-size: 0.8rem;
  padding: 0.3rem 0.7rem;
  border-radius: 8px;
  letter-spacing: 0.1em;
  pointer-events: none;
  z-index: 2;
}

.sticker-1 {
  top: -12px; right: -10px;
  background: var(--accent);
  color: #fff;
  transform: rotate(8deg);
  animation: jitter 3s ease-in-out infinite;
}

.sticker-2 {
  bottom: -12px; left: 10px;
  background: var(--accent2);
  color: var(--dark);
  transform: rotate(-5deg);
  animation: jitter 4s ease-in-out infinite reverse;
}

.hero-copy {
  flex: 1;
  text-align: right;
  z-index: 1;
  padding-left: 1rem;
  min-width: 0;
}

.hero-eyebrow {
  font-family: var(--font-head);
  font-weight: 700;
  font-size: 0.85rem;
  color: var(--accent);
  letter-spacing: 0.1em;
  margin-bottom: 0.5rem;
}

.hero-h1 {
  font-family: var(--font-head);
  font-weight: 900;
  font-size: clamp(1.6rem, 3.5vw, 3rem);
  color: var(--green);
  line-height: 1.1;
  margin-bottom: 0.8rem;
  letter-spacing: -0.02em;
  word-break: break-all;
}

.hero-sub {
  font-size: 1rem;
  color: var(--muted);
  line-height: 1.6;
  margin-bottom: 1.2rem;
  max-width: 360px;
  margin-left: auto;
}

.hero-cta {
  display: inline-block;
  background: var(--green);
  color: var(--dark);
  font-family: var(--font-head);
  font-weight: 900;
  font-size: 1rem;
  padding: 0.75rem 1.8rem;
  border-radius: 50px;
  border: 3px solid var(--dark);
  box-shadow: 4px 4px 0 var(--dark2);
  transition: transform 0.15s, box-shadow 0.15s;
  letter-spacing: 0.03em;
  min-height: 44px;
  line-height: 1.5;
}

.hero-cta:hover {
  transform: translate(-2px, -2px);
  box-shadow: 6px 6px 0 var(--dark2);
  color: var(--dark);
  background: var(--green2);
}

/* ============================================================
   MARQUEE
   ============================================================ */
.marquee-bar {
  background: var(--green);
  color: var(--dark);
  overflow: hidden;
  white-space: nowrap;
  padding: 0.55rem 0;
  border-bottom: 2px solid var(--dark);
  width: 100%;
}

.marquee-track {
  display: inline-block;
  animation: marquee-scroll 28s linear infinite;
  font-family: var(--font-head);
  font-weight: 800;
  font-size: 0.9rem;
  letter-spacing: 0.05em;
}

@keyframes marquee-scroll {
  from { transform: translateX(0); }
  to { transform: translateX(-50%); }
}

/* ============================================================
   CONTENT MAIN
   main > article.wrap > section > div
   ============================================================ */
.content-main {
  display: flex;
  flex: 1;
  gap: 0;
  align-items: flex-start;
  position: relative;
  overflow-x: hidden;
}

/* Aside on the left of content */
.content-aside {
  flex: 0 0 200px;
  width: 200px;
  position: sticky;
  top: 0;
  align-self: flex-start;
  max-height: 100vh;
  overflow-y: auto;
  overflow-x: hidden;
  background: var(--dark2);
  border-right: 2px solid var(--dark3);
  padding: 1.5rem 1rem;
}

.aside-inner { position: relative; }

.aside-eyebrow {
  display: block;
  font-family: var(--font-head);
  font-weight: 700;
  font-size: 0.72rem;
  color: var(--accent);
  letter-spacing: 0.15em;
  margin-bottom: 0.2rem;
}

.aside-title {
  font-family: var(--font-head);
  font-weight: 900;
  font-size: 1.05rem;
  color: var(--green);
  margin-bottom: 1rem;
  line-height: 1.2;
}

.aside-nav-list { display: flex; flex-direction: column; gap: 0.1rem; }

.aside-link {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.5rem 0.4rem;
  font-size: 0.83rem;
  color: var(--muted);
  border-radius: 8px;
  transition: background 0.15s, color 0.15s;
  font-weight: 500;
  min-height: 40px;
  word-break: keep-all;
}

.aside-link:hover {
  background: var(--dark3);
  color: var(--green);
}

.aside-num {
  font-weight: 900;
  font-size: 0.68rem;
  color: var(--green);
  opacity: 0.5;
  min-width: 18px;
  flex-shrink: 0;
}

.aside-badge {
  margin-top: 1.5rem;
  background: var(--accent2);
  color: var(--dark);
  font-family: var(--font-head);
  font-weight: 900;
  font-size: 0.75rem;
  padding: 0.4rem 0.7rem;
  border-radius: 8px;
  text-align: center;
  letter-spacing: 0.05em;
  transform: rotate(-2deg);
}

/* Wrap + section + div */
.wrap {
  flex: 1;
  min-width: 0;
  padding: 2rem 2rem;
  max-width: 860px;
  overflow-x: hidden;
}

.page-section { position: relative; }

.page-article {
  position: relative;
  min-height: 200px;
  overflow-x: hidden;
}

.article-deco {
  position: absolute;
  top: -20px;
  right: -20px;
  pointer-events: none;
  z-index: 0;
  overflow: hidden;
}

.deco-circle {
  position: absolute;
  border-radius: 50%;
  opacity: 0.12;
}

.c1 {
  width: 180px; height: 180px;
  background: var(--green);
  top: 0; right: 0;
}

.c2 {
  width: 100px; height: 100px;
  background: var(--accent);
  top: 60px; right: 60px;
}

/* ============================================================
   ARTICLE / PAGE CONTENT STYLES
   ============================================================ */
.page-article h2 {
  font-family: var(--font-head);
  font-weight: 900;
  font-size: clamp(1.3rem, 2.5vw, 2rem);
  color: var(--green);
  margin: 2.5rem 0 0.6rem;
  line-height: 1.2;
  letter-spacing: -0.02em;
  position: relative;
  word-break: break-all;
}

.page-article h3 {
  font-family: var(--font-head);
  font-weight: 800;
  font-size: 1.1rem;
  color: var(--white);
  margin: 1.8rem 0 0.5rem;
  line-height: 1.3;
  word-break: break-all;
}

.page-article p {
  font-size: 1rem;
  line-height: 1.75;
  color: var(--white);
  margin-bottom: 1rem;
  overflow-wrap: break-word;
  word-break: break-word;
}

.page-article ul, .page-article ol {
  padding-left: 1.4rem;
  margin-bottom: 1rem;
}

.page-article li {
  font-size: 1rem;
  line-height: 1.7;
  margin-bottom: 0.4rem;
  color: var(--white);
  overflow-wrap: break-word;
  word-break: break-word;
}

.page-article a {
  color: var(--green);
  text-decoration: underline;
  text-decoration-thickness: 2px;
  word-break: break-all;
}

.page-article a:hover { color: var(--green2); }

.page-article section {
  scroll-margin-top: 2rem;
  padding: 2rem 0;
  border-bottom: 2px dashed var(--dark3);
  position: relative;
  overflow: hidden;
}

.page-article section:last-child { border-bottom: none; }

.page-article small {
  display: block;
  font-family: var(--font-head);
  font-weight: 700;
  font-size: 0.72rem;
  color: var(--accent);
  letter-spacing: 0.15em;
  margin-bottom: 0.2rem;
}

.page-article table {
  width: 100%;
  border-collapse: collapse;
  margin-bottom: 1.2rem;
  font-size: 0.92rem;
  display: block;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}

.page-article th {
  background: var(--dark3);
  color: var(--green);
  font-family: var(--font-head);
  font-weight: 800;
  padding: 0.6rem 1rem;
  text-align: left;
  border: 2px solid var(--dark3);
  white-space: nowrap;
}

.page-article td {
  padding: 0.55rem 1rem;
  border: 1px solid var(--dark3);
  vertical-align: top;
}

.page-article tr:nth-child(even) td { background: rgba(128,255,0,0.04); }

.page-article blockquote {
  border-left: 4px solid var(--green);
  padding: 0.8rem 1.2rem;
  background: var(--dark3);
  border-radius: 0 var(--rad) var(--rad) 0;
  margin-bottom: 1rem;
  font-style: italic;
  color: var(--muted);
  overflow-wrap: break-word;
  word-break: break-word;
}

.page-article .card {
  background: var(--dark3);
  border: 3px solid var(--green);
  border-radius: var(--rad);
  padding: 1.2rem 1.5rem;
  margin-bottom: 1.2rem;
  box-shadow: 4px 4px 0 rgba(128,255,0,0.2);
  position: relative;
  overflow: hidden;
}

.page-article section::before {
  content: attr(data-num);
  position: absolute;
  top: 0.5rem;
  right: 1rem;
  font-family: var(--font-head);
  font-weight: 900;
  font-size: 5rem;
  color: rgba(128,255,0,0.04);
  pointer-events: none;
  line-height: 1;
  user-select: none;
}

/* ============================================================
   FOOTER
   footer > section×n
   ============================================================ */
.site-footer {
  background: var(--dark2);
  border-top: 3px solid var(--green);
}

.footer-top-row {
  display: flex;
  flex-wrap: wrap;
}

.footer-brand-sec {
  flex: 1;
  min-width: 240px;
  padding: 2rem 2rem 1.5rem;
  border-bottom: 2px dashed var(--dark3);
  border-right: 2px dashed var(--dark3);
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
}

.footer-links-sec {
  flex: 1;
  min-width: 240px;
  padding: 2rem 2rem 1.5rem;
  border-bottom: 2px dashed var(--dark3);
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.footer-brand-sec .footer-logo-wrap { margin-bottom: 0.2rem; }

.footer-desc {
  font-size: 0.9rem;
  color: var(--muted);
  line-height: 1.6;
  overflow-wrap: break-word;
  word-break: break-word;
}

.footer-contacts {
  display: flex;
  flex-direction: column;
  gap: 0.3rem;
}

.contact-item {
  font-size: 0.85rem;
  color: var(--muted);
  overflow-wrap: break-word;
  word-break: break-all;
}

.footer-sticker {
  position: absolute;
  top: 1.5rem;
  right: 1.5rem;
  background: var(--green);
  color: var(--dark);
  font-family: var(--font-head);
  font-weight: 900;
  font-size: 0.8rem;
  padding: 0.3rem 0.6rem;
  border-radius: 6px;
  transform: rotate(-8deg);
  letter-spacing: 0.1em;
}

.footer-form-block { }

.footer-eyebrow {
  display: block;
  font-family: var(--font-head);
  font-weight: 700;
  font-size: 0.72rem;
  color: var(--accent);
  letter-spacing: 0.15em;
  margin-bottom: 0.2rem;
}

.footer-form-title {
  font-family: var(--font-head);
  font-weight: 900;
  font-size: 1.1rem;
  color: var(--white);
  margin-bottom: 0.8rem;
}

.subscribe-form {
  display: flex;
  gap: 0.5rem;
  flex-wrap: wrap;
}

.sub-input {
  flex: 1;
  min-width: 160px;
  max-width: 100%;
  background: var(--dark3);
  border: 2px solid var(--green);
  border-radius: 10px;
  color: var(--white);
  font-family: var(--font-body);
  font-size: 0.9rem;
  padding: 0.6rem 1rem;
  outline: none;
  min-height: 44px;
}

.sub-input::placeholder { color: var(--muted); }
.sub-input:focus { border-color: var(--green2); box-shadow: 0 0 0 3px rgba(128,255,0,0.15); }

.sub-btn {
  background: var(--green);
  color: var(--dark);
  border: none;
  border-radius: 10px;
  font-family: var(--font-head);
  font-weight: 900;
  font-size: 0.9rem;
  padding: 0.6rem 1.4rem;
  cursor: pointer;
  min-height: 44px;
  transition: background 0.15s, transform 0.15s;
  letter-spacing: 0.05em;
  white-space: nowrap;
}

.sub-btn:hover { background: var(--green2); transform: translateY(-1px); }

.footer-nav-list {
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
}

.footer-nav-link {
  color: var(--muted);
  font-size: 0.9rem;
  padding: 0.3rem 0;
  display: block;
  transition: color 0.15s;
  min-height: 40px;
  line-height: 2;
}

.footer-nav-link:hover { color: var(--green); }

.footer-copy-sec {
  padding: 1rem 2rem;
  background: var(--dark2);
  border-top: 1px solid var(--dark3);
}

.copyright {
  font-size: 0.8rem;
  color: var(--muted);
  text-align: center;
  line-height: 1.6;
  overflow-wrap: break-word;
  word-break: break-word;
}

/* ============================================================
   ANIMATIONS
   ============================================================ */
@keyframes jitter {
  0%, 100% { transform: rotate(8deg) translate(0,0); }
  25% { transform: rotate(10deg) translate(1px,-1px); }
  50% { transform: rotate(7deg) translate(-1px,1px); }
  75% { transform: rotate(9deg) translate(1px,0); }
}

/* Scroll reveal */
.reveal {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity 0.5s ease, transform 0.5s ease;
}

.reveal.visible {
  opacity: 1;
  transform: none;
}

.reveal-stagger .reveal { transition-delay: calc(var(--i, 0) * 0.1s); }

/* ============================================================
   SCROLL MARGIN for sidebar + sections
   ============================================================ */
section[id] {
  scroll-margin-top: 2rem;
}

/* ============================================================
   RESPONSIVE
   ============================================================ */
@media (max-width: 900px) {
  .sidebar-nav {
    position: fixed;
    width: 260px;
    transform: translateX(-100%);
    transition: transform 0.25s ease;
    z-index: 300;
  }

  .sidebar-nav[open] {
    transform: translateX(0);
  }

  .main-area {
    margin-left: 0;
    max-width: 100%;
    width: 100%;
  }

  .hero-wrap {
    flex-direction: column;
    min-height: auto;
    padding: 1.5rem 1rem;
    gap: 1.2rem;
  }

  .hero-media {
    flex: none;
    max-width: 100%;
    width: 100%;
    order: 1;
  }

  .hero-copy {
    order: 2;
    text-align: center;
    padding-left: 0;
  }

  .hero-sub { margin-left: auto; margin-right: auto; }

  .content-main {
    flex-direction: column;
  }

  .content-aside {
    position: static;
    width: 100%;
    max-height: none;
    border-right: none;
    border-bottom: 2px solid var(--dark3);
    flex: none;
  }

  .aside-nav-list { flex-direction: row; flex-wrap: wrap; gap: 0.3rem; }

  .wrap {
    padding: 1.5rem 1rem;
    max-width: 100%;
  }

  .footer-top-row { flex-direction: column; }

  .footer-brand-sec {
    border-right: none;
    min-width: 0;
    padding: 1.5rem 1rem;
  }

  .footer-links-sec {
    min-width: 0;
    padding: 1.5rem 1rem;
  }

  .footer-copy-sec { padding: 0.8rem 1rem; }

  .subscribe-form { flex-direction: column; }
  .sub-input, .sub-btn { width: 100%; min-width: 0; }
}

@media (max-width: 480px) {
  .hero-h1 { font-size: 1.5rem; word-break: break-all; }
  .hero-bg-text { font-size: 5rem; }
  .sidebar-nav { width: 82vw; max-width: 280px; }
  .wrap { padding: 1rem 0.8rem; }
  .page-article h2 { font-size: 1.2rem; }
  .hero-wrap { padding: 1.2rem 0.8rem; }
}

/* ============================================================
   MOBILE TOGGLE BUTTON (injected by JS)
   ============================================================ */
.mobile-nav-btn {
  position: fixed;
  top: 8px;
  left: 12px;
  z-index: 400;
  background: var(--green);
  color: var(--dark);
  border: none;
  border-radius: 10px;
  font-size: 1.3rem;
  width: 44px;
  height: 44px;
  cursor: pointer;
  display: none;
  align-items: center;
  justify-content: center;
  font-family: var(--font-head);
  font-weight: 900;
  box-shadow: 2px 2px 0 var(--dark2);
}

@media (max-width: 900px) {
  .mobile-nav-btn { display: flex; }
}

.mobile-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(15,20,10,0.65);
  z-index: 250;
}

.mobile-overlay.active { display: block; }

/* ============================================================
   PREFERS REDUCED MOTION
   ============================================================ */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }

  .marquee-track { animation: none; }

  .reveal {
    opacity: 1;
    transform: none;
    transition: none;
  }
}
