/* ============================================
   Designing the District — Assessment Styles
   ============================================ */

@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700;800;900&family=Playfair+Display:ital,wght@0,700;1,400&display=swap');

/* ---------- Reset & Base ---------- */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  color: #333;
  line-height: 1.6;
  background: #fff;
}

/* ---------- Page Container ---------- */
.page {
  max-width: 8.5in;
  margin: 0 auto;
  padding: 0.75in 0.85in;
}

/* ---------- Cover Page ---------- */
.cover {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  min-height: 100vh;
  background: #000;
  color: #fff;
  text-align: center;
  padding: 2in 1in;
}

.cover .logo {
  width: 320px;
  max-width: 80%;
  margin-bottom: 3rem;
}

.cover h1 {
  font-family: 'Inter', sans-serif;
  font-weight: 800;
  font-size: 2.4rem;
  letter-spacing: -0.02em;
  text-transform: uppercase;
  margin-bottom: 0.5rem;
}

.cover .subtitle {
  font-weight: 300;
  font-size: 1.1rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: #ccc;
  margin-bottom: 3rem;
}

.cover .meta {
  font-size: 0.85rem;
  color: #999;
  line-height: 1.8;
}

.cover .meta strong {
  color: #ccc;
  font-weight: 500;
}

.cover .divider-line {
  width: 60px;
  height: 2px;
  background: #fff;
  margin: 2rem auto;
}

/* ---------- Section Headers ---------- */
.section-header {
  border-bottom: 3px solid #000;
  padding-bottom: 0.75rem;
  margin-bottom: 1.5rem;
  margin-top: 2.5rem;
}

.section-header h2 {
  font-family: 'Inter', sans-serif;
  font-weight: 800;
  font-size: 1.5rem;
  text-transform: uppercase;
  letter-spacing: -0.01em;
  color: #000;
  margin-bottom: 0.25rem;
}

.section-header .section-meta {
  display: flex;
  align-items: center;
  gap: 1rem;
  margin-top: 0.35rem;
}

.badge {
  display: inline-block;
  background: #000;
  color: #fff;
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  padding: 0.2rem 0.6rem;
  border-radius: 2px;
}

.skills-tested {
  font-size: 0.8rem;
  color: #777;
  font-style: italic;
}

/* ---------- Content Blocks ---------- */
h3 {
  font-family: 'Inter', sans-serif;
  font-weight: 700;
  font-size: 1.05rem;
  color: #000;
  margin-top: 1.5rem;
  margin-bottom: 0.5rem;
}

p {
  margin-bottom: 0.85rem;
}

/* ---------- Inset / Reference Material ---------- */
.reference-material {
  background: #f5f5f5;
  border-left: 4px solid #000;
  padding: 1.25rem 1.5rem;
  margin: 1.25rem 0;
  border-radius: 0 4px 4px 0;
}

.reference-material .label {
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: #000;
  margin-bottom: 0.75rem;
}

.reference-material p {
  font-size: 0.9rem;
  margin-bottom: 0.6rem;
  color: #444;
}

.reference-material p:last-child {
  margin-bottom: 0;
}

/* Email styling within reference material */
.email-block {
  background: #fff;
  border: 1px solid #e0e0e0;
  border-radius: 4px;
  padding: 1.25rem 1.5rem;
  margin: 0.75rem 0;
}

.email-block .email-header {
  font-size: 0.8rem;
  color: #777;
  margin-bottom: 0.75rem;
  padding-bottom: 0.5rem;
  border-bottom: 1px solid #eee;
}

.email-block .email-header strong {
  color: #333;
}

.email-block .email-body {
  font-size: 0.9rem;
  color: #333;
}

.email-block .email-body p {
  margin-bottom: 0.5rem;
}

/* ---------- Task Instructions ---------- */
.task-box {
  background: #fff;
  border: 2px solid #000;
  padding: 1.25rem 1.5rem;
  margin: 1.25rem 0;
  border-radius: 4px;
}

.task-box .task-label {
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: #000;
  margin-bottom: 0.5rem;
}

.task-box p, .task-box li {
  font-size: 0.92rem;
}

.task-box ul, .task-box ol {
  padding-left: 1.25rem;
  margin-bottom: 0.5rem;
}

.task-box li {
  margin-bottom: 0.3rem;
}

