﻿:root {
  --bg: #f8fafc;
  --card: #ffffff;
  --text: #172033;
  --muted: #64748b;
  --line: #e2e8f0;
  --teal: #4AC4F3;
  --teal-dark: #0796c9;
  --blue: #0284c7;
  --soft-shadow: 0 18px 45px rgba(15, 23, 42, .08);
  --small-shadow: 0 8px 22px rgba(15, 23, 42, .05);
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  min-height: 100vh;
  font-family: "Roboto", Arial, sans-serif;
  color: var(--text);
  background:
    radial-gradient(circle at 8% 0%, rgba(14, 165, 233, .12), transparent 28rem),
    radial-gradient(circle at 92% 5%, rgba(74, 196, 243, .18), transparent 30rem),
    var(--bg);
}

a { color: inherit; }

.docs-header {
  position: sticky;
  top: 0;
  z-index: 40;
  border-bottom: 1px solid rgba(226, 232, 240, .9);
  background: rgba(255, 255, 255, .92);
  backdrop-filter: blur(16px);
}

.header-inner {
  max-width: 1240px;
  margin: 0 auto;
  padding: 14px 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
}

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

.logo-link img {
  width: auto;
  height: 40px;
  display: block;
}

.top-nav {
  display: flex;
  align-items: center;
  gap: 8px;
  overflow-x: auto;
  scrollbar-width: none;
}

.top-nav::-webkit-scrollbar { display: none; }

.top-nav a {
  white-space: nowrap;
  border-radius: 999px;
  padding: 10px 14px;
  color: #475569;
  font-size: 14px;
  font-weight: 700;
  text-decoration: none;
  transition: 160ms ease;
}

.top-nav a:hover {
  color: var(--teal-dark);
  background: #eaf8fe;
}

.page {
  width: min(1240px, calc(100% - 32px));
  margin: 0 auto;
  padding: 28px 0 56px;
}

.hero {
  display: grid;
  grid-template-columns: minmax(0, 1.25fr) minmax(280px, .75fr);
  gap: 24px;
  align-items: stretch;
  border: 1px solid var(--line);
  border-radius: 28px;
  background: rgba(255, 255, 255, .9);
  box-shadow: var(--soft-shadow);
  padding: 28px;
}

.hero-copy {
  display: flex;
  flex-direction: column;
  justify-content: center;
  min-height: 260px;
}

.eyebrow {
  width: fit-content;
  border-radius: 999px;
  padding: 7px 12px;
  background: #eaf8fe;
  color: var(--teal-dark);
  font-size: 12px;
  font-weight: 800;
  letter-spacing: .12em;
  text-transform: uppercase;
}

.hero h1 {
  margin: 18px 0 0;
  max-width: 820px;
  font-size: clamp(34px, 5vw, 56px);
  line-height: 1.07;
  letter-spacing: 0;
  font-weight: 800;
}

.hero p {
  margin: 16px 0 0;
  max-width: 720px;
  color: var(--muted);
  font-size: 17px;
  line-height: 1.7;
}

.hero-search {
  width: min(560px, 100%);
  margin-top: 24px;
}

.hero-search label,
.sidebar-search label {
  display: block;
  margin-bottom: 8px;
  color: #334155;
  font-size: 13px;
  font-weight: 800;
}

.hero-search input,
.sidebar-search input {
  width: 100%;
  height: 48px;
  border: 1px solid #cbd5e1;
  border-radius: 16px;
  background: #fff;
  color: var(--text);
  outline: none;
  padding: 0 15px;
  transition: 160ms ease;
}

.hero-search input:focus,
.sidebar-search input:focus {
  border-color: var(--teal);
  box-shadow: 0 0 0 4px rgba(74, 196, 243, .18);
}

