/*
Theme Name: My Theme (Pro)
Author: You
Version: 2.0
Description: Refined professional version for Scooter Insights — elegant, modern, and fast.
*/

/* ============================= */
/* 🎨 COLOR SYSTEM & VARIABLES   */
/* ============================= */
:root {
  --primary: #0a3d62;       /* deep blue */
  --primary-dark: #062743;
  --accent: #ff8a00;        /* warm orange */
  --accent-light: #ffb84d;
  --bg: #f6f8fa;
  --bg-dark: #0b1220;
  --card: #ffffff;
  --card-dark: #111827;
  --text: #222;
  --text-light: #e6eef9;
  --muted: #6b7280;
  --muted-dark: #9ca3af;
  --radius: 12px;
  --container-width: 1100px;
  --shadow: 0 6px 18px rgba(13,25,35,0.06);
  --shadow-hover: 0 10px 28px rgba(13,25,35,0.12);
  --transition: all 0.4s ease;
  font-family: 'Poppins', Arial, sans-serif;
}

/* ============================= */
/* 🧼 RESET + GLOBAL             */
/* ============================= */
* { box-sizing: border-box; margin: 0; padding: 0; }
html, body { height: 100%; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: inherit;
  line-height: 1.6;
  transition: var(--transition);
}

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

/* ============================= */
/* 🏠 HEADER                     */
/* ============================= */
.site-header {
  background: linear-gradient(90deg, var(--primary), var(--primary-dark));
  color: #fff;
  padding: 16px 0;
  position: sticky;
  top: 0;
  z-index: 999;
  box-shadow: 0 2px 8px rgba(0,0,0,0.12);
  backdrop-filter: blur(10px);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
}

.site-branding h1 {
  margin: 0;
  font-weight: 700;
  font-size: 1.3rem;
  letter-spacing: 0.5px;
}
.site-branding img.custom-logo {
  max-height: 58px;
  width: auto;
}

/* Header controls */
.header-controls { display: flex; gap: 10px; align-items: center; }
.menu-toggle {
  display: none;
  background: transparent;
  border: 1px solid rgba(255,255,255,0.2);
  color: #fff;
  padding: 8px 10px;
  border-radius: 6px;
  cursor: pointer;
}
#dark-toggle {
  background: transparent;
  border: none;
  color: #fff;
  font-size: 1.4rem;
  cursor: pointer;
  transition: transform 0.3s ease, color 0.3s ease;
}
#dark-toggle:hover { transform: rotate(25deg); color: var(--accent); }

/* ============================= */
/* 🧭 NAVIGATION                 */
/* ============================= */
#primary-menu {
  list-style: none;
  display: flex;
  gap: 18px;
}
#primary-menu a {
  color: #fff;
  text-decoration: none;
  padding: 8px 14px;
  border-radius: 6px;
  font-weight: 600;
  transition: var(--transition);
}
#primary-menu a:hover {
  background: rgba(255,255,255,0.1);
  color: var(--accent-light);
}

/* ============================= */
/* 🦸 HERO SECTION               */
/* ============================= */
.hero {
  padding: 80px 20px;
  text-align: center;
  color: #fff;
  background: linear-gradient(180deg, rgba(10,61,98,0.95), rgba(10,61,98,0.85));
  border-bottom: 4px solid var(--accent);
}
.hero h1 {
  font-size: 2.8rem;
  font-weight: 800;
  margin-bottom: 12px;
}
.hero p {
  font-size: 1.1rem;
  margin-bottom: 24px;
  color: rgba(255,255,255,0.92);
}
.hero .btn {
  display: inline-block;
  padding: 12px 22px;
  background: var(--accent);
  color: #fff;
  border-radius: 40px;
  text-decoration: none;
  font-weight: 700;
  box-shadow: 0 6px 20px rgba(255,138,0,0.3);
  transition: var(--transition);
}
.hero .btn:hover {
  background: var(--accent-light);
  transform: translateY(-3px);
  box-shadow: 0 8px 24px rgba(255,138,0,0.45);
}