/* ---------- Writing Space ---------- */
.writing-space {
  border: 1px dashed #ccc;
  border-radius: 4px;
  padding: 1rem 1.25rem;
  margin: 1rem 0;
  min-height: 180px;
  position: relative;
}

.writing-space::before {
  content: 'Write your response here';
  position: absolute;
  top: 1rem;
  left: 1.25rem;
  font-size: 0.8rem;
  color: #bbb;
  font-style: italic;
}

/* ---------- Client Brief ---------- */
.brief-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.75rem;
  margin: 1rem 0;
}

.brief-item {
  background: #f5f5f5;
  padding: 0.75rem 1rem;
  border-radius: 4px;
}

.brief-item .brief-label {
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: #999;
  margin-bottom: 0.2rem;
}

.brief-item .brief-value {
  font-size: 0.9rem;
  font-weight: 500;
  color: #222;
}

/* ---------- Page Header (non-cover pages) ---------- */
.page-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-bottom: 0.75rem;
  border-bottom: 1px solid #e0e0e0;
  margin-bottom: 2rem;
}

.page-header .logo-small {
  height: 28px;
}

.page-header .page-title {
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: #999;
}

/* ---------- Welcome Section ---------- */
.welcome {
  margin-bottom: 2rem;
}

.welcome h2 {
  font-family: 'Playfair Display', serif;
  font-weight: 700;
  font-size: 1.6rem;
  color: #000;
  margin-bottom: 0.75rem;
}

.welcome p {
  font-size: 0.95rem;
  color: #555;
}

.overview-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 0.75rem;
  margin: 1.5rem 0;
}

.overview-item {
  text-align: center;
  padding: 1rem 0.5rem;
  background: #f5f5f5;
  border-radius: 4px;
}

.overview-item .overview-number {
  font-size: 1.8rem;
  font-weight: 800;
  color: #000;
  line-height: 1;
}

.overview-item .overview-label {
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: #888;
  margin-top: 0.3rem;
}

/* ---------- Tips Box ---------- */
.tips-box {
  background: #f9f9f9;
  border: 1px solid #e0e0e0;
  border-radius: 4px;
  padding: 1rem 1.25rem;
  margin: 1.5rem 0;
}

.tips-box h4 {
  font-size: 0.8rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin-bottom: 0.5rem;
}

.tips-box ul {
  padding-left: 1.25rem;
  font-size: 0.88rem;
  color: #555;
}

.tips-box li {
  margin-bottom: 0.25rem;
}

/* ---------- Candidate Info ---------- */
.candidate-info {
  margin: 1.5rem 0;
  padding: 1.5rem;
  background: #f9f9f9;
  border: 1px solid #e0e0e0;
  border-radius: 4px;
}

.candidate-info h3 {
  margin-top: 0;
  margin-bottom: 1rem;
}

.input-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
  margin-bottom: 0.75rem;
}

.input-row:last-child {
  margin-bottom: 0;
}

.input-group label {
  display: block;
  font-size: 0.78rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: #555;
  margin-bottom: 0.3rem;
}

.input-group .required {
  color: #c00;
}

.input-group input {
  width: 100%;
  padding: 0.6rem 0.75rem;
  font-family: 'Inter', sans-serif;
  font-size: 0.9rem;
  border: 1px solid #d0d0d0;
  border-radius: 4px;
  background: #fff;
  color: #333;
  transition: border-color 0.2s ease;
}

.input-group input:focus {
  outline: none;
  border-color: #000;
}

.input-group input::placeholder {
  color: #bbb;
}

/* ---------- Textarea Fields ---------- */
.textarea-group {
  margin: 1.25rem 0;
}

.textarea-group label {
  display: block;
  font-size: 0.78rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: #555;
  margin-bottom: 0.4rem;
}

.textarea-group textarea {
  width: 100%;
  padding: 0.85rem 1rem;
  font-family: 'Inter', sans-serif;
  font-size: 0.9rem;
  line-height: 1.6;
  border: 1px solid #d0d0d0;
  border-radius: 4px;
  background: #fff;
  color: #333;
  resize: vertical;
  transition: border-color 0.2s ease;
}

.textarea-group textarea:focus {
  outline: none;
  border-color: #000;
  box-shadow: 0 0 0 3px rgba(0, 0, 0, 0.06);
}

