:root {
  --ink: #0F3D3E;
  --ink-900: #0A2A2B;
  --ink-800: #0D3536;
  --ink-600: #1C5A5B;
  --ink-100: #E3ECEA;
  --ink-50: #F0F5F3;
  --gold: #C9A24B;
  --gold-700: #9C7A2E;
  --gold-100: #F5ECD7;
  --gold-50: #FBF6EA;
  --bg: #FAF8F3;
  --surface: #FFFFFF;
  --line: #E8E2D4;
  --text: #1E2B2B;
  --muted: #5B6866;
  --ok: #2F7A57;
  --ok-bg: #E7F3EC;
  --bad: #B0443A;
  --bad-bg: #FBEAE7;
  --r-sm: 10px;
  --r: 16px;
  --r-lg: 24px;
  --sh-sm: 0 1px 2px rgba(15, 61, 62, .06), 0 2px 8px rgba(15, 61, 62, .05);
  --sh: 0 12px 32px -14px rgba(15, 61, 62, .22);
  --sh-lg: 0 30px 60px -25px rgba(15, 61, 62, .38);
  --wrap: 1180px;
  --head-h: 72px;
  --font: "Plus Jakarta Sans", system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
}

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

html {
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--head-h) + 16px);
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  font-family: var(--font);
  font-size: 17px;
  line-height: 1.75;
  color: var(--text);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
}

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

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

a {
  color: var(--ink-600);
  text-decoration-thickness: 1px;
  text-underline-offset: 3px;
  transition: color .2s;
}
a:hover { color: var(--gold-700); }

h1, h2, h3, h4 {
  margin: 0 0 .6em;
  font-weight: 800;
  line-height: 1.25;
  color: var(--ink-900);
  letter-spacing: -.01em;
}
h1 { font-size: clamp(2rem, 1.4rem + 2.6vw, 3.25rem); letter-spacing: -.02em; }
h2 { font-size: clamp(1.6rem, 1.25rem + 1.4vw, 2.3rem); }
h3 { font-size: 1.2rem; }

p { margin: 0 0 1.1em; }
ul, ol { margin: 0 0 1.1em; padding-left: 1.3em; }
li { margin-bottom: .4em; }
strong { color: var(--ink-900); }

.wrap { width: min(100% - 40px, var(--wrap)); margin-inline: auto; }

