/* ============================================
   How To Make Boys - Main Stylesheet
   Clean, trustworthy design for parenting content
   ============================================ */

/* Import fonts */
@import url('https://fonts.googleapis.com/css2?family=Poppins:wght@300;400;600;700&family=Open+Sans:wght@300;400;600&display=swap');

/* CSS Variables for easy customization */
:root {
  /* Colors - Soft, trustworthy palette */
  --primary: #4A90E2;
  --primary-dark: #357ABD;
  --secondary: #E8F4F8;
  --accent: #FF6B9D;
  --text-dark: #2C3E50;
  --text-medium: #546E7A;
  --text-light: #7F8C8D;
  --bg-light: #FAFBFC;
  --bg-white: #FFFFFF;
  --border: #E0E6ED;
  
  /* Typography */
  --font-heading: 'Poppins', sans-serif;
  --font-body: 'Open Sans', sans-serif;
  
  /* Spacing */
  --spacing-xs: 0.5rem;
  --spacing-sm: 1rem;
  --spacing-md: 2rem;
  --spacing-lg: 3rem;
  --spacing-xl: 4rem;
  
  /* Layout */
  --max-width: 1200px;
  --content-width: 800px;
  --border-radius: 12px;
  
  /* Shadows */
  --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.05);
  --shadow-md: 0 4px 16px rgba(0, 0, 0, 0.08);
  --shadow-lg: 0 8px 32px rgba(0, 0, 0, 0.12);
}

/* ============================================
   Reset & Base Styles
   ============================================ */

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

html {
  scroll-behavior: smooth;
  font-size: 16px;
}

body {
  font-family: var(--font-body);
  color: var(--text-dark);
  background: var(--bg-light);
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

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

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

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

/* ============================================
   Typography
   ============================================ */

h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-heading);
  font-weight: 600;
  line-height: 1.3;
  color: var(--text-dark);
  margin-bottom: var(--spacing-sm);
}

h1 {
  font-size: 2.5rem;
  font-weight: 700;
}

h2 {
  font-size: 2rem;
}

h3 {
  font-size: 1.5rem;
}

h4 {
  font-size: 1.25rem;
}

p {
  margin-bottom: var(--spacing-sm);
  color: var(--text-medium);
}

/* ============================================
   Header & Navigation
   ============================================ */

.header {
  background: var(--bg-white);
  box-shadow: var(--shadow-sm);
  position: sticky;
  top: 0;
  z-index: 1000;
  transition: box-shadow 0.3s ease;
}

.header.scrolled {
  box-shadow: var(--shadow-md);
}

.header-container {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: var(--spacing-sm) var(--spacing-md);
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.logo {
  height: 50px;
  transition: transform 0.3s ease;
}

.logo:hover {
  transform: scale(1.05);
}

.nav {
  display: flex;
  gap: var(--spacing-md);
  align-items: center;
}

.nav a {
  font-family: var(--font-heading);
  font-weight: 500;
  font-size: 0.95rem;
  color: var(--text-dark);
  padding: var(--spacing-xs) var(--spacing-sm);
  border-radius: 6px;
  transition: all 0.3s ease;
}

.nav a:hover {
  background: var(--secondary);
  color: var(--primary);
}

/* Mobile menu toggle */
.menu-toggle {
  display: none;
  background: none;
  border: none;
  font-size: 1.5rem;
  color: var(--text-dark);
  cursor: pointer;
}

/* ============================================
   Hero Section
   ============================================ */

.hero {
  background: linear-gradient(135deg, var(--secondary) 0%, var(--bg-white) 100%);
  padding: var(--spacing-xl) var(--spacing-md);
  position: relative;
  overflow: hidden;
}

.hero::before {
  content: '';
  position: absolute;
  top: -50%;
  right: -10%;
  width: 600px;
  height: 600px;
  background: radial-gradient(circle, rgba(74, 144, 226, 0.1) 0%, transparent 70%);
  border-radius: 50%;
  animation: float 20s ease-in-out infinite;
}

@keyframes float {
  0%, 100% { transform: translateY(0) rotate(0deg); }
  50% { transform: translateY(-30px) rotate(5deg); }
}

.hero-container {
  max-width: var(--max-width);
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--spacing-lg);
  align-items: center;
  position: relative;
  z-index: 1;
}

