@import url("brand.css");

/* Roboto for readability */
@import url("https://fonts.googleapis.com/css2?family=Roboto:wght@400;500;700;800&display=swap");

/* Local tokens requested */
:root{
  --red-text: #8d0000;     /* for red text accents */
  --red-cta:  #ea0000;     /* button background */
  --red-hover:#ea0000;     /* hover text contrast */
  --header-offset: 74px;   /* keep header visible + prevent overlap */
}

/* ---------------------------
   Base / Reset
--------------------------- */
* { box-sizing: border-box; }
html, body { height: 100%; }
body{
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font: 500 16px/1.68 Roboto, system-ui, -apple-system, Segoe UI, Arial, sans-serif;
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;

  /* Because header is fixed */
  padding-top: var(--header-offset);
}

img{ max-width:100%; height:auto; display:block; }
a{ color: inherit; text-decoration: none; }
button{ font: inherit; }

:focus-visible{ outline: 2px solid var(--red-hover); outline-offset: 3px; }

.container{
  width: min(var(--container), calc(100% - (var(--gutter) * 2)));
  margin: 0 auto;
}

.muted{ color: var(--text-muted); }
.small{ font-size: 13px; }

/* ---------------------------
   Type
--------------------------- */
.h1{
  margin: 0;
  font: 800 clamp(28px, 3.2vw, 54px)/1.08 Roboto, system-ui, sans-serif;
  letter-spacing: -0.02em;
  color: var(--text-strong);
}
.h2{
  margin: 0;
  font: 800 clamp(20px, 1.8vw, 28px)/1.18 Roboto, system-ui, sans-serif;
  letter-spacing: -0.012em;
  color: var(--text-strong);
}
.h3{
  margin: 0;
  font: 800 16px/1.25 Roboto, system-ui, sans-serif;
  color: var(--text-strong);
}

.lead{
  margin: 12px 0 0;
  max-width: 72ch;
  font-size: 1.25rem;       /* 20px if root is 16px */
  line-height: 1.6;
  color: rgba(15, 23, 42, 0.86); /* darker than muted, still soft */
}

/* ---------------------------
   Layout
--------------------------- */
.section{ padding: 56px 0; }
.section-tight{ padding: 32px 0; }

.grid{ display:grid; gap: 16px; }
.grid-2{ grid-template-columns: repeat(2, minmax(0,1fr)); }
.grid-3{ grid-template-columns: repeat(3, minmax(0,1fr)); }

@media (max-width: 980px){
  .grid-2, .grid-3 { grid-template-columns: 1fr; }
}

/* ---------------------------
   Buttons (per spec)
--------------------------- */
.btn{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  gap: 10px;
  padding: 11px 14px;
  border-radius: 14px;
  font-size: 14px;
  font-weight: 800;
  border: 1px solid transparent;
  cursor: pointer;
  user-select:none;
  white-space: nowrap;
  transition: transform 140ms ease, background 140ms ease, border-color 140ms ease, box-shadow 140ms ease, filter 140ms ease, color 140ms ease;
}
.btn:active{ transform: translateY(1px); }

.btn-primary{
  background: var(--red-cta);   /* #ea0000 */
  color:#fff;
}
.btn-primary:hover{
  filter: brightness(0.96);
  box-shadow: 0 10px 22px rgba(15,23,42,0.12);
}

.btn-secondary{
  background:#fff;
  border-color: rgba(229,231,235,0.95);
  color: var(--text-strong);
}
.btn-secondary:hover{ background: var(--panel-soft); }

.btn-link{
  color: var(--red-text); /* #8d0000 */
  font-weight: 800;
  padding: 0;
  border: 0;
  background: transparent;
}
.btn-link:hover{
  color: var(--red-hover); /* #ea0000 */
  text-decoration: underline;
}

/* ---------------------------
   Header / Nav (always visible)
--------------------------- */
.header{
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  width: 100%;
  z-index: 999;
  background: rgba(255,255,255,0.92);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid rgba(229,231,235,0.95);
}
.header.is-scrolled{
  box-shadow: 0 10px 20px rgba(15,23,42,0.06);
}
.header-inner{
  display:flex;
  align-items:center;
  gap: 14px;
  padding: 12px 0;
}

.brand{
  display:flex;
  align-items:center;
  gap: 10px;
  min-width: 220px;
}

