/*! HTML5 Boilerplate v9.0.1 | MIT License | https://html5boilerplate.com/ */

/* main.css 3.0.0 | MIT License | https://github.com/h5bp/main.css#readme */
/*
 * What follows is the result of much research on cross-browser styling.
 * Credit left inline and big thanks to Nicolas Gallagher, Jonathan Neal,
 * Kroc Camen, and the H5BP dev community and team.
 */

/* ==========================================================================
   Base styles: opinionated defaults
   ========================================================================== */

html {
  color: #222;
  font-size: 1em;
  line-height: 1.4;
}

/*
 * Remove text-shadow in selection highlight:
 * https://twitter.com/miketaylr/status/12228805301
 *
 * Customize the background color to match your design.
 */

::-moz-selection {
  background: #b3d4fc;
  text-shadow: none;
}

::selection {
  background: #b3d4fc;
  text-shadow: none;
}

/*
 * A better looking default horizontal rule
 */

hr {
  display: block;
  height: 1px;
  border: 0;
  border-top: 1px solid #ccc;
  margin: 1em 0;
  padding: 0;
}

/*
 * Remove the gap between audio, canvas, iframes,
 * images, videos and the bottom of their containers:
 * https://github.com/h5bp/html5-boilerplate/issues/440
 */

audio,
canvas,
iframe,
img,
svg,
video {
  vertical-align: middle;
}

/*
 * Remove default fieldset styles.
 */

fieldset {
  border: 0;
  margin: 0;
  padding: 0;
}

/*
 * Allow only vertical resizing of textareas.
 */

textarea {
  resize: vertical;
}

/* ==========================================================================
   Author's custom styles
   ========================================================================== */

/* CSS Variables */
:root {
  /* Design System Colors from design.md */
  --primary-color: #172126;
  --primary-dark: #0d1114;
  --primary-light: #2d3a42;
  --accent-color: #2c9684;
  --accent-dark: #257a6b;
  --neutral-color: #e5e7eb;

  /* Derived/Supporting Colors */
  --secondary-white: #ffffff;
  --secondary-light: #f2f2f2;
  --text-dark: #172126;
  --text-light: #5a6b73;
  --text-muted: #8a9ba3;
  --bg-light: #f2f2f2;
  --bg-white: #ffffff;
  --border-color: #e5e7eb;

  /* Shadows and Effects */
  --shadow-sm: 0 2px 4px rgba(23, 33, 38, 0.1);
  --shadow-md: 0 4px 6px rgba(23, 33, 38, 0.12);
  --shadow-lg: 0 10px 25px rgba(23, 33, 38, 0.15);
  --transition: all 0.3s ease;
  --max-width: 1200px;
  --font-primary: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
}

/* Base Styles */
* {
  box-sizing: border-box;
}

body {
  font-family: var(--font-primary);
  color: var(--text-dark);
  line-height: 1.6;
  background-color: var(--bg-white);
  margin: 0;
  padding: 0;
}

.container {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 20px;
}

img {
  max-width: 100%;
  height: auto;
}

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

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

/* Typography */
h1, h2, h3, h4, h5, h6 {
  font-weight: 600;
  line-height: 1.2;
  margin: 0 0 1rem 0;
  color: var(--text-dark);
}

h1 {
  font-size: 2.5rem;
}

h2 {
  font-size: 2rem;
}

h3 {
  font-size: 1.5rem;
}

p {
  margin: 0 0 1rem 0;
}

/* Buttons */
.btn {
  display: inline-block;
  padding: 12px 28px;
  border-radius: 4px;
  font-weight: 500;
  text-align: center;
  transition: var(--transition);
  cursor: pointer;
  border: 2px solid transparent;
}

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

.btn-primary:hover {
  background-color: var(--primary-dark);
  border-color: var(--primary-dark);
  color: white;
}

.btn-secondary {
  background-color: transparent;
  color: var(--primary-color);
  border-color: var(--primary-color);
}

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

.btn-large {
  padding: 16px 40px;
  font-size: 1.1rem;
}

/* Header & Navigation */
.site-header {
  background-color: var(--bg-white);
  box-shadow: var(--shadow-sm);
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
}

.site-header .container {
  display: flex;
  justify-content: space-between;
  align-items: center;
  height: 70px;
}