.textarea-group textarea::placeholder {
  color: #bbb;
}

/* ---------- Submit Section ---------- */
.submit-section {
  margin-top: 3rem;
  padding-top: 1.5rem;
  border-top: 2px solid #000;
  text-align: center;
}

.submit-inner {
  margin-bottom: 2rem;
}

.submit-inner h3 {
  font-size: 1.1rem;
  margin-bottom: 0.5rem;
}

.submit-inner p {
  font-size: 0.88rem;
  color: #777;
  margin-bottom: 1.5rem;
}

.submit-btn {
  display: inline-block;
  background: #000;
  color: #fff;
  font-family: 'Inter', sans-serif;
  font-size: 0.9rem;
  font-weight: 600;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  padding: 0.85rem 2.5rem;
  border: none;
  border-radius: 4px;
  cursor: pointer;
  transition: background 0.2s ease, transform 0.1s ease;
}

.submit-btn:hover {
  background: #333;
}

.submit-btn:active {
  transform: scale(0.98);
}

.footer-note {
  font-size: 0.75rem;
  color: #bbb;
  margin-top: 1.5rem;
}

/* ---------- File Upload ---------- */
.file-upload-group input[type="file"] {
  width: 100%;
  padding: 0.6rem 0.75rem;
  font-family: 'Inter', sans-serif;
  font-size: 0.85rem;
  border: 1px dashed #d0d0d0;
  border-radius: 4px;
  background: #fff;
  color: #333;
  cursor: pointer;
  transition: border-color 0.2s ease;
}

.file-upload-group input[type="file"]:hover {
  border-color: #000;
}

.file-upload-group input[type="file"]:focus {
  outline: none;
  border-color: #000;
}

.file-hint {
  font-size: 0.75rem;
  color: #999;
  margin-top: 0.3rem;
  margin-bottom: 0;
}

/* ---------- Scenario Box ---------- */
.scenario-box {
  background: #f5f5f5;
  border-left: 4px solid #000;
  padding: 1.25rem 1.5rem;
  margin: 1rem 0;
  border-radius: 0 4px 4px 0;
}

.scenario-box .scenario-label {
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: #000;
  margin-bottom: 0.5rem;
}

.scenario-box p {
  font-size: 0.92rem;
  color: #444;
}

/* ---------- Rubric-Specific Styles ---------- */
.rubric-section {
  margin-bottom: 2rem;
  padding-bottom: 1.5rem;
  border-bottom: 1px solid #e0e0e0;
}

.rubric-section:last-child {
  border-bottom: none;
}

.rating-scale {
  display: flex;
  gap: 0.75rem;
  margin: 1rem 0;
}

.rating-item {
  flex: 1;
  padding: 0.75rem;
  border: 1px solid #e0e0e0;
  border-radius: 4px;
  text-align: center;
}

.rating-item.strong {
  border-color: #000;
  background: #f5f5f5;
}