.nav{
  display:flex;
  align-items:center;
  gap: 4px;
  margin-left: auto;
  flex-wrap: wrap;
}
.nav a{
  color: var(--text-strong);
  font-size: 13px;
  font-weight: 800;
  padding: 10px 10px;
  border-radius: 12px;
  border: 1px solid transparent;
  transition: background 140ms ease, border-color 140ms ease, color 140ms ease;
}
.nav a:hover{
  color: var(--red-hover);
  background: rgba(248,250,252,0.95);
  border-color: rgba(229,231,235,0.85);
}

.header-cta{
  display:flex;
  gap: 10px;
  margin-left: 10px;
}

/* iOS blue text fix + hamburger icon button styling */
.menu-toggle{
  display:none;
  margin-left: auto;
  padding: 10px 12px;
  border-radius: 12px;
  border: 1px solid rgba(229,231,235,0.95);
  background:#fff;

  -webkit-appearance: none;
  appearance: none;

  color: var(--text-strong);
  line-height: 0;
  cursor:pointer;
}
.menu-toggle svg{
  width: 22px;
  height: 22px;
  display:block;
}
.menu-toggle:hover{
  background: rgba(248,250,252,0.95);
}

/* icon swap */
.menu-toggle .icon-close{ display: none; }
.menu-toggle.is-open .icon-hamburger{ display: none; }
.menu-toggle.is-open .icon-close{ display: block; }

@media (max-width: 1120px){
  .nav, .header-cta{ display:none; }
  .menu-toggle{ display:inline-flex; align-items:center; justify-content:center; }
}

/* ---------------------------
   Mobile Drawer
--------------------------- */
.drawer-backdrop{
  position: fixed;
  inset: 0;
  background: rgba(15,23,42,0.34);
  display:none;
  z-index: 990;
}
.drawer{
  position: fixed;
  top:0;
  right:0;
  height:100%;
  width: min(420px, 92vw);
  background:#fff;
  border-left: 1px solid rgba(229,231,235,0.95);
  box-shadow: var(--shadow-md);
  transform: translateX(102%);
  transition: transform 220ms ease;
  z-index: 991;
  display:flex;
  flex-direction: column;
}
.drawer.open{ transform: translateX(0); }
.drawer-backdrop.open{ display:block; }

.drawer-head{
  display:flex;
  align-items:center;
  justify-content: space-between;
  padding: 14px 16px;
  border-bottom: 1px solid rgba(229,231,235,0.95);
}
.drawer-title{ font-weight: 900; color: var(--text-strong); }

.drawer-body{ padding: 14px 16px; overflow:auto; }

/* Drawer links */
.drawer a{
  display:block;
  padding: 12px 12px;
  border-radius: 14px;
  font-weight: 900;
  color: var(--text-strong);
}
.drawer a:hover{
  background: rgba(248,250,252,0.95);
  color: var(--red-hover);
}

/* Drawer button: keep white text */
.drawer a.btn,
.drawer a.btn:hover{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  color:#fff !important;
  background: var(--red-cta);
  border: 1px solid transparent;
  padding: 11px 14px;
}
.drawer a.btn:hover{ filter: brightness(0.96); }

.drawer-cta{
  padding: 14px 16px;
  border-top: 1px solid rgba(229,231,235,0.95);
}

/* ---------------------------
   Hero — background image (index.php)
--------------------------- */
.hero{
  position: relative;
  border-bottom: 1px solid rgba(229,231,235,0.95);

  background-image: url("hero2-hs.jpg");
  background-repeat: no-repeat;
  background-size: cover;
  background-position: center;
  background-color: #fff;

  min-height: calc(100vh - var(--header-offset));

  display: flex;
  align-items: center;
  justify-content: center;

  /* Move content up by 15% of viewport height */
  padding-bottom: 20vh;
}

.hero::before{ content: none; }

.hero-inner{
  text-align: center;
  width: 100%;
}

@media (max-width: 768px){
  .hero-inner{
    padding-left: var(--gutter);
    padding-right: var(--gutter);
  }
}

.hero-inner .lead,
.hero-inner .h1{
  margin-left: auto;
  margin-right: auto;
}

.hero-top{
  display:grid;
  grid-template-columns: 1fr;
  gap: 18px;
  align-items: center;
}

/* ---------------------------
   Media (used across site)
--------------------------- */
.media{
  border-radius: var(--radius-xl);
  border: 1px solid rgba(229,231,235,0.92);
  overflow:hidden;
  background: rgba(248,250,252,0.95);
  box-shadow: var(--shadow-sm);
}
.media img{
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.media-division{ aspect-ratio: 4 / 3; }

/* ---------------------------
   Division sections (index.php)
--------------------------- */
.division{
  background: #fff;
  border: 1px solid rgba(229,231,235,0.92);
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow-sm);
  overflow: hidden;
}
.division-inner{
  padding: 22px;
  display:grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 18px;
  align-items: start;
}
@media (max-width: 980px){
  .division-inner{ grid-template-columns: 1fr; }
}

