/* Extracted from inline <style> blocks and style="" attributes to enable removal of 'unsafe-inline' in CSP */
/* Font faces */
@font-face { font-family: 'Inter var'; font-style: normal; font-weight: 100 900; font-display: swap; src: url('../fonts/Inter-roman.var.woff2') format('woff2-variations'); }
@font-face { font-family: 'Inter var'; font-style: italic; font-weight: 100 900; font-display: swap; src: url('../fonts/Inter-italic.var.woff2') format('woff2-variations'); }

/* Root variables & palette */
:root{--font-sans:"Inter var","Inter",system-ui,-apple-system,Segoe UI,Roboto,sans-serif;--bg:#0b1020;--bg-elev:#0f172a;--text:#e5e7eb;--muted:#94a3b8;--border:#1f2937}
html{font-family:var(--font-sans)}
:root{ --lk-bg:#0b1220; --lk-surface:#0f1a2d; --lk-surface-2:#111b30; --lk-border:rgba(255,255,255,.06); --lk-border-strong:rgba(255,255,255,.12); --lk-text:#e8eef8; --lk-muted:#b4c0cf; --lk-accent:#2d6cdf; --lk-accent-contrast:#ffffff; --lk-shadow:0 10px 35px rgba(0,0,0,.45); --lk-radius:16px; --lk-radius-pill:999px; }
/* Style policy: no inline style or inline event handler usage.
	Dynamic presentation must use classes (.is-hidden, .text-muted, .cursor-pointer, .served-by-line, .agent-status.*) or data-* attributes.
	Background & color fallbacks handled via utility classes.
*/
[data-theme="light"], .theme-light{ --lk-bg:#f6f8fc; --lk-surface:#ffffff; --lk-surface-2:#f1f5fb; --lk-border:rgba(0,0,0,.08); --lk-border-strong:rgba(0,0,0,.12); --lk-text:#0f172a; --lk-muted:#52627a; --lk-accent:#2d6cdf; --lk-accent-contrast:#ffffff; --lk-shadow:0 10px 24px rgba(0,0,0,.12); }

/* Critical layout originally inline */
*{box-sizing:border-box}
body{margin:0;font-family:Inter,system-ui,-apple-system,Segoe UI,Roboto,Helvetica,Arial;line-height:1.6;color:var(--text);background:var(--bg)}
header{position:sticky;top:0;z-index:50;background:#0f172acc;border-bottom:1px solid var(--border)}
.container{width:min(1200px,92vw);margin-inline:auto}
.nav{display:flex;align-items:center;justify-content:space-between;padding:.85rem 0;gap:1rem}
.brand{flex:1 1 auto}
.hero{padding:clamp(3rem,6vw + 1rem,7rem) 0;display:grid;grid-template-columns:1.2fr .8fr;gap:2rem;align-items:center}
@media(max-width:900px){.hero{grid-template-columns:1fr}}
.headline{font-size:clamp(1.6rem,2.8vw + 1rem,2.3rem);line-height:1.15;margin:0 0 1rem}
.subline{color:var(--muted);margin:0 0 1.5rem}
.hero-visual{aspect-ratio:4/3;border:1px solid var(--border);border-radius:1rem;overflow:hidden;background:#111827}
.badge{display:inline-block;padding:.25rem .55rem;border-radius:999px;font-size:.7rem;line-height:1;font-weight:500;border:1px solid transparent;white-space:nowrap;letter-spacing:.5px}
.badge-neutral{background:#334155;color:#e2e8f0;border-color:#475569}
.badge-warn{background:#fff3cd;color:#664d03;border-color:#ffec99}
.badge-ok{background:#133a21;color:#b3f2c8;border-color:#1d5d38}
.badge-degraded{background:#1e3a8a;color:#bfdbfe;border-color:#3b82f6}

/* Legacy UI suppression */
body.assistant-open{padding-bottom:0!important}
#riv-wrap,#vrm-wrap,#svg-avatar-wrap,#svg-mascot,#assistant-panel,#assistant-log,#assistant-form,
#leo-assistant,#la-open,#la-panel,#ai-avatar-wrap,#ai-controls,#ai-text,#live2d-wrap{display:none!important}

/* Icon links */
.icon-links{display:flex;flex-wrap:wrap;gap:.5rem;margin:.75rem 0 1rem}
.icon-links .icon-btn{display:inline-flex;align-items:center;justify-content:center;width:42px;height:42px;border:1px solid var(--border);border-radius:999px;background:#121a2e;color:#e8ecf8;text-decoration:none}
.icon-links .icon-btn:hover{background:#0f1830}
.icon-links .icon-btn:focus-visible{outline:2px solid #60a5fa;outline-offset:2px}
.icon-links .icon-btn svg{width:20px;height:20px;fill:currentColor}

/* Utilities replacing inline style attributes */
.status-pill{margin-left:.75rem}
.mt-3{margin-top:.75rem}
.mt-4{margin-top:1rem}
.img-fallback-gradient{ background:linear-gradient(180deg,#141b2d,#0b1223); }
.cursor-pointer{ cursor:pointer; }
.text-muted{ color: var(--lk-muted, #52627a); }
.is-hidden{ display:none !important; }
.agent-status .agent-dot[data-color]{ background: attr(data-color color, #e74c3c); }
/* Fallback for browsers without attr(color) support: override via status classes */
.agent-status.ok .agent-dot{ background:#2ecc71; }
.agent-status.warn .agent-dot{ background:#f1c40f; }
.agent-status.err .agent-dot{ background:#e74c3c; }
.served-by-line{ opacity:.75; font-size:12px; margin-bottom:.25rem; }
.served-by-line[data-accent]{ color: var(--lk-accent, #2d6cdf); }
.text-right{text-align:right}
.footer-build{grid-column:1 / -1;margin-top:.5rem}
.detail-title{margin:0}
.gallery-caption{margin-top:.75rem}

/* Project page shared styles (extracted from per-page inline <style>) */
.project-header{padding:2rem 0;border-bottom:1px solid var(--border)}
.project-content{padding:3rem 0}
.meta-dates{margin-top:1rem;font-size:.75rem;letter-spacing:.5px;text-transform:uppercase;color:var(--muted);display:flex;gap:1.25rem;flex-wrap:wrap}
.meta-dates time{font-weight:600;color:var(--text);text-transform:none;letter-spacing:0;font-size:.8rem}
.meta-dates span.label{font-weight:500}
.breadcrumb{font-size:.8rem;display:flex;flex-wrap:wrap;gap:.35rem;align-items:center;margin-bottom:1rem;color:var(--muted)}
.breadcrumb a{color:var(--muted)}
.breadcrumb a:hover{color:var(--text)}
.back-link{display:inline-flex;align-items:center;gap:.5rem;margin-bottom:1rem;color:var(--muted);padding:.5rem .75rem;border-radius:.6rem;border:1px solid var(--border)}
.back-link:hover{color:var(--text);background:color-mix(in oklab,var(--card) 80%,transparent)}
.project-nav{border-top:1px solid var(--border);margin-top:3rem;padding-top:2rem;display:flex;justify-content:space-between;gap:1rem}
.project-nav a{flex:1;display:flex;flex-direction:column;padding:1rem 1.25rem;border:1px solid var(--border);border-radius:.8rem;background:var(--card)}
.project-nav a:hover{border-color:color-mix(in oklab,var(--accent) 45%,var(--border))}
.project-nav span.label{font-size:.7rem;text-transform:uppercase;letter-spacing:.5px;color:var(--muted);margin-bottom:.25rem}
@media (max-width:700px){.project-nav{flex-direction:column}}

/* Gallery shared */
.gallery-dialog{border:none;padding:0;background:transparent;max-width:min(90vw,1000px)}
.gallery-dialog::backdrop{background:rgba(0,0,0,.65);backdrop-filter:blur(4px)}
.gallery-frame{position:relative;background:var(--card);padding:1.5rem 2.5rem;border:1px solid var(--border);border-radius:1rem;box-shadow:var(--shadow);display:flex;flex-direction:column;align-items:center}
.gallery-frame img{max-width:100%;height:auto;border-radius:.5rem}
.gallery-close,.gallery-prev,.gallery-next{position:absolute;top:.75rem;background:var(--card);border:1px solid var(--border);width:2.2rem;height:2.2rem;border-radius:.6rem;display:flex;align-items:center;justify-content:center;cursor:pointer;font-size:1.1rem}
.gallery-close{right:.75rem}
.gallery-prev{left:.75rem;top:50%;transform:translateY(-50%)}
.gallery-next{right:.75rem;top:50%;transform:translateY(-50%)}
.gallery-close:hover,.gallery-prev:hover,.gallery-next:hover{border-color:color-mix(in oklab,var(--accent) 45%,var(--border))}
.gallery-item{cursor:zoom-in}
.gallery-thumbs{margin-top:1rem;display:flex;gap:.5rem;flex-wrap:wrap;justify-content:center}
.gallery-thumbs button{border:1px solid var(--border);background:var(--card);padding:0;width:60px;height:40px;border-radius:.4rem;overflow:hidden;cursor:pointer;position:relative}
.gallery-thumbs button img{width:100%;height:100%;object-fit:cover}
.gallery-thumbs button[aria-current="true"]{outline:2px solid var(--accent);outline-offset:2px}
.gallery-thumbs button:hover{border-color:color-mix(in oklab,var(--accent) 45%,var(--border))}
.gallery-thumbs button:focus-visible{outline:2px solid var(--focus);outline-offset:2px}
.gallery-thumbs button[aria-current="true"]:focus-visible{outline:3px solid var(--accent)}

/* End extracted */