.logo a {
  display: flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
}

.logo a img {
  height: 40px;
  width: auto;
  display: block;
}

.logo-text {
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--primary-color);
}

.main-nav {
  display: flex;
  align-items: center;
}

.nav-menu {
  display: flex;
  list-style: none;
  margin: 0;
  padding: 0;
  gap: 30px;
}

.nav-menu a {
  color: var(--text-dark);
  font-weight: 500;
  padding: 5px 0;
  position: relative;
}

.nav-menu a::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 0;
  height: 2px;
  background-color: var(--primary-color);
  transition: var(--transition);
}

.nav-menu a:hover::after,
.nav-menu a:focus::after {
  width: 100%;
}

.nav-menu .btn-contact {
  background-color: var(--accent-color);
  color: white;
  padding: 10px 20px;
  border-radius: 4px;
}

.nav-menu .btn-contact::after {
  display: none;
}

.nav-menu .btn-contact:hover {
  background-color: var(--accent-dark);
  color: white;
}

/* Mobile Navigation Toggle */
.nav-toggle {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  padding: 10px;
}

.hamburger {
  display: block;
  width: 25px;
  height: 3px;
  background-color: var(--text-dark);
  position: relative;
  transition: var(--transition);
}

.hamburger::before,
.hamburger::after {
  content: '';
  position: absolute;
  width: 25px;
  height: 3px;
  background-color: var(--text-dark);
  transition: var(--transition);
}

.hamburger::before {
  top: -8px;
}

.hamburger::after {
  bottom: -8px;
}

/* Hero Section - Background image with blue gradient overlay */
.hero {
  position: relative;
  background-image: url('../img/hero-bg.jpeg');
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  color: white;
  padding: 150px 0 100px;
  text-align: center;
  margin-top: 70px;
  min-height: 70vh;
  display: flex;
  align-items: center;
}

/* Gradient overlay for text readability */
.hero::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(135deg, rgba(23, 33, 38, 0.92) 0%, rgba(13, 17, 20, 0.88) 100%);
  z-index: 1;
}

.hero .container {
  position: relative;
  z-index: 2;
}

.hero h1 {
  font-size: 2.3rem;
  color: white;
  margin-bottom: 1.5rem;
  letter-spacing: 2px;
  text-shadow: 0 2px 4px rgba(0,0,0,0.3);
}

.hero-subtitle {
  font-size: 1.25rem;
  color: var(--secondary-light);
  max-width: 700px;
  margin: 0 auto 2.5rem;
  text-shadow: 0 1px 2px rgba(0,0,0,0.2);
}

.hero-cta {
  display: flex;
  gap: 20px;
  justify-content: center;
  flex-wrap: wrap;
}

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

.hero .btn-primary:hover {
  background-color: transparent;
  color: white;
}

.hero .btn-secondary {
  background-color: var(--accent-color);
  border-color: var(--accent-color);
  color: white;
}

.hero .btn-secondary:hover {
  background-color: var(--accent-dark);
  border-color: var(--accent-dark);
  color: white;
}

/* Section Styles */
section {
  padding: 80px 0;
}

.section-header {
  text-align: center;
  margin-bottom: 60px;
}

.section-header h2 {
  color: var(--primary-color);
  margin-bottom: 1rem;
}

.section-intro {
  font-size: 1.25rem;
  color: var(--text-light);
  max-width: 600px;
  margin: 0 auto;
}

/* Mission Section */
.mission {
  background-color: var(--bg-light);
}

.mission-content {
  max-width: 800px;
  margin: 0 auto;
  text-align: center;
}

.mission-content p {
  font-size: 1.1rem;
  color: var(--text-light);
  margin-bottom: 1.5rem;
}

/* What We Do Section */
.what-we-do {
  background-color: var(--bg-white);
}

.services-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 40px;
}

.service-card {
  background-color: var(--bg-light);
  padding: 40px;
  border-radius: 8px;
  box-shadow: var(--shadow-sm);
  transition: var(--transition);
}

.service-card:hover {
  box-shadow: var(--shadow-lg);
  transform: translateY(-5px);
}

.service-card h3 {
  color: var(--primary-color);
  margin-bottom: 1rem;
}

