/*
 * Role descriptions on Whistler Alpha Research Limited letterhead.
 * One flowing sheet: reads as a page on screen, prints as a Letter document.
 * Colours and marks match the WARL letterhead used for company documents.
 */
:root {
  --ink: #0a2540;
  --ink-2: #0f2847;
  --text: #2f3a47;
  --muted: #5a6c7d;
  --rule: #e0e6ed;
  --wash: #f7f9fb;
  --blue: #2980b9;
  --blue-deep: #1a5276;
  --bar: linear-gradient(90deg, #0f2847 0%, #1a5276 40%, #2980b9 70%, #5dade2 100%);
}

* { margin: 0; padding: 0; box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; }

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  color: var(--text);
  background: #e9edf1;
  font-size: 15px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}

a { color: var(--blue-deep); text-underline-offset: 3px; }
a:hover { color: var(--ink); }
a:focus-visible, .btn:focus-visible { outline: 2px solid var(--blue); outline-offset: 3px; border-radius: 3px; }

.skip { position: absolute; left: -9999px; }
.skip:focus { left: 16px; top: 16px; z-index: 10; background: #fff; padding: 8px 12px; }

/* Screen-only strip above the sheet */
.toolbar {
  max-width: 8.5in;
  margin: 0 auto;
  padding: 20px 4px 0;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  font-size: 14px;
}
.toolbar a { font-weight: 500; text-decoration: none; }
.toolbar a:hover { text-decoration: underline; }

.sheet {
  position: relative;
  max-width: 8.5in;
  margin: 16px auto 40px;
  background: #fff;
  box-shadow: 0 1px 2px rgba(10, 37, 64, 0.08), 0 12px 32px rgba(10, 37, 64, 0.1);
  padding: 0 clamp(20px, 7vw, 0.75in);
}
.sheet::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 6px;
  height: 1.8in;
  background: linear-gradient(180deg, #0a2540 0%, #1b6ca8 60%, #38bdf8 100%);
}

/* Letterhead */
.letterhead {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  flex-wrap: wrap;
  gap: 12px 24px;
  padding: 0.5in 0 0.28in;
  position: relative;
}
.letterhead::after {
  content: '';
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 3px;
  background: var(--bar);
}
.logo-block { display: flex; align-items: center; gap: 14px; }
.logo-block svg { width: 58px; height: 58px; flex-shrink: 0; }
.company { font-size: 19px; font-weight: 700; color: var(--ink); letter-spacing: -0.3px; line-height: 1.25; }
.address { font-size: 11.5px; color: var(--muted); line-height: 1.6; text-align: right; font-style: normal; }

/* Title block */
.title-block { padding: 0.34in 0 0; }
h1 { font-size: clamp(24px, 4.2vw, 30px); line-height: 1.2; font-weight: 700; color: var(--ink); letter-spacing: -0.5px; }
.subtitle { font-size: 16px; font-weight: 500; color: var(--muted); margin-top: 6px; }

.facts {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(170px, 1fr));
  gap: 14px 28px;
  margin-top: 22px;
  padding: 16px 0;
  border-top: 1px solid var(--rule);
  border-bottom: 1px solid var(--rule);
}
.facts dt { font-size: 12px; font-weight: 600; color: var(--muted); }
.facts dd { font-size: 14px; font-weight: 500; color: var(--ink); margin-top: 2px; }

.apply-line { margin-top: 20px; display: flex; flex-wrap: wrap; align-items: center; gap: 12px 18px; font-size: 14px; color: var(--muted); }

.btn {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  padding: 10px 20px;
  background: var(--ink);
  color: #fff;
  font-size: 14.5px;
  font-weight: 600;
  text-decoration: none;
  border-radius: 4px;
  transition: background-color 0.2s ease;
}
.btn:hover { background: var(--blue-deep); color: #fff; }
.btn:active { background: #06182b; }

/* Body copy */
.content { padding: 8px 0 0.4in; max-width: 68ch; }
.content h2 {
  font-size: 17px;
  font-weight: 700;
  color: var(--ink);
  letter-spacing: -0.2px;
  margin-top: 34px;
  margin-bottom: 12px;
  padding-bottom: 6px;
  border-bottom: 1px solid var(--rule);
}
.content h3 { font-size: 15px; font-weight: 600; color: var(--ink-2); margin: 18px 0 8px; }
.content p { margin-bottom: 12px; }
.content ul, .content ol { margin: 0 0 12px 1.25em; }
.content li { margin-bottom: 9px; padding-left: 2px; }
.content strong { color: var(--ink); font-weight: 600; }

.apply-box {
  margin-top: 36px;
  padding: 20px 22px;
  background: var(--wash);
  border-left: 3px solid var(--blue);
  border-radius: 0 4px 4px 0;
}
.apply-box h2 { margin: 0 0 6px; padding: 0; border: 0; }
.apply-box p { margin-bottom: 14px; }
.apply-box p:last-child { margin-bottom: 0; }

/* Letterhead footer */
.sheet-footer { padding: 0 0 0.3in; }
.sheet-footer::before { content: ''; display: block; height: 2px; background: var(--bar); margin-bottom: 10px; }
.sheet-footer div { display: flex; justify-content: space-between; flex-wrap: wrap; gap: 4px 16px; font-size: 11px; color: #7b8b9c; letter-spacing: 0.2px; }
.sheet-footer .reg { font-weight: 600; }

@media (max-width: 560px) {
  .address { text-align: left; }
  .toolbar { padding-inline: 16px; }
  .sheet { margin: 12px 0 0; }
}

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

@page { size: letter; margin: 0.55in 0; }

@media print {
  body { background: #fff; font-size: 10.5px; line-height: 1.6; }
  .toolbar, .skip, .screen-only { display: none !important; }
  .sheet { max-width: none; margin: 0; box-shadow: none; padding: 0 0.75in; -webkit-print-color-adjust: exact; print-color-adjust: exact; }
  .sheet::before { top: -0.55in; }
  .letterhead { padding-top: 0; }
  .logo-block svg { width: 54px; height: 54px; }
  .company { font-size: 18px; }
  .address { font-size: 8.5px; }
  h1 { font-size: 20px; }
  .subtitle { font-size: 11px; }
  .facts { margin-top: 14px; padding: 10px 0; gap: 8px 20px; grid-template-columns: repeat(4, 1fr); }
  .facts dt { font-size: 8.5px; }
  .facts dd { font-size: 10px; }
  .apply-line { font-size: 10px; margin-top: 12px; }
  .btn { min-height: 0; padding: 6px 12px; font-size: 10px; }
  .content { max-width: none; padding-bottom: 0.25in; }
  .content h2 { font-size: 12px; margin-top: 18px; margin-bottom: 7px; padding-bottom: 4px; break-after: avoid; }
  .content h3 { font-size: 10.5px; break-after: avoid; }
  .content p, .content ul, .content ol { margin-bottom: 7px; }
  .content li { margin-bottom: 4px; break-inside: avoid; }
  .apply-box { margin-top: 20px; padding: 12px 14px; break-inside: avoid; }
  .sheet-footer { break-inside: avoid; padding-bottom: 0; }
  .sheet-footer div { font-size: 7.5px; }
  a { color: var(--blue-deep); }
}
