:root {
  color-scheme: dark;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-synthesis: none;
  --page: #17181a;
  --surface: #202124;
  --surface-raised: #26272a;
  --line: #3c3d40;
  --line-strong: #57585a;
  --text: #f0efea;
  --muted: #aaa9a6;
  --quiet: #85878a;
  --selection: #dedbd3;
  background: var(--page);
  color: var(--text);
}
* { box-sizing: border-box; }
body { min-width: 320px; margin: 0; background: var(--page); }
button, input, select { font: inherit; }
button, summary { cursor: pointer; }
[hidden] { display: none !important; }
:focus-visible { outline: 2px solid var(--selection); outline-offset: 3px; }

.app-shell { width: min(100%, 860px); margin: 0 auto; padding: 0 28px 56px; }
.app-header { height: 68px; display: flex; align-items: center; border-bottom: 1px solid var(--line); }
.app-header h1 { margin: 0; font-size: 1.2rem; font-weight: 630; letter-spacing: -.025em; }

.control-section { padding: 19px 0 21px; border-bottom: 1px solid var(--line); }
.section-heading { display: flex; align-items: baseline; gap: 12px; margin-bottom: 13px; }
.section-heading h2 { margin: 0; font-size: 1rem; line-height: 1.3; font-weight: 600; letter-spacing: -.015em; }
.section-heading span { color: var(--quiet); font-size: .8rem; }