.quick-panel {
  border: 1px solid #c7ecfb;
  border-radius: 24px;
  background: linear-gradient(145deg, #eff6ff, #ecfeff);
  padding: 20px;
  display: grid;
  gap: 12px;
}

.quick-item {
  display: flex;
  align-items: center;
  gap: 12px;
  border: 1px solid rgba(226, 232, 240, .92);
  border-radius: 18px;
  background: rgba(255, 255, 255, .78);
  padding: 15px;
  box-shadow: 0 4px 12px rgba(15, 23, 42, .04);
}

.quick-icon {
  font-size: 24px;
  line-height: 1;
}

.quick-item strong {
  display: block;
  font-size: 15px;
  line-height: 1.35;
}

.module-section {
  margin-top: 24px;
}

.section-heading {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin-bottom: 18px;
}

.section-heading span {
  color: var(--teal-dark);
  font-size: 13px;
  font-weight: 800;
  letter-spacing: .12em;
  text-transform: uppercase;
}

.section-heading h2 {
  margin: 0;
  font-size: 28px;
  line-height: 1.2;
  font-weight: 800;
}

.module-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
}

.module-card {
  position: relative;
  overflow: hidden;
  min-height: 258px;
  border: 1px solid var(--line);
  border-radius: 24px;
  background: var(--card);
  padding: 22px;
  box-shadow: var(--small-shadow);
  display: flex;
  flex-direction: column;
  transition: 180ms ease;
}

.module-card::after {
  content: "";
  position: absolute;
  right: -44px;
  top: -48px;
  width: 160px;
  height: 160px;
  border-radius: 999px;
  background: rgba(14, 165, 233, .09);
  transition: 180ms ease;
}

.module-card:hover {
  transform: translateY(-3px);
  border-color: #93c5fd;
  box-shadow: var(--soft-shadow);
}

.module-card:hover::after {
  background: rgba(74, 196, 243, .18);
  transform: scale(1.04);
}

