/* ============================================================
   Understanding Disability — styles.css
   Styled to follow the Calvin University Brand Identity
   Standards: maroon & gold primary palette, with Bright Red
   and Renew Blue used as supporting secondary accents.
   Typefaces use Calvin's sanctioned system alternates
   (Century Gothic / Arial / Georgia).
   Sizing: rem/em throughout; px only where absolutely needed
   (borders, shadows, spinner thickness).
   ============================================================ */

:root {
  /* Calvin primary palette */
  --maroon: #8c2131;        /* Classic 29 Maroon (PMS 202 U) */
  --gold: #f3cd00;          /* Classic 6 Gold (PMS 7405 U) */
  /* Calvin secondary palette (accent only) */
  --bright-red: #c2002f;    /* Bright Red (PMS 200 U) */
  --renew-blue: #71b1c8;    /* Renew Blue (PMS 7458 U) */
  --dark: #1a1a1a;
  --light: #f8f9f5;

  font-size: 100%;
}

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

html {
  scroll-behavior: smooth;
}

body {
  font-family: Arial, Helvetica, "Century Gothic", sans-serif;
  color: var(--dark);
  background: var(--light);
  overflow-x: hidden;
  line-height: 1.6;
}

img {
  max-width: 100%;
  display: block;
}

a {
  color: var(--maroon);
  text-decoration: none;
}

/* ---------- Loader ---------- */
.loader {
  position: fixed;
  inset: 0;
  background: var(--maroon);
  z-index: 9999;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: opacity 0.5s ease, visibility 0.5s ease;
}
.loader.hidden {
  opacity: 0;
  visibility: hidden;
}
.loader-spinner {
  width: 3.125rem;
  height: 3.125rem;
  border: 3px solid rgba(255, 255, 255, 0.3); /* px for crisp ring */
  border-top-color: var(--gold);
  border-radius: 50%;
  animation: spin 1s linear infinite;
}
@keyframes spin {
  to { transform: rotate(360deg); }
}

/* ---------- Hero ---------- */
.hero {
  position: relative;
  min-height: 44rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  overflow: hidden;
  padding: 2rem;
}
.hero-bg {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background:
    url('https://images.unsplash.com/photo-1544620347-c4fd4a3d5957?auto=format&fit=crop&w=1600&q=80')
    center / cover no-repeat;
  filter: brightness(0.45);
  transform: scale(1.1);
  animation: heroZoom 20s ease-in-out infinite alternate;
  z-index: 0;
}
@keyframes heroZoom {
  from { transform: scale(1.1); }
  to   { transform: scale(1.2); }
}
.hero-content {
  position: relative;
  z-index: 2;
  color: white;
  max-width: 56rem;
  padding: 0 2rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
}
.hero-badge {
  display: inline-block;
  padding: 0.5rem 1.5rem;
  background: rgba(255, 255, 255, 0.15);
  backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, 0.3);
  border-radius: 3.125rem;
  font-size: 0.9rem;
  letter-spacing: 0.125em;
  text-transform: uppercase;
  margin-bottom: 1.5rem;
  animation: fadeInUp 1s ease 0.2s both;
}
.hero h1 {
  font-family: Georgia, "Times New Roman", serif; /* Century Schoolbook alternate */
  font-size: clamp(2.5rem, 6vw, 5rem);
  font-weight: 700;
  line-height: 1.1;
  margin-bottom: 1rem;
  animation: fadeInUp 1s ease 0.4s both;
}
.hero h1 span {
  color: var(--gold);
}
.hero p {
  font-size: clamp(1rem, 2vw, 1.25rem);
  line-height: 1.7;
  opacity: 0.92;
  margin-bottom: 2rem;
  animation: fadeInUp 1s ease 0.6s both;
}
.hero-cta {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 1rem 2.5rem;
  background: var(--maroon);
  color: white;
  text-decoration: none;
  border-radius: 3.125rem;
  font-weight: 600;
  font-size: 1.1rem;
  transition: all 0.3s ease;
  animation: fadeInUp 1s ease 0.8s both;
}
.hero-cta:hover {
  background: #b02a3c;
  transform: translateY(-0.125rem);
  box-shadow: 0 0.625rem 1.875rem rgba(140, 33, 49, 0.3);
}
.hero-mission {
  position: relative;
  z-index: 3;
  max-width: 50rem;
  width: 95%;
  padding: 2rem;
  background: rgba(26, 26, 26, 0.78);
  backdrop-filter: blur(10px);
  border-radius: 1rem;
  color: white;
  text-align: center;
  margin-top: 2rem;
  animation: fadeInUp 1s ease 1s both;
}
.hero-mission .section-label {
  background: rgba(243, 205, 0, 0.2);
  color: var(--gold);
  margin-bottom: 1rem;
  display: inline-block;
}
.hero-mission h2 {
  color: white;
  font-size: 2rem;
  margin-bottom: 1rem;
}
.hero-mission h2 {
  font-family: Georgia, "Times New Roman", serif;
}
.hero-mission p {
  color: rgba(255, 255, 255, 0.9);
  font-size: 1rem;
  line-height: 1.6;
  margin: 0;
  opacity: 1;
}
.scroll-indicator {
  position: absolute;
  bottom: 2rem;
  left: 50%;
  transform: translateX(-50%);
  z-index: 2;
  animation: bounce 2s ease infinite;
}
.scroll-indicator svg {
  width: 1.875rem;
  height: 1.875rem;
  fill: white;
  opacity: 0.7;
}
@keyframes bounce {
  0%, 20%, 50%, 80%, 100% { transform: translateX(-50%) translateY(0); }
  40% { transform: translateX(-50%) translateY(-0.625rem); }
  60% { transform: translateX(-50%) translateY(-0.3125rem); }
}
@keyframes fadeInUp {
  from { opacity: 0; transform: translateY(1.875rem); }
  to   { opacity: 1; transform: translateY(0); }
}