.device-choices, .task-choices, .memory-choices { border: 0; margin: 0; padding: 0; min-width: 0; }
.device-choices { display: inline-flex; max-width: 100%; overflow: hidden; border: 1px solid var(--line-strong); border-radius: 8px; }
.device-choices label, .task-choices label, .memory-choices label { position: relative; display: block; cursor: pointer; }
.device-choices input, .task-choices input, .memory-choices input { position: absolute; width: 1px; height: 1px; opacity: 0; }
.device-choices label > span { display: flex; align-items: center; justify-content: center; min-height: 42px; padding: 8px 19px; border-right: 1px solid var(--line-strong); background: var(--surface); color: #d4d4d1; font-size: .875rem; line-height: 1.2; text-align: center; }
.device-choices label:last-child > span { border-right: 0; }
.device-choices input:checked + span, .task-choices input:checked + span, .memory-choices input:checked + span { background: var(--selection); border-color: var(--selection); color: #1c1d1f; font-weight: 600; }
.device-choices label:hover > span, .task-choices label:hover > span, .memory-choices label:hover > span { filter: brightness(1.12); }
.device-choices input:focus-visible + span, .task-choices input:focus-visible + span, .memory-choices input:focus-visible + span { outline: 2px solid var(--selection); outline-offset: -3px; }

.device-input { margin-top: 15px; }
.device-input > label, .memory-choices legend, .field label, .gpu-search label { display: block; margin: 0 0 8px; color: #c8c8c4; font-size: .875rem; line-height: 1.35; font-weight: 500; }
.memory-choices { display: flex; flex-wrap: wrap; gap: 8px; }
.memory-choices legend { width: 100%; padding: 0; }
.memory-choices label > span, .task-choices label > span { display: flex; align-items: center; justify-content: center; min-height: 38px; padding: 7px 14px; border: 1px solid var(--line-strong); border-radius: 7px; background: var(--surface); color: #d9d9d5; font-size: .875rem; line-height: 1.2; }
.memory-choices label > span { min-width: 62px; }
.task-choices { display: flex; flex-wrap: wrap; gap: 8px; }

.device-input > select, .device-input > input, .field input, .field select, .gpu-entry select, .gpu-search input, .catalog-body input {
  height: 42px; border: 1px solid var(--line-strong); border-radius: 7px; background-color: var(--surface);
  color: var(--text); padding: 0 12px; font-size: .9rem; outline: 0;
}
.device-input > select, .field input, .field select, .gpu-search input { width: 100%; }
.device-input > select, .field select, .gpu-entry select {
  appearance: none; padding-right: 38px; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 16 16'%3E%3Cpath d='m4 6 4 4 4-4' fill='none' stroke='%23bbbcb9' stroke-width='1.5'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-position: right 12px center;
}
input::placeholder { color: var(--quiet); }
.field-help { color: var(--muted); font-size: .78rem; line-height: 1.5; margin: 8px 0 0; }
.gpu-entry { display: flex; align-items: center; gap: 14px; max-width: 530px; }
.gpu-entry select { flex: 1; min-width: 0; }
.text-control { padding: 8px 0; border: 0; background: transparent; color: var(--text); font-size: .82rem; text-decoration: underline; text-decoration-color: var(--quiet); text-underline-offset: 3px; white-space: nowrap; }
.gpu-search { max-width: 530px; margin-top: 12px; }

.priority-control { width: min(100%, 510px); }
.priority-top { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.priority-top label { font-size: .9rem; color: #d8d8d4; }
.priority-top label span { margin: 0 5px; color: var(--quiet); }
.priority-top output { font-size: .875rem; color: var(--text); font-weight: 600; }
.priority-control input[type=range] { appearance: none; display: block; width: 100%; height: 4px; margin: 18px 0 0; border-radius: 3px; background: var(--line-strong); cursor: pointer; }
.priority-control input[type=range]::-webkit-slider-thumb { appearance: none; width: 18px; height: 18px; border-radius: 50%; border: 3px solid var(--page); background: var(--selection); box-shadow: 0 0 0 1px var(--selection); }
.priority-control input[type=range]::-moz-range-thumb { width: 12px; height: 12px; border-radius: 50%; border: 3px solid var(--page); background: var(--selection); box-shadow: 0 0 0 1px var(--selection); }
.range-ticks { display: flex; justify-content: space-between; padding: 7px 2px 0; }
.range-ticks span { width: 3px; height: 4px; background: var(--quiet); }
.range-ends { display: flex; justify-content: space-between; margin-top: 3px; color: var(--muted); font-size: .75rem; }

.advanced { border-bottom: 1px solid var(--line); }
.advanced > summary { display: flex; align-items: center; justify-content: space-between; gap: 12px; min-height: 49px; list-style: none; }
.advanced > summary::-webkit-details-marker, .model-row summary::-webkit-details-marker, .catalog > summary::-webkit-details-marker { display: none; }
.advanced > summary > span:first-child { color: #dcdcd7; font-size: .875rem; font-weight: 550; }
.advanced > summary > span:first-child::after { content: '⌄'; display: inline-block; margin-left: 8px; color: var(--muted); }
.advanced[open] > summary > span:first-child::after { transform: rotate(180deg); }
.advanced > summary > span:last-child { color: var(--muted); font-size: .78rem; text-align: right; }
.advanced-fields { display: grid; grid-template-columns: repeat(2, minmax(0,1fr)); gap: 16px; padding: 4px 0 13px; }
.advanced > .field-help { margin: 0 0 16px; }
.form-error { border: 1px solid #986b63; border-radius: 7px; background: #372b29; color: #f6d8d0; padding: 10px 12px; font-size: .875rem; margin: 12px 0 0; }

.results { padding-top: 27px; }
.results-heading { display: flex; align-items: end; justify-content: space-between; gap: 16px; padding-bottom: 14px; border-bottom: 1px solid var(--line-strong); }
.results-heading h2 { margin: 0; font-size: 1.42rem; line-height: 1.2; font-weight: 620; letter-spacing: -.03em; }
.results-heading p { margin: 5px 0 0; color: var(--muted); font-size: .83rem; line-height: 1.4; }
.results-note { flex: none; color: var(--quiet); font-size: .77rem; white-space: nowrap; }
.initial-state { margin: 25px 0; color: var(--muted); font-size: .9rem; }

.model-row { border-bottom: 1px solid var(--line); }
.model-row > summary { display: grid; grid-template-columns: minmax(0,1fr) 112px 132px 17px; gap: 16px; align-items: center; min-height: 82px; padding: 12px 8px; list-style: none; }
.model-row > summary:hover { background: #1c1d20; }
.model-title { min-width: 0; }
.model-title strong { display: block; color: var(--text); font-size: 1rem; line-height: 1.3; font-weight: 600; letter-spacing: -.015em; overflow-wrap: anywhere; }
.model-title small { display: block; margin-top: 5px; color: var(--muted); font-size: .77rem; line-height: 1.35; }
.metric { min-width: 0; }
.metric > span { display: block; margin-bottom: 4px; color: var(--quiet); font-size: .75rem; }
.metric strong { color: var(--text); font-size: .93rem; font-weight: 600; line-height: 1.25; }
.chevron { width: 8px; height: 8px; border-right: 1.5px solid var(--muted); border-bottom: 1.5px solid var(--muted); transform: rotate(45deg); transition: transform .16s; }
.model-row[open] .chevron { transform: rotate(225deg); }
.model-details { padding: 0 20px 18px 8px; color: #c4c4c0; font-size: .85rem; line-height: 1.5; }
.model-details p { margin: 0 0 15px; }
.detail-grid { display: grid; grid-template-columns: repeat(4, minmax(0,1fr)); gap: 16px; padding: 13px 0; border-top: 1px solid var(--line); }
.detail-grid > div { min-width: 0; }
.detail-label { display: block; color: var(--quiet); font-size: .75rem; margin-bottom: 4px; }
.detail-grid strong { display: block; color: var(--text); font-size: .83rem; font-weight: 550; overflow-wrap: anywhere; }
.model-details .ram-warning { color: #e1c4a6; margin: 4px 0 0; }
.model-details p:last-child { margin-bottom: 0; }
.show-more, .browse-more { width: 100%; padding: 13px 8px; border: 0; background: transparent; color: #deded9; font-size: .82rem; text-align: left; }
.show-more:hover, .browse-more:hover, .text-control:hover { text-decoration: underline; }
.hidden-row { display: none; }
.expanded-list .hidden-row { display: block; }

.catalog { margin-top: 17px; border: 1px solid var(--line); border-radius: 8px; background: var(--surface); }
.catalog > summary { list-style: none; padding: 14px 16px; color: var(--text); font-size: .88rem; font-weight: 550; }
.catalog > summary::after { content: '⌄'; float: right; color: var(--muted); }
.catalog[open] > summary::after { transform: rotate(180deg); }
.catalog-body { padding: 0 16px 16px; }
.catalog-body > p:first-child { margin: 0 0 13px; color: var(--muted); font-size: .8rem; line-height: 1.45; }
.catalog-body label { display: block; margin-bottom: 7px; color: #d6d6d2; font-size: .875rem; }
.catalog-body input { width: min(100%,390px); }
.catalog-count { color: var(--muted); font-size: .78rem; margin: 12px 0 4px; }
.catalog-list { border-top: 1px solid var(--line); }
.catalog-list .model-row > summary { min-height: 72px; }
.catalog-no-results { color: var(--muted); font-size: .875rem; margin: 14px 0 0; }
.browse-more { padding-left: 0; border-top: 1px solid var(--line); }
.secondary-heading { margin: 25px 0 0; padding-bottom: 10px; border-bottom: 1px solid var(--line-strong); font-size: .97rem; font-weight: 600; }
.empty-state { padding: 20px 0; border-bottom: 1px solid var(--line); }
.empty-state strong { font-size: .9rem; font-weight: 600; }
.empty-state p { color: var(--muted); font-size: .85rem; line-height: 1.5; margin: 6px 0 0; }

.resources { margin-top: 21px; border-top: 1px solid var(--line); padding-top: 19px; }
.resources h3 { margin: 0 0 5px; font-size: 1rem; font-weight: 600; }
.resources > p { color: var(--muted); font-size: .85rem; line-height: 1.5; margin: 0 0 13px; }
.resource-grid { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 12px; }
.resource-card { padding: 15px; border: 1px solid var(--line); border-radius: 8px; background: var(--surface); }
.resource-card strong { font-size: .9rem; font-weight: 600; }
.resource-card p { color: var(--muted); font-size: .8rem; line-height: 1.5; margin: 8px 0 11px; }
.resource-card a, .privacy-note a { color: #e4e4df; text-decoration: underline; text-decoration-color: var(--quiet); text-underline-offset: 3px; }
.resource-card a { display: inline-block; margin-right: 12px; font-size: .8rem; }
.privacy-note { color: var(--muted); font-size: .8rem; line-height: 1.5; margin: 12px 0 0; }
.method-note { padding-top: 19px; color: var(--muted); font-size: .78rem; line-height: 1.55; }
.method-note summary { color: #d5d5d0; font-size: .82rem; }
.method-note p { margin: 9px 0 0; }
.method-note strong { color: #dddcd5; font-weight: 550; }

@media (max-width: 700px) {
  .app-shell { padding: 0 20px 40px; }
  .model-row > summary { grid-template-columns: minmax(0,1fr) 86px 17px; gap: 12px; }
  .model-row .metric.speed { display: none; }
  .detail-grid { grid-template-columns: repeat(2,minmax(0,1fr)); }
}
@media (max-width: 500px) {
  .app-shell { padding: 0 16px 36px; }
  .app-header { height: 60px; }
  .control-section { padding: 17px 0 19px; }
  .device-choices { display: grid; grid-template-columns: repeat(3,minmax(0,1fr)); width: 100%; }
  .device-choices label > span { height: 100%; padding: 8px 7px; }
  .memory-choices, .task-choices { gap: 7px; }
  .memory-choices label > span, .task-choices label > span { min-height: 37px; padding: 7px 11px; }
  .advanced-fields, .resource-grid { grid-template-columns: 1fr; }
  .results { padding-top: 23px; }
  .results-heading { align-items: start; }
  .results-heading h2 { font-size: 1.26rem; }
  .results-note { max-width: 91px; white-space: normal; text-align: right; line-height: 1.35; }
  .model-row > summary { grid-template-columns: minmax(0,1fr) 76px 13px; gap: 10px; padding: 12px 3px; }
  .model-title strong { font-size: .94rem; }
  .model-title small { font-size: .75rem; }
  .metric strong { font-size: .83rem; }
  .model-details { padding-left: 3px; }
}
@media (max-width: 370px) {
  .gpu-entry { flex-wrap: wrap; align-items: start; }
  .gpu-entry select { flex-basis: 100%; }
}
@media (prefers-reduced-motion: reduce) { * { transition: none !important; } }

/* Landing, sharing and trust content */
.brand { color: var(--text); font-size: 1.2rem; font-weight: 630; letter-spacing: -.025em; text-decoration: none; }
.hero { padding: 50px 0 28px; border-bottom: 1px solid var(--line); }
.eyebrow { margin: 0 0 10px; color: var(--quiet); font-size: .72rem; font-weight: 650; letter-spacing: .08em; text-transform: uppercase; }
.hero h1 { max-width: 700px; margin: 0; font-size: clamp(2rem, 5vw, 3.35rem); line-height: .99; letter-spacing: -.055em; font-weight: 650; }
.hero > p:not(.eyebrow):not(.hero-note) { max-width: 650px; margin: 18px 0 0; color: #cececa; font-size: 1rem; line-height: 1.6; }
.hero-note { margin: 12px 0 0; color: var(--quiet); font-size: .78rem; line-height: 1.5; }
.result-actions { min-height: 48px; display: flex; align-items: center; gap: 12px; border-bottom: 1px solid var(--line); }
.secondary-button { padding: 8px 0; border: 0; background: transparent; color: #deded9; font-size: .8rem; text-decoration: underline; text-decoration-color: var(--quiet); text-underline-offset: 3px; }
.secondary-button:hover { text-decoration-color: var(--text); }
.share-status { color: var(--quiet); font-size: .78rem; }
.content-section { margin-top: 56px; padding-top: 28px; border-top: 1px solid var(--line-strong); }
.content-section > h2 { max-width: 650px; margin: 0; font-size: 1.55rem; line-height: 1.2; letter-spacing: -.03em; font-weight: 620; }
.info-grid { display: grid; grid-template-columns: repeat(3,minmax(0,1fr)); gap: 12px; margin-top: 22px; }
.info-grid article { padding: 17px; border: 1px solid var(--line); border-radius: 8px; background: var(--surface); }
.step-number { color: var(--quiet); font-size: .72rem; letter-spacing: .08em; }
.info-grid h3 { margin: 22px 0 7px; font-size: .95rem; font-weight: 600; }
.info-grid p { margin: 0; color: var(--muted); font-size: .82rem; line-height: 1.55; }
.faq details { border-bottom: 1px solid var(--line); }
.faq details:first-of-type { margin-top: 18px; border-top: 1px solid var(--line); }
.faq summary { padding: 15px 0; color: #e0dfda; font-size: .9rem; font-weight: 550; }
.faq details p { max-width: 700px; margin: -4px 0 17px; color: var(--muted); font-size: .84rem; line-height: 1.6; }
.disclaimer-panel { margin-top: 45px; padding: 18px; border: 1px solid var(--line); border-radius: 8px; background: var(--surface); }
.disclaimer-panel h2 { margin: 0 0 8px; font-size: .95rem; font-weight: 600; }
.disclaimer-panel p { margin: 7px 0 0; color: var(--muted); font-size: .8rem; line-height: 1.55; }
.disclaimer-panel a, .site-footer a { color: #dddcd7; text-decoration: underline; text-decoration-color: var(--quiet); text-underline-offset: 3px; }
.site-footer { display: flex; justify-content: space-between; gap: 18px; align-items: center; margin-top: 28px; padding: 22px 0 0; border-top: 1px solid var(--line); color: var(--quiet); font-size: .75rem; }
.site-footer nav { display: flex; flex-wrap: wrap; gap: 14px; }

.legal-shell { width: min(100%, 760px); margin: 0 auto; padding: 0 28px 64px; }
.legal-content { padding: 46px 0 0; }
.legal-content h1 { margin: 0 0 12px; font-size: clamp(2rem, 5vw, 2.8rem); line-height: 1.05; letter-spacing: -.045em; }
.legal-content h2 { margin: 32px 0 8px; font-size: 1.08rem; }
.legal-content p, .legal-content li { color: #c0c0bc; font-size: .9rem; line-height: 1.65; }
.legal-content a { color: var(--text); }
.legal-content .updated { color: var(--quiet); font-size: .78rem; }

@media (max-width: 700px) {
  .hero { padding-top: 38px; }
  .info-grid { grid-template-columns: 1fr; }
}
@media (max-width: 500px) {
  .hero { padding: 32px 0 23px; }
  .hero h1 { font-size: 2.2rem; }
  .site-footer { align-items: flex-start; flex-direction: column; }
  .legal-shell { padding: 0 16px 42px; }
}

/* Quiet ambient colour: a slow, low-contrast aurora behind the interface. */
body {
  position: relative;
  isolation: isolate;
  overflow-x: hidden;
}
body::before {
  content: '';
  position: fixed;
  z-index: -1;
  inset: -18vh -14vw;
  pointer-events: none;
  background:
    radial-gradient(circle at 18% 22%, rgba(76, 118, 160, .13), transparent 32%),
    radial-gradient(circle at 82% 18%, rgba(112, 82, 138, .11), transparent 30%),
    radial-gradient(circle at 66% 78%, rgba(62, 126, 116, .09), transparent 34%);
  filter: blur(28px) saturate(.85);
  opacity: .68;
  transform: translate3d(0, 0, 0) scale(1.02);
  animation: ambient-drift 24s ease-in-out infinite alternate;
}
body::after {
  content: '';
  position: fixed;
  z-index: -1;
  inset: 0;
  pointer-events: none;
  background: linear-gradient(180deg, rgba(23, 24, 26, .10), rgba(23, 24, 26, .78) 70%, var(--page));
}

@keyframes ambient-drift {
  0% { transform: translate3d(-1.2%, -.8%, 0) scale(1.02); }
  50% { transform: translate3d(1.4%, .9%, 0) scale(1.055); }
  100% { transform: translate3d(-.4%, 1.5%, 0) scale(1.035); }
}

@media (prefers-reduced-motion: reduce) {
  body::before { animation: none; }
}