.service-card p {
  color: var(--text-light);
  margin: 0;
}

/* Partners Section */
.partners {
  background-color: var(--bg-light);
}

.partners-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(400px, 1fr));
  gap: 40px;
  max-width: 900px;
  margin: 0 auto;
}

.partner-type {
  background-color: var(--bg-white);
  padding: 40px;
  border-radius: 8px;
  box-shadow: var(--shadow-sm);
}

.partner-type h3 {
  color: var(--primary-color);
  margin-bottom: 1rem;
}

.partner-type p {
  color: var(--text-light);
  margin: 0;
}

/* Contact CTA Section */
.contact-cta {
  background: linear-gradient(135deg, var(--primary-color) 0%, var(--primary-dark) 100%);
  color: white;
  text-align: center;
}

.contact-cta h2 {
  color: white;
  font-size: 2.5rem;
  margin-bottom: 1rem;
}

.contact-cta p {
  color: rgba(255,255,255,0.9);
  font-size: 1.1rem;
  max-width: 600px;
  margin: 0 auto 2rem;
}

.contact-cta .btn-primary {
  background-color: white;
  color: var(--primary-color);
  border-color: white;
}

.contact-cta .btn-primary:hover {
  background-color: transparent;
  color: white;
}

/* Footer */
.site-footer {
  background-color: var(--text-dark);
  color: white;
  padding: 60px 0 20px;
}

.footer-content {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 40px;
  margin-bottom: 40px;
}

.footer-logo {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 0.5rem;
}

.footer-logo img {
  height: 50px;
  width: auto;
}

.footer-logo-text {
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--primary-light);
}

.footer-tagline {
  color: var(--text-muted);
  font-size: 0.9rem;
  margin: 0;
}

.footer-contact h3,
.footer-nav h3 {
  color: white;
  font-size: 1.1rem;
  margin-bottom: 1rem;
}

.footer-contact p {
  color: var(--text-muted);
  margin-bottom: 0.5rem;
}

.footer-contact a {
  color: var(--primary-light);
}

.footer-contact a:hover {
  color: white;
}

.footer-nav ul {
  list-style: none;
  padding: 0;
  margin: 0;
}

.footer-nav li {
  margin-bottom: 0.5rem;
}

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

.footer-nav a:hover {
  color: white;
}

.footer-bottom {
  border-top: 1px solid rgba(255,255,255,0.1);
  padding-top: 20px;
  text-align: center;
}

.footer-bottom p {
  color: var(--text-muted);
  font-size: 0.9rem;
  margin: 0.5rem 0;
}

/* ==========================================================================
   Contact Page Styles
   ========================================================================== */

/* Page Header */
.page-header {
  background: linear-gradient(135deg, var(--primary-color) 0%, var(--primary-dark) 100%);
  color: white;
  padding: 150px 0 80px;
  text-align: center;
  margin-top: 70px;
}

.page-header h1 {
  color: white;
  font-size: 2.5rem;
  margin-bottom: 1rem;
}

.page-intro {
  color: rgba(255,255,255,0.9);
  font-size: 1.25rem;
  max-width: 600px;
  margin: 0 auto;
}

/* Contact Section */
.contact-section {
  background-color: var(--bg-white);
  padding: 80px 0;
}

.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1.5fr;
  gap: 60px;
  align-items: start;
}

/* Contact Info */
.contact-info h2 {
  color: var(--primary-color);
  margin-bottom: 1.5rem;
}

.contact-info > p {
  color: var(--text-light);
  font-size: 1.1rem;
  margin-bottom: 2rem;
}

.contact-details {
  display: flex;
  flex-direction: column;
  gap: 25px;
}

.contact-item h3 {
  color: var(--text-dark);
  font-size: 1.1rem;
  margin-bottom: 0.5rem;
}

.contact-item p {
  color: var(--text-light);
  margin: 0;
}

.contact-item a {
  color: var(--primary-color);
  font-weight: 500;
}

.contact-item a:hover {
  color: var(--primary-dark);
}

/* Contact Form */
.contact-form-wrapper {
  background-color: var(--bg-light);
  padding: 50px;
  border-radius: 8px;
  box-shadow: var(--shadow-sm);
}

