/* FalconEdge device lookup page. Sticker sizes use cqw so the seal scales like a printed object. */

.fe-page {
  --fe-navy: #0b2447;
  --fe-blue: #19376d;
  --fe-red: #ec1c24;
  --fe-paper: #eef0f6;
  --fe-trace: #8fb8e8;
  --fe-muted: #4e5a73;
  --fe-line: #cfd6e4;
  color: var(--fe-blue);
}

.fe-page [hidden] {
  display: none !important;
}

.fe-page :focus-visible {
  outline: 3px solid var(--fe-blue);
  outline-offset: 2px;
}

/* ---------- Hero ---------- */

.fe-hero {
  background: var(--fe-paper);
  margin-top: 28px;
  padding: 64px 0 84px;
}

.fe-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 480px);
  grid-template-rows: auto 1fr;
  grid-template-areas:
    "head stage"
    "specs stage";
  column-gap: clamp(40px, 6vw, 90px);
  align-items: start;
}

.fe-head {
  grid-area: head;
}

.fe-stage {
  grid-area: stage;
}

.fe-specs {
  grid-area: specs;
}

.fe-page .fe-title {
  color: var(--fe-navy);
  font-size: clamp(36px, 4.4vw, 58px);
  font-weight: 700;
  line-height: 1.1;
  letter-spacing: -0.02em;
  margin: 0 0 24px;
}

.fe-page .fe-lead {
  color: var(--fe-blue);
  font-size: 19px;
  line-height: 1.6;
  margin: 0 0 18px;
  max-width: 34em;
}

.fe-page .fe-hint {
  color: var(--fe-muted);
  font-size: 16px;
  line-height: 1.6;
  margin: 0;
  max-width: 36em;
}

/* ---------- Result heading ---------- */

.fe-result {
  animation: fe-appear 0.45s ease 0.45s backwards;
}

.fe-page .fe-model {
  color: var(--fe-navy);
  font-size: clamp(30px, 3.4vw, 46px);
  font-weight: 700;
  line-height: 1.12;
  letter-spacing: -0.02em;
  margin: 0 0 8px;
}

.fe-page .fe-model:focus {
  outline: none;
}

.fe-page .fe-tagline {
  color: var(--fe-blue);
  font-size: 18px;
  line-height: 1.5;
  margin: 0 0 18px;
}

.fe-page .fe-registered {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px 14px;
  color: var(--fe-muted);
  font-size: 16px;
  line-height: 1.4;
  margin: 0 0 26px;
}

.fe-registered__status {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--fe-navy);
  font-weight: 700;
}

.fe-registered__status svg {
  width: 18px;
  height: 18px;
  flex: none;
}

.fe-registered strong {
  color: var(--fe-navy);
  font-weight: 700;
  letter-spacing: 0.06em;
}

/* ---------- Spec rows ---------- */

.fe-page .fe-specs {
  list-style: none;
  margin: 0;
  padding: 0;
  border-top: 1px solid var(--fe-line);
  animation: fe-appear 0.45s ease 0.55s backwards;
}

.fe-specs li {
  margin: 0;
  border-bottom: 1px solid var(--fe-line);
}

.fe-page .fe-spec {
  display: grid;
  grid-template-columns: 150px minmax(0, 1fr);
  gap: 16px;
  width: 100%;
  padding: 12px 10px;
  border: 0;
  border-radius: 0;
  background: transparent;
  color: var(--fe-navy);
  font: inherit;
  text-align: left;
  transition: background-color 0.15s ease;
}

.fe-page button.fe-spec {
  cursor: pointer;
}

.fe-page button.fe-spec:hover,
.fe-page .fe-spec.is-active {
  background: rgba(25, 55, 109, 0.09);
}

.fe-spec__label {
  color: var(--fe-muted);
  font-size: 15px;
  font-weight: 500;
  line-height: 1.5;
}

.fe-spec__value {
  color: var(--fe-navy);
  font-size: 17px;
  font-weight: 700;
  line-height: 1.4;
}

.fe-spec__value small {
  display: block;
  color: var(--fe-muted);
  font-size: 14.5px;
  font-weight: 500;
  margin-top: 2px;
}

/* ---------- Preview: fills the spec rows' slot until a serial is found ---------- */

.fe-preview {
  grid-area: specs;
  align-self: end;
  margin-top: 26px;
}

.fe-page .fe-preview__title {
  color: var(--fe-navy);
  font-size: 18px;
  font-weight: 700;
  line-height: 1.3;
  margin: 0 0 12px;
}

