/*
Theme Name: Custom Auto Theme
Author: System
Version: 1.0
*/

html {scroll-behavior: smooth;}
html, body {overflow-x:hidden;}
a {display: inline-block; text-align: center;}

:root {
  --bg: #FAFBFC;
  --bg-alt: #F0F4F7;
  --text: #1A2332;
  --text-muted: #5A6B7D;
  --accent: #2A9D8F;
  --accent-light: #E6F5F3;
  --accent-dark: #1E7A6E;
  --border: #E2E8F0;
  --white: #FFFFFF;
  --shadow-sm: 0 1px 3px rgba(0,0,0,0.06);
  --shadow-md: 0 4px 16px rgba(0,0,0,0.08);
  --shadow-lg: 0 8px 32px rgba(0,0,0,0.10);
  --radius: 12px;
  --max-w: 780px;
  --font-body: 'Source Sans 3', sans-serif;
  --font-heading: 'Playfair Display', serif;
  --transition: 0.3s cubic-bezier(0.4,0,0.2,1);
}

@import url('https://fonts.googleapis.com/css2?family=Playfair+Display:wght@400;600;700;800&family=Source+Sans+3:wght@300;400;500;600;700&display=swap');

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

body {
  font-family: var(--font-body);
  background: var(--bg);
  color: var(--text);
  font-size: 17px;
  line-height: 1.75;
  -webkit-font-smoothing: antialiased;
}

/* ── HEADER / NAV ── */
.site-header {
  background: var(--white);
  border-bottom: 1px solid var(--border);
  position: sticky;
  top: 0;
  z-index: 100;
  backdrop-filter: blur(12px);
  background: rgba(255,255,255,0.92);
}
.site-header .inner {
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 64px;
}
.site-logo {
  font-family: var(--font-heading);
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--accent-dark);
  text-decoration: none;
  letter-spacing: -0.02em;
}
.site-logo:hover { color: var(--accent); }
.site-nav { display: flex; gap: 8px; align-items: center; }
.site-nav a {
  font-size: 0.9rem;
  color: var(--text-muted);
  text-decoration: none;
  padding: 6px 14px;
  border-radius: 8px;
  font-weight: 500;
  transition: var(--transition);
}
.site-nav a:hover {
  background: var(--accent-light);
  color: var(--accent-dark);
}
.nav-toggle { display:none; background:none; border:none; cursor:pointer; padding:8px; }
.nav-toggle span { display:block; width:22px; height:2px; background:var(--text); margin:5px 0; transition:var(--transition); }

@media(max-width:768px){
  .site-nav {
    display: none;
    position: absolute;
    top: 64px; left:0; right:0;
    background: var(--white);
    flex-direction: column;
    padding: 16px;
    border-bottom: 1px solid var(--border);
    box-shadow: var(--shadow-md);
  }
  .site-nav.open { display:flex; }
  .nav-toggle { display:block; }
}

/* ── HERO ── */
.hero {
  padding: 80px 24px;
  text-align: center;
  background: linear-gradient(180deg, var(--accent-light) 0%, var(--bg) 100%);
}
.hero h1 {
  font-family: var(--font-heading);
  font-size: clamp(2rem, 5vw, 3.2rem);
  font-weight: 800;
  color: var(--text);
  line-height: 1.2;
  max-width: 700px;
  margin: 0 auto 16px;
}
.hero p {
  color: var(--text-muted);
  font-size: 1.15rem;
  max-width: 540px;
  margin: 0 auto;
}

/* ── BREADCRUMBS ── */
.breadcrumbs {
  max-width: var(--max-w);
  margin: 32px auto 0;
  padding: 0 24px;
  font-size: 0.85rem;
  color: var(--text-muted);
}
.breadcrumbs a {
  color: var(--accent);
  text-decoration: none;
  text-align: left;
}
.breadcrumbs a:hover { text-decoration: underline; }
.breadcrumbs span { margin: 0 6px; }

