:root {
  font-family: 'DM Sans', 'Segoe UI', sans-serif;
  color: #202a32;
  background: #f7f8f6;
  font-synthesis: none;
  text-rendering: optimizeLegibility;
  --ink: #1d2a32;
  --muted: #7d8587;
  --line: #e9ece8;
  --sidebar: #111a24;
  --orange: #e66c43;
  --green: #2d7058;
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }
html { scroll-behavior: smooth; }
body { margin: 0; min-width: 320px; min-height: 100vh; }
button, input { font: inherit; }
button { cursor: pointer; }
a { color: inherit; text-decoration: none; }
.visually-hidden { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0; }

.app-shell { min-height: 100vh; }
.sidebar {
  position: fixed; inset: 0 auto 0 0; z-index: 4; display: flex; flex-direction: column;
  width: 244px; padding: 29px 18px 17px; color: #e9efed; background: var(--sidebar);
}
.brand { display: flex; align-items: center; gap: 11px; padding: 0 9px; }
.brand-mark { display: grid; width: 36px; height: 36px; place-items: center; border-radius: 12px 12px 12px 3px; background: #e8774e; color: #fff7ed; font: 800 21px 'Manrope', sans-serif; transform: rotate(-3deg); }
.brand-copy { display: grid; gap: 1px; }
.brand-copy strong { color: #fff; font: 800 18px 'Manrope', sans-serif; letter-spacing: -.8px; }
.brand-copy small { color: #89979a; font: 500 8px 'DM Mono', monospace; letter-spacing: 1.7px; }
.sidebar-label { padding: 0 11px; margin: 54px 0 13px; color: #738187; font: 500 9px 'DM Mono', monospace; letter-spacing: 1.4px; }
.side-nav { display: grid; gap: 6px; }
.nav-link { display: flex; align-items: center; width: 100%; gap: 12px; padding: 11px 11px; border: 0; border-radius: 7px; background: transparent; color: #a9b5b4; font-size: 12px; text-align: left; }
.nav-link:hover, .nav-link:focus-visible { background: #1b2932; color: #fff; outline: none; }
.nav-link.is-active { background: #26363e; color: #fff; box-shadow: inset 2px 0 #e77a52; }
.nav-icon { display: grid; width: 17px; place-items: center; color: #9eb4ac; font-size: 18px; }
.nav-count { margin-left: auto; color: #829194; font: 500 10px 'DM Mono', monospace; }
.sidebar-spacer { flex: 1; min-height: 70px; }
.sidebar-note { padding: 15px 14px; border: 1px solid #293940; border-radius: 9px; background: #17242c; }
.note-icon { color: #f09a6b; font-size: 16px; }
.sidebar-note strong { display: block; margin-top: 9px; color: #e5ece8; font-size: 11px; font-weight: 600; }
.sidebar-note p { margin: 5px 0 0; color: #879697; font-size: 10px; line-height: 1.6; }
.sidebar-footer { display: flex; align-items: center; gap: 7px; padding: 19px 8px 0; color: #859394; font: 400 9px 'DM Mono', monospace; }
.status-dot { width: 6px; height: 6px; border-radius: 50%; background: #6ac08c; box-shadow: 0 0 0 3px #254133; }
.version-label { margin-left: auto; color: #5e6e72; }

.main-content { max-width: 1600px; min-height: 100vh; padding: 0 49px; margin-left: 244px; }
.topbar { display: flex; align-items: center; justify-content: space-between; height: 70px; border-bottom: 1px solid var(--line); }
.breadcrumb { display: flex; align-items: center; gap: 11px; color: #909898; font-size: 11px; }
.breadcrumb strong { color: #455157; font-weight: 600; }
.crumb-sep { color: #c4c9c6; }
.topbar-right { display: flex; align-items: center; gap: 17px; }
.local-badge { display: flex; align-items: center; gap: 6px; color: #557865; font: 500 9px 'DM Mono', monospace; letter-spacing: .5px; }
.local-badge span { color: #67a27d; font-size: 8px; }
.mobile-favorites { display: none; align-items: center; gap: 5px; padding: 6px 8px; border: 1px solid #e4e9e3; border-radius: 4px; background: #fff; color: #65756a; font-size: 9px; }
.mobile-favorites[aria-pressed="true"] { border-color: #cdddcf; background: #edf4ed; color: #42634b; }
.mobile-favorites span { font: 500 9px 'DM Mono', monospace; }
.avatar { width: 29px; height: 29px; border: 1px solid #dfe5df; border-radius: 50%; background: #e8eee8; color: #42604c; font: 600 11px 'Manrope', sans-serif; }

.welcome { position: relative; display: flex; align-items: center; justify-content: space-between; min-height: 330px; padding: 45px 54px; margin-top: 28px; overflow: hidden; border-radius: 11px; background: #e7eee8; }
.welcome-copy { position: relative; z-index: 2; width: min(58%, 560px); }
.eyebrow { display: flex; align-items: center; gap: 9px; color: #68816f; font: 500 9px 'DM Mono', monospace; letter-spacing: 1.25px; }
.eyebrow-line { display: inline-block; width: 17px; height: 1px; background: #d27551; }
.welcome h1 { margin: 19px 0 10px; color: #1b2b30; font: 600 clamp(34px, 4vw, 51px)/1.08 'Manrope', sans-serif; letter-spacing: -2.6px; }
.welcome h1 span { color: #59846c; }
.welcome-description { max-width: 410px; margin: 0; color: #62706d; font-size: 12px; line-height: 1.7; }
.browse-button { display: inline-flex; align-items: center; gap: 16px; padding: 11px 15px; margin-top: 22px; border-radius: 5px; background: #203b37; color: #fff; font-size: 10px; font-weight: 600; transition: background .2s, transform .2s; }
.browse-button:hover { background: #315d4f; transform: translateY(-1px); }
.browse-button span { color: #a9cdb7; font-size: 15px; line-height: 10px; }
.welcome-art { position: absolute; inset: 0 0 0 46%; overflow: hidden; }
.art-orbit { position: absolute; right: 12%; top: -50%; width: 410px; height: 410px; border: 1px solid rgba(69, 111, 91, .13); border-radius: 50%; }
.orbit-two { top: -38%; right: 6%; width: 500px; height: 500px; border-color: rgba(69, 111, 91, .1); }
.art-sun { position: absolute; top: 15%; right: 23%; width: 116px; height: 116px; border-radius: 50%; background: #ecc08c; box-shadow: 0 0 0 17px rgba(236, 192, 140, .15); }
.art-hill { position: absolute; right: -9%; bottom: -74px; width: 120%; height: 190px; border-radius: 50% 50% 0 0; transform: rotate(-8deg); }
.hill-back { right: -20%; bottom: -101px; background: #a8c4ac; }
.hill-front { right: -4%; bottom: -141px; background: #6e9a80; transform: rotate(7deg); }
.art-stamp { position: absolute; z-index: 2; top: 23%; right: 43%; display: grid; justify-items: center; gap: 5px; width: 94px; height: 94px; padding-top: 18px; border: 1px solid rgba(41, 79, 63, .28); border-radius: 50%; color: #335844; font: 500 8px/1.35 'DM Mono', monospace; letter-spacing: .6px; transform: rotate(10deg); }
.stamp-star { font-size: 14px; }
.art-caption { position: absolute; z-index: 2; right: 12%; bottom: 17px; color: rgba(255,255,255,.82); font: 500 8px 'DM Mono', monospace; letter-spacing: 1.4px; }
.welcome-grain { position: absolute; inset: 0; pointer-events: none; opacity: .13; background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 180 180' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='.16'/%3E%3C/svg%3E"); }

.catalog-section { padding-top: 48px; }
.section-heading { display: flex; align-items: end; justify-content: space-between; }
.section-eyebrow { color: #7a8580; }
.section-heading h2 { margin: 11px 0 6px; color: #243239; font: 600 clamp(21px, 2.2vw, 28px)/1.2 'Manrope', sans-serif; letter-spacing: -1px; }
.heading-period { color: #de7952; }
.section-description { margin: 0; color: #89918f; font-size: 11px; }
.catalog-summary { display: flex; align-items: center; gap: 11px; padding: 0 2px 5px 0; }
.summary-number { color: #344a40; font: 500 25px 'Manrope', sans-serif; letter-spacing: -1px; }
.summary-label { color: #929995; font: 500 8px/1.55 'DM Mono', monospace; letter-spacing: .6px; }
.toolbar { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 19px 0 18px; margin-top: 23px; border-top: 1px solid var(--line); }
.search-box { display: flex; align-items: center; gap: 8px; width: 220px; min-width: 175px; padding: 8px 10px; border: 1px solid #e4e9e4; border-radius: 5px; background: #fff; color: #8d9996; }
.search-box:focus-within { border-color: #9db8a2; box-shadow: 0 0 0 3px rgba(82, 129, 94, .08); }
.search-icon { font-size: 20px; line-height: 12px; transform: rotate(-20deg); }
.search-box input { width: 100%; min-width: 0; border: 0; outline: 0; background: transparent; color: var(--ink); font-size: 10px; }
.search-box input::placeholder { color: #a0a9a5; }
.search-box kbd { padding: 2px 5px; border: 1px solid #e7ebe7; border-radius: 3px; color: #a5adaa; font: 10px 'DM Mono', monospace; }
.filter-group { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 5px; }
.filter-chip { padding: 8px 10px; border: 1px solid transparent; border-radius: 4px; background: transparent; color: #828b88; font-size: 9px; white-space: nowrap; }
.filter-chip:hover { background: #eef2ed; color: #3a5645; }
.filter-chip.is-selected { border-color: #dfe7df; background: #eaf0e9; color: #3d624b; font-weight: 600; }
.saved-banner { display: flex; align-items: center; justify-content: space-between; padding: 10px 13px; margin-bottom: 14px; border: 1px solid #e1e9df; border-radius: 5px; background: #f0f5ef; color: #50705a; font-size: 10px; }
.saved-banner button { border: 0; background: transparent; color: #426b4c; font-size: 10px; font-weight: 600; }
.storage-notice { padding: 10px 12px; border: 1px solid #edc8aa; border-radius: 4px; background: #fff6ed; color: #865330; font-size: 11px; line-height: 1.5; }
.system-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; }
.system-card { position: relative; display: flex; flex-direction: column; min-height: 280px; overflow: hidden; border: 1px solid #e7eae6; border-radius: 7px; background: #fff; transition: border-color .2s, box-shadow .2s, transform .2s; }
.system-card:hover { border-color: #d7dfd8; box-shadow: 0 9px 24px rgba(41, 62, 49, .08); transform: translateY(-2px); }
.card-visual { position: relative; display: flex; align-items: center; justify-content: space-between; min-height: 99px; padding: 17px 18px; overflow: hidden; background: var(--card-bg); }
.card-visual::before, .card-visual::after { position: absolute; content: ''; border: 1px solid var(--card-line); border-radius: 50%; }
.card-visual::before { top: -57px; right: -12px; width: 175px; height: 175px; }
.card-visual::after { top: -39px; right: 8px; width: 139px; height: 139px; }
.card-number { position: absolute; top: 12px; right: 14px; color: var(--card-muted); font: 500 8px 'DM Mono', monospace; letter-spacing: 1px; }
.card-symbol { position: relative; z-index: 1; display: grid; width: 46px; height: 46px; place-items: center; border: 1px solid var(--card-line); border-radius: 14px 14px 14px 5px; background: var(--card-icon-bg); color: var(--card-ink); font: 700 19px 'Manrope', sans-serif; transform: rotate(-4deg); }
.card-spark { position: absolute; right: 35px; bottom: 9px; color: var(--card-ink); opacity: .55; font-size: 24px; }
.card-category { position: relative; z-index: 1; align-self: end; padding: 5px 7px; border: 1px solid var(--card-line); border-radius: 3px; color: var(--card-ink); font: 500 8px 'DM Mono', monospace; letter-spacing: .4px; }
.card-body { display: flex; flex: 1; flex-direction: column; padding: 14px 16px 13px; }
.card-eyebrow { color: #a2aaa5; font: 500 8px 'DM Mono', monospace; letter-spacing: .9px; text-transform: uppercase; }
.card-title-row { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-top: 6px; }
.card-title { margin: 0; color: #29373c; font: 700 15px 'Manrope', sans-serif; letter-spacing: -.35px; }
.favorite-button { display: grid; flex: 0 0 auto; width: 27px; height: 27px; place-items: center; border: 1px solid #edf0ed; border-radius: 50%; background: #fff; color: #a0aaa4; font-size: 15px; line-height: 1; }
.favorite-button:hover { border-color: #e8c1ad; color: #d97b55; }
.favorite-button.is-favorite { border-color: #f5e2d5; background: #fff7f2; color: #d5714c; }
.card-description { min-height: 32px; margin: 6px 0 10px; color: #858e8b; font-size: 10px; line-height: 1.55; }
.feature-list { display: flex; flex-wrap: wrap; gap: 5px; margin: auto 0 12px; padding: 0; list-style: none; }
.feature-list li { padding: 4px 6px; border-radius: 3px; background: #f5f7f4; color: #7f8983; font-size: 8px; }
.card-footer { display: flex; align-items: center; justify-content: space-between; padding-top: 10px; border-top: 1px solid #f0f2ef; }
.demo-status { display: flex; align-items: center; gap: 6px; color: #a0a8a4; font-size: 8px; }
.demo-status::before { width: 5px; height: 5px; border-radius: 50%; background: #cbd1cb; content: ''; }
.demo-status.is-configured { color: #5a8265; }
.demo-status.is-configured::before { background: #65a57a; }
.demo-status.is-down { color: #b0705a; }
.demo-status.is-down::before { background: #d98a6e; }
.card-access { margin: 0 0 10px; color: #6f7b75; font: 500 8px 'DM Mono', monospace; letter-spacing: .2px; }
.feature-list { margin-bottom: 8px; }
.card-actions { display: flex; gap: 6px; }
.card-action { padding: 6px 8px; border: 1px solid #e7ece7; border-radius: 4px; background: #fff; color: #77827c; font-size: 8px; font-weight: 600; }
.card-action:hover { border-color: #b7c9b9; color: #42634b; }
.card-action.primary { border-color: #264c3b; background: #264c3b; color: #fff; }
.card-action.primary:hover { border-color: #386e53; background: #386e53; }
.empty-state { padding: 60px 20px; text-align: center; }
.empty-state > span { color: #9cb49f; font-size: 28px; }
.empty-state h3 { margin: 10px 0 4px; color: #33423a; font: 600 17px 'Manrope', sans-serif; }
.empty-state p { margin: 0 0 15px; color: #8c9690; font-size: 11px; }
.empty-state button { border: 0; background: transparent; color: #45714f; font-size: 10px; font-weight: 600; }
.page-footer { display: flex; justify-content: space-between; padding: 28px 0 24px; margin-top: 18px; border-top: 1px solid var(--line); color: #a0a9a3; font: 500 8px 'DM Mono', monospace; letter-spacing: .8px; }
.footer-dot { padding: 0 4px; color: #e27e55; }

.link-dialog { width: min(430px, calc(100% - 32px)); padding: 26px; border: 1px solid #e3e8e2; border-radius: 10px; background: #fcfdfb; color: var(--ink); box-shadow: 0 24px 70px rgba(17, 26, 36, .25); }
.link-dialog::backdrop { background: rgba(15, 25, 30, .52); backdrop-filter: blur(2px); }
.dialog-top { display: flex; align-items: center; justify-content: space-between; margin-bottom: 19px; }
.dialog-mark { display: grid; width: 33px; height: 33px; place-items: center; border-radius: 8px; background: #e8f0e8; color: #52775d; font-size: 16px; }
.dialog-close { width: 27px; height: 27px; border: 0; border-radius: 50%; background: #f1f3f0; color: #78827c; font-size: 19px; line-height: 1; }
.link-dialog h2 { margin: 9px 0 5px; color: #24342f; font: 700 22px 'Manrope', sans-serif; letter-spacing: -.7px; }
.dialog-description { margin: 0 0 21px; color: #7d8881; font-size: 11px; line-height: 1.6; }
.url-label { display: block; margin-bottom: 7px; color: #53615a; font-size: 10px; font-weight: 600; }
.link-dialog input { width: 100%; padding: 11px 12px; border: 1px solid #dfe6df; border-radius: 5px; outline: none; background: #fff; color: #23332d; font-size: 11px; }
.link-dialog input:focus { border-color: #729778; box-shadow: 0 0 0 3px rgba(82, 129, 94, .09); }
.link-dialog input::placeholder { color: #afb8b1; }
.field-help { margin: 7px 0 0; color: #9aa39d; font-size: 9px; line-height: 1.5; }
.field-error { margin: 8px 0 0; color: #a34837; font-size: 10px; }
.dialog-actions { display: flex; justify-content: flex-end; gap: 8px; margin-top: 24px; }
.dialog-actions button { padding: 9px 12px; border-radius: 4px; font-size: 10px; font-weight: 600; }
.button-quiet { border: 1px solid #e4e9e3; background: #fff; color: #76817a; }
.button-primary { border: 1px solid #254d39; background: #254d39; color: #fff; }
.button-primary:hover { background: #35694d; }
.button-primary span { padding-left: 6px; color: #b8d3bd; }
.remove-link { display: block; padding: 0; margin-top: 16px; border: 0; background: transparent; color: #a75a45; font-size: 9px; }

@media (max-width: 1100px) {
  .main-content { padding-right: 28px; padding-left: 28px; }
  .system-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .toolbar { align-items: flex-start; flex-direction: column; }
  .filter-group { justify-content: flex-start; }
}
@media (max-width: 760px) {
  .sidebar { position: sticky; inset: 0 0 auto; width: auto; height: 59px; flex-direction: row; align-items: center; justify-content: space-between; padding: 0 16px; }
  .brand { padding: 0; }
  .brand-mark { width: 31px; height: 31px; border-radius: 10px 10px 10px 3px; font-size: 18px; }
  .brand-copy strong { font-size: 16px; }
  .sidebar-label, .side-nav, .sidebar-spacer, .sidebar-note, .sidebar-footer { display: none; }
  .main-content { padding: 0 17px; margin: 0; }
  .topbar { height: 52px; }
  .breadcrumb { font-size: 10px; }
  .topbar-right { gap: 6px; }
  .mobile-favorites { display: flex; }
  .welcome { min-height: 370px; align-items: flex-start; padding: 29px 22px; margin-top: 16px; }
  .welcome-copy { width: 100%; }
  .welcome h1 { max-width: 350px; font-size: 39px; }
  .welcome-description { max-width: 310px; }
  .welcome-art { inset: 43% 0 0 12%; }
  .art-sun { top: 10%; right: 28%; width: 82px; height: 82px; }
  .art-stamp { top: 19%; right: 53%; width: 72px; height: 72px; padding-top: 13px; font-size: 6px; }
  .art-caption { right: 8%; bottom: 11px; font-size: 6px; }
  .catalog-section { padding-top: 37px; }
  .section-heading { align-items: flex-start; }
  .section-heading h2 { max-width: 300px; font-size: 23px; }
  .catalog-summary { gap: 6px; padding-top: 15px; }
  .summary-number { font-size: 20px; }
  .summary-label { font-size: 7px; }
  .search-box { width: 100%; }
  .filter-group { gap: 3px; }
  .filter-chip { padding: 7px 8px; font-size: 8px; }
  .system-grid { grid-template-columns: 1fr; gap: 11px; }
  .system-card { min-height: 266px; }
  .card-visual { min-height: 87px; }
  .page-footer { gap: 15px; flex-direction: column; font-size: 7px; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; transition-duration: .01ms !important; }
}
