@font-face {
  font-family: "General Sans";
  src: url("src/assets/Font/fonts/GeneralSans-Variable.woff2") format("woff2");
  font-weight: 200 700;
  font-style: normal;
  font-display: swap;
}

:root {
  --bg: #f4f7fa;
  --fg: #0a1019;
  --ink: #0a1019;
  --light: #f4f7fa;
  --muted: rgba(10, 16, 25, 0.55);
  --line: rgba(10, 16, 25, 0.12);
  --radius: 0;
  --shell: 88rem;
  --ease-hover: cubic-bezier(0.2, 0.8, 0.2, 1);
  --ease-out: cubic-bezier(0.215, 0.61, 0.355, 1);
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html { font-size: 16px; -webkit-font-smoothing: antialiased; }
body {
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
  background: var(--bg);
  color: var(--fg);
  font-family: "General Sans", sans-serif;
}
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; background: none; border: none; cursor: pointer; }
img { display: block; max-width: 100%; }
:focus-visible { outline: 2px solid var(--fg); outline-offset: 2px; }

@media (max-width: 1920px) { html { font-size: 0.833333vw; } }
@media (max-width: 1440px) { html { font-size: 1.111111vw; } }
@media (max-width: 1024px) { html { font-size: 1.5625vw; } }
@media (max-width: 640px)  { html { font-size: 4.444444vw; } }

.skip {
  position: absolute; left: 1rem; top: 1rem; z-index: 60;
  transform: translateY(-150%);
  background: var(--ink); color: var(--light);
  padding: 0.5rem 1rem; font-size: 0.875rem;
}
.skip:focus { transform: none; position: fixed; }

.header {
  background: var(--ink);
  color: var(--light);
}
.header-inner {
  max-width: var(--shell);
  margin-inline: auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
  padding: 1.25rem;
}
.brand img { height: 1.75rem; width: auto; }
.brand:hover { transform: scale(1.04); }
.back {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  border: 1px solid rgba(244, 247, 250, 0.18);
  background: rgba(10, 16, 25, 0.35);
  padding: 0.5rem 1rem;
  font-size: 0.75rem;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--light);
  transition: background 0.35s var(--ease-hover);
}
.back:hover { background: rgba(244, 247, 250, 0.1); }
.back svg { width: 0.875rem; height: 0.875rem; }

.main {
  flex: 1;
  max-width: var(--shell);
  width: 100%;
  margin-inline: auto;
  padding: 2.5rem 1.25rem 3rem;
}
.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  border: 1px solid var(--line);
  padding: 0.375rem 1rem;
  margin-bottom: 1rem;
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--muted);
}
.eyebrow .dot {
  width: 0.375rem;
  height: 0.375rem;
  background: var(--muted);
}
h1 {
  max-width: 22ch;
  font-size: 2rem;
  font-weight: 600;
  letter-spacing: -0.02em;
  line-height: 1.15;
  text-wrap: balance;
}

.docs {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 1.25rem;
  margin: 1.5rem 0 2rem;
}
.docs a {
  font-size: 0.875rem;
  color: var(--muted);
  box-shadow: inset 0 -1px 0 transparent;
  transition: color 0.3s var(--ease-hover), box-shadow 0.3s var(--ease-hover);
}
.docs a:hover { color: var(--fg); }
.docs a[aria-current="page"] {
  color: var(--fg);
  box-shadow: inset 0 -1px 0 var(--fg);
}

.toolbar {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 0.5rem;
  padding: 0.65rem 1rem;
  background: var(--light);
  border: 1px solid var(--line);
  border-bottom: none;
}
.tool-btn {
  width: 2rem;
  height: 2rem;
  display: grid;
  place-items: center;
  border: 1px solid var(--line);
  color: var(--ink);
  transition: background 0.3s var(--ease-hover);
}
.tool-btn:hover:not(:disabled) { background: rgba(10, 16, 25, 0.06); }
.tool-btn:disabled { opacity: 0.35; cursor: default; }
.tool-btn svg { width: 0.875rem; height: 0.875rem; }

.viewer {
  overflow: auto;
  background: #e4e9ee;
  border: 1px solid var(--line);
  min-height: 70vh;
  height: calc(100dvh - 18rem);
}
.viewer-pages {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1rem;
  padding: 1.5rem 1rem 2.5rem;
}
.viewer-pages canvas {
  display: block;
  max-width: none;
  background: #fff;
  box-shadow: 0 8px 24px rgba(10, 16, 25, 0.08);
}
.viewer-status {
  padding: 3rem 1.25rem;
  text-align: center;
  font-size: 0.875rem;
  color: var(--muted);
}

.foot {
  background: var(--ink);
  color: rgba(244, 247, 250, 0.45);
  padding: 1.25rem;
  font-size: 0.75rem;
  text-align: center;
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition: none !important; }
}