/* ── READING TIME WIDGET ── */
.reading-meta {
  max-width: var(--max-w);
  margin: 24px auto;
  padding: 0 24px;
  display: flex;
  align-items: center;
  gap: 16px;
  font-size: 0.9rem;
  color: var(--text-muted);
}
.reading-meta .dot {
  width: 4px; height: 4px;
  background: var(--accent);
  border-radius: 50%;
}
.reading-meta .category-badge {
  background: var(--accent-light);
  color: var(--accent-dark);
  padding: 3px 12px;
  border-radius: 20px;
  font-weight: 600;
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

/* ── ARTICLE ── */
.article-title {
  font-family: var(--font-heading);
  font-size: clamp(1.8rem, 4vw, 2.6rem);
  font-weight: 700;
  line-height: 1.25;
  max-width: var(--max-w);
  margin: 0 auto 32px;
  padding: 0 24px;
  color: var(--text);
}
.article-body {
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 0 24px 48px;
}
.article-body h2 {
  font-family: var(--font-heading);
  font-size: 1.6rem;
  font-weight: 600;
  margin: 48px 0 16px;
  color: var(--text);
  position: relative;
  padding-left: 20px;
}
.article-body h2::before {
  content: '';
  position: absolute;
  left: 0; top: 4px; bottom: 4px;
  width: 4px;
  background: var(--accent);
  border-radius: 2px;
}
.article-body p {
  margin-bottom: 20px;
  color: var(--text);
}
.article-body blockquote {
  border-left: 3px solid var(--accent);
  margin: 32px 0;
  padding: 20px 24px;
  background: var(--accent-light);
  border-radius: 0 var(--radius) var(--radius) 0;
  font-style: italic;
  color: var(--text-muted);
}
.article-body img {
  width: 100%;
  border-radius: var(--radius);
  margin: 32px 0;
  box-shadow: var(--shadow-md);
}
.article-body ul, .article-body ol {
  padding-left: 24px;
  margin-bottom: 20px;
}
.article-body li { margin-bottom: 8px; }

/* ── SCROLL ANIMATIONS ── */
.fade-in {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}
.fade-in.visible {
  opacity: 1;
  transform: translateY(0);
}

/* ── READ ALSO ── */
.read-also {
  max-width: var(--max-w);
  margin: 0 auto 48px;
  padding: 0 24px;
}
.read-also h3 {
  font-family: var(--font-heading);
  font-size: 1.3rem;
  margin-bottom: 20px;
  color: var(--text);
}
.read-also-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 16px;
}
.read-also-card {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 20px;
  text-decoration: none;
  transition: var(--transition);
}
.read-also-card:hover {
  border-color: var(--accent);
  box-shadow: var(--shadow-md);
  transform: translateY(-2px);
}
.read-also-card h4 {
  font-family: var(--font-heading);
  font-size: 1rem;
  color: var(--text);
  margin-bottom: 8px;
  text-align: left;
  line-height: 1.4;
}
.read-also-card p {
  font-size: 0.85rem;
  color: var(--text-muted);
  text-align: left;
}

/* ── ARTICLE CARDS (home) ── */
.articles-section {
  max-width: 1100px;
  margin: 0 auto;
  padding: 60px 24px;
}
.articles-section h2 {
  font-family: var(--font-heading);
  font-size: 1.8rem;
  text-align: center;
  margin-bottom: 40px;
}
.articles-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 24px;
}
.article-card {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  text-decoration: none;
  transition: var(--transition);
}
.article-card:hover {
  box-shadow: var(--shadow-lg);
  transform: translateY(-4px);
}
.article-card-img {
  width: 100%;
  height: 200px;
  object-fit: cover;
}
.article-card-body {
  padding: 24px;
}
.article-card-body h3 {
  font-family: var(--font-heading);
  font-size: 1.15rem;
  color: var(--text);
  margin-bottom: 8px;
  text-align: left;
  line-height: 1.35;
}
.article-card-body p {
  font-size: 0.9rem;
  color: var(--text-muted);
  text-align: left;
}
.article-card-meta {
  font-size: 0.8rem;
  color: var(--accent);
  font-weight: 600;
  margin-bottom: 6px;
  text-align: left;
}

/* ── SUBSCRIBE ── */
.subscribe-section {
  max-width: var(--max-w);
  margin: 0 auto 60px;
  padding: 0 24px;
}
.subscribe-box {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 40px;
  text-align: center;
}
.subscribe-box h3 {
  font-family: var(--font-heading);
  font-size: 1.4rem;
  margin-bottom: 8px;
}
.subscribe-box p {
  color: var(--text-muted);
  margin-bottom: 24px;
  font-size: 0.95rem;
}
.subscribe-form {
  display: flex;
  gap: 12px;
  max-width: 460px;
  margin: 0 auto;
}
.subscribe-form input[type="email"] {
  flex: 1;
  padding: 12px 16px;
  border: 1px solid var(--border);
  border-radius: 8px;
  font-size: 0.95rem;
  font-family: var(--font-body);
  outline: none;
  transition: var(--transition);
}
.subscribe-form input[type="email"]:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(42,157,143,0.12);
}
.subscribe-form button {
  padding: 12px 28px;
  background: var(--accent);
  color: var(--white);
  border: none;
  border-radius: 8px;
  font-size: 0.95rem;
  font-weight: 600;
  cursor: pointer;
  transition: var(--transition);
  font-family: var(--font-body);
  white-space: nowrap;
}
.subscribe-form button:hover {
  background: var(--accent-dark);
}
@media(max-width:520px){
  .subscribe-form { flex-direction:column; }
}