.fe-page .fe-preview .fe-specs {
  animation: none;
}

.fe-preview .fe-spec {
  padding: 9px 10px;
}

.fe-preview .fe-spec__value {
  color: var(--fe-muted);
  font-size: 16px;
  font-weight: 500;
}

/* ---------- Stage: the drawing sits under the seal ---------- */

.fe-stage {
  position: relative;
  z-index: 1;
  width: 100%;
  aspect-ratio: 520 / 680;
  container-type: inline-size;
}

.fe-cutaway {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  display: block;
}

.fe-cutaway text {
  fill: #d5e1f2;
  font-family: var(--falcon-font);
  font-size: 16px;
  font-weight: 500;
  stroke: none;
}

.fe-frame {
  fill: #0a1f44;
  stroke: var(--fe-trace);
  stroke-width: 2;
}

.fe-frame--inner {
  fill: none;
  stroke-width: 1;
  opacity: 0.45;
}

.fe-trace-line {
  fill: none;
  stroke: var(--fe-trace);
  stroke-width: 1;
  opacity: 0.35;
}

.fe-part {
  fill: none;
  stroke: var(--fe-trace);
  stroke-width: 1.6;
  stroke-linejoin: round;
  transition: opacity 0.15s ease;
}

.fe-part .fe-solid {
  fill: #0e2a57;
}

.fe-cutaway.has-active .fe-part:not(.is-active) {
  opacity: 0.32;
}

.fe-part.is-active {
  stroke: #ff6b70;
}

.fe-part.is-active .fe-solid {
  fill: #47182f;
}

.fe-part.is-active text {
  fill: #fff;
}

.fe-part.is-active .fe-fan {
  animation: fe-spin 1.6s linear infinite;
}

.fe-cutaway.has-two-fans .fe-fan--third {
  display: none;
}

/* ---------- The seal: a copy of the printed warranty sticker ---------- */

.fe-seal {
  position: absolute;
  inset: 0;
  display: flex;
  background: #fff;
  border-radius: 2.6cqw;
  padding: 2cqw;
  margin: 0;
  box-shadow: 0 18px 44px rgba(11, 36, 71, 0.28);
}

.fe-seal__print {
  position: relative;
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: stretch;
  background: var(--fe-navy);
  border-radius: 1.4cqw;
  padding: 5.4cqw 7cqw 3.4cqw;
  text-align: center;
}

.fe-seal__print::before,
.fe-seal__print::after {
  content: "";
  position: absolute;
  pointer-events: none;
  border-radius: 1cqw;
}

.fe-seal__print::before {
  inset: 1.3cqw;
  border: 1px solid rgba(255, 255, 255, 0.75);
}

.fe-seal__print::after {
  inset: 2.3cqw;
  border: 1px solid var(--fe-red);
}

.fe-seal__logo {
  display: block;
  width: 36cqw;
  height: auto;
  margin: 0 auto 3cqw;
}

.fe-seal__rule {
  height: 2px;
  background: var(--fe-red);
  margin-bottom: 3.6cqw;
}

.fe-seal__void {
  color: #fff;
  font-size: 8.9cqw;
  font-weight: 700;
  line-height: 1.1;
  letter-spacing: 0.01em;
  white-space: nowrap;
}

.fe-seal__void-sub {
  color: #fff;
  font-size: 4cqw;
  font-weight: 700;
  line-height: 1.3;
  letter-spacing: 0.02em;
  margin-bottom: 2.4cqw;
}

.fe-seal__text {
  color: #e6edf7;
  font-size: max(11px, 3cqw);
  font-weight: 500;
  line-height: 1.4;
  margin-bottom: 3.4cqw;
}

.fe-seal__panel {
  position: relative;
  z-index: 1;
  flex: 1;
  display: flex;
  flex-direction: column;
  background: var(--fe-paper);
  border-radius: 2.2cqw;
  padding: 3.6cqw 4.4cqw 4cqw;
}

.fe-page .fe-seal__label {
  display: block;
  color: var(--fe-navy);
  font-size: max(11px, 3.1cqw);
  font-weight: 700;
  letter-spacing: 0.06em;
  line-height: 1.3;
  margin: 0 0 1.2cqw;
}

.fe-seal input.fe-seal__input {
  display: block;
  width: 100%;
  height: auto;
  border: 0;
  border-bottom: 2px solid #9aa9bf;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
  color: var(--fe-navy);
  font-family: inherit;
  font-size: max(17px, 6.8cqw);
  font-weight: 700;
  letter-spacing: 0.05em;
  line-height: 1.25;
  margin: 0;
  padding: 0.6cqw 0 1cqw;
  text-align: center;
  text-transform: uppercase;
}

