/* MY HUB — design system
   Kind: software / personal digital hub
   Swiss minimal · system fonts · one system · one section per screen
   Tokens, typography, components, pages. Responsive rules in responsive.css. */

:root {
  /* palette — black / white / grey, one accent */
  --paper: #FFFFFF;
  --paper-2: #F7F7F5;
  --ink: #111111;
  --ink-2: #555550;
  --ink-3: #8A8A85;
  --line: #E4E4DF;
  --accent: #111111;
  --accent-on: #FFFFFF;
  --ok: #1F8A4C;
  --dev: #B7791F;
  --arch: #8A8A85;

  /* system */
  --radius: 10px;
  --radius-sm: 6px;
  --wrap: 1200px;
  --gutter: 40px;
  --head-h: 64px;

  /* type — system stack, no webfonts */
  --sans: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue",
          Arial, "Noto Sans SC", "PingFang SC", "Microsoft YaHei", sans-serif;
  --mono: ui-monospace, SFMono-Regular, "SF Mono", Menlo, Consolas, "Liberation Mono", monospace;
}

html[data-theme="dark"] {
  --paper: #0B0B0C;
  --paper-2: #141416;
  --ink: #F5F5F3;
  --ink-2: #B9B9B3;
  --ink-3: #8A8A85;
  --line: #2B2B2E;
  --accent: #F5F5F3;
  --accent-on: #0B0B0C;
  --ok: #6FD39A;
  --dev: #E3B35C;
  --arch: #9A9A95;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  min-height: 100vh;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  transition: background-color .18s ease, color .18s ease;
}
a { color: inherit; text-decoration: none; }
img { max-width: 100%; display: block; }
button, input, select { font: inherit; color: inherit; }
button { cursor: pointer; }
:focus-visible { outline: 2px solid var(--ink); outline-offset: 3px; }
input:focus, select:focus { outline: 2px solid var(--ink); outline-offset: 2px; }
::selection { background: var(--ink); color: var(--paper); }

.wrap { width: min(100% - var(--gutter) * 2, var(--wrap)); margin-inline: auto; }
.skip-link { position: absolute; left: 16px; top: -60px; z-index: 200; background: var(--ink); color: var(--paper); padding: 10px 16px; border-radius: var(--radius-sm); }
.skip-link:focus { top: 12px; }
.mono, .eyebrow, .label { font-family: var(--mono); }
.eyebrow { font-size: 11px; letter-spacing: .1em; text-transform: uppercase; color: var(--ink-3); margin: 0; }

/* ---------- header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 50;
  height: var(--head-h);
  background: color-mix(in srgb, var(--paper) 92%, transparent);
  backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--line);
}
.site-header__inner { height: 100%; display: flex; align-items: center; justify-content: space-between; gap: 24px; }
.brand { display: inline-flex; align-items: center; gap: 10px; font-weight: 700; font-size: 15px; letter-spacing: -.02em; white-space: nowrap; }
.brand-mark { width: 28px; height: 28px; border: 1.5px solid var(--ink); border-radius: var(--radius-sm); display: grid; place-items: center; font-family: var(--mono); font-size: 10px; font-weight: 700; letter-spacing: -.04em; }
.nav { display: flex; align-items: center; gap: 26px; }
.nav a { font-size: 13.5px; color: var(--ink-2); padding: 6px 0; border-bottom: 2px solid transparent; white-space: nowrap; transition: color .15s ease, border-color .15s ease; }
.nav a:hover { color: var(--ink); }
.nav a[aria-current="page"] { color: var(--ink); border-bottom-color: var(--ink); }
.header-actions { display: flex; align-items: center; gap: 8px; }
.theme-btn { display: inline-flex; align-items: center; gap: 7px; height: 36px; padding: 0 11px; border: 1px solid var(--line); border-radius: var(--radius-sm); background: var(--paper); font-size: 12.5px; white-space: nowrap; transition: border-color .15s ease; }
.theme-btn:hover { border-color: var(--ink); }
.theme-btn svg { width: 15px; height: 15px; fill: none; stroke: currentColor; stroke-width: 1.6; }
.theme-btn .icon-sun { display: none; }
html[data-theme="dark"] .theme-btn .icon-moon { display: none; }
html[data-theme="dark"] .theme-btn .icon-sun { display: block; }
.nav-toggle { display: none; width: 38px; height: 38px; border: 1px solid var(--line); border-radius: var(--radius-sm); background: var(--paper); align-items: center; justify-content: center; }
.nav-toggle span { display: block; width: 17px; height: 1.5px; background: var(--ink); position: relative; }
.nav-toggle span::before, .nav-toggle span::after { content: ""; position: absolute; left: 0; width: 17px; height: 1.5px; background: var(--ink); transition: transform .18s ease; }
.nav-toggle span::before { top: -5px; }
.nav-toggle span::after { top: 5px; }
.nav-toggle[aria-expanded="true"] span { background: transparent; }
.nav-toggle[aria-expanded="true"] span::before { transform: translateY(5px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] span::after { transform: translateY(-5px) rotate(-45deg); }

/* ---------- buttons: one pair ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 9px;
  min-height: 46px; padding: 0 20px;
  border-radius: var(--radius-sm); border: 1px solid var(--ink);
  font-size: 13.5px; font-weight: 600; letter-spacing: -.01em;
  transition: transform .15s ease, background-color .15s ease, color .15s ease;
}
.btn:hover { transform: translateY(-2px); }
.btn:active { transform: translateY(0); }
.btn--primary { background: var(--accent); color: var(--accent-on); }
.btn--ghost { background: transparent; color: var(--ink); }
.btn--ghost:hover { background: var(--paper-2); }
.btn--small { min-height: 38px; padding: 0 14px; font-size: 12.5px; }
.btn__arrow { font-size: 16px; line-height: 1; }

/* ---------- hero entrance (once on load) ---------- */
[data-enter] .enter { opacity: 0; transform: translateY(14px); }
[data-enter].is-entered .enter { opacity: 1; transform: none; transition: opacity .55s ease, transform .55s cubic-bezier(.2,.8,.2,1); }
[data-enter].is-entered .enter:nth-child(2) { transition-delay: .07s; }
[data-enter].is-entered .enter:nth-child(3) { transition-delay: .14s; }
[data-enter].is-entered .enter:nth-child(4) { transition-delay: .21s; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  [data-enter] .enter { opacity: 1; transform: none; }
  *, *::before, *::after { animation-duration: .01ms !important; transition-duration: .01ms !important; }
}