.contact-form-wrapper h2 {
  color: var(--primary-color);
  margin-bottom: 1.5rem;
}

.form-success {
  background-color: var(--accent-color);
  color: white;
  padding: 15px 20px;
  border-radius: 4px;
  margin-bottom: 20px;
}

.form-success p {
  margin: 0;
}

.contact-form {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.form-group {
  display: flex;
  flex-direction: column;
}

.form-group label {
  font-weight: 500;
  color: var(--text-dark);
  margin-bottom: 8px;
  font-size: 0.95rem;
}

.form-group input,
.form-group select,
.form-group textarea {
  padding: 12px 15px;
  border: 2px solid var(--border-color);
  border-radius: 4px;
  font-size: 1rem;
  font-family: var(--font-primary);
  transition: var(--transition);
  background-color: white;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
  outline: none;
  border-color: var(--primary-color);
  box-shadow: 0 0 0 3px rgba(26, 82, 118, 0.1);
}

.form-group input.error,
.form-group select.error,
.form-group textarea.error {
  border-color: #e74c3c;
  background-color: #fdf2f2;
}

.form-group textarea {
  resize: vertical;
  min-height: 120px;
}

.form-group select {
  cursor: pointer;
}

.form-privacy {
  margin-top: 10px;
}

.checkbox-label {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  cursor: pointer;
  font-size: 0.9rem;
  color: var(--text-light);
  line-height: 1.5;
}

.checkbox-label input[type="checkbox"] {
  width: auto;
  margin: 0;
  margin-top: 3px;
  cursor: pointer;
}

.checkbox-label span {
  flex: 1;
}

/* Partnership Types Section */
.partnership-types {
  background-color: var(--bg-light);
  padding: 80px 0;
}

.partnership-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
  gap: 40px;
  max-width: 900px;
  margin: 0 auto;
}

.partnership-card {
  background-color: var(--bg-white);
  padding: 40px;
  border-radius: 8px;
  box-shadow: var(--shadow-sm);
}

.partnership-card h3 {
  color: var(--primary-color);
  margin-bottom: 1.5rem;
}

.partnership-card ul {
  list-style: none;
  padding: 0;
  margin: 0;
}

.partnership-card li {
  padding: 10px 0;
  padding-left: 25px;
  position: relative;
  color: var(--text-light);
  border-bottom: 1px solid var(--border-color);
}

.partnership-card li:last-child {
  border-bottom: none;
}

.partnership-card li::before {
  content: '✓';
  position: absolute;
  left: 0;
  color: var(--accent-color);
  font-weight: bold;
}

/* Responsive Design for Contact Page */
@media only screen and (max-width: 900px) {
  .contact-grid {
    grid-template-columns: 1fr;
    gap: 40px;
  }

  .contact-form-wrapper {
    padding: 30px;
  }

  .page-header h1 {
    font-size: 2rem;
  }
}

@media only screen and (max-width: 768px) {
  .page-header {
    padding: 120px 0 60px;
  }

  .page-intro {
    font-size: 1.1rem;
  }

  .partnership-grid {
    grid-template-columns: 1fr;
    max-width: 100%;
  }

  .partnership-card {
    padding: 30px;
  }
}

/* ==========================================================================
   Responsive Design - General
   ========================================================================== */
@media only screen and (max-width: 768px) {
  .nav-toggle {
    display: block;
  }

  .nav-menu {
    position: absolute;
    top: 70px;
    left: 0;
    right: 0;
    background-color: var(--bg-white);
    flex-direction: column;
    padding: 20px;
    box-shadow: var(--shadow-md);
    transform: translateY(-100%);
    opacity: 0;
    visibility: hidden;
    transition: var(--transition);
    gap: 15px;
  }

  .nav-menu.active {
    transform: translateY(0);
    opacity: 1;
    visibility: visible;
  }

  .nav-menu .btn-contact {
    display: inline-block;
    margin-top: 10px;
  }

  .hero {
    padding: 120px 0 80px;
    min-height: 60vh;
    background-position: center;
  }

  .hero h1 {
    font-size: 2rem;
    padding: 0 15px;
  }

  .hero-subtitle {
    font-size: 1.1rem;
    padding: 0 20px;
  }

  h1 {
    font-size: 2rem;
  }

  h2 {
    font-size: 1.5rem;
  }

  section {
    padding: 60px 0;
  }

  .services-grid,
  .partners-grid {
    grid-template-columns: 1fr;
  }

  .partners-grid {
    max-width: 100%;
  }

  .service-card,
  .partner-type {
    padding: 30px;
  }

  .footer-content {
    grid-template-columns: 1fr;
    gap: 30px;
  }
}

