:root {
    color-scheme: light;
    --paper: #f8f8f5;
    --ink: #17232f;
    --muted: #59606a;
    --line: #d9dcd7;
    --accent: #f4794d;
    --action: #a64025;
    font: 100%/1.5 "Segoe UI", Arial, sans-serif;
    color: var(--ink);
    background: var(--paper);
}
* { box-sizing: border-box; }
body { margin: 0; }
button, input { font: inherit; color: inherit; }
button { cursor: pointer; }
[hidden] { display: none !important; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); }
a { color: inherit; text-decoration: none; }
:is(button, a, input):focus-visible { outline: 3px solid #ad4b2c; outline-offset: 3px; }
.page-width { width: min(1240px, calc(100% - clamp(32px, 8.4vw, 128px))); margin-inline: auto; }
.site-header { border-bottom: 1px solid var(--line); background: #fff; }
.header-row { display: flex; align-items: center; min-height: 73px; }
.brand { display: inline-flex; align-items: center; font-weight: 760; letter-spacing: -.07em; font-size: 1.4rem; line-height: 1; }
.brand-hub { color: #a63d22; }
.brand-mark { position: relative; margin-right: 9px; width: 33px; height: 33px; border-radius: 8px; background: #ed7043; overflow: hidden; transform: rotate(-2deg); }
.brand-mark i { position: absolute; top: 8px; left: 7px; width: 7px; height: 17px; background: #19232c; transform: skewX(-20deg); }
.brand-mark i:nth-child(2) { left: 18px; transform: skewX(20deg); }
.brand-mark i:nth-child(3) { top: 18px; left: 12px; width: 7px; height: 4px; transform: none; }
.brand-divider { height: 21px; width: 1px; background: var(--line); margin-inline: 18px; }
.brand-context { font-size: .85rem; color: #656c70; }
.manage-link { margin-left: auto; display: inline-flex; align-items: center; gap: 8px; font-weight: 600; font-size: .87rem; padding: 8px 14px; border: 1px solid var(--line); border-radius: 8px; }
.manage-link:hover { border-color: #a3aaa8; }
.control-icon { font-size: 1.02rem; line-height: 1; }
.hero { position: relative; isolation: isolate; overflow: hidden; display: grid; grid-template-columns: 1.05fr 1fr; border-radius: 21px; background: #17232f; color: #fff; margin-top: clamp(20px, 3vw, 40px); min-height: 294px; }
.hero-copy { align-self: center; padding: clamp(28px, 3.7vw, 55px); }
.hero h1 { font-size: clamp(3.2rem, 5.4vw, 5.3rem); font-weight: 650; line-height: .97; letter-spacing: -.065em; margin: 0; }
.hero h1 span { color: var(--accent); }
.hero p { font-size: clamp(.92rem, 1.16vw, 1.05rem); line-height: 1.55; color: #c7cfd2; max-width: 385px; margin: 17px 0 0; }
.hero-art { position: relative; display: grid; place-items: center; overflow: hidden; }
.mesh { position: absolute; inset: 0; background-image: linear-gradient(#92b8c41b 1px, transparent 1px), linear-gradient(90deg, #92b8c41b 1px, transparent 1px), radial-gradient(ellipse at 62% 45%, #3b5165 0%, transparent 70%); background-size: 25px 25px, 25px 25px, 100% 100%; mask-image: linear-gradient(90deg, transparent 1%, black 30%); }
.stack-art { position: relative; width: 350px; height: 245px; transform: translate(-1%, 0); }
.plate { position: absolute; width: 221px; height: 135px; left: 60px; top: 56px; border-radius: 8px; transform: rotate(-34deg) skewX(18deg) scaleY(.84); overflow: hidden; }
.plate-back { transform: translateY(55px) rotate(-34deg) skewX(18deg) scaleY(.84); background: #324c5f; border: 1.5px solid #8aabae; box-shadow: -2px 5px 0 #243846; }
.plate-middle { transform: translateY(25px) rotate(-34deg) skewX(18deg) scaleY(.84); background: #273a4a; border: 2px solid #aec4bf; box-shadow: -2px 5px 0 #526b79; }
.art-grid { margin: 11px; height: calc(100% - 22px); border: 1px dashed #a5baba88; background-image: linear-gradient(#adc6c52e 1px, transparent 1px), linear-gradient(90deg, #adc6c52e 1px, transparent 1px); background-size: 12px 12px; }
.plate-front { top: 49px; background: #f4b28e; border: 2px solid #ffc3a3; box-shadow: -2px 5px 0 #bd633e; }
.plate-toolbar { display: flex; align-items: center; gap: 4px; height: 19px; padding: 0 8px; border-bottom: 1px solid #965e4d; background: #f28861; }
.plate-toolbar i { width: 4px; height: 4px; border-radius: 50%; background: #794637; }
.plate-body { display: flex; gap: 12px; padding: 11px; height: calc(100% - 19px); }
.plate-menu { width: 25%; display: grid; align-content: start; gap: 8px; border-right: 1px solid #ac775e; padding-right: 8px; }
.plate-menu i { display: block; height: 4px; border: 1px solid #99664f; border-radius: 1px; }
.plate-menu i:first-child { height: 17px; background: #f28a5c; }
.plate-canvas { flex: 1; display: grid; grid-template-columns: 1fr 1fr; grid-template-rows: 1fr 1fr; gap: 7px; }
.plate-canvas i { border: 1px solid #93634c; border-radius: 3px; background: #f8c6a2; }
.plate-canvas i:first-child { grid-column: 1 / -1; background: repeating-linear-gradient(-45deg, #f0a785 0 5px, #e99a74 5px 6px); }
.plate-canvas i:nth-last-child(-n+2) { display: none; }
.library { padding-block: clamp(32px, 3.7vw, 54px) 60px; }
.library-toolbar, .library-heading, .library-controls { display: flex; align-items: center; }
.library-toolbar { justify-content: space-between; gap: 16px; margin-bottom: 22px; }
.library-heading { gap: 11px; }
.library-heading h2 { margin: 0; font-size: clamp(1.4rem, 2vw, 1.78rem); font-weight: 650; letter-spacing: -.055em; line-height: 1.24; }
.count { display: inline-grid; place-items: center; min-width: 26px; padding-inline: 7px; height: 24px; color: #44514e; background: #e8ebe5; border: 1px solid #dbe0d8; border-radius: 7px; font-weight: 650; font-size: .78rem; }
.library-controls { gap: 10px; }
.search { display: flex; align-items: center; gap: 10px; min-height: 39px; padding-inline: 12px; border-radius: 8px; border: 1px solid var(--line); background: #fff; color: #5b6469; }
.search:focus-within { outline: 2px solid var(--action); }
.search input { width: 160px; min-width: 0; background: transparent; border: none; outline: none; font-size: .85rem; }
.search input:focus-visible { outline: none; }
.search-icon { position: relative; border-radius: 50%; width: 12px; height: 12px; border: 1.5px solid currentColor; margin-right: 2px; }
.search-icon::after { content: ""; position: absolute; width: 6px; height: 1.5px; border-radius: 3px; background: currentColor; top: 9px; left: 8px; transform: rotate(46deg); }
.view-switch { display: flex; gap: 2px; padding: 3px; border-radius: 8px; background: #fff; border: 1px solid var(--line); }
.view-switch button { border: 0; background: transparent; color: #646e72; width: 31px; height: 31px; border-radius: 5px; display: grid; place-items: center; }
.view-switch button[aria-pressed=true] { background: #e8ece7; color: var(--ink); }
.grid-icon, .list-icon { width: 15px; height: 15px; display: block; }
.grid-icon { background: linear-gradient(currentColor 0 0) top left/6px 6px, linear-gradient(currentColor 0 0) top right/6px 6px, linear-gradient(currentColor 0 0) bottom left/6px 6px, linear-gradient(currentColor 0 0) bottom right/6px 6px; background-repeat: no-repeat; }
.list-icon { background: repeating-linear-gradient(to bottom, currentColor 0 2px, transparent 2px 5px) center / 15px 12px no-repeat; }
.project-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 22px; }
.project-card { display: flex; flex-direction: column; min-width: 0; overflow: hidden; border: 1px solid #d8dcd5; border-radius: 14px; background: #fff; transition: border-color .18s, transform .18s, box-shadow .18s; }
.project-card:hover { transform: translateY(-3px); border-color: #a8b4ad; box-shadow: 0 8px 23px #24342312; }
.cover { --surface: #d0e5d8; --dark: #255549; --toned: #67a286; --light: #eaf3ed; position: relative; isolation: isolate; aspect-ratio: 2.05; overflow: hidden; display: grid; place-items: center; background-color: var(--surface); background-image: radial-gradient(#33495132 .85px, transparent .85px); background-size: 8px 8px; border-bottom: 1px solid #24342312; }
.cover-service { --surface: #f4d8b8; --dark: #8b472d; --toned: #d58d5e; --light: #f9ede1; }
.cover-inspection { --surface: #d9deee; --dark: #454e7b; --toned: #878fb8; --light: #edf0f8; }
.cover-general { --surface: #d9e2e9; --dark: #3e596f; --toned: #899fae; --light: #ecf1f4; }
.preview-screen { display: flex; inline-size: 68%; aspect-ratio: 1.87; border-radius: 7px; overflow: hidden; background: #fff; border: 1px solid #28342d47; box-shadow: 5px 6px 0 #14231e13, 0 10px 18px #23382517; transform: rotate(-3deg); }
.cover-service .preview-screen { transform: rotate(3deg); }
.cover-inspection .preview-screen { transform: rotate(-2deg); }
.preview-side { display: flex; flex-direction: column; align-items: flex-start; gap: 8%; width: 17%; padding: 6% 3%; background: var(--dark); }
.preview-logo { width: 42%; aspect-ratio: 1; border: 1.5px solid #fff; border-radius: 26%; margin-bottom: 14%; transform: rotate(-8deg); }
.preview-side b { width: 84%; height: 2px; min-height: 2px; background: #ffffff66; }
.preview-side b:nth-child(3) { width: 65%; }
.preview-side b:last-child { width: 71%; }
.preview-main { flex: 1; display: flex; flex-direction: column; padding: 5% 6%; overflow: hidden; }
.preview-strip { display: flex; justify-content: space-between; align-items: center; border-bottom: 1px solid var(--surface); padding-bottom: 3%; }
.preview-strip i { width: 27%; height: 2px; background: var(--toned); }
.preview-strip b { width: 6px; height: 6px; border-radius: 50%; background: var(--toned); }
.preview-title { height: 4px; width: 39%; border-radius: 1px; margin: 5% 0; background: var(--dark); }
.mini-stats { display: flex; gap: 4%; height: 23%; }
.mini-stats i, .mini-board>div { flex: 1; background: var(--light); border: 1px solid var(--surface); border-radius: 3px; }
.mini-stats i::before, .mini-stats i::after { content: ""; width: 50%; height: 2px; display: block; margin: 7% 14% 0; background: var(--toned); }
.mini-stats i::after { width: 25%; height: 3px; background: var(--dark); }
.mini-chart { min-height: 12px; flex: 1; display: flex; gap: 4%; align-items: flex-end; margin-top: 5%; padding-inline: 3%; border-bottom: 1px solid var(--surface); background: repeating-linear-gradient(to top, transparent 0 22%, var(--light) 23% 25%); }
.mini-chart i { flex: 1; height: 70%; background: var(--toned); border-radius: 2px 2px 0 0; }
.mini-chart i:nth-child(even) { height: 45%; }
.mini-chart i:nth-child(3n) { height: 58%; }
.mini-chart i:nth-child(5), .mini-chart i:last-child { height: 90%; background: var(--dark); }
.mini-board { display: flex; gap: 4%; flex: 1; }
.mini-board>div { padding: 3%; }
.mini-board>div::before { content: ""; display: block; width: 67%; border-top: 2px solid var(--toned); margin-bottom: 14%; }
.mini-board i { display: block; height: 28%; border: 1px solid var(--surface); background: white; margin-bottom: 8%; border-radius: 2px; box-shadow: inset 2px 0 var(--toned); }
.mini-inspection { display: flex; align-items: center; gap: 10%; flex: 1; border-radius: 4px; border: 1px solid var(--surface); background: var(--light); padding: 4% 6%; }
.mini-ring { width: 32%; aspect-ratio: 1; border-radius: 50%; background: radial-gradient(circle, var(--light) 0 41%, transparent 43%), conic-gradient(var(--dark) 0 69%, var(--toned) 69% 84%, var(--surface) 84% 100%); }
.mini-checks { flex: 1; display: grid; gap: 5px; }
.mini-checks i { height: 4px; background: linear-gradient(to right, var(--toned) 0 8%, transparent 8% 17%, var(--toned) 17% 85%, transparent 85%); }
.mini-generic { flex: 1; display: grid; grid-template-columns: 1fr 1fr; gap: 5%; }
.mini-generic i { background: var(--light); border: 1px solid var(--surface); border-radius: 3px; }
.card-copy { flex: 1; padding: 19px 22px 16px; display: flex; flex-direction: column; min-width: 0; }
.card-meta { display: flex; align-items: center; gap: 7px; margin-bottom: 9px; font-size: .67rem; font-weight: 650; letter-spacing: .08em; text-transform: uppercase; color: #4e575b; }
.theme-dot { width: 7px; height: 7px; border-radius: 2px; background: #5b798f; }
.dot-inventory { background: #57957a; }
.dot-service { background: #bb7446; }
.dot-inspection { background: #787faf; }
.meta-separator { color: #a5aaa8; }
.card-copy h3 { margin: 0; font-size: clamp(1.16rem, 1.6vw, 1.5rem); line-height: 1.25; font-weight: 650; letter-spacing: -.045em; overflow-wrap: anywhere; }
.card-copy p { color: var(--muted); margin: 7px 0 0; font-size: .89rem; line-height: 1.55; overflow-wrap: anywhere; }
.card-action { display: flex; align-items: center; justify-content: space-between; margin-top: auto; padding-top: 18px; color: var(--action); font-size: .83rem; font-weight: 650; }
.card-action span:last-child { display: grid; place-items: center; border: 1px solid #dedfd9; color: var(--ink); height: 26px; width: 26px; border-radius: 50%; line-height: 1; font-size: .9rem; }
.project-card:hover .card-action span:last-child { border-color: var(--action); color: var(--action); }
.project-grid.is-list { grid-template-columns: 1fr; gap: 12px; }
.is-list .project-card { display: grid; grid-template-columns: minmax(150px, 22%) 1fr; }
.is-list .cover { aspect-ratio: auto; min-height: 125px; border-bottom: 0; }
.is-list .card-copy { padding: 16px 24px; }
.is-list .card-meta { margin-bottom: 5px; }
.is-list .card-action { padding-top: 8px; }
.empty-state { margin: 0; text-align: center; color: var(--muted); padding: 46px 16px; border-radius: 14px; border: 1px dashed var(--line); background: #fff; }
#clear-search { padding: 5px 7px; margin-top: 6px; color: var(--action); background: none; border: 0; text-decoration: underline; }
.footer { border-top: 1px solid var(--line); padding-block: 19px 28px; color: #616b70; font-size: .78rem; }
@media (max-width: 930px) {
    .project-grid { gap: 15px; }
    .card-copy { padding: 16px; }
    .stack-art { transform: scale(.86); }
}
@media (max-width: 760px) {
    .hero { min-height: 235px; }
    .stack-art { transform: scale(.75); width: 310px; }
    .project-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .search input { width: 120px; }
}
@media (max-width: 560px) {
    .header-row { min-height: 59px; }
    .brand { font-size: 1.17rem; }
    .brand-mark { width: 30px; height: 30px; margin-right: 6px; }
    .brand-divider, .brand-context { display: none; }
    .manage-link { padding: 7px 10px; font-size: .8rem; }
    .hero { border-radius: 15px; min-height: 226px; grid-template-columns: 1fr; }
    .hero-copy { z-index: 1; padding: 28px 22px; }
    .hero h1 { font-size: clamp(3rem, 10.6vw, 3.6rem); }
    .hero p { font-size: .86rem; width: 72%; max-width: 265px; }
    .hero-art { position: absolute; width: 44%; inset: 0 0 0 auto; z-index: -1; }
    .stack-art { position: absolute; top: 16%; right: -74px; transform: scale(.49); transform-origin: center right; width: 350px; }
    .library-toolbar { flex-wrap: wrap; margin-bottom: 16px; gap: 12px; }
    .library-controls { width: 100%; }
    .search { flex: 1; }
    .search input { width: 100%; }
    .project-grid { grid-template-columns: minmax(0, 1fr); }
    .cover { aspect-ratio: 2.25; }
    .preview-screen { width: 62%; }
    .card-copy { padding: 16px 18px; }
    .card-copy h3 { font-size: 1.3rem; }
    .card-action { padding-top: 13px; }
    .is-list .project-card { grid-template-columns: 80px minmax(0, 1fr); }
    .is-list .preview-screen { width: 100px; transform: rotate(-8deg) scale(.7); }
    .is-list .card-copy { padding: 12px; }
    .is-list h3 { font-size: 1.05rem; }
}
@media (prefers-reduced-motion: reduce) {
    .project-card { transition: none; }
}
