:root {
  --paper: #f6f7f5;
  --surface: #fff;
  --ink: #182d3b;
  --muted: #60717c;
  --line: #dce3e5;
  --teal: #087f79;
  --teal-dark: #075d5a;
  --navy: #132c3b;
  --amber: #bd8a47;
  --danger: #a73939;
  --serif: Georgia, "Times New Roman", serif;
  --sans: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --shadow: 0 12px 32px rgba(18, 44, 59, .08);
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin: 0; background: var(--paper); color: var(--ink); font: 15px/1.6 var(--sans); }
button, input, textarea, select { font: inherit; }
a { color: var(--teal-dark); }
a:hover { color: var(--teal); }
.site-header { min-height: 72px; padding: 0 max(5vw, 22px); display: flex; align-items: center; justify-content: space-between; gap: 28px; border-bottom: 1px solid var(--line); background: rgba(255,255,255,.88); }
.brand { display: inline-flex; align-items: center; gap: 11px; color: var(--navy); text-decoration: none; font: 600 18px var(--serif); }
.brand-mark { display: grid; width: 32px; height: 32px; place-items: center; border-radius: 50%; background: var(--teal-dark); color: #fff; font: 600 14px var(--serif); }
.brand small { display: block; margin-top: 1px; color: var(--muted); font: 9px var(--sans); letter-spacing: .15em; }
.site-nav { display: flex; align-items: center; gap: clamp(14px, 3vw, 36px); }
.site-nav a, .admin-account a { color: #435763; text-decoration: none; font-size: 13px; }
.site-nav .nav-admin { padding: 8px 13px; border: 1px solid var(--line); border-radius: 4px; }
.site-nav a:hover, .admin-account a:hover { color: var(--teal); }
main { min-height: 58vh; }
.page-wrap { width: min(1100px, calc(100% - 42px)); margin: 0 auto; }
.hero { padding: clamp(52px, 8vw, 100px) 0 54px; display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(250px, .9fr); align-items: center; gap: 8%; }
.eyebrow { margin: 0 0 14px; color: var(--teal); font: 10px var(--sans); letter-spacing: .16em; text-transform: uppercase; }
.eyebrow::before { content: ""; display: inline-block; width: 24px; height: 1px; margin: 0 11px 3px 0; background: var(--amber); }
h1, h2, h3 { color: var(--navy); }
.hero h1 { max-width: 650px; margin: 0 0 18px; font: 400 clamp(44px, 6vw, 74px)/1.02 var(--serif); letter-spacing: -.052em; }
.hero h1 em { color: var(--teal); }
.hero-copy { max-width: 480px; color: var(--muted); font-size: 16px; }
.hero-note { margin-top: 26px; padding: 12px 15px; border-left: 2px solid var(--amber); background: #f1f0e9; color: #6b6a5d; font-size: 12px; }
.hero-panel { min-height: 320px; display: flex; flex-direction: column; justify-content: space-between; padding: 30px; overflow: hidden; border-radius: 5px; background: radial-gradient(circle at 83% 18%, transparent 0 30%, #ffffff14 30.3% 30.6%, transparent 30.9%), repeating-linear-gradient(25deg, transparent 0 18px, #ffffff09 19px, transparent 20px), var(--navy); color: #fff; box-shadow: var(--shadow); }
.panel-label, .panel-caption { color: #b9ccc9; font-size: 11px; }
.panel-score { font: 58px/.95 var(--serif); color: #e8d4a9; }
.panel-score small { display: block; margin-top: 10px; color: #cfdbd8; font: 11px var(--sans); letter-spacing: .04em; }
.panel-title { max-width: 280px; margin: auto 0 8px; font: 29px/1.14 var(--serif); }
.panel-caption { margin: 0; }
.search-panel { position: relative; padding: 24px; border: 1px solid var(--line); border-radius: 6px; background: var(--surface); box-shadow: var(--shadow); }
.search-panel label, .field label { display: block; margin: 0 0 7px; color: #3d505b; font-size: 12px; font-weight: 650; }
.search-row { display: flex; gap: 10px; }
.search-row input { flex: 1; min-width: 0; }
.search-row .search-mode { width: auto; max-width: 220px; font-size: 12px; }
.input, .field input, .field select, .field textarea, .search-row input { width: 100%; min-height: 44px; padding: 10px 12px; border: 1px solid #cbd6d9; border-radius: 4px; background: white; color: var(--ink); }
.input:focus, .field input:focus, .field select:focus, .field textarea:focus, .search-row input:focus { border-color: var(--teal); outline: 3px solid #087f7918; }
.search-help, .field-help { color: var(--muted); font-size: 11px; }
.button { min-height: 42px; display: inline-flex; align-items: center; justify-content: center; gap: 7px; padding: 9px 15px; border: 1px solid var(--teal); border-radius: 4px; background: var(--teal); color: white; text-decoration: none; font: 600 13px var(--sans); cursor: pointer; transition: background .18s, transform .18s; }
.button:hover { transform: translateY(-1px); background: var(--teal-dark); color: white; }
.button-secondary { border-color: var(--line); background: white; color: var(--ink); }
.button-secondary:hover { background: #f1f5f4; color: var(--ink); }
.button-danger { border-color: var(--danger); background: var(--danger); }
.button-small { min-height: 34px; padding: 6px 10px; font-size: 12px; }
.section { padding: 42px 0; border-top: 1px solid var(--line); }
.section-heading { display: flex; align-items: end; justify-content: space-between; gap: 20px; margin-bottom: 18px; }
.section-heading h2, .page-heading h1 { margin: 0; font: 34px/1.15 var(--serif); letter-spacing: -.035em; }
.section-kicker { margin: 0 0 6px; color: var(--teal); font: 10px var(--sans); letter-spacing: .15em; text-transform: uppercase; }
.company-grid { display: grid; grid-template-columns: repeat(3, 1fr); border-top: 1px solid var(--line); border-left: 1px solid var(--line); }
.company-card { min-height: 105px; padding: 16px; border-right: 1px solid var(--line); border-bottom: 1px solid var(--line); background: transparent; text-decoration: none; transition: background .18s, transform .18s; }
.company-card:hover { transform: translateY(-2px); background: white; }
.company-card strong { display: block; color: var(--navy); font: 19px var(--serif); }
.company-card span { display: block; margin-top: 6px; color: var(--muted); font-size: 11px; }
.how-grid, .indicator-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 13px; }
.info-card { padding: 18px; border: 1px solid var(--line); border-radius: 5px; background: white; }
.info-card h3 { margin: 0 0 7px; font: 19px var(--serif); }
.info-card p { margin: 0; color: var(--muted); font-size: 12px; }
.disclaimer { margin: 32px 0; display: grid; grid-template-columns: 25px 1fr; gap: 13px; padding: 18px; border: 1px solid #e0d3b6; border-radius: 4px; background: #f4f0e5; color: #786844; }
.disclaimer strong { font-size: 12px; }
.disclaimer p { margin: 5px 0 0; color: #746f61; font-size: 11px; }
.site-footer { padding: 28px max(5vw, 22px) 16px; border-top: 1px solid var(--line); background: #fff; }
.footer-inner { width: min(1100px, 100%); margin: 0 auto; display: flex; justify-content: space-between; gap: 35px; }
.brand-footer { font-size: 16px; }
.footer-inner p { max-width: 420px; margin: 11px 0; color: var(--muted); font-size: 11px; }
.footer-inner nav { display: flex; flex-wrap: wrap; align-content: start; gap: 12px 20px; }
.footer-inner nav a { color: #596b75; font-size: 11px; text-decoration: none; }
.footer-bottom { width: min(1100px, 100%); margin: 18px auto 0; padding-top: 12px; border-top: 1px solid #e9eded; color: #7c898f; font-size: 10px; }
.flash { width: min(1100px, calc(100% - 42px)); margin: 16px auto; padding: 11px 14px; border: 1px solid #b8d9d3; border-radius: 4px; background: #eff8f5; color: #165b52; font-size: 13px; }
.flash-error { border-color: #e6c7c7; background: #fff3f3; color: #8a2525; }
.content-page { width: min(850px, calc(100% - 42px)); margin: 0 auto; padding: 52px 0 70px; }
.content-page h1 { margin: 0 0 20px; font: 42px var(--serif); }
.content-page h2 { margin-top: 32px; font: 25px var(--serif); }
.content-page p, .content-page li { color: #52646d; }
.results-wrap { padding: 50px 0 70px; }
.results-list { display: grid; gap: 12px; margin-top: 23px; }
.result-row { display: flex; align-items: center; justify-content: space-between; gap: 22px; padding: 18px 20px; border: 1px solid var(--line); border-radius: 5px; background: white; text-decoration: none; box-shadow: 0 4px 13px #18314108; }
.result-row:hover { border-color: #96beb9; }
.result-row h2 { margin: 0; font: 22px var(--serif); }
.result-meta { margin-top: 5px; color: var(--muted); font-size: 12px; }
.risk-badge { display: inline-flex; align-items: center; padding: 5px 9px; border-radius: 99px; background: #e7efea; color: #22604c; font-size: 10px; font-weight: 700; white-space: nowrap; }
.risk-moderate { background: #f7f0db; color: #8b681a; }
.risk-high { background: #fbe9d9; color: #985019; }
.risk-critical { background: #fae4e4; color: #9b2727; }
.risk-insufficient_data { background: #edf0f1; color: #58666e; }
.company-detail { padding: 48px 0 65px; }
.detail-head { display: flex; justify-content: space-between; gap: 25px; align-items: start; }
.detail-head h1 { margin: 2px 0 9px; font: 43px var(--serif); }
.detail-meta { display: flex; flex-wrap: wrap; gap: 8px 18px; color: var(--muted); font-size: 12px; }
.detail-panel { margin-top: 28px; padding: 23px; border: 1px solid var(--line); border-radius: 5px; background: white; }
.score-card { display: flex; align-items: center; gap: 18px; }
.score-card strong, .score-card span:not(.score-gauge span) { display: block; }
.score-card strong { font: 23px var(--serif); }
.score-card div:last-child span { margin-top: 5px; color: var(--muted); font-size: 11px; }
.score-progress { width: 120px; height: 12px; flex: 0 0 auto; appearance: none; border: 0; border-radius: 99px; background: #e4e9e8; }
.score-progress::-webkit-progress-bar { border-radius: 99px; background: #e4e9e8; }
.score-progress::-webkit-progress-value { border-radius: 99px; background: var(--teal); }
.score-progress::-moz-progress-bar { border-radius: 99px; background: var(--teal); }
.score-progress.score-moderate::-webkit-progress-value, .score-progress.score-moderate::-moz-progress-bar { background: #bd8a47; }
.score-progress.score-high::-webkit-progress-value, .score-progress.score-high::-moz-progress-bar { background: #bc663b; }
.score-progress.score-critical::-webkit-progress-value, .score-progress.score-critical::-moz-progress-bar { background: #b33838; }
.score-empty { display: grid; gap: 3px; color: var(--muted); }
.score-empty strong { color: var(--ink); font: 21px var(--serif); }
.score-empty span { font-size: 12px; }
.detail-grid { display: grid; grid-template-columns: 1fr .8fr; gap: 20px; margin-top: 20px; }
.detail-box { padding: 20px; border: 1px solid var(--line); border-radius: 5px; background: white; }
.detail-box h2 { margin: 0 0 14px; font: 23px var(--serif); }
.indicator-item { padding: 14px 0; border-top: 1px solid #e9eeee; }
.indicator-item:first-of-type { border-top: 0; padding-top: 0; }
.indicator-title { display: flex; justify-content: space-between; gap: 14px; font-weight: 650; font-size: 13px; }
.indicator-value { color: var(--teal-dark); font: 12px var(--sans); }
.indicator-item p { margin: 6px 0; color: var(--muted); font-size: 12px; }
.evidence-list { margin: 6px 0 0; padding-left: 16px; color: #52646d; font-size: 11px; }
.detail-label { color: var(--muted); font-size: 10px; text-transform: uppercase; letter-spacing: .08em; }
.detail-value { margin: 4px 0 13px; overflow-wrap: anywhere; }
.contact-form { display: grid; gap: 16px; margin-top: 25px; }
.field { display: grid; gap: 6px; }
.field textarea { min-height: 130px; resize: vertical; }
.honeypot { position: absolute !important; left: -10000px !important; width: 1px !important; height: 1px !important; overflow: hidden !important; }

/* Admin portal */
.admin-body { background: #f2f5f6; }
.admin-header { height: 65px; padding: 0 25px; display: flex; align-items: center; justify-content: space-between; background: var(--navy); }
.admin-header .brand { color: white; font-size: 16px; }
.admin-header .brand-mark { background: var(--teal); }
.admin-account { display: flex; align-items: center; gap: 20px; color: #d6e3e4; font-size: 12px; }
.admin-account a { color: #d6e3e4; }
.link-button { border: 0; padding: 0; background: none; color: #d6e3e4; font: inherit; cursor: pointer; }
.link-button:hover { color: white; }
.admin-main .link-button { color: var(--teal-dark); margin: 3px; }
.field input[type="checkbox"] { width: auto; min-height: auto; }
.admin-layout { min-height: calc(100vh - 65px); display: grid; grid-template-columns: 220px minmax(0, 1fr); }
.admin-sidebar { padding: 22px 12px; background: #1a3848; }
.admin-sidebar nav { display: grid; gap: 5px; }
.admin-sidebar a { padding: 9px 12px; border-radius: 4px; color: #c8d4d7; font-size: 12px; text-decoration: none; }
.admin-sidebar a:hover, .admin-sidebar a.active { background: #254859; color: white; }
.admin-main { min-width: 0; width: min(1200px, 100%); padding: 34px clamp(18px, 4vw, 50px); }
.admin-main .flash { width: 100%; margin: 0 0 18px; }
.admin-page-heading { margin-bottom: 23px; }
.admin-page-heading .eyebrow { margin-bottom: 5px; }
.admin-page-heading h1 { margin: 0; font: 34px var(--serif); }
.stat-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 13px; margin-bottom: 22px; }
.stat-card { padding: 16px; border: 1px solid var(--line); border-radius: 5px; background: white; }
.stat-card span { display: block; color: var(--muted); font-size: 11px; }
.stat-card strong { display: block; margin-top: 4px; color: var(--navy); font: 27px var(--serif); }
.admin-card { min-width: 0; max-width: 100%; margin-bottom: 18px; padding: 18px; border: 1px solid var(--line); border-radius: 5px; background: white; }
.admin-card h2 { margin: 0 0 14px; font: 22px var(--serif); }
.admin-toolbar { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 14px; margin-bottom: 15px; }
.admin-toolbar h2 { margin: 0; }
.table-wrap { min-width: 0; max-width: 100%; overflow-x: auto; }
table { width: 100%; border-collapse: collapse; background: white; font-size: 12px; }
th, td { padding: 11px 10px; border-bottom: 1px solid #e8eded; text-align: left; vertical-align: top; }
th { color: #596a73; font-size: 10px; text-transform: uppercase; letter-spacing: .08em; }
td { color: #30434d; }
td a { text-decoration: none; }
.form-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 15px; }
.form-grid .wide { grid-column: 1 / -1; }
.form-actions { display: flex; flex-wrap: wrap; gap: 9px; margin-top: 17px; }
.inline-form { display: inline; }
.filter-row { display: flex; flex-wrap: wrap; gap: 9px; margin-bottom: 14px; }
.filter-row > input, .filter-row > select { min-width: 0; flex: 1 1 160px; }
.score-input { width: 85px; }
.status-text { font-size: 11px; color: var(--muted); }
.auth-wrap { width: min(440px, calc(100% - 38px)); margin: 8vh auto; }
.auth-card { padding: 28px; border: 1px solid var(--line); border-radius: 6px; background: white; box-shadow: var(--shadow); }
.auth-card h1 { margin: 0 0 7px; font: 30px var(--serif); }
.auth-card > p { margin: 0 0 20px; color: var(--muted); font-size: 12px; }
.auth-card .contact-form { gap: 13px; }
.admin-notice { padding: 13px 15px; border-left: 3px solid var(--amber); background: #f7f3e9; color: #6c614a; font-size: 12px; }
.pagination { display: flex; gap: 8px; align-items: center; margin-top: 14px; font-size: 12px; }
@media (max-width: 850px) {
  .hero { grid-template-columns: 1fr; gap: 25px; }
  .hero-panel { min-height: 230px; }
  .how-grid, .indicator-grid { grid-template-columns: repeat(2, 1fr); }
  .admin-layout { grid-template-columns: minmax(0, 1fr); }
  .admin-sidebar { padding: 10px; }
  .admin-sidebar nav { grid-template-columns: repeat(3, max-content); overflow-x: auto; }
  .stat-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 570px) {
  .site-header { align-items: flex-start; flex-direction: column; gap: 10px; padding: 14px 18px; }
  .site-nav { width: 100%; justify-content: space-between; gap: 8px; }
  .site-nav a { font-size: 11px; }
  .page-wrap { width: calc(100% - 34px); }
  .hero { padding-top: 47px; }
  .hero h1 { font-size: 49px; }
  .search-panel { padding: 17px; }
  .search-row { flex-direction: column; }
  .search-row .search-mode { width: 100%; max-width: none; }
  .company-grid, .how-grid, .indicator-grid, .detail-grid { grid-template-columns: 1fr; }
  .section-heading, .result-row, .detail-head, .footer-inner { align-items: flex-start; flex-direction: column; }
  .detail-head h1 { font-size: 35px; }
  .admin-header { padding: 0 14px; }
  .admin-account { gap: 8px; font-size: 10px; }
  .admin-sidebar nav { grid-template-columns: repeat(2, max-content); }
  .admin-main { padding: 25px 14px; }
  .filter-row { flex-direction: column; }
  .filter-row > input, .filter-row > select { flex: initial; width: 100%; }
  .form-grid { grid-template-columns: 1fr; }
  .form-grid .wide { grid-column: auto; }
  .stat-grid { gap: 8px; }
  .stat-card { padding: 12px; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; transition-duration: .01ms !important; }
}