/* ---------- home hero: split ---------- */
.hero {
  min-height: calc(100svh - var(--head-h));
  display: flex; align-items: center;
  padding: 64px 0 72px;
  border-bottom: 1px solid var(--line);
}
.hero__grid { display: grid; grid-template-columns: 1fr 1.05fr; gap: 64px; align-items: center; }
.hero h1 {
  margin: 20px 0 0;
  font-size: clamp(46px, 6.2vw, 82px);
  line-height: .98; font-weight: 700; letter-spacing: -.055em;
}
.hero__lead { margin: 26px 0 0; max-width: 46ch; color: var(--ink-2); font-size: clamp(16px, 1.6vw, 18px); }
.hero__actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 34px; }

/* real product UI window — the directory itself */
.window { border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; background: var(--paper); box-shadow: 0 24px 60px -32px rgba(0,0,0,.22); }
.window__bar { display: flex; align-items: center; gap: 12px; height: 38px; padding: 0 14px; background: var(--paper-2); border-bottom: 1px solid var(--line); }
.window__dots { display: flex; gap: 5px; }
.window__dots i { width: 8px; height: 8px; border-radius: 50%; background: var(--line); }
.window__path { font-family: var(--mono); font-size: 10.5px; color: var(--ink-3); }
.window__body { display: grid; grid-template-columns: 170px 1fr; min-height: 290px; }
.window__side { padding: 16px; background: var(--paper-2); border-right: 1px solid var(--line); }
.window__side .label { margin-bottom: 10px; }
.window__nav { display: block; padding: 6px 9px; border-radius: var(--radius-sm); font-size: 12.5px; color: var(--ink-2); }
.window__nav.is-on { background: var(--paper); color: var(--ink); font-weight: 600; }
.window__main { padding: 16px 18px; }
.window__search { height: 32px; display: flex; align-items: center; padding: 0 11px; border: 1px solid var(--line); border-radius: var(--radius-sm); font-size: 11.5px; color: var(--ink-3); margin-bottom: 10px; }
.wrow { display: grid; grid-template-columns: 30px 1fr auto; align-items: center; gap: 10px; padding: 9px 0; border-bottom: 1px solid var(--line); }
.wrow:last-child { border-bottom: 0; }
.wrow__icon { width: 30px; height: 30px; display: grid; place-items: center; border: 1px solid var(--line); border-radius: var(--radius-sm); background: var(--paper-2); font-family: var(--mono); font-size: 9px; font-weight: 700; }
.wrow b { display: block; font-size: 12.5px; font-weight: 600; }
.wrow small { font-family: var(--mono); font-size: 10px; color: var(--ink-3); }
.wrow__status { font-family: var(--mono); font-size: 9.5px; color: var(--ink-3); border: 1px solid var(--line); border-radius: 999px; padding: 2px 7px; }