.module-icon {
  position: relative;
  z-index: 1;
  display: grid;
  place-items: center;
  width: 60px;
  height: 60px;
  border-radius: 20px;
  background: linear-gradient(145deg, #eaf8fe, #eff6ff);
  box-shadow: inset 0 0 0 1px rgba(226, 232, 240, .9);
  font-size: 30px;
}

.module-card h3 {
  position: relative;
  z-index: 1;
  margin: 18px 0 0;
  font-size: 23px;
  line-height: 1.2;
  font-weight: 800;
}

.module-card p {
  position: relative;
  z-index: 1;
  margin: 12px 0 0;
  color: var(--muted);
  line-height: 1.65;
}

.module-footer {
  position: relative;
  z-index: 1;
  margin-top: auto;
  padding-top: 18px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.badge {
  display: inline-flex;
  align-items: center;
  min-height: 32px;
  border-radius: 999px;
  background: #eaf8fe;
  color: var(--teal-dark);
  padding: 6px 11px;
  font-size: 13px;
  font-weight: 800;
}

.open-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  background: var(--teal);
  color: #fff;
  padding: 9px 13px;
  font-size: 14px;
  font-weight: 800;
  text-decoration: none;
  transition: 160ms ease;
}

.open-link:hover {
  background: var(--teal-dark);
}

.notice-card,
.empty-card,
.error-card,
.content-message {
  border: 1px solid var(--line);
  border-radius: 20px;
  background: #fff;
  padding: 18px;
  color: var(--muted);
}

.notice-card {
  grid-column: 1 / -1;
  border-color: #fecaca;
  background: #fff7f7;
  color: #b91c1c;
}

.notice-card span {
  display: block;
  margin-top: 6px;
  color: #7f1d1d;
  font-size: 14px;
}

.empty-card {
  grid-column: 1 / -1;
}

.category-video {
  width: min(1240px, calc(100% - 32px));
  margin: 24px auto 0;
}

.category-video-inner {
  border: 1px solid var(--line);
  border-radius: 28px;
  background: #fff;
  box-shadow: var(--soft-shadow);
  overflow: hidden;
}

.category-video-copy {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 18px 22px;
  border-bottom: 1px solid var(--line);
  background: linear-gradient(145deg, #ffffff, #f0f9ff);
}

.category-video-copy span {
  color: var(--teal-dark);
  font-size: 13px;
  font-weight: 800;
  letter-spacing: .12em;
  text-transform: uppercase;
}

.category-video-copy strong {
  color: #0f172a;
  font-size: 18px;
  line-height: 1.3;
  text-align: right;
}

.category-video-frame {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 9;
  background: #020617;
}

.category-video-frame iframe,
.category-video-frame video {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: 0;
  display: block;
}

.error-card {
  border-color: #fecaca;
  background: #fff7f7;
  color: #b91c1c;
}

.guide-layout {
  display: grid;
  grid-template-columns: 340px minmax(0, 1fr);
  gap: 22px;
  align-items: start;
}

.sidebar {
  position: sticky;
  top: 88px;
  max-height: calc(100vh - 110px);
  overflow: auto;
  border: 1px solid var(--line);
  border-radius: 24px;
  background: rgba(255, 255, 255, .94);
  box-shadow: var(--soft-shadow);
  padding: 16px;
}

.back-link {
  display: inline-flex;
  align-items: center;
  border: 1px solid #cbd5e1;
  border-radius: 999px;
  background: #fff;
  color: #334155;
  padding: 9px 13px;
  font-size: 14px;
  font-weight: 800;
  text-decoration: none;
  transition: 160ms ease;
}

.back-link:hover {
  border-color: #7dd3fc;
  background: #f0f9ff;
  color: var(--teal-dark);
}

.category-box {
  margin-top: 14px;
  border: 1px solid #c7ecfb;
  border-radius: 22px;
  background: linear-gradient(145deg, #eaf8fe, #eff6ff);
  padding: 18px;
}

.category-box small {
  color: var(--teal-dark);
  font-size: 12px;
  font-weight: 900;
  letter-spacing: .14em;
  text-transform: uppercase;
}

.category-box h1 {
  margin: 10px 0 0;
  font-size: 24px;
  line-height: 1.2;
  font-weight: 800;
}

.category-box p {
  margin: 10px 0 0;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.6;
}

.sidebar-search {
  margin-top: 18px;
}

.article-nav {
  margin-top: 14px;
  display: grid;
  gap: 9px;
}

.article-link {
  width: 100%;
  text-align: left;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: #fff;
  padding: 13px;
  cursor: pointer;
  display: grid;
  grid-template-columns: 34px minmax(0, 1fr);
  gap: 10px;
  transition: 160ms ease;
}

.article-link:hover,
.article-link.active {
  border-color: #7dd3fc;
  background: #f0f9ff;
}

.article-index {
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border-radius: 12px;
  background: #eef2ff;
  color: #2563eb;
  font-size: 12px;
  font-weight: 800;
}

.article-link strong {
  color: #1e293b;
  line-height: 1.4;
  font-size: 14px;
  font-weight: 800;
}

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

.article-card {
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 26px;
  background: #fff;
  box-shadow: var(--soft-shadow);
}

.article-head {
  border-bottom: 1px solid var(--line);
  background: linear-gradient(145deg, #fff, #ecfeff);
  padding: 28px;
}

.article-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  color: var(--teal-dark);
  font-size: 14px;
  font-weight: 800;
}

.article-meta span {
  border-radius: 999px;
  background: #eaf8fe;
  padding: 6px 10px;
}

.article-title {
  margin: 14px 0 0;
  font-size: clamp(30px, 4vw, 46px);
  line-height: 1.14;
  letter-spacing: 0;
  font-weight: 800;
}

.article-intro {
  max-width: 760px;
  margin: 14px 0 0;
  color: var(--muted);
  line-height: 1.7;
}

.article-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 20px;
}

.btn-primary,
.btn-secondary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 42px;
  border-radius: 999px;
  padding: 10px 15px;
  font-size: 14px;
  font-weight: 800;
  text-decoration: none;
  cursor: pointer;
  transition: 160ms ease;
}

.btn-primary {
  border: 1px solid var(--teal);
  background: var(--teal);
  color: #fff;
}

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

.btn-secondary {
  border: 1px solid #cbd5e1;
  background: #fff;
  color: #334155;
}

.btn-secondary:hover {
  border-color: #7dd3fc;
  background: #f0f9ff;
  color: var(--teal-dark);
}

.article-content {
  padding: 30px;
  color: #334155;
  font-size: 16px;
  line-height: 1.85;
}

.article-content > *:first-child { margin-top: 0; }
.article-content > *:last-child { margin-bottom: 0; }

.article-content h1,
.article-content h2,
.article-content h3,
.article-content h4 {
  color: #0f172a;
  line-height: 1.28;
  font-weight: 800;
}

.article-content h2 { font-size: 26px; margin: 28px 0 12px; }
.article-content h3 { font-size: 22px; margin: 24px 0 10px; }
.article-content p { margin: 12px 0; }
.article-content ul,
.article-content ol { padding-left: 24px; }
.article-content li { margin: 6px 0; }

.article-content a {
  color: var(--blue);
  font-weight: 700;
  text-decoration: none;
}

.article-content a:hover { text-decoration: underline; }

.article-content figure {
  margin: 22px 0;
  border: 1px solid var(--line);
  border-radius: 22px;
  background: #f8fafc;
  padding: 10px;
}

.article-content img {
  display: block;
  width: 100%;
  max-width: 100%;
  height: auto;
  border-radius: 16px;
  background: #fff;
  cursor: zoom-in;
}

.article-content table {
  width: 100%;
  border-collapse: collapse;
  overflow: hidden;
  border-radius: 14px;
}

.article-content th,
.article-content td {
  border: 1px solid var(--line);
  padding: 10px;
  vertical-align: top;
}

.article-content th {
  background: #f8fafc;
  color: #0f172a;
}

.hidden { display: none !important; }

.thin-scrollbar::-webkit-scrollbar {
  width: 8px;
  height: 8px;
}

.thin-scrollbar::-webkit-scrollbar-thumb {
  background: #cbd5e1;
  border-radius: 999px;
}

.image-modal {
  position: fixed;
  inset: 0;
  z-index: 80;
  display: none;
  align-items: center;
  justify-content: center;
  background: rgba(2, 6, 23, .86);
  padding: 18px;
}

.image-modal.open { display: flex; }

.image-modal button {
  position: absolute;
  top: 16px;
  right: 16px;
  border: 0;
  border-radius: 999px;
  background: #fff;
  color: #0f172a;
  padding: 10px 15px;
  font-weight: 800;
  cursor: pointer;
}

.image-modal img {
  max-width: 94vw;
  max-height: 88vh;
  border-radius: 16px;
  background: #fff;
}

@media (max-width: 980px) {
  .header-inner {
    padding: 12px 16px;
    align-items: flex-start;
    flex-direction: column;
  }

  .top-nav {
    width: 100%;
  }

  .page {
    width: min(100% - 24px, 1240px);
    padding: 18px 0 42px;
  }

  .category-video {
    width: min(100% - 24px, 1240px);
    margin-top: 14px;
  }

  .category-video-copy {
    align-items: flex-start;
    flex-direction: column;
  }

  .category-video-copy strong {
    text-align: left;
  }

  .hero {
    grid-template-columns: 1fr;
    padding: 20px;
  }

  .hero-copy {
    min-height: unset;
  }

  .module-grid {
    grid-template-columns: 1fr;
  }

  .guide-layout {
    grid-template-columns: 1fr;
  }

  .sidebar {
    position: static;
    max-height: none;
  }

  .article-head,
  .article-content {
    padding: 20px;
  }
}