.fe-seal input.fe-seal__input::placeholder {
  color: #5f6d85;
  font-size: max(14px, 3.8cqw);
  font-weight: 500;
  letter-spacing: 0;
  opacity: 1;
  text-transform: none;
}

.fe-seal input.fe-seal__input:focus {
  border-bottom-color: var(--fe-navy);
  outline: none;
}

.fe-seal.has-error input.fe-seal__input {
  border-bottom-color: var(--fe-red);
}

/* The barcode takes the panel's spare height and gives it up to an error message. */
.fe-seal__code {
  position: relative;
  flex: 1 0 13cqw;
  margin: 2.2cqw 0;
  overflow: hidden;
}

.fe-seal__bars {
  position: absolute;
  top: 0;
  left: 0;
  display: block;
  width: 100%;
  height: 100%;
  fill: var(--fe-navy);
  shape-rendering: crispEdges;
}

/* Blank bars keep the panel's shape until a serial is typed. */
.fe-seal__bars.is-empty {
  background: repeating-linear-gradient(90deg, #cdd4e2 0 2px, transparent 2px 5px, #cdd4e2 5px 6px, transparent 6px 11px);
}

.fe-seal__code::after {
  content: "";
  position: absolute;
  top: 0;
  bottom: 0;
  left: 0;
  width: 3px;
  background: var(--fe-red);
  box-shadow: 0 0 10px 2px rgba(236, 28, 36, 0.6);
  opacity: 0;
}

.fe-seal.is-scanning .fe-seal__code::after {
  opacity: 1;
  animation: fe-scan 0.48s ease-in-out;
}

.fe-page .fe-seal__message {
  min-height: calc(2 * 1.35 * max(12px, 3.2cqw));
  color: #b3141a;
  font-size: max(12px, 3.2cqw);
  font-weight: 500;
  line-height: 1.35;
  margin: 0 0 1.2cqw;
  text-align: center;
}

.fe-page .fe-seal__message:empty {
  min-height: 0;
  margin: 0;
}

.fe-seal__message a {
  color: inherit;
  text-decoration: underline;
}

.fe-seal button.fe-seal__go {
  display: block;
  width: 100%;
  margin-top: auto;
  padding: 2.5cqw 0;
  border: 0;
  border-radius: 25px;
  background: var(--fe-red);
  color: #fff;
  cursor: pointer;
  font-family: inherit;
  font-size: max(15px, 3.9cqw);
  font-weight: 700;
  line-height: 1.3;
  transition: background-color 0.15s ease;
}

.fe-seal button.fe-seal__go:hover {
  background: #c5141b;
}

.fe-seal button.fe-seal__go:disabled {
  cursor: progress;
  opacity: 0.75;
}

.fe-seal__foot {
  color: #fff;
  font-size: max(9px, 2.5cqw);
  font-weight: 700;
  letter-spacing: 0.05em;
  line-height: 1.3;
  margin-top: 2.6cqw;
}

.fe-flap {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  overflow: visible;
  pointer-events: none;
  opacity: 0;
  filter: drop-shadow(-5px 7px 12px rgba(0, 0, 0, 0.45));
}

/* ---------- Unit notes ---------- */

.fe-unit {
  background: #fff;
  padding: 72px 0;
}

.fe-unit__grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 36px clamp(28px, 4vw, 56px);
}

.fe-page .fe-note h2 {
  color: var(--fe-navy);
  font-size: 21px;
  font-weight: 700;
  line-height: 1.3;
  margin: 0 0 10px;
}

.fe-page .fe-note p,
.fe-page .fe-note li {
  color: var(--fe-muted);
  font-size: 16px;
  line-height: 1.6;
  margin: 0;
}

.fe-page .fe-note p + p {
  margin-top: 10px;
}

.fe-page .fe-note ul {
  list-style: none;
  margin: 0;
  padding: 0;
}

.fe-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 14px 18px;
  margin-top: 44px;
  padding-top: 28px;
  border-top: 1px solid #e4e5ea;
}

.fe-page .fe-action {
  display: inline-flex;
  align-items: center;
  min-height: 46px;
  padding: 0 26px;
  border: 1.5px solid var(--fe-blue);
  border-radius: 25px;
  background: transparent;
  color: var(--fe-blue);
  cursor: pointer;
  font-family: inherit;
  font-size: 16px;
  font-weight: 700;
  line-height: 1.2;
  transition: background-color 0.15s ease, color 0.15s ease;
}

