/* Spacing system copied from the reference verification portal this mirrors:
   a root font-size that steps at 1400px, rem-based spacing, an 83.33% card,
   and a fixed-height document viewer. */

:root {
  --navy-900: #030d24;
  --navy-600: #0d2f6b;
  --card: #ffffff;
  --ink: #1c2430;
  --ink-soft: #55606e;
  --line: #d8dee6;
  --ok-bg: #d2f4f1;
  --ok-ink: #0d6b4f;
  --warn-bg: #fdf0d8;
  --warn-ink: #8a5a08;
  --bad-bg: #fbe2e2;
  --bad-ink: #9b1c1c;
  --btn: #2f6fdd;
  --btn-hover: #2559b8;
  --radius: 3px;
}

* { box-sizing: border-box; }

/* display rules below would otherwise beat the hidden attribute */
[hidden] { display: none !important; }

/* the reference scales everything off the root font-size */
html { font-size: 12px; }
@media (min-width: 1400px) { html { font-size: 13px; } }

html, body { margin: 0; padding: 0; }

body {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  font-family: Poppins, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  font-size: 1rem;
  color: var(--ink);
  background-color: var(--navy-900);
  background-image: url("assets/hex_map_bg.jpg");   /* reference/images/hex_map_bg.jpg */
  background-repeat: unset;                          /* as .kt-grid--hor sets it */
  background-size: auto;
  background-attachment: fixed;
}

/* ---------- layout ---------- */
.stage {
  flex: 1;
  display: flex;
  justify-content: center;
  padding: 2rem 5px 0;               /* 24px top at 12px root, 26px at 13px */
}

.card {
  width: calc(78% - 20px);           /* .col-md-10.mx-auto, trimmed a little narrower */
  background: var(--card);
  border-radius: 4px;
  box-shadow: 0 18px 50px rgba(0, 0, 0, .45);
  padding: 15px;
  margin-bottom: 20px;
}
@media (min-width: 1400px) {
  .stage { padding: 2rem 20px 0; }   /* wider page gutters kick in with the large root font */
  .card { padding: 25px; }
}

/* ---------- header ---------- */
.card-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  flex-wrap: wrap;
  margin-bottom: 1.5rem;
}

.issuer-mark { width: 300px; max-width: 100%; height: auto; }
.product-mark { width: 217px; max-width: 100%; height: auto; }

/* ---------- status banner ---------- */
.status {
  border-radius: var(--radius);
  padding: 1rem;                     /* 12px / 13px */
  font-size: 1rem;
  line-height: 1.5;
  display: flex;
  align-items: center;
  gap: .8rem;
  margin-bottom: 1.5rem;             /* 18px / 19.5px */
}
.status svg { width: 1.4rem; height: 1.4rem; flex: none; fill: none; stroke: currentColor; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }
.status strong { font-weight: 700; }
.status-ok   { background: var(--ok-bg);   color: var(--ok-ink); }
.status-warn { background: var(--warn-bg); color: var(--warn-ink); }
.status-bad  { background: var(--bad-bg);  color: var(--bad-ink); }

/* ---------- viewer ---------- */
/* Toolbar + scroll area stand in for the Telerik report viewer the reference uses. */
.viewer {
  border: 1px solid var(--line);
  border-radius: 2px;
  height: 400px;                     /* main.css: 400px to 1024, 422px from 1025 */
  display: flex;
  flex-direction: column;
}
@media (min-width: 1025px) { .viewer { height: 422px; } }