.hero-content h1 {
  font-size: 3rem;
  margin-bottom: var(--spacing-sm);
  background: linear-gradient(135deg, var(--text-dark) 0%, var(--primary) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.hero-content .subtitle {
  font-size: 1.25rem;
  color: var(--text-medium);
  margin-bottom: var(--spacing-md);
  font-weight: 300;
}

.hero-image {
  border-radius: var(--border-radius);
  box-shadow: var(--shadow-lg);
  overflow: hidden;
  animation: fadeInUp 0.8s ease-out 0.3s backwards;
}

@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(30px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.hero-image img {
  width: 100%;
  height: auto;
}

.cta-button {
  display: inline-block;
  background: var(--primary);
  color: white;
  padding: var(--spacing-sm) var(--spacing-md);
  border-radius: 8px;
  font-family: var(--font-heading);
  font-weight: 600;
  font-size: 1.1rem;
  box-shadow: var(--shadow-md);
  transition: all 0.3s ease;
}

.cta-button:hover {
  background: var(--primary-dark);
  transform: translateY(-2px);
  box-shadow: var(--shadow-lg);
  color: white;
}

/* ============================================
   Trust Badges
   ============================================ */

.trust-section {
  background: var(--bg-white);
  padding: var(--spacing-md);
  text-align: center;
}

.trust-container {
  max-width: var(--max-width);
  margin: 0 auto;
  display: flex;
  justify-content: center;
  gap: var(--spacing-lg);
  flex-wrap: wrap;
}

.trust-badge {
  display: flex;
  align-items: center;
  gap: var(--spacing-xs);
  color: var(--text-medium);
  font-size: 0.95rem;
}

.trust-badge svg {
  color: var(--primary);
  font-size: 1.5rem;
}

/* ============================================
   Content Section
   ============================================ */

.content-section {
  padding: var(--spacing-xl) var(--spacing-md);
  max-width: var(--max-width);
  margin: 0 auto;
}

.section-header {
  text-align: center;
  margin-bottom: var(--spacing-lg);
}

.section-header h2 {
  font-size: 2.5rem;
  margin-bottom: var(--spacing-sm);
}

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

/* ============================================
   Article Grid
   ============================================ */

.article-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: var(--spacing-md);
  margin-bottom: var(--spacing-lg);
}

.article-card {
  background: var(--bg-white);
  border-radius: var(--border-radius);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  transition: all 0.3s ease;
}

.article-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-md);
}

.article-card-image {
  width: 100%;
  height: 200px;
  object-fit: cover;
  background: var(--secondary);
}

.article-card-content {
  padding: var(--spacing-md);
}

.article-card h3 {
  margin-bottom: var(--spacing-xs);
  font-size: 1.3rem;
}

.article-card p {
  color: var(--text-light);
  font-size: 0.95rem;
  margin-bottom: var(--spacing-sm);
}

.article-meta {
  display: flex;
  gap: var(--spacing-sm);
  font-size: 0.85rem;
  color: var(--text-light);
  margin-bottom: var(--spacing-sm);
}

.read-more {
  color: var(--primary);
  font-weight: 600;
  font-size: 0.95rem;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  transition: gap 0.3s ease;
}

.read-more:hover {
  gap: 0.75rem;
}

/* ============================================
   Ad Placement Zones
   ============================================ */

.ad-zone {
  background: var(--bg-light);
  border: 2px dashed var(--border);
  border-radius: var(--border-radius);
  padding: var(--spacing-md);
  margin: var(--spacing-lg) 0;
  text-align: center;
  min-height: 250px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.ad-zone::before {
  content: 'Advertisement';
  color: var(--text-light);
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 1px;
}

/* ============================================
   Footer
   ============================================ */

.footer {
  background: var(--text-dark);
  color: var(--bg-light);
  padding: var(--spacing-xl) var(--spacing-md) var(--spacing-md);
}

.footer-container {
  max-width: var(--max-width);
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: var(--spacing-lg);
  margin-bottom: var(--spacing-md);
}

.footer-section h4 {
  color: white;
  margin-bottom: var(--spacing-sm);
}

.footer-section p,
.footer-section a {
  color: var(--bg-light);
  font-size: 0.95rem;
  margin-bottom: var(--spacing-xs);
}

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

.footer-links {
  list-style: none;
}

.footer-links li {
  margin-bottom: var(--spacing-xs);
}

.footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  padding-top: var(--spacing-md);
  text-align: center;
  color: var(--text-light);
  font-size: 0.9rem;
}

/* ============================================
   Responsive Design
   ============================================ */

@media (max-width: 768px) {
  html {
    font-size: 14px;
  }
  
  .hero-container {
    grid-template-columns: 1fr;
    text-align: center;
  }
  
  .hero-content h1 {
    font-size: 2rem;
  }
  
  .nav {
    display: none;
    flex-direction: column;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: var(--bg-white);
    box-shadow: var(--shadow-md);
    padding: var(--spacing-md);
  }
  
  .nav.active {
    display: flex;
  }
  
  .menu-toggle {
    display: block;
  }
  
  .article-grid {
    grid-template-columns: 1fr;
  }
  
  .footer-container {
    grid-template-columns: 1fr;
  }
}

/* ============================================
   Utility Classes
   ============================================ */

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

.text-center {
  text-align: center;
}