/* Smooth scroll for anchor links */
html {
  scroll-behavior: smooth;
}

/* Focus styles for accessibility */
a:focus,
button:focus {
  outline: 2px solid var(--primary-color);
  outline-offset: 2px;
}

/* Skip link for accessibility */
.skip-link {
  position: absolute;
  top: -40px;
  left: 0;
  background: var(--primary-color);
  color: white;
  padding: 8px;
  text-decoration: none;
  z-index: 100;
}

.skip-link:focus {
  top: 0;
}

/* ==========================================================================
   Helper classes
   ========================================================================== */

/*
 * Hide visually and from screen readers
 */

.hidden,
[hidden] {
  display: none !important;
}

/*
 * Hide only visually, but have it available for screen readers:
 * https://snook.ca/archives/html_and_css/hiding-content-for-accessibility
 *
 * 1. For long content, line feeds are not interpreted as spaces and small width
 *    causes content to wrap 1 word per line:
 *    https://medium.com/@jessebeach/beware-smushed-off-screen-accessible-text-5952a4c2cbfe
 */

.visually-hidden {
  border: 0;
  clip: rect(0, 0, 0, 0);
  height: 1px;
  margin: -1px;
  overflow: hidden;
  padding: 0;
  position: absolute;
  white-space: nowrap;
  width: 1px;
  /* 1 */
}

/*
 * Extends the .visually-hidden class to allow the element
 * to be focusable when navigated to via the keyboard:
 * https://www.drupal.org/node/897638
 */

.visually-hidden.focusable:active,
.visually-hidden.focusable:focus {
  clip: auto;
  height: auto;
  margin: 0;
  overflow: visible;
  position: static;
  white-space: inherit;
  width: auto;
}

/*
 * Hide visually and from screen readers, but maintain layout
 */

.invisible {
  visibility: hidden;
}

/*
 * Clearfix: contain floats
 *
 * The use of `table` rather than `block` is only necessary if using
 * `::before` to contain the top-margins of child elements.
 */

.clearfix::before,
.clearfix::after {
  content: "";
  display: table;
}

.clearfix::after {
  clear: both;
}

/* ==========================================================================
   EXAMPLE Media Queries for Responsive Design.
   These examples override the primary ('mobile first') styles.
   Modify as content requires.
   ========================================================================== */

@media only screen and (min-width: 35em) {
  /* Style adjustments for viewports that meet the condition */
}

@media print,
  (-webkit-min-device-pixel-ratio: 1.25),
  (min-resolution: 1.25dppx),
  (min-resolution: 120dpi) {
  /* Style adjustments for high resolution devices */
}

/* ==========================================================================
   Print styles.
   Inlined to avoid the additional HTTP request:
   https://www.phpied.com/delay-loading-your-print-css/
   ========================================================================== */

@media print {
  *,
  *::before,
  *::after {
    background: #fff !important;
    color: #000 !important;
    /* Black prints faster */
    box-shadow: none !important;
    text-shadow: none !important;
  }

  a,
  a:visited {
    text-decoration: underline;
  }

  a[href]::after {
    content: " (" attr(href) ")";
  }

  abbr[title]::after {
    content: " (" attr(title) ")";
  }

  /*
   * Don't show links that are fragment identifiers,
   * or use the `javascript:` pseudo protocol
   */
  a[href^="#"]::after,
  a[href^="javascript:"]::after {
    content: "";
  }

  pre {
    white-space: pre-wrap !important;
  }

  pre,
  blockquote {
    border: 1px solid #999;
    page-break-inside: avoid;
  }

  tr,
  img {
    page-break-inside: avoid;
  }

  p,
  h2,
  h3 {
    orphans: 3;
    widows: 3;
  }

  h2,
  h3 {
    page-break-after: avoid;
  }
}

