/* Xerox GDAP Request form */

:root {
  --xerox-red: #cc0000;
  --xerox-red-dark: #a30000;
  --ink: #1a1a1a;
  --ink-muted: #5a5a5a;
  --line: #d8d8d8;
  --surface: #ffffff;
  --surface-alt: #f4f4f4;
  --focus: #0057b8;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

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

body {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  background: var(--surface-alt);
  color: var(--ink);
  font-family: "Helvetica Neue", Helvetica, Arial, sans-serif;
  font-size: 16px;
  line-height: 1.6;
}

.container {
  width: 100%;
  max-width: 1080px;
  margin: 0 auto;
  padding: 0 24px;
}

/* Header */

.site-header {
  background: var(--surface);
  border-bottom: 1px solid var(--line);
}

.header-inner {
  display: flex;
  align-items: center;
  gap: 16px;
  padding-top: 20px;
  padding-bottom: 20px;
}

.brand {
  display: inline-flex;
  color: var(--xerox-red);
  text-decoration: none;
}

.brand-mark {
  width: 132px;
  height: 26px;
  display: block;
}

.brand-divider {
  width: 1px;
  height: 24px;
  background: var(--line);
}

.brand-context {
  font-size: 15px;
  color: var(--ink-muted);
  letter-spacing: 0.02em;
}

.header-accent {
  height: 4px;
  background: var(--xerox-red);
}

/* Page */

.page {
  flex: 1;
  padding-top: 48px;
  padding-bottom: 64px;
}

.page-heading {
  max-width: 720px;
  margin-bottom: 36px;
}

h1 {
  margin: 0 0 12px;
  font-size: 40px;
  line-height: 1.15;
  font-weight: 700;
  letter-spacing: -0.01em;
}

h2 {
  margin: 0 0 20px;
  font-size: 20px;
  font-weight: 700;
}

.lede {
  margin: 0;
  font-size: 17px;
  color: var(--ink-muted);
}

.layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 32px;
  align-items: start;
}

/* Form card */

.card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-top: 4px solid var(--xerox-red);
  padding: 32px;
}

label {
  display: block;
  margin-bottom: 6px;
  font-size: 14px;
  font-weight: 700;
  letter-spacing: 0.01em;
}

input[type="text"],
input[type="email"],
select {
  width: 100%;
  padding: 12px 14px;
  margin-bottom: 22px;
  font: inherit;
  font-size: 16px;
  color: var(--ink);
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 0;
  appearance: none;
}

select {
  background-image: linear-gradient(45deg, transparent 50%, var(--ink) 50%),
    linear-gradient(135deg, var(--ink) 50%, transparent 50%);
  background-position: calc(100% - 20px) 50%, calc(100% - 14px) 50%;
  background-size: 6px 6px, 6px 6px;
  background-repeat: no-repeat;
  padding-right: 42px;
}

input:focus-visible,
select:focus-visible,
.btn:focus-visible,
a:focus-visible {
  outline: 2px solid var(--focus);
  outline-offset: 2px;
}

.btn {
  display: inline-block;
  padding: 13px 32px;
  font: inherit;
  font-size: 16px;
  font-weight: 700;
  color: #fff;
  background: var(--xerox-red);
  border: 1px solid var(--xerox-red);
  border-radius: 0;
  cursor: pointer;
  transition: background 0.15s ease, border-color 0.15s ease;
}

.btn:hover {
  background: var(--xerox-red-dark);
  border-color: var(--xerox-red-dark);
}

.btn[disabled] {
  opacity: 0.5;
  cursor: not-allowed;
}

/* Loading + status */

#preloader {
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 15px;
  color: var(--ink-muted);
}

#preloader[hidden] {
  display: none;
}

.spinner {
  width: 20px;
  height: 20px;
  border: 3px solid var(--line);
  border-top-color: var(--xerox-red);
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}

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

@media (prefers-reduced-motion: reduce) {
  .spinner {
    animation: none;
  }
}

.form-status {
  margin: 18px 0 0;
  font-size: 15px;
}

.form-status:empty {
  display: none;
}

.form-status.is-success {
  color: #1a7a3c;
}

.form-status.is-error {
  color: var(--xerox-red);
}

/* Roles panel */

.roles {
  background: var(--surface);
  border: 1px solid var(--line);
  padding: 32px;
}

.roles-title {
  margin: 0 0 8px;
  font-size: 18px;
  line-height: 1.5;
}

.roles-title:empty {
  display: none;
}

.roles-detail {
  color: var(--ink-muted);
  font-size: 15px;
}

.roles-detail a {
  color: var(--xerox-red);
  text-decoration: none;
}

.roles-detail a:hover {
  text-decoration: underline;
}

.accordion-toggle {
  display: block;
  padding: 8px 0;
  border-bottom: 1px solid var(--line);
  font-weight: 700;
}

.accordion-content {
  display: none;
}

.accordion-content.active {
  display: block;
  padding: 10px 0 14px;
  color: var(--ink-muted);
}

/* Footer */

.site-footer {
  background: var(--ink);
  color: #cfcfcf;
  font-size: 13px;
}

.footer-inner {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 24px;
  justify-content: space-between;
  padding-top: 24px;
  padding-bottom: 24px;
}

.footer-note {
  color: #9a9a9a;
}

/* Responsive */

@media (max-width: 900px) {
  .layout {
    grid-template-columns: minmax(0, 1fr);
  }

  h1 {
    font-size: 32px;
  }

  .page {
    padding-top: 32px;
  }
}
