/* Open EU Commons capability registry. */
:root {
  color-scheme: light;
  --ink: #171717;
  --muted: #656565;
  --line: #d7d7d7;
  --line-strong: #999;
  --surface: #fff;
  --subtle: #f5f5f5;
  font-family: Arial, Helvetica, sans-serif;
}

* { box-sizing: border-box; }
body { margin: 0; min-width: 320px; background: var(--surface); color: var(--ink); font-size: 16px; line-height: 1.5; }
button, select, textarea { font: inherit; }
a { color: inherit; text-decoration-thickness: 1px; text-underline-offset: 3px; }

.service-header { min-height: 68px; padding: 0 max(24px, calc((100vw - 1200px) / 2)); display: flex; align-items: center; justify-content: space-between; gap: 24px; border-bottom: 1px solid var(--ink); background: white; }
.identity { display: flex; align-items: center; gap: 12px; color: inherit; text-decoration: none; }
.identity > span:last-child { display: grid; line-height: 1.2; }
.identity strong { font-size: 1rem; }
.identity small, .prototype-label { color: var(--muted); font-size: .75rem; }
.identity-mark { position: relative; width: 28px; height: 28px; display: block; border: 1px solid var(--ink); border-radius: 50%; }
.identity-mark i { position: absolute; width: 3px; height: 3px; border-radius: 50%; background: var(--ink); }
.identity-mark i:nth-child(1) { left: 12px; top: 3px; }.identity-mark i:nth-child(2) { right: 5px; top: 7px; }.identity-mark i:nth-child(3) { right: 5px; bottom: 7px; }.identity-mark i:nth-child(4) { left: 12px; bottom: 3px; }.identity-mark i:nth-child(5) { left: 5px; bottom: 7px; }.identity-mark i:nth-child(6) { left: 5px; top: 7px; }
.prototype-label { padding: 4px 7px; border: 1px solid var(--line); }