.fe-page .fe-action:hover {
  background: var(--fe-blue);
  color: #fff;
}

.fe-page .fe-action--solid {
  background: var(--fe-red);
  border-color: var(--fe-red);
  color: #fff;
}

.fe-page .fe-action--solid:hover {
  background: #c5141b;
  border-color: #c5141b;
}

.fe-copy-status {
  color: var(--fe-muted);
  font-size: 15px;
}

/* ---------- Model comparison ---------- */

/* The theme pulls the footer up 160px over the section above it. */
.fe-models {
  background: var(--fe-paper);
  padding: 80px 0 250px;
}

.fe-page .fe-models__title {
  color: var(--fe-navy);
  font-size: clamp(28px, 3.2vw, 40px);
  font-weight: 700;
  line-height: 1.18;
  letter-spacing: -0.015em;
  margin: 0 0 12px;
}

.fe-page .fe-models__lead {
  color: var(--fe-muted);
  font-size: 17px;
  line-height: 1.6;
  margin: 0 0 34px;
  max-width: 44em;
}

.fe-compare {
  width: 100%;
  border: 0;
  border-collapse: separate;
  border-spacing: 0;
  border-radius: 12px;
  overflow: hidden;
  background: #fff;
  table-layout: fixed;
}

.fe-compare th,
.fe-compare td {
  padding: 14px 18px;
  border: 0;
  border-bottom: 1px solid #e4e5ea;
  font-size: 16px;
  line-height: 1.45;
  text-align: left;
  vertical-align: top;
}

.fe-compare tbody tr:last-child th,
.fe-compare tbody tr:last-child td {
  border-bottom: 0;
}

.fe-compare thead th {
  background: var(--fe-navy);
  color: #fff;
  font-weight: 700;
  border-bottom: 0;
}

.fe-compare tbody th {
  color: var(--fe-navy);
  font-weight: 700;
}

.fe-compare td {
  color: var(--fe-blue);
}

.fe-compare__name {
  display: block;
}

.fe-compare__yours {
  display: none;
  font-size: 14px;
  font-weight: 500;
}

.fe-compare thead th.is-yours {
  background: var(--fe-red);
}

.fe-compare thead th.is-yours .fe-compare__yours {
  display: block;
  color: #fff;
}

.fe-compare td.is-yours {
  background: #fdf0f0;
}

.fe-models__notes {
  margin-top: 26px;
  max-width: 46em;
}

.fe-page .fe-models__notes p {
  color: var(--fe-muted);
  font-size: 15.5px;
  line-height: 1.6;
  margin: 0 0 8px;
}

.fe-models__notes a {
  color: var(--fe-blue);
  font-weight: 700;
  text-decoration: underline;
}

/* ---------- Motion ---------- */

@keyframes fe-appear {
  from {
    opacity: 0;
  }
}

@keyframes fe-scan {
  from {
    left: 0;
  }
  to {
    left: 100%;
  }
}

@keyframes fe-spin {
  to {
    transform: rotate(360deg);
  }
}

@media (prefers-reduced-motion: reduce) {
  .fe-result,
  .fe-page .fe-specs,
  .fe-part.is-active .fe-fan {
    animation: none;
  }
}

/* ---------- Smaller screens ---------- */

@media (max-width: 991px) {
  .fe-hero {
    padding: 44px 0 64px;
  }

  .fe-grid {
    grid-template-columns: minmax(0, 1fr);
    grid-template-rows: none;
    grid-template-areas:
      "head"
      "stage"
      "specs";
    row-gap: 32px;
  }

  .fe-preview {
    margin-top: 0;
  }

  .fe-stage {
    justify-self: center;
    max-width: 480px;
  }

  .fe-unit__grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 575px) {
  .fe-page .fe-lead {
    font-size: 17px;
  }

  .fe-unit {
    padding: 52px 0;
  }

  .fe-unit__grid {
    grid-template-columns: minmax(0, 1fr);
  }

  .fe-page .fe-spec {
    grid-template-columns: 112px minmax(0, 1fr);
    gap: 12px;
    padding: 11px 4px;
  }

  .fe-models {
    padding: 56px 0 224px;
  }

  .fe-compare th,
  .fe-compare td {
    font-size: 14px;
    padding: 11px 8px;
  }
}

/* The smallest phones need the room for the error message. */
@media (max-width: 340px) {
  .fe-seal__text {
    display: none;
  }
}
