/* ===========================================================
   Research Wire — Design System
   Single source of truth for site styling.
   =========================================================== */

/* ---------- Color Palette ---------- */

:root {
  --primary: #1F3A5F;
  --secondary: #2A9D8F;
  --accent: #E9C46A;
  --background: #FFFFFF;
  --text: #343A40;
  --light: #F8F9FA;
}

/* ---------- Typography ---------- */

body {
  color: var(--text);
  line-height: 1.8;
  font-size: 1.08rem;
}

h1, h2, h3, h4 {
  color: var(--primary);
  font-weight: 700;
}

/*--------------------------------------------------
 Personally added this to control all uppercase
---------------------------------------------------*/
h1, h2, h3, h4, h5, h6 {
  text-transform: none;
}

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

a:hover {
  color: var(--primary);
}

hr {
  margin: 2rem 0;
}

img {
  border-radius: 10px;
}

/*--------------------------------------------------
 Hero
---------------------------------------------------*/

.hero {
  background: linear-gradient(135deg, var(--primary) 0%, #16283f 100%);
  color: #fff;
  text-align: center;
  padding: 7rem 1.5rem;
  margin-bottom: 0;
}

.hero h1 {
  color: #fff;
  font-size: 2.75rem;
  font-weight: 800;
  max-width: 42rem;
  margin: 0 auto 1.25rem;
}

.hero p {
  font-size: 1.2rem;
  color: rgba(255, 255, 255, 0.85);
  max-width: 38rem;
  margin: 0 auto 2.25rem;
  line-height: 1.7;
}

.hero .btn {
  margin: 0 .4rem;
}

.hero .btn-primary {
  background: var(--accent);
  color: var(--primary);
  border: none;
}

.hero .btn-primary:hover {
  background: #f0d488;
  color: var(--primary);
}

.hero .btn-outline-primary {
  border: 2px solid rgba(255, 255, 255, 0.6);
  color: #fff;
}

.hero .btn-outline-primary:hover {
  background: rgba(255, 255, 255, 0.12);
  border-color: #fff;
  color: #fff;
}

/*--------------------------------------------------
 Section backgrounds
---------------------------------------------------*/

section {
  padding-top: 0rem;
  padding-bottom: 0rem;
}

.section-white {
  background: white;
  padding: 6rem 0;
}

.section-light {
  background: var(--light);
  padding: 6rem 0;
}

.section-primary {
  background: var(--primary);
  color: white;
  text-align: center;
  padding: 6rem 0;
}

.section-primary h1,
.section-primary h2,
.section-primary h3 {
  color: white;
}

.section-primary p {
  color: rgba(255, 255, 255, 0.85);
  max-width: 34rem;
  margin-left: auto;
  margin-right: auto;
}

/* btn-primary defaults to a navy background, which would be
   invisible against this section's navy background */
.section-primary .btn-primary {
  background: var(--accent);
  color: var(--primary);
  border: none;
}

.section-primary .btn-primary:hover {
  background: #f0d488;
  color: var(--primary);
}

/* Center section headings across the homepage */
.section-white h2,
.section-light h2 {
  text-align: center;
}

/*--------------------------------------------------
 Featured Services / card grid
---------------------------------------------------*/

.grid h3 {
  color: var(--primary);
  margin-top: 1rem;
  font-size: 1.15rem;
}

.grid > div {
  background: white;
  padding: 1.75rem;
  border-radius: 12px;
  box-shadow: 0 3px 12px rgba(0, 0, 0, .08);
  transition: transform .2s ease, box-shadow .2s ease;
  height: 100%;
}

.grid > div:hover {
  transform: translateY(-4px);
  box-shadow: 0 8px 24px rgba(0, 0, 0, .12);
}

.grid i.bi {
  color: var(--secondary);
  font-size: 1.4rem;
}

.card {
  border: none;
  border-radius: 15px;
  box-shadow: 0 5px 20px rgba(0, 0, 0, .08);
  transition: .3s;
}

.card:hover {
  transform: translateY(-6px);
}

/*--------------------------------------------------
 Navigation bar
---------------------------------------------------*/

.navbar {
  padding-top: 1rem;
  padding-bottom: 1rem;
  box-shadow: 0 2px 15px rgba(0, 0, 0, .06);
}

.navbar-brand {
  font-weight: 700;
  font-size: 1.4rem;
}

.nav-link {
  margin-left: .6rem;
  margin-right: .6rem;
}

/*--------------------------------------------------
 Buttons
---------------------------------------------------*/

.btn {
  border-radius: 40px;
  padding: .9rem 1.8rem;
  font-weight: 600;
}

.btn-primary {
  background: var(--primary);
  border: none;
}

.btn-primary:hover {
  background: var(--secondary);
}

.btn-outline-primary {
  border: 2px solid var(--primary);
  color: var(--primary);
}

.btn-outline-primary:hover {
  background: var(--primary);
  color: #fff;
}

/*--------------------------------------------------
 Footer
---------------------------------------------------*/

.page-footer,
footer {
  margin-top: 2rem;
  padding: 3rem 1rem 2rem;
  background: var(--light);
  border-top: 1px solid rgba(0, 0, 0, .06);
}

.page-footer a {
  color: var(--text);
}

.page-footer a:hover {
  color: var(--secondary);
}

.footer-heading {
  color: var(--primary);
  font-weight: 700;
  font-size: .85rem;
  text-transform: uppercase;
  letter-spacing: .06em;
  margin-bottom: .75rem;
}

.footer-copyright {
  color: #868e96;
  font-size: .85rem;
}

.footer-social {
  margin-top: .5rem;
}

.footer-social a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2.2rem;
  height: 2.2rem;
  margin-right: .5rem;
  border-radius: 50%;
  background: white;
  box-shadow: 0 2px 8px rgba(0, 0, 0, .08);
  color: var(--primary);
  font-size: 1rem;
}