/* ── FOOTER ── */
.site-footer {
  background: var(--white);
  border-top: 1px solid var(--border);
  padding: 48px 24px 32px;
}
.footer-inner {
  max-width: 1100px;
  margin: 0 auto;
  text-align: center;
}
.footer-links {
  display: flex;
  justify-content: center;
  gap: 24px;
  margin-bottom: 20px;
  flex-wrap: wrap;
}
.footer-links a {
  font-size: 0.9rem;
  color: var(--text-muted);
  text-decoration: none;
  transition: var(--transition);
}
.footer-links a:hover { color: var(--accent); }
.footer-copy {
  font-size: 0.82rem;
  color: var(--text-muted);
  margin-bottom: 12px;
}
.footer-disclaimer {
  font-size: 0.78rem;
  color: var(--text-muted);
  max-width: 600px;
  margin: 12px auto 0;
  opacity: 0.8;
  line-height: 1.6;
}

/* ── COOKIE MODAL ── */
.cookie-modal {
  position: fixed;
  bottom: 24px;
  right: 24px;
  max-width: 380px;
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 24px;
  box-shadow: var(--shadow-lg);
  z-index: 999;
  animation: slideUp 0.4s ease;
}
@keyframes slideUp {
  from { opacity:0; transform:translateY(20px); }
  to { opacity:1; transform:translateY(0); }
}
.cookie-modal.hidden { display: none; }
.cookie-modal h4 {
  font-family: var(--font-heading);
  font-size: 1.05rem;
  margin-bottom: 8px;
}
.cookie-modal p {
  font-size: 0.85rem;
  color: var(--text-muted);
  margin-bottom: 16px;
  line-height: 1.5;
}
.cookie-btns {
  display: flex;
  gap: 10px;
}
.cookie-btns button {
  flex: 1;
  padding: 10px;
  border-radius: 8px;
  font-size: 0.88rem;
  font-weight: 600;
  cursor: pointer;
  transition: var(--transition);
  font-family: var(--font-body);
  border: none;
}
.cookie-accept {
  background: var(--accent);
  color: var(--white);
}
.cookie-accept:hover { background: var(--accent-dark); }
.cookie-decline {
  background: var(--bg-alt);
  color: var(--text-muted);
  border: 1px solid var(--border) !important;
}
.cookie-decline:hover { background: var(--border); }

@media(max-width:480px){
  .cookie-modal { left:16px; right:16px; max-width:none; bottom:16px; }
}

/* ── POLICY / LEGAL PAGES ── */
.legal-page {
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 48px 24px 64px;
}
.legal-page h1 {
  font-family: var(--font-heading);
  font-size: 2rem;
  margin-bottom: 32px;
  color: var(--text);
}
.legal-page h2 {
  font-family: var(--font-heading);
  font-size: 1.3rem;
  margin: 36px 0 12px;
  color: var(--text);
}
.legal-page p {
  margin-bottom: 16px;
  color: var(--text-muted);
  line-height: 1.8;
}

/* ── SUCCESS PAGE ── */
.success-page {
  min-height: 60vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 60px 24px;
}
.success-page h1 {
  font-family: var(--font-heading);
  font-size: clamp(2rem, 5vw, 3rem);
  color: var(--accent-dark);
  margin-bottom: 16px;
}
.success-page p {
  color: var(--text-muted);
  font-size: 1.1rem;
  margin-bottom: 32px;
  max-width: 440px;
}
.btn-home {
  padding: 14px 36px;
  background: var(--accent);
  color: var(--white);
  border-radius: 8px;
  text-decoration: none;
  font-weight: 600;
  font-size: 1rem;
  transition: var(--transition);
}
.btn-home:hover { background: var(--accent-dark); }

/* ── 404 ── */
.page-404 {
  min-height: 70vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 60px 24px;
}
.page-404 .err-code {
  font-family: var(--font-heading);
  font-size: clamp(5rem, 15vw, 10rem);
  font-weight: 800;
  color: var(--accent-light);
  line-height: 1;
}
.page-404 h1 {
  font-family: var(--font-heading);
  font-size: 1.8rem;
  margin: 16px 0 12px;
}
.page-404 p {
  color: var(--text-muted);
  margin-bottom: 32px;
}

/* ── AUTHOR ── */
.author-box {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 32px;
}
.author-avatar {
  width: 44px; height: 44px;
  border-radius: 50%;
  background: var(--accent-light);
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-heading);
  font-weight: 700;
  color: var(--accent-dark);
  font-size: 1.1rem;
}
.author-info { text-align: left; }
.author-info .name { font-weight: 600; font-size: 0.95rem; }
.author-info .role { font-size: 0.82rem; color: var(--text-muted); }

/* ── DISCLAIMER BANNER ── */
.article-disclaimer {
  background: var(--bg-alt);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 20px 24px;
  margin: 40px 0 0;
  font-size: 0.85rem;
  color: var(--text-muted);
  line-height: 1.6;
}