.viewer-toolbar {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 5px 8px;
  background: #f7f8fa;
  border-bottom: 1px solid var(--line);
  flex: none;
}
.tool {
  width: 32px; height: 30px;
  display: grid; place-items: center;
  background: none; border: 0; border-radius: 4px;
  cursor: pointer; color: #46505d;
}
.tool:hover { background: #e6e9ee; }
.tool svg { width: 19px; height: 19px; fill: none; stroke: currentColor; stroke-width: 1.4; stroke-linecap: round; stroke-linejoin: round; }
.tool[data-action="pan"] svg { fill: currentColor; stroke: none; }
.tool.is-active { background: #dde3ec; }
.tool-right { margin-left: auto; }
.tool-sep { width: 1px; height: 20px; background: var(--line); margin: 0 6px; }
.zoom select {
  font: inherit; font-size: 1.05rem;
  padding: 4px 6px;
  border: 1px solid var(--line);
  border-radius: 4px;
  background: #fff;
  color: #46505d;
}

.viewer-body {
  flex: 1;
  background: #f1f2f4;
  padding: 10px 0;
  display: flex;
  justify-content: center;
  align-items: flex-start;
  overflow: auto;
}
.viewer-body.pan-mode { cursor: grab; }
.viewer-body.is-grabbing { cursor: grabbing; }

.doc {
  flex: none;
  box-shadow: 0 2px 10px rgba(0,0,0,.22);
  background: #fff;
  overflow: hidden;
}
.doc > * { transform-origin: top left; }
.cert-img { display: block; width: 940px; height: 665px; }

.doc-empty {
  width: 940px;
  aspect-ratio: 1.414 / 1;
  display: grid;
  place-items: center;
  text-align: center;
  color: var(--ink-soft);
  padding: 40px;
  font-size: 1.15rem;
}

/* ---------- reference + actions ---------- */
.reference { text-align: center; font-size: 1rem; color: #3a4552; margin: 1.5rem 0; }

.actions { display: flex; flex-direction: column; align-items: center; gap: 1.5rem; }
.btn {
  display: inline-flex; align-items: center; gap: .7rem;
  font: inherit; font-size: 1rem;
  padding: .65rem 1rem;              /* 7.8x12 at 12px root, 8.45x13 at 13px */
  border: 0; border-radius: var(--radius);
  cursor: pointer;
  color: #fff; background: var(--btn);
}
.btn:hover { background: var(--btn-hover); }
.btn:disabled { opacity: .5; cursor: default; }
.btn-icon { width: 1.3rem; height: 1.3rem; fill: none; stroke: currentColor; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }

.verify-result {
  text-align: center;
  font-size: .95rem;
  color: var(--ink-soft);
  margin: 0;
  min-height: 1.4rem;
}

/* ---------- verification details ---------- */
.details { margin-bottom: 1.2rem; }

.details-table {
  width: 100%;
  border-collapse: collapse;
  font-size: .95rem;
}
.details-table th,
.details-table td {
  padding: .55rem .8rem;
  line-height: 1.35;
  text-align: left;
  vertical-align: middle;
}
.details-table thead th {
  background: #f7f8fa;
  font-weight: 600;
  color: var(--ink);
}
.details-table tbody tr:nth-child(even) { background: #f7f8fa; }
.details-key { color: #46505d; }
.details-value { color: #0f6b6b; font-weight: 600; }
.details-check { text-align: right; width: 6rem; }

.row-icon {
  width: 1.25rem; height: 1.25rem;
  fill: none; stroke: #0f7a6a; stroke-width: 1.6;
  stroke-linecap: round; stroke-linejoin: round;
  vertical-align: middle;
}
.row-icon-bad { stroke: currentColor; }

.details-verdict { margin: 0; padding: .7rem .8rem; font-size: .95rem; }
.details-verdict svg { width: 1.25rem; height: 1.25rem; }

.details-foot { text-align: right; padding: .45rem .2rem 0; }
.details-hide {
  background: none; border: 0; padding: 0;
  font: inherit; font-size: .95rem;
  color: #6b6fd8; cursor: pointer;
}
.details-hide { text-decoration: underline; }

/* keys are shown at once; values and check marks fade in row by row */
.is-masked {
  opacity: 0;
  transition: opacity .45s ease;
}
.is-masked.is-in { opacity: 1; }

@media (prefers-reduced-motion: reduce) {
  .is-masked { transition: none; }
}

/* ---------- footer ---------- */
.site-footer {
  display: flex; justify-content: space-between; align-items: center;
  gap: 18px; flex-wrap: wrap;
  padding: 24px 30px;
  background: #10161f;
  color: #e3e8f0; font-size: 1.15rem;
}
@media (min-width: 1400px) { .site-footer { padding: 26px 60px; } }
.footer-links { display: flex; gap: 26px; flex-wrap: wrap; }
.site-footer a { color: #e3e8f0; text-decoration: none; display: inline-flex; align-items: center; gap: 6px; }
.site-footer a:hover { text-decoration: underline; }
.ext { width: 13px; height: 13px; fill: none; stroke: currentColor; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }

/* .col-md-10 only narrows the card from 768px up; below that it is full width */
/* .col-md-10 stops narrowing the card below Bootstrap's md breakpoint */
@media (max-width: 767.98px) {
  .card { width: 100%; }
  .card-head { gap: 14px; }
}

/* main.css drops the padding and the card radius at 725px */
@media (max-width: 725px) {
  .stage { padding: 0; }
  .card {
    margin-bottom: 0;
    border-radius: 0;
    box-shadow: none;
  }
  .issuer-mark, .product-mark { width: 45%; }   /* .kt-header__brand-logo img */
}

@media (max-width: 500px) {
  .card-head { justify-content: center; text-align: center; }
  .site-footer { justify-content: center; text-align: center; padding: 24px 20px; }
  .footer-links { justify-content: center; gap: 18px; }
}