.footer-social a:hover {
  background: var(--secondary);
  color: white;
}

.footer-links a {
  margin: 0 .4rem;
}

/*--------------------------------------------------
 Dark mode overrides
 Quarto toggles a class on <body> (quarto-dark /
 quarto-light) rather than recomputing our CSS, so
 anything using fixed light-theme colors needs an
 explicit override here. The hero is intentionally
 left untouched — it's a fixed navy block in both
 modes by design.
---------------------------------------------------*/

body.quarto-dark {
  --text: #E4E6EB;
  --light: #1E2530;
}

body.quarto-dark h1,
body.quarto-dark h2,
body.quarto-dark h3,
body.quarto-dark h4 {
  color: var(--secondary);
}

body.quarto-dark a {
  color: var(--accent);
}

body.quarto-dark a:hover {
  color: var(--secondary);
}

body.quarto-dark .section-white,
body.quarto-dark .grid > div,
body.quarto-dark .card {
  background: #242C39;
  box-shadow: 0 3px 12px rgba(0, 0, 0, .35);
}

body.quarto-dark .grid > div:hover,
body.quarto-dark .card:hover {
  box-shadow: 0 8px 24px rgba(0, 0, 0, .45);
}

body.quarto-dark .section-primary {
  background: #16283f;
}

body.quarto-dark .navbar {
  box-shadow: 0 2px 15px rgba(0, 0, 0, .3);
}

body.quarto-dark .page-footer,
body.quarto-dark footer {
  background: var(--light);
  border-top-color: rgba(255, 255, 255, .08);
}

body.quarto-dark .footer-social a {
  background: #242C39;
  color: var(--secondary);
}

body.quarto-dark .footer-copyright {
  color: #9BA3AF;
}

body.quarto-dark .btn-outline-primary {
  border-color: var(--secondary);
  color: var(--secondary);
}

body.quarto-dark .btn-outline-primary:hover {
  background: var(--secondary);
  color: #16283f;
}