main { width: min(1200px, calc(100% - 48px)); margin: 0 auto; }
.breadcrumb { padding: 22px 0 12px; display: flex; gap: 8px; color: var(--muted); font-size: .82rem; }
.page-heading { padding: 34px 0 38px; display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 50px; align-items: end; border-bottom: 1px solid var(--ink); }
.section-label { margin: 0 0 8px; color: var(--muted); font-size: .72rem; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; }
h1 { max-width: 720px; margin: 0; font-size: clamp(2.2rem, 4vw, 3.8rem); font-weight: 500; line-height: 1.04; letter-spacing: -.035em; }
.intro { max-width: 760px; margin: 16px 0 0; color: #4c4c4c; font-size: 1.03rem; }
.registry-summary { min-width: 340px; margin: 0; display: grid; grid-template-columns: repeat(3, 1fr); border: 1px solid var(--line-strong); }
.registry-summary div { padding: 12px 14px; border-right: 1px solid var(--line); }
.registry-summary div:last-child { border: 0; }
.registry-summary dt { color: var(--muted); font-size: .7rem; }
.registry-summary dd { margin: 2px 0 0; font-weight: 700; }

.application-layout { margin: 30px 0; display: grid; grid-template-columns: 340px minmax(0, 1fr); border: 1px solid var(--line-strong); }
.search-panel, .results-panel { padding: 25px; }
.search-panel { border-right: 1px solid var(--line-strong); background: var(--subtle); }
.panel-heading { display: flex; gap: 12px; align-items: flex-start; margin-bottom: 22px; }
.panel-heading h2 { margin: 0; font-size: 1.08rem; }
.panel-heading p { margin: 2px 0 0; color: var(--muted); font-size: .78rem; }
.step { min-width: 26px; height: 26px; display: grid; place-items: center; border: 1px solid var(--ink); font-size: .7rem; font-weight: 700; }
form { display: grid; gap: 7px; }
label { margin-top: 8px; font-size: .78rem; font-weight: 700; }
select, textarea { width: 100%; padding: 10px; border: 1px solid var(--line-strong); border-radius: 0; background: white; color: var(--ink); outline: none; }
select:focus, textarea:focus { border-color: var(--ink); box-shadow: 0 0 0 1px var(--ink); }
textarea { min-height: 102px; resize: vertical; line-height: 1.45; }
.primary-button, .secondary-button, .row-action, .champion-action { min-height: 40px; padding: 8px 13px; border-radius: 0; cursor: pointer; font-weight: 700; }
.primary-button { margin-top: 12px; border: 1px solid var(--ink); background: var(--ink); color: white; }
.primary-button:hover { background: #333; }
.secondary-button, .row-action, .champion-action { border: 1px solid var(--ink); background: white; color: var(--ink); }
.field-note { margin: 17px 0 0; padding-top: 14px; border-top: 1px solid var(--line); color: var(--muted); font-size: .72rem; }
.results-heading { padding-bottom: 17px; border-bottom: 1px solid var(--line); }

.match-summary { margin-bottom: 14px; padding: 10px 12px; border-left: 3px solid var(--ink); background: var(--subtle); font-size: .82rem; }
.registry-table { width: 100%; border-collapse: collapse; }
.registry-table th, table th { padding: 8px; border-bottom: 1px solid var(--ink); text-align: left; font-size: .7rem; text-transform: uppercase; letter-spacing: .04em; }
.registry-table td { padding: 15px 8px; border-bottom: 1px solid var(--line); vertical-align: top; font-size: .8rem; }
.tool-name { display: block; font-size: .92rem; }
.tool-description { display: block; max-width: 280px; margin-top: 3px; color: var(--muted); font-size: .74rem; }
.status-text { font-weight: 700; }
.row-action, .champion-action { min-height: 32px; padding: 5px 8px; font-size: .72rem; }
.row-action.selected, .champion-action.requested { background: var(--ink); color: white; }

.no-match { border: 1px solid var(--line-strong); }
.no-match-header { padding: 17px 19px; border-left: 4px solid var(--ink); background: var(--subtle); }
.no-match-header h3 { margin: 0; font-size: 1.02rem; }
.no-match-header p { margin: 4px 0 0; color: var(--muted); font-size: .82rem; }
.requirement-review { padding: 19px; }
.requirement-review h4 { margin: 0 0 11px; font-size: .75rem; text-transform: uppercase; }
.requirement-review dl { margin: 0; display: grid; grid-template-columns: repeat(2, 1fr); gap: 11px 22px; }
.requirement-review dt { color: var(--muted); font-size: .7rem; }
.requirement-review dd { margin: 2px 0 0; font-size: .82rem; font-weight: 650; }
.build-route { padding: 16px 19px; border-top: 1px solid var(--line); background: var(--subtle); display: flex; align-items: center; justify-content: space-between; gap: 20px; }
.build-route p { margin: 0; color: var(--muted); font-size: .8rem; }

.champion-section { margin-top: 23px; border-top: 1px solid var(--ink); }
.champion-heading { padding: 15px 0 10px; display: flex; justify-content: space-between; gap: 20px; align-items: end; }
.champion-heading h3 { margin: 0; font-size: .96rem; }
.champion-heading p { max-width: 430px; margin: 0; color: var(--muted); font-size: .72rem; text-align: right; }
.champion-list { border: 1px solid var(--line-strong); }
.champion-row { display: grid; grid-template-columns: 1.05fr 1.25fr .8fr auto; gap: 16px; align-items: center; padding: 14px; border-bottom: 1px solid var(--line); }
.champion-row:last-child { border-bottom: 0; }
.champion-company strong { display: block; font-size: .84rem; }
.champion-company span, .champion-detail span { display: block; margin-top: 2px; color: var(--muted); font-size: .7rem; }
.champion-detail strong { display: block; font-size: .77rem; }
.champion-outcome { font-size: .78rem; font-weight: 700; }
.champion-action { white-space: nowrap; }

.build-brief { margin: 30px 0; border: 1px solid var(--line-strong); }
.brief-header { padding: 22px 25px; display: flex; justify-content: space-between; align-items: start; gap: 20px; border-bottom: 1px solid var(--ink); }
.brief-header h2 { margin: 0; font-size: 1.4rem; font-weight: 500; }
.brief-header h2 span { color: var(--muted); font-family: monospace; font-size: .78rem; font-weight: 400; }
.draft-status { padding: 4px 7px; border: 1px solid var(--line-strong); color: var(--muted); font-size: .7rem; }
.brief-grid { display: grid; grid-template-columns: 1.15fr .85fr; }
.brief-grid > section { padding: 23px 25px; border-bottom: 1px solid var(--line); }
.brief-grid > section + section { border-left: 1px solid var(--line); }
.build-brief h3 { margin: 0 0 13px; font-size: .88rem; }
.definition-list { margin: 19px 0 0; display: grid; grid-template-columns: repeat(2, 1fr); gap: 13px; }
.definition-list dt, .funding-list dt { color: var(--muted); font-size: .72rem; }
.definition-list dd { margin: 2px 0 0; font-size: .82rem; font-weight: 650; }
.funding-list { margin: 0; }
.funding-list div { padding: 6px 0; display: flex; justify-content: space-between; gap: 20px; border-bottom: 1px solid var(--line); }
.funding-list dd { margin: 0; font-size: .82rem; font-variant-numeric: tabular-nums; }
.funding-list .total { margin-top: 4px; padding-top: 10px; border-bottom: 0; font-weight: 700; }
.scenario-note { margin: 12px 0 0; color: var(--muted); font-size: .7rem; }
.deliverables, .milestones, .brief-champions { padding: 23px 25px; border-bottom: 1px solid var(--line); }
.deliverable-grid { display: grid; grid-template-columns: repeat(4, 1fr); border: 1px solid var(--line); }
.deliverable-grid div { min-height: 132px; padding: 15px; border-right: 1px solid var(--line); }
.deliverable-grid div:last-child { border: 0; }
.deliverable-grid strong { display: block; margin-bottom: 6px; font-size: .82rem; }
.deliverable-grid span { color: var(--muted); font-size: .74rem; }
.brief-champions { display: grid; grid-template-columns: .65fr 1.35fr; gap: 26px; background: var(--subtle); }
.brief-champions p { margin: 0; color: var(--muted); font-size: .74rem; }
.brief-champion-list { border-left: 1px solid var(--ink); }
.brief-champion { padding: 8px 0 8px 15px; border-bottom: 1px solid var(--line); }
.brief-champion:last-child { border-bottom: 0; }
.brief-champion strong { display: block; font-size: .8rem; }
.brief-champion span { color: var(--muted); font-size: .72rem; }
table { width: 100%; border-collapse: collapse; }
td { padding: 10px; border-bottom: 1px solid var(--line); font-size: .78rem; }
td:last-child { font-weight: 700; white-space: nowrap; }
.brief-actions { min-height: 72px; padding: 14px 25px; display: flex; align-items: center; gap: 9px; background: var(--subtle); }
.brief-actions .primary-button { margin: 0; }
#action-message { margin-left: 8px; font-size: .76rem; font-weight: 650; }

footer { padding: 4px 0 34px; display: flex; justify-content: space-between; gap: 30px; color: var(--muted); font-size: .72rem; }
footer p { margin: 0; }

@media (max-width: 900px) {
  .page-heading { grid-template-columns: 1fr; gap: 24px; }.registry-summary { min-width: 0; }
  .application-layout { grid-template-columns: 1fr; }.search-panel { border-right: 0; border-bottom: 1px solid var(--line-strong); }
  .brief-grid { grid-template-columns: 1fr; }.brief-grid > section + section { border-left: 0; }
  .deliverable-grid { grid-template-columns: repeat(2, 1fr); }.deliverable-grid div:nth-child(2) { border-right: 0; }.deliverable-grid div:nth-child(-n+2) { border-bottom: 1px solid var(--line); }
  .champion-row { grid-template-columns: 1fr 1fr; }.brief-champions { grid-template-columns: 1fr; }
}

@media (max-width: 600px) {
  .service-header { padding: 12px 18px; }.prototype-label { display: none; }
  main { width: min(100% - 28px, 1200px); }.registry-summary { grid-template-columns: 1fr; }.registry-summary div { border-right: 0; border-bottom: 1px solid var(--line); }
  .search-panel, .results-panel { padding: 19px 15px; }.requirement-review dl, .definition-list { grid-template-columns: 1fr; }
  .build-route { align-items: stretch; flex-direction: column; }.deliverable-grid { grid-template-columns: 1fr; }.deliverable-grid div { border-right: 0; border-bottom: 1px solid var(--line); }
  .champion-heading { align-items: start; flex-direction: column; }.champion-heading p { text-align: left; }.champion-row { grid-template-columns: 1fr; gap: 7px; }
  .brief-grid > section, .deliverables, .milestones, .brief-champions { padding: 19px 16px; }.milestones { overflow-x: auto; }.brief-actions { align-items: stretch; flex-direction: column; }
  footer { flex-direction: column; }
}