.mt-lg {
  margin-top: var(--spacing-lg);
}

.mb-lg {
  margin-bottom: var(--spacing-lg);
}

/* Lazy loading - images fade in when loaded */
img[loading="lazy"] {
  opacity: 0;
  transition: opacity 0.5s ease;
}

img[loading="lazy"].loaded {
  opacity: 1;
}

/* ============================================
   Hero Carousel
   ============================================ */

.hero-carousel {
  position: relative;
  width: 100%;
  max-width: 600px;
}

.carousel-container {
  position: relative;
  width: 100%;
  overflow: hidden;
  border-radius: var(--border-radius);
  box-shadow: var(--shadow-lg);
}

.carousel-slides {
  position: relative;
  width: 100%;
  height: 400px;
}

.carousel-slide {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  opacity: 0;
  transition: opacity 0.8s ease-in-out;
  pointer-events: none;
}

.carousel-slide.active {
  opacity: 1;
  pointer-events: auto;
}

.carousel-slide img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

/* Navigation Buttons */
.carousel-btn {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background: rgba(255, 255, 255, 0.9);
  border: none;
  width: 45px;
  height: 45px;
  border-radius: 50%;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 28px;
  color: var(--primary);
  transition: all 0.3s ease;
  z-index: 10;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
}

.carousel-btn:hover {
  background: white;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
  transform: translateY(-50%) scale(1.1);
}

.carousel-prev {
  left: 15px;
}

.carousel-next {
  right: 15px;
}

.carousel-btn span {
  line-height: 1;
  margin-top: -4px;
}

/* Dot Indicators */
.carousel-dots {
  position: absolute;
  bottom: 20px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  gap: 10px;
  z-index: 10;
}

.carousel-dot {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  border: 2px solid white;
  background: rgba(255, 255, 255, 0.5);
  cursor: pointer;
  transition: all 0.3s ease;
  padding: 0;
}

.carousel-dot:hover {
  background: rgba(255, 255, 255, 0.8);
  transform: scale(1.2);
}

.carousel-dot.active {
  background: white;
  width: 32px;
  border-radius: 6px;
}

/* Responsive adjustments */
@media (max-width: 768px) {
  .carousel-slides {
    height: 300px;
  }

  .carousel-btn {
    width: 38px;
    height: 38px;
    font-size: 24px;
  }

  .carousel-prev {
    left: 10px;
  }

  .carousel-next {
    right: 10px;
  }

  .carousel-dots {
    bottom: 15px;
  }

  .carousel-dot {
    width: 10px;
    height: 10px;
  }

  .carousel-dot.active {
    width: 26px;
  }
}

/* ===== SOCIAL MEDIA SHARE BUTTONS ===== */
.social-share {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 1.5rem 0;
  margin: 2rem 0;
  border-top: 2px solid #ECF0F1;
  border-bottom: 2px solid #ECF0F1;
}

.social-share-label {
  font-weight: 600;
  color: #546E7A;
  font-size: 0.95rem;
  margin-right: 8px;
}

.social-share-buttons {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

.social-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 10px 16px;
  border-radius: 8px;
  text-decoration: none;
  font-size: 0.9rem;
  font-weight: 600;
  color: white;
  transition: all 0.3s ease;
  box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}

.social-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0,0,0,0.2);
}

.social-btn svg {
  width: 18px;
  height: 18px;
  fill: currentColor;
}

.social-btn-pinterest {
  background: #E60023;
}

.social-btn-pinterest:hover {
  background: #BD081C;
}

.social-btn-facebook {
  background: #1877F2;
}

.social-btn-facebook:hover {
  background: #0C63D4;
}

.social-btn-twitter {
  background: #1DA1F2;
}

.social-btn-twitter:hover {
  background: #0C85D0;
}

.social-btn-email {
  background: #546E7A;
}

.social-btn-email:hover {
  background: #37474F;
}

.social-btn-copy {
  background: #4CAF50;
}

.social-btn-copy:hover {
  background: #388E3C;
}

.social-btn-copy.copied {
  background: #2E7D32;
}

/* Social media links in footer */
.social-links {
  display: flex;
  gap: 15px;
  margin-top: 1rem;
}

.social-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.1);
  color: #BDC3C7;
  transition: all 0.3s ease;
  text-decoration: none;
  font-size: 1.2rem;
}

.social-icon:hover {
  background: #4A90E2;
  color: white;
  transform: translateY(-3px);
}

.social-icon svg {
  width: 20px;
  height: 20px;
  fill: currentColor;
}

/* Responsive social buttons */
@media (max-width: 768px) {
  .social-share {
    flex-direction: column;
    align-items: flex-start;
    gap: 12px;
  }

  .social-share-label {
    margin-right: 0;
  }

  .social-btn {
    font-size: 0.85rem;
    padding: 8px 12px;
  }
}