/* ---------- sections ---------- */
.section { padding: clamp(64px, 8vw, 104px) 0; border-top: 1px solid var(--line); }
.section--flush { padding-top: 56px; }
.section__head { display: flex; align-items: flex-end; justify-content: space-between; gap: 32px; margin-bottom: 40px; }
.section__head h2 { margin: 10px 0 0; font-size: clamp(30px, 4vw, 48px); line-height: 1.05; font-weight: 650; letter-spacing: -.04em; }
.section__head p { margin: 0; max-width: 44ch; color: var(--ink-2); font-size: 14px; }
.section__link { font-size: 13px; font-weight: 600; border-bottom: 1px solid var(--ink); padding-bottom: 2px; white-space: nowrap; }
.section__link:hover { color: var(--ink-3); border-color: var(--ink-3); }

/* ---------- directory toolbar ---------- */
.toolbar { display: grid; grid-template-columns: 1fr 190px auto; gap: 14px; align-items: end; margin-bottom: 18px; }
.field { display: flex; flex-direction: column; gap: 6px; }
.field label { font-family: var(--mono); font-size: 10px; letter-spacing: .08em; text-transform: uppercase; color: var(--ink-3); }
.search-wrap { position: relative; }
.search-wrap svg { position: absolute; left: 13px; top: 50%; transform: translateY(-50%); width: 16px; height: 16px; stroke: var(--ink-3); fill: none; stroke-width: 1.7; }
.search-input { width: 100%; height: 46px; padding: 0 14px 0 40px; border: 1px solid var(--line); border-radius: var(--radius-sm); background: var(--paper); font-size: 13.5px; }
.search-input::placeholder { color: var(--ink-3); }
.select { width: 100%; height: 46px; padding: 0 12px; border: 1px solid var(--line); border-radius: var(--radius-sm); background: var(--paper); font-size: 13px; }
.results-count { font-family: var(--mono); font-size: 11.5px; color: var(--ink-3); padding-bottom: 14px; white-space: nowrap; }
.filters { display: flex; flex-wrap: wrap; gap: 16px; margin-bottom: 26px; }
.filter-group { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; }
.filter-label { font-family: var(--mono); font-size: 10px; color: var(--ink-3); text-transform: uppercase; letter-spacing: .07em; margin-right: 3px; }
.chip { height: 34px; padding: 0 13px; border-radius: var(--radius-sm); border: 1px solid var(--line); background: var(--paper); font-size: 12.5px; color: var(--ink-2); transition: border-color .15s ease, color .15s ease, background-color .15s ease; }
.chip:hover { border-color: var(--ink); color: var(--ink); }
.chip.is-active { background: var(--ink); color: var(--paper); border-color: var(--ink); }

/* ---------- cards ---------- */
.card-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.site-card, .project-card {
  display: flex; flex-direction: column;
  border: 1px solid var(--line); border-radius: var(--radius);
  background: var(--paper);
  transition: transform .18s ease, border-color .18s ease, box-shadow .18s ease;
}
.site-card:hover, .project-card:hover { transform: translateY(-3px); border-color: var(--ink-3); box-shadow: 0 14px 34px -24px rgba(0,0,0,.28); }
.site-card { padding: 22px; min-height: 190px; }
.site-card__top, .project-card__top { display: flex; align-items: flex-start; justify-content: space-between; gap: 10px; }
.site-card__icon { width: 40px; height: 40px; display: grid; place-items: center; border: 1px solid var(--line); border-radius: var(--radius-sm); background: var(--paper-2); font-family: var(--mono); font-size: 10.5px; font-weight: 700; }
.site-card__arrow { color: var(--ink-3); font-size: 16px; transition: transform .18s ease, color .18s ease; }
.site-card:hover .site-card__arrow { transform: translate(2px,-2px); color: var(--ink); }
.site-card h3, .project-card h3 { margin: 18px 0 3px; font-size: 17px; font-weight: 650; letter-spacing: -.02em; }
.site-card__domain, .project-card__meta { font-family: var(--mono); font-size: 11.5px; color: var(--ink-3); }
.site-card__desc, .project-card__desc { margin: 12px 0 18px; color: var(--ink-2); font-size: 13.5px; }
.site-card__foot, .project-card__foot { margin-top: auto; padding-top: 14px; border-top: 1px solid var(--line); display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.tag { padding: 3px 9px; border: 1px solid var(--line); border-radius: var(--radius-sm); font-size: 10.5px; color: var(--ink-2); }
.status { display: inline-flex; align-items: center; gap: 6px; font-family: var(--mono); font-size: 10.5px; color: var(--ink-2); }
.status::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: var(--arch); }
.status--online::before, .status--active::before { background: var(--ok); }
.status--development::before, .status--experiment::before { background: var(--dev); }
.status--archived::before { background: var(--arch); }
.project-card { padding: 22px; min-height: 220px; }
.project-card__cover { height: 72px; margin: -22px -22px 18px; display: grid; place-items: center; background: var(--paper-2); border-bottom: 1px solid var(--line); border-radius: var(--radius) var(--radius) 0 0; font-family: var(--mono); font-size: 11px; letter-spacing: .06em; text-transform: uppercase; color: var(--ink-3); overflow: hidden; }
.project-card__cover img { width: 100%; height: 100%; object-fit: cover; }
.project-card__stack { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 14px; }
.project-links { display: flex; gap: 12px; }
.project-links a { font-size: 12px; font-weight: 600; border-bottom: 1px solid var(--line); padding-bottom: 1px; }
.project-links a:hover { border-color: var(--ink); }
.empty { padding: 64px 24px; text-align: center; border: 1px dashed var(--line); border-radius: var(--radius); color: var(--ink-2); }
.empty strong { display: block; color: var(--ink); font-size: 17px; margin-bottom: 8px; }
.empty button { margin-top: 18px; }
.demo-flag { font-family: var(--mono); font-size: 9.5px; color: var(--ink-3); border: 1px solid var(--line); border-radius: 4px; padding: 1px 6px; vertical-align: middle; margin-left: 6px; }