/* ============================= */
/* 📦 SECTIONS & CARDS           */
/* ============================= */
.section {
  max-width: var(--container-width);
  margin: 60px auto;
  padding: 0 20px;
}
.section h2 {
  font-size: 1.8rem;
  margin-bottom: 18px;
  color: var(--primary);
  text-align: center;
  position: relative;
}
.section h2::after {
  content: "";
  width: 60px;
  height: 3px;
  background: var(--accent);
  display: block;
  margin: 8px auto 0;
  border-radius: 2px;
}

.cards {
  display: grid;
  gap: 22px;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  margin-top: 20px;
}
.card {
  background: var(--card);
  border-radius: var(--radius);
  padding: 20px;
  box-shadow: var(--shadow);
  transition: var(--transition);
  overflow: hidden;
}
.card:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow-hover);
}
.card h3 {
  margin-bottom: 8px;
  color: var(--primary);
  font-size: 1.15rem;
}
.card p {
  color: var(--muted);
  font-size: 0.95rem;
  margin-bottom: 8px;
}
.card a {
  color: var(--accent);
  font-weight: 600;
  text-decoration: none;
}
.card a:hover { text-decoration: underline; }

/* Featured Posts */
.featured-posts .post-card img {
  width: 100%;
  height: 180px;
  object-fit: cover;
  border-radius: 10px;
  margin-bottom: 10px;
}
.featured-posts .post-card h3 { font-size: 1.1rem; margin-bottom: 8px; }
.featured-posts .post-card p { color: var(--muted); }

/* ============================= */
/* 🦶 FOOTER                     */
/* ============================= */
.site-footer {
  background: var(--primary-dark);
  color: #dbe9f5;
  padding: 40px 0;
  margin-top: 60px;
}
.footer-inner {
  display: flex;
  flex-wrap: wrap;
  gap: 24px;
  justify-content: space-between;
  align-items: flex-start;
}
.footer-widget {
  max-width: 320px;
}
.footer-newsletter input[type="email"] {
  padding: 10px 12px;
  border-radius: 8px;
  border: none;
  width: 240px;
  margin-right: 8px;
}
.footer-newsletter button {
  padding: 10px 14px;
  border-radius: 8px;
  background: var(--accent);
  color: #fff;
  border: none;
  cursor: pointer;
  transition: var(--transition);
}
.footer-newsletter button:hover {
  background: var(--accent-light);
  transform: translateY(-2px);
}
.footer-bottom {
  text-align: center;
  margin-top: 20px;
  color: rgba(219,233,245,0.8);
  font-size: 0.9rem;
}

/* ============================= */
/* 🌙 DARK MODE                 */
/* ============================= */
body.dark-mode {
  background: var(--bg-dark);
  color: var(--text-light);
}
body.dark-mode .site-header {
  background: linear-gradient(90deg, #071223, #0f1b3b);
}
body.dark-mode .card,
body.dark-mode .page {
  background: var(--card-dark);
  color: var(--text-light);
  border: 1px solid rgba(255,255,255,0.05);
  box-shadow: none;
}
body.dark-mode #primary-menu a { color: #cfd8e3; }
body.dark-mode .hero {
  background: linear-gradient(180deg, #061325, #0b1e3a);
}
body.dark-mode .hero .btn {
  background: var(--accent);
  box-shadow: 0 0 20px rgba(255,138,0,0.4);
}

/* ============================= */
/* 📱 RESPONSIVE DESIGN          */
/* ============================= */
@media (max-width: 900px) {
  .menu-toggle { display: inline-block; }
  #primary-menu {
    display: none;
    flex-direction: column;
    background: rgba(255,255,255,0.95);
    position: absolute;
    right: 20px;
    top: 70px;
    padding: 12px;
    border-radius: 10px;
    box-shadow: 0 8px 24px rgba(0,0,0,0.15);
  }
  #primary-menu.open { display: flex; }
  .hero { padding: 60px 16px; }
  .hero h1 { font-size: 2rem; }
  .section { margin: 40px auto; }
  body.dark-mode #primary-menu {
    background: rgba(15,23,36,0.98);
  }
}
/* ===== BLOG INDEX STYLING ===== */
.blog-index {
  padding: 60px 20px;
  max-width: 1200px;
  margin: 0 auto;
}