/* ---------- Section label pill ---------- */
.section-label {
  display: inline-block;
  padding: 0.4rem 1.2rem;
  background: rgba(140, 33, 49, 0.1);
  color: var(--maroon);
  border-radius: 3.125rem;
  font-size: 0.85rem;
  font-weight: 600;
  letter-spacing: 0.125em;
  text-transform: uppercase;
  margin-bottom: 1.5rem;
}
.section-label--red {
  background: rgba(194, 0, 47, 0.1);
  color: var(--bright-red);
}
.section-label--blue {
  background: rgba(113, 177, 200, 0.18);
  color: #2f7a94;
}

/* ---------- Types / directory ---------- */
.orgs-section {
  padding: 6rem 2rem;
  max-width: 87.5rem;
  margin: 0 auto;
}
.orgs-header {
  text-align: center;
  margin-bottom: 4rem;
}
.orgs-header h2 {
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(2rem, 4vw, 3rem);
  color: var(--dark);
  margin-bottom: 1rem;
}
.orgs-header p {
  color: #666;
  font-size: 1.1rem;
}
.filter-buttons {
  display: flex;
  justify-content: center;
  gap: 0.75rem;
  flex-wrap: wrap;
  margin-bottom: 3rem;
}
.filter-btn {
  padding: 0.6rem 1.5rem;
  border: 2px solid #ddd;
  background: white;
  border-radius: 3.125rem;
  cursor: pointer;
  font-family: Arial, Helvetica, sans-serif;
  font-size: 0.9rem;
  font-weight: 500;
  transition: all 0.3s ease;
  color: var(--dark);
}
.filter-btn:hover,
.filter-btn.active {
  border-color: var(--maroon);
  background: var(--maroon);
  color: white;
}
.orgs-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(21.875rem, 1fr));
  gap: 2rem;
}
.org-card {
  background: white;
  border-radius: 1rem;
  overflow: hidden;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.06);
  transition: all 0.4s ease;
  opacity: 0;
  transform: translateY(1.25rem);
}
.org-card.visible {
  opacity: 1;
  transform: translateY(0);
}
.org-card:hover {
  transform: translateY(-0.5rem);
  box-shadow: 0 1.25rem 2.5rem rgba(0, 0, 0, 0.12);
}
.org-card-image {
  height: 12.5rem;
  overflow: hidden;
  position: relative;
}
.org-card-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.6s ease;
}
.org-card:hover .org-card-image img {
  transform: scale(1.08);
}
.org-card-tag {
  position: absolute;
  top: 1rem;
  left: 1rem;
  padding: 0.35rem 1rem;
  background: rgba(255, 255, 255, 0.9);
  backdrop-filter: blur(10px);
  border-radius: 3.125rem;
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--maroon);
  text-transform: uppercase;
  letter-spacing: 0.0625rem;
}
.org-card-tag--blue {
  color: #2f7a94;
}
.org-card-content {
  padding: 1.5rem;
}
.org-card-content h3 {
  font-family: Georgia, "Times New Roman", serif;
  font-size: 1.3rem;
  color: var(--dark);
  margin-bottom: 0.5rem;
}
.org-card-content p {
  font-size: 0.95rem;
  color: #666;
  line-height: 1.6;
  margin-bottom: 1.25rem;
}
.org-card-link {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.7rem 1.5rem;
  background: var(--maroon);
  color: white;
  border-radius: 3.125rem;
  font-size: 0.9rem;
  font-weight: 500;
  transition: all 0.3s ease;
}
.org-card-link:hover {
  background: #b02a3c;
  gap: 0.75rem;
}
/* Secondary (blue) card link — used for resource cards */
.org-card-link--blue {
  background: var(--renew-blue);
}
.org-card-link--blue:hover {
  background: #5b9bb4;
}