/* ---------- stats: one design moment ---------- */
.stats { display: grid; grid-template-columns: repeat(4, 1fr); border-top: 1px solid var(--line); border-left: 1px solid var(--line); }
.stat { padding: 36px 28px; border-right: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.stat__num { font-size: clamp(44px, 6vw, 72px); line-height: 1; font-weight: 650; letter-spacing: -.06em; font-variant-numeric: tabular-nums; }
.stat__label { margin-top: 12px; font-family: var(--mono); font-size: 11px; letter-spacing: .06em; text-transform: uppercase; color: var(--ink-3); }

/* ---------- intro / about ---------- */
.intro { display: grid; grid-template-columns: 1fr 1.2fr; gap: 64px; align-items: start; }
.intro h2 { margin: 0; font-size: clamp(30px, 4vw, 50px); line-height: 1.08; letter-spacing: -.04em; font-weight: 650; }
.intro p { margin: 0 0 18px; color: var(--ink-2); font-size: 16px; }
.intro p:last-child { margin-bottom: 0; }
.about-list { display: grid; grid-template-columns: repeat(2, 1fr); gap: 14px; margin-top: 40px; }
.about-item { padding: 24px; border: 1px solid var(--line); border-radius: var(--radius); background: var(--paper); transition: border-color .15s ease; }
.about-item:hover { border-color: var(--ink-3); }
.about-item h3 { margin: 0 0 8px; font-size: 15px; font-weight: 650; }
.about-item p { margin: 0; color: var(--ink-2); font-size: 13.5px; }
.note { padding: 22px 24px; border: 1px dashed var(--line); border-radius: var(--radius); background: var(--paper-2); color: var(--ink-2); font-size: 13px; margin-top: 32px; }
.note strong { color: var(--ink); }
.page-hero { padding: 80px 0 48px; }
.page-hero h1 { margin: 14px 0 0; font-size: clamp(48px, 8vw, 92px); line-height: .98; letter-spacing: -.055em; font-weight: 700; }
.page-hero p { margin: 22px 0 0; max-width: 56ch; color: var(--ink-2); font-size: 17px; }

/* ---------- footer: compact, structured close ---------- */
.site-footer { border-top: 1px solid var(--line); padding: 72px 0 34px; background: var(--paper); }
.site-footer__inner { display: block; }
.site-footer__lead { margin: 0; font-size: clamp(32px, 5vw, 60px); line-height: 1.05; letter-spacing: -.045em; font-weight: 650; max-width: 20ch; }
.site-footer__grid { display: grid; grid-template-columns: 1.6fr 1fr 1fr; gap: 40px; align-items: start; margin-top: 44px; }
.site-footer__col h3 { margin: 0 0 14px; font-family: var(--mono); font-size: 10px; letter-spacing: .1em; text-transform: uppercase; color: var(--ink-3); font-weight: 500; }
.site-footer__col p { margin: 0; color: var(--ink-2); font-size: 13.5px; max-width: 34ch; }
.site-footer__col ul { list-style: none; margin: 0; padding: 0; }
.site-footer__col li { margin: 0 0 8px; }
.site-footer__col a { font-size: 13.5px; color: var(--ink-2); transition: color .15s ease; }
.site-footer__col a:hover { color: var(--ink); }
.site-footer__meta { margin-top: 52px; padding-top: 20px; border-top: 1px solid var(--line); display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap; font-family: var(--mono); font-size: 11px; color: var(--ink-3); }
.site-footer__meta a { border-bottom: 1px solid var(--line); }
@media (max-width: 900px) { .site-footer__grid { grid-template-columns: 1fr 1fr; gap: 28px; } .site-footer__col:first-child { grid-column: 1 / -1; } }
@media (max-width: 560px) { .site-footer__grid { grid-template-columns: 1fr; } .site-footer__col:first-child { grid-column: auto; } }