.points{
  margin: 12px 0 0;
  padding: 0;
  list-style: none;
  display:grid;
  gap: 8px;
}
.points li{
  display:flex;
  gap: 10px;
  align-items:flex-start;
  color: var(--text-muted);
}
.dot{
  width: 7px;
  height: 7px;
  border-radius: 999px;
  background: var(--red-text);
  margin-top: 10px;
  flex: none;
}

/* ---------------------------
   Footer (site-wide)
--------------------------- */
.footer{
  margin-top: 54px;
  background:#fff;
  border-top: 1px solid rgba(229,231,235,0.95);
}
.footer-grid{
  padding: 34px 0;
  display:grid;
  grid-template-columns: 2fr 1fr 1fr;
  gap: 18px;
}
.footer h3{
  margin:0;
  font-size: 13px;
  font-weight: 900;
  color: var(--text-strong);
}
.footer-links{
  display:grid;
  gap: 10px;
  margin-top: 10px;
}
.footer-links a{
  font-weight: 800;
  color: var(--text-strong);
}
.footer-links a:hover{ color: var(--red-hover); }

.footer-bottom{
  border-top: 1px solid rgba(229,231,235,0.95);
  padding: 14px 0;
  color: var(--text-muted);
  font-size: 12px;
}
@media (max-width: 980px){
  .footer-grid{ grid-template-columns: 1fr; }
}

.socials{
  display:flex;
  gap:10px;
  align-items:center;
}

.social-btn{
  width: 38px;
  height: 38px;
  display:inline-flex;
  align-items:center;
  justify-content:center;
  border-radius: 999px;
  border: 1px solid rgba(100,116,139,0.35); /* muted grey */
  color: rgba(100,116,139,0.9);            /* muted grey */
  background: transparent;
  transition: background 140ms ease, border-color 140ms ease, color 140ms ease, transform 140ms ease;
}

.social-btn svg{
  width: 18px;
  height: 18px;
}

.social-btn:hover{
  background: rgba(100,116,139,0.10);
  border-color: rgba(100,116,139,0.55);
  color: rgba(100,116,139,1);
  transform: translateY(-1px);
}

/* ---------------------------
   Impact Section (index.php)
--------------------------- */
.impact{
  background: #ffffff;
  padding: 44px 0; /* was 60px */
  border-bottom: 1px solid rgba(229,231,235,0.95);
}

.impact-inner{
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
}

.impact-card{
  background: var(--panel);
  border: 1px solid rgba(229,231,235,0.95);
  border-radius: 18px;
  padding: 18px 18px 20px;
  box-shadow: 0 10px 22px rgba(15,23,42,0.06);
  position: relative;
  overflow: hidden;
  transition: transform 160ms ease, box-shadow 160ms ease, border-color 160ms ease;
}

/* subtle brand accent bar */
.impact-card::before{
  content:"";
  position:absolute;
  inset: 0 0 auto 0;
  height: 3px;
  background: linear-gradient(90deg, rgba(234,0,0,0.85), rgba(141,0,0,0.35));
}

.impact-card:hover{
  transform: translateY(-3px);
  box-shadow: 0 14px 30px rgba(15,23,42,0.10);
  border-color: rgba(229,231,235,1);
}

.impact-icon{
  width: 44px;
  height: 44px;
  border-radius: 12px;
  display:flex;
  align-items:center;
  justify-content:center;
  color: rgba(141,0,0,0.95); /* brand red */
  background: rgba(141,0,0,0.06);
  border: 1px solid rgba(141,0,0,0.12);
}

.impact-icon svg{
  width: 22px;
  height: 22px;
}

.impact-copy{
  margin-top: 14px;
}

.impact-heading{
  margin: 0;
  font-size: 15px;
  font-weight: 900;
  color: var(--text-strong);
  letter-spacing: -0.01em;
}

.impact-text{
  margin: 8px 0 0;
  font-size: 16px;
  line-height: 1.5;
  color: rgba(15, 23, 42, 0.86);
}

/* Mobile */
@media (max-width: 980px){
  .impact-inner{
    grid-template-columns: 1fr;
  }
}