.rating-item .rating-label {
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.rating-item .rating-desc {
  font-size: 0.78rem;
  color: #777;
  margin-top: 0.25rem;
}

.look-for, .red-flags {
  margin: 0.75rem 0;
}

.look-for h4, .red-flags h4 {
  font-size: 0.8rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-bottom: 0.3rem;
}

.red-flags h4 {
  color: #999;
}

.look-for ul, .red-flags ul {
  padding-left: 1.25rem;
  font-size: 0.88rem;
}

.look-for li, .red-flags li {
  margin-bottom: 0.2rem;
}

.overall-box {
  background: #000;
  color: #fff;
  padding: 1.5rem;
  border-radius: 4px;
  margin-top: 2rem;
}

.overall-box h3 {
  color: #fff;
  margin-top: 0;
  margin-bottom: 0.75rem;
}

.overall-box p {
  font-size: 0.9rem;
  color: #ccc;
}

.notes-space {
  border: 1px dashed #555;
  border-radius: 4px;
  padding: 1rem;
  margin-top: 1rem;
  min-height: 100px;
  color: #666;
  font-size: 0.8rem;
  font-style: italic;
}

/* ---------- Footer ---------- */
.page-footer {
  margin-top: 3rem;
  padding-top: 1rem;
  border-top: 1px solid #e0e0e0;
  text-align: center;
  font-size: 0.75rem;
  color: #bbb;
}

/* ============================================
   Mobile Responsive
   ============================================ */
@media (max-width: 768px) {

  /* Cover */
  .cover {
    padding: 1.5in 1.25rem;
  }

  .cover .logo {
    width: 240px;
  }

  .cover h1 {
    font-size: 1.6rem;
  }

  .cover .subtitle {
    font-size: 0.9rem;
    letter-spacing: 0.1em;
  }

  /* Page container */
  .page {
    padding: 0.5rem 1rem;
  }

  /* Page header */
  .page-header {
    flex-direction: row;
    gap: 0.5rem;
    margin-bottom: 1.25rem;
  }

  .page-header .logo-small {
    height: 22px;
  }

  .page-header .page-title {
    font-size: 0.65rem;
  }

  /* Welcome */
  .welcome h2 {
    font-size: 1.3rem;
  }

  .welcome p {
    font-size: 0.88rem;
  }

  /* Overview grid — 2x2 on mobile */
  .overview-grid {
    grid-template-columns: 1fr 1fr;
  }

  .overview-item .overview-number {
    font-size: 1.5rem;
  }

  /* Input rows — stack on mobile */
  .input-row {
    grid-template-columns: 1fr;
    gap: 0.75rem;
  }

  /* Brief grid — stack on mobile */
  .brief-grid {
    grid-template-columns: 1fr;
  }

  /* Reference material */
  .reference-material {
    padding: 1rem 1rem;
  }

  /* Email blocks */
  .email-block {
    padding: 0.85rem 1rem;
  }

  .email-block .email-header {
    font-size: 0.75rem;
  }

  .email-block .email-body {
    font-size: 0.85rem;
  }

  /* Task boxes */
  .task-box {
    padding: 1rem 1rem;
  }

  /* Section headers */
  .section-header h2 {
    font-size: 1.2rem;
  }

  .section-header .section-meta {
    flex-direction: column;
    align-items: flex-start;
    gap: 0.35rem;
  }

  /* Textareas — taller on mobile for easier typing */
  .textarea-group textarea {
    font-size: 16px; /* prevents iOS zoom on focus */
    padding: 0.75rem;
  }

  /* Inputs — prevent iOS zoom */
  .input-group input {
    font-size: 16px;
  }

  /* Scenario boxes */
  .scenario-box {
    padding: 1rem;
  }

  /* Submit */
  .submit-btn {
    width: 100%;
    padding: 1rem;
    font-size: 0.95rem;
  }

  /* Rating scale — stack on very small screens */
  .rating-scale {
    flex-direction: column;
  }

  /* Rubric overall box */
  .overall-box {
    padding: 1.25rem;
  }
}

@media (max-width: 420px) {
  .cover {
    padding: 1in 1rem;
  }

  .cover .logo {
    width: 200px;
  }

  .cover h1 {
    font-size: 1.35rem;
  }

  .overview-grid {
    grid-template-columns: 1fr 1fr;
    gap: 0.5rem;
  }

  .overview-item {
    padding: 0.75rem 0.25rem;
  }
}

/* ============================================
   Print Styles
   ============================================ */
@media print {
  @page {
    size: letter;
    margin: 0.6in 0.7in;
  }

  body {
    font-size: 11pt;
    color: #000;
  }

  .cover {
    min-height: 0;
    height: 100vh;
    page-break-after: always;
    -webkit-print-color-adjust: exact;
    print-color-adjust: exact;
  }

  .page {
    padding: 0;
    max-width: none;
  }

  .page-break {
    page-break-before: always;
  }

  .section-header {
    page-break-after: avoid;
  }

  .reference-material,
  .task-box,
  .email-block,
  .scenario-box {
    page-break-inside: avoid;
    -webkit-print-color-adjust: exact;
    print-color-adjust: exact;
  }

  .writing-space {
    min-height: 200px;
    page-break-inside: avoid;
  }

  .textarea-group textarea {
    border: 1px solid #ccc;
    page-break-inside: avoid;
  }

  .submit-section {
    display: none;
  }

  .candidate-info {
    -webkit-print-color-adjust: exact;
    print-color-adjust: exact;
  }

  .overview-grid {
    -webkit-print-color-adjust: exact;
    print-color-adjust: exact;
  }

  .badge {
    -webkit-print-color-adjust: exact;
    print-color-adjust: exact;
  }

  .no-print {
    display: none;
  }
}