.blog-header {
  text-align: center;
  margin-bottom: 50px;
}

.blog-header .page-title {
  font-size: 2.4rem;
  color: #0f2027;
  font-family: 'Poppins', sans-serif;
  font-weight: 700;
  margin-bottom: 10px;
}

.blog-header .page-subtitle {
  color: #555;
  font-size: 1.1rem;
}

/* ===== POSTS GRID ===== */
.posts-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 35px;
}

.post-card {
  background: #fff;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 6px 15px rgba(0,0,0,0.1);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.post-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 10px 20px rgba(0,0,0,0.15);
}

/* ===== IMAGE ===== */
.post-thumb img {
  width: 100%;
  height: 220px;
  object-fit: cover;
  transition: transform 0.3s ease;
}

.post-card:hover .post-thumb img {
  transform: scale(1.05);
}

/* ===== CONTENT ===== */
.post-content {
  padding: 20px 25px 30px;
}

.post-meta {
  font-size: 0.9rem;
  color: #888;
  margin-bottom: 10px;
}

.post-title a {
  color: #0f2027;
  font-weight: 700;
  font-size: 1.3rem;
  text-decoration: none;
  transition: color 0.3s ease;
}

.post-title a:hover {
  color: #00bcd4;
}

.post-excerpt {
  color: #444;
  margin: 15px 0 25px;
  line-height: 1.6;
}

/* ===== READ MORE BUTTON ===== */
.read-more {
  display: inline-block;
  color: #fff;
  background: linear-gradient(90deg, #00bcd4, #2196f3);
  padding: 10px 18px;
  border-radius: 25px;
  font-weight: 600;
  font-size: 0.95rem;
  text-decoration: none;
  transition: background 0.3s ease, transform 0.3s ease;
}

.read-more:hover {
  background: linear-gradient(90deg, #2196f3, #00bcd4);
  transform: scale(1.05);
}

/* ===== PAGINATION ===== */
.pagination {
  margin-top: 40px;
  text-align: center;
}

.pagination a,
.pagination span {
  display: inline-block;
  padding: 10px 15px;
  margin: 3px;
  border-radius: 6px;
  color: #333;
  font-weight: 500;
  text-decoration: none;
  transition: all 0.3s ease;
}

.pagination a:hover,
.pagination .current {
  background: #00bcd4;
  color: #fff;
}

/* ===== NO POSTS ===== */
.no-posts {
  text-align: center;
  font-size: 1.2rem;
  color: #666;
  padding: 60px 0;
}
/* Smooth mode switch */
body.mode-transition {
  transition: background-color 0.5s ease, color 0.5s ease;
}

/* Header shrink */
.site-header.shrink {
  background: rgba(255,255,255,0.95);
  box-shadow: 0 2px 10px rgba(0,0,0,0.08);
  padding: 10px 0;
  transition: all 0.3s ease;
}

/* Scroll to Top */
.scroll-top {
  position: fixed;
  right: 25px;
  bottom: 25px;
  background: var(--accent-color, #0073e6);
  color: #fff;
  border: none;
  border-radius: 50%;
  padding: 12px 14px;
  font-size: 18px;
  cursor: pointer;
  display: none;
  z-index: 99;
  box-shadow: 0 3px 8px rgba(0,0,0,0.3);
  transition: all 0.3s ease;
}
.scroll-top.show { display: block; }
.scroll-top:hover { transform: translateY(-3px) scale(1.05); }

/* Fade-in Animation */
.fade-in-up {
  opacity: 0;
  transform: translateY(25px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}
.fade-in-up.visible {
  opacity: 1;
  transform: translateY(0);
}

/* Newsletter feedback */
#newsletter-msg .success { color: #28a745; font-weight: 500; }
#newsletter-msg .error { color: #dc3545; font-weight: 500; }
.loading {
  display: inline-block;
  width: 14px;
  height: 14px;
  border: 2px solid #fff;
  border-top: 2px solid transparent;
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}
@keyframes spin { 100% { transform: rotate(360deg); } }
