/* Digital Rurals – Theme Colors */
:root {
  --primary: #3f6766;       /* Deep teal – main buttons, headers */
  --secondary: #597574;     /* Muted teal – accents, hover states */
  --light: #ffffff;         /* White – cards, backgrounds */
  --gray-teal: #789293;     /* Soft gray-teal – body text, subtitles */
  --bg: #f8fafc;            /* Very light background */
  --shadow: rgba(63,103,102,0.12);
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: 'Inter', system-ui, -apple-system, sans-serif;
  background: var(--bg);
  color: var(--gray-teal);
  line-height: 1.7;
}

a { color: inherit; text-decoration: none; }

img { max-width: 100%; height: auto; display: block; }

/* Header & Navigation */
header {
  background: var(--primary);
  color: white;
  padding: 1rem 0;
  position: sticky;
  top: 0;
  z-index: 1000;
  box-shadow: 0 4px 15px var(--shadow);
}

nav {
  max-width: 1400px;
  margin: 0 auto;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0 1.5rem;
}

.logo {
  font-size: 1.7rem;
  font-weight: 800;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.logo span { color: var(--secondary); }

.nav-links {
  display: flex;
  gap: 2rem;
  font-weight: 500;
}

.nav-links a {
  color: white;
  transition: all 0.3s;
  position: relative;
  padding: 0.4rem 0;
}

.nav-links a:hover,
.nav-links a.active {
  color: var(--secondary);
}

.nav-links a::after {
  content: '';
  position: absolute;
  width: 0;
  height: 2px;
  bottom: -4px;
  left: 0;
  background: var(--secondary);
  transition: width 0.3s;
}

.nav-links a:hover::after,
.nav-links a.active::after {
  width: 100%;
}

/* Mobile Menu */
.menu-toggle {
  display: none;
  font-size: 1.8rem;
  cursor: pointer;
  color: white;
}

@media (max-width: 900px) {
  .menu-toggle { display: block; }
  .nav-links {
    display: none;
    flex-direction: column;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: var(--primary);
    padding: 1.5rem;
    gap: 1.2rem;
  }
  .nav-links.active { display: flex; }
}

/* Hero with Background Image */
.hero {
  background: linear-gradient(rgba(63,103,102,0.65), rgba(63,103,102,0.75)),
              url('../img/bg1.jpg') center/cover no-repeat;
  height: 85vh;
  min-height: 600px;
  color: white;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 0 1.5rem;
}

.hero-content {
  max-width: 900px;
}

.hero h1 {
  font-size: clamp(2.6rem, 7vw, 4.8rem);
  margin-bottom: 1.2rem;
  line-height: 1.1;
}

.hero h1 span { color: var(--light); }

.hero p {
  font-size: 1.25rem;
  max-width: 720px;
  margin: 0 auto 2.2rem;
  opacity: 0.95;
}

.cta-btn {
  display: inline-block;
  background: var(--secondary);
  color: white;
  padding: 1rem 2.5rem;
  border-radius: 50px;
  font-weight: 600;
  font-size: 1.1rem;
  transition: all 0.3s;
}

.cta-btn:hover {
  background: var(--primary);
  transform: translateY(-3px);
  box-shadow: 0 10px 25px rgba(63,103,102,0.3);
}

/* Sections */
section {
  padding: 6rem 1.5rem;
}

.container {
  max-width: 1400px;
  margin: 0 auto;
}

h2 {
  font-size: 2.6rem;
  color: var(--primary);
  text-align: center;
  margin-bottom: 1.5rem;
  position: relative;
}

h2::after {
  content: '';
  width: 80px;
  height: 4px;
  background: var(--secondary);
  position: absolute;
  bottom: -12px;
  left: 50%;
  transform: translateX(-50%);
}

/* About Grid */
.about-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4rem;
  align-items: center;
  margin-top: 3rem;
}

.about-text h3 {
  color: var(--secondary);
  margin-bottom: 1.2rem;
}

@media (max-width: 900px) {
  .about-grid { grid-template-columns: 1fr; gap: 3rem; }
}

/* Programs Grid */
.programs-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 2rem;
  margin-top: 3rem;
}

.program-card {
  background: white;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 6px 20px var(--shadow);
  transition: transform 0.3s, box-shadow 0.3s;
}

.program-card:hover {
  transform: translateY(-10px);
  box-shadow: 0 15px 35px rgba(0,0,0,0.12);
}

.program-img {
  height: 220px;
  background-size: cover;
  background-position: center;
}

.program-content {
  padding: 1.8rem;
  text-align: center;
}

.program-content h3 {
  color: var(--primary);
  margin-bottom: 1rem;
}

/* Contact Form */
.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 3rem;
  margin-top: 3rem;
}

.contact-form input,
.contact-form textarea {
  width: 100%;
  padding: 1rem;
  margin-bottom: 1.2rem;
  border: 1px solid #d1d5db;
  border-radius: 8px;
  font-size: 1rem;
}

.contact-form textarea { min-height: 160px; }

.contact-form button {
  background: var(--primary);
  color: white;
  border: none;
  padding: 1rem 2.5rem;
  border-radius: 8px;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.3s;
}

.contact-form button:hover {
  background: var(--secondary);
}

/* Footer */
footer {
  background: var(--primary);
  color: white;
  text-align: center;
  padding: 3rem 1rem 2rem;
  margin-top: 4rem;
}

.social-icons {
  margin: 1.5rem 0;
  font-size: 1.6rem;
}

.social-icons a {
  color: white;
  margin: 0 1rem;
  transition: color 0.3s;
}

.social-icons a:hover { color: var(--secondary); }

/* Responsive Adjustments */
@media (max-width: 900px) {
  .contact-grid { grid-template-columns: 1fr; }
  .hero { height: 70vh; min-height: 500px; }
}