:root {
  --brand-orange: #ff5900;
  --brand-footer-gray: #333333;
  --ink: #000000;
  --paper: #ffffff;
  --line: #e9ecef;
}

html {
  font-size: 14px;
  position: relative;
  min-height: 100%;
}

@media (min-width: 768px) {
  html {
    font-size: 16px;
  }
}

body {
  margin-bottom: 60px;
  color: var(--ink);
  background-color: var(--paper);
}

.brand-header {
  background-color: var(--paper);
  padding: 1rem 0;
  text-align: center;
}

.brand-header-logo {
  height: 56px;
}

.brand-stripe {
  background-color: var(--brand-orange);
  height: 40px;
  width: 100%;
}

.brand-footer {
  background-color: var(--brand-footer-gray);
  padding: 1.5rem 0;
  text-align: center;
  position: absolute;
  bottom: 0;
  width: 100%;
}

.brand-footer-logo {
  height: 44px;
}

.navbar-brand {
  font-weight: 700;
}

.validation-page,
.result-page {
  min-height: calc(100vh - 260px);
  display: grid;
  place-items: center;
  padding: 1.5rem 1rem;
  box-sizing: border-box;
}

.validation-card,
.result-card {
  width: min(760px, 100%);
  max-width: 100%;
  background-color: var(--paper);
  padding: 1.5rem;
  text-align: center;
  box-sizing: border-box;
}

.validation-title {
  color: var(--ink);
  font-family: 'Zilla Slab', serif;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.02em;
  margin-bottom: 1.5rem;
}

.validation-subtitle {
  margin-bottom: 1rem;
}

.validation-card .form-control {
  max-width: 320px;
  margin: 0 auto 1.5rem;
  border-radius: 6px;
  text-align: center;
}

.input-readonly {
  background-color: #eef0f2;
  color: #6c757d;
  cursor: not-allowed;
  border-color: var(--line);
}

.input-readonly:focus {
  background-color: #eef0f2;
  box-shadow: none;
  border-color: var(--line);
}

.btn-validate,
.btn-close-result {
  background-color: var(--brand-orange);
  color: #fff;
  border: none;
  border-radius: 999px;
  min-width: 160px;
  padding: 0.6rem 1.5rem;
  font-weight: 700;
}

.btn-validate:hover,
.btn-close-result:hover {
  background-color: #df4f02;
  color: #fff;
}

.result-fields {
  display: inline-grid;
  grid-template-columns: auto minmax(0, 1fr);
  column-gap: 0.5rem;
  row-gap: 0.6rem;
  margin: 0 auto 1.5rem;
  text-align: left;
  max-width: 100%;
}

.result-row {
  display: contents;
}

.result-label {
  color: var(--brand-orange);
  font-weight: 700;
  text-align: right;
  white-space: nowrap;
}

.result-value {
  color: var(--ink);
  text-align: left;
  overflow-wrap: anywhere;
  word-break: break-word;
}

.result-footnote {
  font-weight: 600;
  margin-bottom: 1rem;
}

.btn-validate:disabled {
  opacity: 0.9;
}

@media (max-width: 576px) {
  .brand-header-logo {
    height: 42px;
  }

  .brand-footer-logo {
    height: 34px;
  }

  .brand-stripe {
    height: 28px;
  }

  .validation-title {
    font-size: 1.25rem;
  }

  .validation-card,
  .result-card {
    padding: 1rem;
  }

  .validation-card .form-control {
    max-width: 100%;
  }

  .result-fields {
    column-gap: 0.4rem;
  }
}