.ic {
  width: 22px;
  height: 22px;
  flex: none;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.ic-wrap { display: grid; place-items: center; flex: none; }

.skip {
  position: absolute;
  left: -999px;
  top: 8px;
}
.skip:focus {
  left: 16px;
  z-index: 100;
  padding: 8px 14px;
  border-radius: 8px;
  background: var(--ink);
  color: #fff;
}

:focus-visible { outline: 3px solid var(--gold); outline-offset: 3px; }

/* ---------- Header ---------- */
.site-head {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(250, 248, 243, .9);
  -webkit-backdrop-filter: saturate(1.4) blur(12px);
  backdrop-filter: saturate(1.4) blur(12px);
  border-bottom: 1px solid transparent;
  transition: border-color .3s, box-shadow .3s;
}
.site-head.is-scrolled {
  border-color: var(--line);
  box-shadow: 0 6px 20px -14px rgba(15, 61, 62, .35);
}

.head-in {
  display: flex;
  align-items: center;
  gap: 24px;
  height: var(--head-h);
}

.brand { display: inline-flex; align-items: center; }
.brand img { height: 42px; width: auto; }

.nav { margin-left: auto; }
.nav ul { list-style: none; margin: 0; padding: 0; display: flex; gap: 2px; }
.nav li { margin: 0; }
.nav a {
  display: block;
  padding: 8px 14px;
  border-radius: 999px;
  font-weight: 600;
  font-size: .95rem;
  color: var(--ink-900);
  text-decoration: none;
  transition: background .2s, color .2s;
}
.nav a:hover,
.nav a[aria-current="page"] { background: var(--ink-100); color: var(--ink); }

.nav-toggle {
  display: none;
  align-items: center;
  justify-content: center;
  width: 46px;
  height: 46px;
  border-radius: 14px;
  border: 1px solid var(--line);
  background: var(--surface);
  color: var(--ink);
  cursor: pointer;
}

@media (max-width: 1080px) {
  .nav {
    position: fixed;
    top: var(--head-h);
    left: 0;
    right: 0;
    padding: 12px 20px 24px;
    background: var(--bg);
    border-bottom: 1px solid var(--line);
    box-shadow: var(--sh);
    opacity: 0;
    visibility: hidden;
    transform: translateY(-8px);
    transition: opacity .25s, transform .25s, visibility .25s;
  }
  .nav.is-open { opacity: 1; visibility: visible; transform: none; }
  .nav ul { flex-direction: column; gap: 4px; }
  .nav a { padding: 14px 16px; border-radius: 12px; font-size: 1.05rem; }
  .nav-toggle { display: inline-flex; margin-left: auto; }
  .site-head .head-cta { display: none; }
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 14px 26px;
  border-radius: 999px;
  border: 1.5px solid transparent;
  font-family: inherit;
  font-weight: 700;
  font-size: 1rem;
  line-height: 1.2;
  text-decoration: none;
  cursor: pointer;
  transition: transform .2s, box-shadow .2s, background .2s, color .2s, border-color .2s;
}
.btn:hover { transform: translateY(-2px); }
.btn .ic { width: 20px; height: 20px; }

.btn-gold {
  background: linear-gradient(135deg, #D9B661, var(--gold) 55%, #B48B36);
  color: var(--ink-900);
  box-shadow: 0 10px 24px -10px rgba(201, 162, 75, .85);
}
.btn-gold:hover { color: var(--ink-900); box-shadow: 0 16px 30px -10px rgba(201, 162, 75, .95); }

.btn-ink { background: var(--ink); color: #fff; }
.btn-ink:hover { background: var(--ink-800); color: #fff; }

.btn-line { border-color: var(--ink); color: var(--ink); background: transparent; }
.btn-line:hover { background: var(--ink); color: #fff; }

.btn-ghost { border-color: rgba(255, 255, 255, .35); color: #fff; background: transparent; }
.btn-ghost:hover { border-color: var(--gold); color: var(--gold); }

.btn-sm { padding: 10px 18px; font-size: .92rem; }

/* ---------- Section basics ---------- */
.sec { padding: clamp(56px, 7vw, 96px) 0; }
.sec-alt { background: var(--surface); }
.sec-tight { padding-top: 0; }

.sec-head { max-width: 760px; margin-bottom: 40px; }
.sec-head.center { margin-inline: auto; text-align: center; }
.sec-head p:last-child { margin-bottom: 0; }

.kicker {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 14px;
  font-size: .8rem;
  font-weight: 700;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--gold-700);
}
.kicker::before {
  content: "";
  width: 28px;
  height: 2px;
  border-radius: 2px;
  background: var(--gold);
}

.lead { font-size: 1.12rem; color: var(--muted); }

.chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 14px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: var(--surface);
  font-size: .88rem;
  font-weight: 600;
  color: var(--ink);
}
.chip .ic { width: 16px; height: 16px; color: var(--ok); stroke-width: 2.4; }

.card {
  padding: 28px;
  border-radius: var(--r);
  border: 1px solid var(--line);
  background: var(--surface);
  box-shadow: var(--sh-sm);
}

.note {
  display: flex;
  gap: 14px;
  padding: 18px 20px;
  border-radius: var(--r);
  background: var(--gold-50);
  border: 1px solid #EADDBA;
  border-left: 4px solid var(--gold);
}
.note .ic { margin-top: 4px; color: var(--gold-700); }
.note p:last-child { margin-bottom: 0; }

.note-warn {
  background: var(--bad-bg);
  border-color: #F0CFC9;
  border-left-color: var(--bad);
}
.note-warn .ic { color: var(--bad); }

.more {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-weight: 700;
  font-size: .95rem;
  color: var(--ink-600);
  text-decoration: none;
}
.more .ic { width: 18px; height: 18px; transition: transform .2s; }
.more:hover .ic { transform: translateX(4px); }

/* ---------- Lists ---------- */
.check-list, .cross-list { list-style: none; padding: 0; }
.check-list li, .cross-list li { position: relative; padding-left: 34px; }
.check-list li::before, .cross-list li::before {
  content: "";
  position: absolute;
  left: 0;
  top: .3em;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background-position: center;
  background-size: 13px;
  background-repeat: no-repeat;
}
.check-list li::before {
  background-color: var(--ok-bg);
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%232F7A57' stroke-width='3.2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M5 12.5l4.5 4.5L19 7.5'/%3E%3C/svg%3E");
}
.cross-list li::before {
  background-color: var(--bad-bg);
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23B0443A' stroke-width='3.2' stroke-linecap='round'%3E%3Cpath d='M6 6l12 12M18 6L6 18'/%3E%3C/svg%3E");
}

.note-list { list-style: none; padding: 0; }
.note-list li { position: relative; padding-left: 34px; }
.note-list li::before {
  content: "!";
  position: absolute;
  left: 0;
  top: .3em;
  display: grid;
  place-items: center;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: var(--gold-100);
  color: var(--gold-700);
  font-weight: 800;
  font-size: .8rem;
  line-height: 1;
}

/* ---------- Tables ---------- */
.table-wrap {
  overflow-x: auto;
  border-radius: var(--r);
  border: 1px solid var(--line);
  background: var(--surface);
  -webkit-overflow-scrolling: touch;
}
table { width: 100%; min-width: 520px; border-collapse: collapse; font-size: .97rem; }
th, td { padding: 14px 18px; text-align: left; border-bottom: 1px solid var(--line); vertical-align: top; }
thead th { background: var(--ink); color: #fff; font-weight: 700; }
tbody tr:last-child td { border-bottom: 0; }
tbody tr:nth-child(even) { background: var(--ink-50); }
tbody th { font-weight: 700; color: var(--ink-900); }

/* ---------- Inner page hero ---------- */
.page-hero {
  position: relative;
  overflow: hidden;
  padding: clamp(28px, 4vw, 48px) 0 clamp(48px, 6vw, 80px);
  background:
    radial-gradient(circle at 92% 8%, rgba(201, 162, 75, .2), transparent 38%),
    linear-gradient(180deg, var(--ink-50), var(--bg));
  border-bottom: 1px solid var(--line);
}
.page-hero .crumbs { margin-bottom: 28px; }
.page-hero h1 { font-size: clamp(1.9rem, 1.35rem + 2.2vw, 2.9rem); }
.page-hero .lead { max-width: 640px; }
.page-hero .meta-bar { margin-top: 24px; }

/* ---------- Breadcrumb & meta ---------- */
.crumbs { font-size: .88rem; color: var(--muted); }
.crumbs ol { list-style: none; display: flex; flex-wrap: wrap; gap: 6px; margin: 0; padding: 0; }
.crumbs li { margin: 0; }
.crumbs li + li::before { content: "/"; margin-right: 6px; color: #B7AE98; }
.crumbs a { color: var(--muted); text-decoration: none; }
.crumbs a:hover { color: var(--gold-700); }

.meta-bar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px 22px;
  font-size: .92rem;
  color: var(--muted);
}
.meta-bar span { display: inline-flex; align-items: center; gap: 8px; }
.meta-bar .ic { width: 18px; height: 18px; color: var(--gold-700); }
.meta-bar a { color: var(--ink); font-weight: 700; text-decoration: none; }

.toc { display: flex; flex-wrap: wrap; gap: 10px; list-style: none; margin: 0; padding: 0; }
.toc li { margin: 0; }
.toc a {
  display: inline-block;
  padding: 8px 16px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: var(--surface);
  font-weight: 600;
  font-size: .92rem;
  color: var(--ink);
  text-decoration: none;
  transition: border-color .2s, background .2s;
}
.toc a:hover { border-color: var(--gold); background: var(--gold-50); color: var(--ink); }

/* ---------- Tabs ---------- */
.tabs { max-width: 980px; margin: 0 auto; }
.tabs-list {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 18px;
  padding: 6px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: var(--bg);
}
html:not(.js) .tabs-list { display: none; }
.tabs-list button {
  flex: 1 1 auto;
  padding: 12px 18px;
  border: 0;
  border-radius: 999px;
  background: transparent;
  font-family: inherit;
  font-weight: 700;
  font-size: .95rem;
  color: var(--ink);
  cursor: pointer;
  transition: background .2s, color .2s;
}
.tabs-list button:hover { background: var(--ink-100); }
.tabs-list button[aria-selected="true"] { background: var(--ink); color: #fff; }

.tab-panel {
  padding: 30px 32px;
  border-radius: var(--r-lg);
  border: 1px solid var(--line);
  background: var(--surface);
  box-shadow: var(--sh-sm);
}
html:not(.js) .tab-panel + .tab-panel { margin-top: 18px; }

.path {
  display: inline;
  padding: 2px 8px;
  border-radius: 6px;
  background: var(--ink-50);
  font-weight: 600;
  color: var(--ink);
}

@media (max-width: 600px) {
  .tabs-list { border-radius: var(--r); }
  .tabs-list button { flex: 1 1 45%; }
  .tab-panel { padding: 24px 20px; }
}

/* ---------- FAQ accordion ---------- */
.faq { display: grid; gap: 14px; }
.faq details {
  border-radius: var(--r);
  border: 1px solid var(--line);
  background: var(--surface);
  transition: box-shadow .25s, border-color .25s;
}
.faq details[open] { border-color: #D9CBA4; box-shadow: var(--sh); }
.faq summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 20px 24px;
  list-style: none;
  cursor: pointer;
  font-weight: 700;
  font-size: 1.05rem;
  line-height: 1.45;
  color: var(--ink-900);
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {
  content: "";
  flex: none;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: var(--ink-100) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%230F3D3E' stroke-width='2.6' stroke-linecap='round'%3E%3Cpath d='M12 5v14M5 12h14'/%3E%3C/svg%3E") center / 14px no-repeat;
  transition: transform .25s, background-color .25s;
}
.faq details[open] summary::after { transform: rotate(45deg); background-color: var(--gold-100); }
.faq .ans { padding: 0 24px 22px; }
.faq .ans p:last-child, .faq .ans ul:last-child, .faq .ans ol:last-child { margin-bottom: 0; }
.faq-narrow { max-width: 860px; margin-inline: auto; }
.faq-more { margin-top: 28px; text-align: center; }

/* ---------- Author box ---------- */
.author-box {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 24px;
  align-items: start;
  padding: 32px;
  border-radius: var(--r-lg);
  border: 1px solid var(--line);
  background: var(--surface);
  box-shadow: var(--sh-sm);
}
.avatar {
  display: grid;
  place-items: center;
  width: 76px;
  height: 76px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--ink), var(--ink-600));
  color: var(--gold);
  font-weight: 800;
  font-size: 1.4rem;
  box-shadow: 0 0 0 5px var(--gold-50);
}
.author-box h3 { margin-bottom: .2em; }
.author-role { display: block; margin-bottom: 12px; font-size: .9rem; font-weight: 600; color: var(--gold-700); }
.author-box p { color: var(--muted); }
.author-links { display: flex; flex-wrap: wrap; gap: 10px 20px; }
@media (max-width: 600px) {
  .author-box { grid-template-columns: 1fr; padding: 24px; }
}

/* ---------- Method note ---------- */
.method {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 22px;
  align-items: start;
  padding: 28px 30px;
  border-radius: var(--r-lg);
  border: 1px solid #EADDBA;
  background: var(--gold-50);
}
.method .ic-wrap { width: 56px; height: 56px; border-radius: 50%; background: var(--ink); color: var(--gold); }
.method h2 { margin-bottom: .4em; font-size: 1.25rem; }
.method p { margin-bottom: .6em; color: var(--muted); }
.method p:last-child { margin-bottom: 0; }
@media (max-width: 600px) { .method { grid-template-columns: 1fr; padding: 24px; } }

/* ---------- SHA-256 box ---------- */
.hash-box {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 8px 16px;
  align-items: center;
  padding: 18px 20px;
  border-radius: var(--r);
  border: 1px solid var(--line);
  background: var(--surface);
}
.hash-box small { grid-column: 1 / -1; font-size: .78rem; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--gold-700); }
.hash-box code {
  font-family: ui-monospace, SFMono-Regular, Consolas, monospace;
  font-size: .9rem;
  line-height: 1.6;
  letter-spacing: .02em;
  color: var(--ink-900);
  overflow-wrap: anywhere;
}
@media (max-width: 560px) {
  .hash-box { grid-template-columns: 1fr; }
  .hash-box .btn { justify-self: start; }
}

/* ---------- CTA band ---------- */
.cta-band {
  position: relative;
  overflow: hidden;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: clamp(36px, 5vw, 64px);
  border-radius: var(--r-lg);
  background:
    radial-gradient(circle at 88% 18%, rgba(201, 162, 75, .38), transparent 45%),
    linear-gradient(135deg, var(--ink-900), var(--ink) 60%, var(--ink-600));
  color: #DCE7E4;
}
.cta-band h2 { color: #fff; margin-bottom: .3em; }
.cta-band p { margin: 0; color: #BFD0CC; max-width: 560px; }
.cta-actions { display: flex; flex-wrap: wrap; gap: 12px; }

/* ---------- Footer ---------- */
.site-foot {
  padding: 72px 0 0;
  background: var(--ink-900);
  color: #B9C9C6;
  font-size: .95rem;
}
.foot-grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr 1.1fr; gap: 40px; }
.foot-logo {
  display: inline-block;
  margin-bottom: 18px;
  padding: 10px 14px;
  border-radius: 12px;
  background: var(--bg);
}
.foot-logo img { height: 36px; width: auto; }
.site-foot h3 { margin-bottom: 16px; font-size: 1rem; color: #fff; letter-spacing: .02em; }
.site-foot ul { list-style: none; margin: 0; padding: 0; }
.site-foot li { margin-bottom: 10px; }
.site-foot a { color: #B9C9C6; text-decoration: none; }
.site-foot a:hover { color: var(--gold); }
.foot-contact li { display: flex; gap: 10px; align-items: flex-start; }
.foot-contact .ic { width: 18px; height: 18px; margin-top: 4px; color: var(--gold); }

.foot-bottom {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 14px 24px;
  margin-top: 56px;
  padding: 24px 0 32px;
  border-top: 1px solid rgba(255, 255, 255, .08);
  font-size: .85rem;
  color: #8FA5A1;
}
.foot-bottom p { margin: 0; }
.foot-age { display: flex; align-items: center; gap: 12px; max-width: 640px; }
.badge-18 {
  display: inline-grid;
  place-items: center;
  flex: none;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  border: 2px solid var(--gold);
  color: var(--gold);
  font-weight: 800;
  font-size: .85rem;
}

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

/* ---------- Mobile download bar ---------- */
.m-bar {
  position: fixed;
  left: 12px;
  right: 12px;
  bottom: 12px;
  z-index: 40;
  display: none;
  align-items: center;
  gap: 12px;
  padding: 10px 10px 10px 18px;
  border-radius: 999px;
  background: var(--ink-900);
  color: #fff;
  box-shadow: var(--sh-lg);
  transform: translateY(140%);
  transition: transform .35s ease;
}
.m-bar.is-show { transform: none; }
.m-bar strong { display: block; font-size: .95rem; line-height: 1.2; color: #fff; }
.m-bar small { font-size: .78rem; color: #9FB4B0; }
.m-bar > div { min-width: 0; }
.m-bar .btn { flex: none; margin-left: auto; white-space: nowrap; }

@media (max-width: 768px) {
  body { font-size: 16.5px; padding-bottom: 84px; }
  .m-bar { display: flex; }
}

/* ---------- Reveal on scroll ---------- */
.js .reveal { opacity: 0; transform: translateY(24px); transition: opacity .7s ease, transform .7s ease; }
.js .reveal.is-in { opacity: 1; transform: none; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .js .reveal { opacity: 1; transform: none; transition: none; }
  *, *::before, *::after { animation: none !important; }
}