/* ---------- Quiz ---------- */
.quiz-section {
  padding: 6rem 2rem;
  background: #f2efe4;
}
.quiz-inner {
  max-width: 46rem;
  margin: 0 auto;
  text-align: center;
}
.quiz-inner > h2 {
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(2rem, 4vw, 3rem);
  color: var(--dark);
  margin-bottom: 1rem;
}
.quiz-intro {
  color: #666;
  font-size: 1.1rem;
  margin-bottom: 2rem;
}
.quiz-form {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 0.75rem;
  text-align: left;
}
.quiz-option {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.75rem 1rem;
  background: white;
  border: 1px solid #ddd;
  border-radius: 0.75rem;
  cursor: pointer;
  transition: all 0.2s ease;
}
.quiz-option:hover {
  border-color: var(--maroon);
}
.quiz-option input {
  width: 1.25rem;
  height: 1.25rem;
  accent-color: var(--maroon);
  flex-shrink: 0;
}
.quiz-option span {
  font-size: 0.95rem;
}
.quiz-option.selected {
  background: rgba(140, 33, 49, 0.08);
  border-color: var(--maroon);
}
.quiz-submit {
  grid-column: 1 / -1;
  margin-top: 1rem;
  padding: 1rem 2rem;
  background: var(--maroon);
  color: white;
  border: 0;
  border-radius: 3.125rem;
  font-family: Arial, Helvetica, sans-serif;
  font-size: 1.05rem;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.3s ease, transform 0.1s ease;
}
.quiz-submit:hover {
  background: #b02a3c;
}
/* Secondary (red) reset button */
.quiz-reset {
  grid-column: 1 / -1;
  padding: 0.6rem;
  background: transparent;
  color: var(--bright-red);
  border: 1px solid var(--bright-red);
  border-radius: 3.125rem;
  font-family: Arial, Helvetica, sans-serif;
  font-size: 0.9rem;
  cursor: pointer;
  transition: all 0.3s ease;
}
.quiz-reset:hover {
  background: rgba(194, 0, 47, 0.08);
  color: #9c0026;
}
.quiz-result {
  margin-top: 1.5rem;
  padding: 1.5rem;
  background: white;
  border-left: 0.35rem solid var(--maroon);
  border-radius: 0.75rem;
  text-align: left;
}
.quiz-result h3 {
  font-family: Georgia, "Times New Roman", serif;
  color: var(--dark);
  margin-bottom: 0.5rem;
}
.quiz-result p {
  color: #666;
  line-height: 1.7;
}
.quiz-result p em {
  color: var(--renew-blue);
  font-style: normal;
  font-weight: 600;
}

/* ---------- Quote ---------- */
.quote-section {
  background:
    url('https://images.unsplash.com/photo-1584697964358-3e14ca57658b?auto=format&fit=crop&w=1600&q=80')
    center / cover no-repeat;
  position: relative;
  padding: 8rem 2rem;
  text-align: center;
  color: white;
}
.quote-section::before {
  content: '';
  position: absolute;
  inset: 0;
  background: rgba(140, 33, 49, 0.78);
}
.quote-content {
  position: relative;
  z-index: 2;
  max-width: 50rem;
  margin: 0 auto;
}
.quote-content blockquote {
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(1.5rem, 3vw, 2.25rem);
  line-height: 1.5;
  margin-bottom: 2rem;
  font-style: italic;
}
.quote-content cite {
  font-style: normal;
  font-size: 1rem;
  opacity: 0.85;
}

/* ---------- Footer ---------- */
footer {
  background: var(--dark);
  color: white;
  padding: 4rem 2rem 2rem;
}
.footer-content {
  max-width: 75rem;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 2fr 1fr 1fr;
  gap: 3rem;
  margin-bottom: 3rem;
}
.footer-brand h3 {
  font-family: Georgia, "Times New Roman", serif;
  font-size: 1.5rem;
  margin-bottom: 1rem;
}
.footer-brand p {
  opacity: 0.7;
  line-height: 1.7;
}
.footer-col h4 {
  font-size: 0.85rem;
  margin-bottom: 1rem;
  color: var(--gold);
  text-transform: uppercase;
  letter-spacing: 0.0625rem;
}
.footer-col ul {
  list-style: none;
}
.footer-col li {
  margin-bottom: 0.5rem;
}
.footer-col a {
  color: rgba(255, 255, 255, 0.7);
  text-decoration: none;
  transition: color 0.3s ease;
}
.footer-col a:hover {
  color: var(--gold);
}
.footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  padding-top: 2rem;
  text-align: center;
  opacity: 0.6;
  font-size: 0.9rem;
}

/* ---------- Responsive (rem-based) ---------- */
@media (max-width: 64rem) {
  .footer-content { grid-template-columns: 1fr; gap: 2rem; }
}
@media (max-width: 48rem) {
  .orgs-grid { grid-template-columns: 1fr; }
  .quiz-form { grid-template-columns: 1fr; }
  .hero { min-height: 38rem; }
}
@media (max-width: 30rem) {
  .filter-buttons { gap: 0.5rem; }
  .filter-btn { padding: 0.5rem 1rem; font-size: 0.8rem; }
}