/* ===== RESET & BASE ===== */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
  font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
  font-size: 16px;
  line-height: 1.7;
  color: #333;
  background: #f9f9f9;
}
a { color: #e63946; text-decoration: none; }
a:hover { text-decoration: underline; }
img { max-width: 100%; height: auto; display: block; }

/* ===== HEADER ===== */
header {
  background: #fff;
  border-bottom: 3px solid #e63946;
  position: sticky;
  top: 0;
  z-index: 1000;
  box-shadow: 0 2px 8px rgba(0,0,0,0.08);
}
.header-inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 65px;
}
.logo { font-size: 1.6rem; font-weight: 800; color: #e63946; letter-spacing: -1px; }
.logo span { color: #333; }

nav ul { list-style: none; display: flex; gap: 24px; }
nav ul li a { font-weight: 600; color: #333; font-size: 0.95rem; transition: color 0.2s; }
nav ul li a:hover { color: #e63946; text-decoration: none; }

.hamburger { display: none; flex-direction: column; gap: 5px; cursor: pointer; background: none; border: none; padding: 4px; }
.hamburger span { width: 25px; height: 3px; background: #333; border-radius: 3px; transition: 0.3s; }

/* ===== HERO ===== */
.hero {
  background: linear-gradient(135deg, #e63946 0%, #c1121f 100%);
  color: #fff;
  text-align: center;
  padding: 70px 20px;
}
.hero h1 { font-size: 2.4rem; font-weight: 800; margin-bottom: 14px; }
.hero p { font-size: 1.1rem; opacity: 0.9; max-width: 600px; margin: 0 auto 24px; }
.btn {
  display: inline-block;
  background: #fff;
  color: #e63946;
  padding: 12px 30px;
  border-radius: 30px;
  font-weight: 700;
  font-size: 1rem;
  transition: transform 0.2s, box-shadow 0.2s;
}
.btn:hover { transform: translateY(-2px); box-shadow: 0 6px 20px rgba(0,0,0,0.15); text-decoration: none; }

/* ===== AD BANNER ===== */
.ad-banner {
  background: #fff;
  border: 1px dashed #ddd;
  text-align: center;
  padding: 10px;
  margin: 20px auto;
  max-width: 1200px;
  font-size: 0.75rem;
  color: #999;
}
.ad-banner ins { display: block; }

/* ===== LAYOUT ===== */
.container { max-width: 1200px; margin: 0 auto; padding: 0 20px; }
.main-layout {
  display: grid;
  grid-template-columns: 1fr 300px;
  gap: 30px;
  padding: 30px 20px;
  max-width: 1200px;
  margin: 0 auto;
}

/* ===== SECTION TITLE ===== */
.section-title {
  font-size: 1.5rem;
  font-weight: 800;
  color: #222;
  margin-bottom: 20px;
  padding-bottom: 10px;
  border-bottom: 3px solid #e63946;
  display: inline-block;
}

/* ===== POST GRID ===== */
.post-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 24px;
  margin-bottom: 30px;
}
.post-card {
  background: #fff;
  border-radius: 10px;
  overflow: hidden;
  box-shadow: 0 2px 12px rgba(0,0,0,0.07);
  transition: transform 0.2s, box-shadow 0.2s;
}
.post-card:hover { transform: translateY(-4px); box-shadow: 0 8px 24px rgba(0,0,0,0.12); }
.post-card-img {
  width: 100%;
  height: 180px;
  object-fit: cover;
  background: linear-gradient(135deg, #e63946, #c1121f);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 3rem;
}
.post-card-body { padding: 16px; }
.post-card-cat {
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  color: #e63946;
  letter-spacing: 1px;
  margin-bottom: 6px;
}
.post-card-title { font-size: 1rem; font-weight: 700; color: #222; margin-bottom: 8px; line-height: 1.4; }
.post-card-excerpt { font-size: 0.85rem; color: #666; margin-bottom: 12px; }
.post-card-meta { font-size: 0.78rem; color: #999; display: flex; gap: 12px; }
.read-more {
  display: inline-block;
  margin-top: 10px;
  font-size: 0.85rem;
  font-weight: 700;
  color: #e63946;
}

/* ===== SIDEBAR ===== */
.sidebar { }
.sidebar-widget {
  background: #fff;
  border-radius: 10px;
  padding: 20px;
  margin-bottom: 24px;
  box-shadow: 0 2px 12px rgba(0,0,0,0.07);
}
.widget-title {
  font-size: 1rem;
  font-weight: 800;
  color: #222;
  margin-bottom: 14px;
  padding-bottom: 8px;
  border-bottom: 2px solid #e63946;
}
.recent-list { list-style: none; }
.recent-list li { padding: 8px 0; border-bottom: 1px solid #f0f0f0; font-size: 0.88rem; }
.recent-list li:last-child { border-bottom: none; }
.tag-cloud { display: flex; flex-wrap: wrap; gap: 8px; }
.tag {
  background: #f0f0f0;
  color: #555;
  padding: 4px 12px;
  border-radius: 20px;
  font-size: 0.8rem;
  font-weight: 600;
  transition: background 0.2s, color 0.2s;
}
.tag:hover { background: #e63946; color: #fff; text-decoration: none; }

/* ===== SINGLE POST ===== */
.post-header { margin-bottom: 24px; }
.post-header h1 { font-size: 2rem; font-weight: 800; color: #222; line-height: 1.3; margin-bottom: 12px; }
.post-meta { font-size: 0.85rem; color: #888; display: flex; gap: 16px; flex-wrap: wrap; margin-bottom: 16px; }
.post-featured-img {
  width: 100%;
  height: 350px;
  background: linear-gradient(135deg, #e63946, #c1121f);
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 5rem;
  margin-bottom: 24px;
}
.post-content { font-size: 1rem; line-height: 1.85; color: #444; }
.post-content h2 { font-size: 1.4rem; font-weight: 800; color: #222; margin: 28px 0 12px; }
.post-content h3 { font-size: 1.15rem; font-weight: 700; color: #333; margin: 22px 0 10px; }
.post-content p { margin-bottom: 16px; }
.post-content ul, .post-content ol { margin: 12px 0 16px 24px; }
.post-content li { margin-bottom: 6px; }
.post-content blockquote {
  border-left: 4px solid #e63946;
  padding: 12px 20px;
  background: #fff5f5;
  margin: 20px 0;
  border-radius: 0 8px 8px 0;
  font-style: italic;
  color: #555;
}

/* ===== BREADCRUMB ===== */
.breadcrumb { font-size: 0.82rem; color: #999; margin-bottom: 16px; }
.breadcrumb a { color: #e63946; }
.breadcrumb span { margin: 0 6px; }

/* ===== CATEGORIES ===== */
.cat-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
  gap: 16px;
  margin-bottom: 30px;
}
.cat-card {
  background: #fff;
  border-radius: 10px;
  padding: 20px;
  text-align: center;
  box-shadow: 0 2px 10px rgba(0,0,0,0.07);
  transition: transform 0.2s;
  cursor: pointer;
}
.cat-card:hover { transform: translateY(-3px); text-decoration: none; }
.cat-card .cat-icon { font-size: 2rem; margin-bottom: 8px; }
.cat-card .cat-name { font-size: 0.9rem; font-weight: 700; color: #333; }
.cat-card .cat-count { font-size: 0.75rem; color: #999; margin-top: 4px; }

/* ===== PAGES (About, Contact, etc.) ===== */
.page-hero {
  background: linear-gradient(135deg, #e63946, #c1121f);
  color: #fff;
  text-align: center;
  padding: 50px 20px;
}
.page-hero h1 { font-size: 2rem; font-weight: 800; }
.page-hero p { opacity: 0.9; margin-top: 8px; }
.page-content {
  max-width: 800px;
  margin: 40px auto;
  padding: 0 20px;
  background: #fff;
  border-radius: 10px;
  padding: 40px;
  box-shadow: 0 2px 12px rgba(0,0,0,0.07);
}
.page-content h2 { font-size: 1.3rem; font-weight: 800; color: #222; margin: 24px 0 10px; }
.page-content p { color: #555; margin-bottom: 14px; line-height: 1.8; }
.page-content ul { margin: 10px 0 14px 24px; color: #555; }
.page-content li { margin-bottom: 6px; }

/* ===== CONTACT FORM ===== */
.contact-form { margin-top: 20px; }
.form-group { margin-bottom: 18px; }
.form-group label { display: block; font-weight: 600; margin-bottom: 6px; color: #444; font-size: 0.9rem; }
.form-group input, .form-group textarea, .form-group select {
  width: 100%;
  padding: 12px 16px;
  border: 1px solid #ddd;
  border-radius: 8px;
  font-size: 0.95rem;
  font-family: inherit;
  transition: border-color 0.2s;
  background: #fafafa;
}
.form-group input:focus, .form-group textarea:focus {
  outline: none;
  border-color: #e63946;
  background: #fff;
}
.form-group textarea { resize: vertical; min-height: 120px; }
.btn-submit {
  background: #e63946;
  color: #fff;
  border: none;
  padding: 13px 32px;
  border-radius: 30px;
  font-size: 1rem;
  font-weight: 700;
  cursor: pointer;
  transition: background 0.2s, transform 0.2s;
}
.btn-submit:hover { background: #c1121f; transform: translateY(-1px); }

/* ===== FOOTER ===== */
footer {
  background: #1a1a2e;
  color: #ccc;
  padding: 50px 20px 20px;
  margin-top: 50px;
}
.footer-grid {
  max-width: 1200px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 30px;
  margin-bottom: 30px;
}
.footer-col h4 { color: #fff; font-size: 1rem; font-weight: 700; margin-bottom: 14px; }
.footer-col ul { list-style: none; }
.footer-col ul li { margin-bottom: 8px; }
.footer-col ul li a { color: #aaa; font-size: 0.88rem; transition: color 0.2s; }
.footer-col ul li a:hover { color: #e63946; text-decoration: none; }
.footer-col p { font-size: 0.88rem; color: #aaa; line-height: 1.7; }
.footer-bottom {
  max-width: 1200px;
  margin: 0 auto;
  border-top: 1px solid #333;
  padding-top: 20px;
  text-align: center;
  font-size: 0.82rem;
  color: #777;
}

/* ===== PAGINATION ===== */
.pagination { display: flex; gap: 8px; justify-content: center; margin: 30px 0; flex-wrap: wrap; }
.pagination a, .pagination span {
  padding: 8px 14px;
  border-radius: 6px;
  font-size: 0.9rem;
  font-weight: 600;
  background: #fff;
  color: #333;
  border: 1px solid #ddd;
  transition: background 0.2s, color 0.2s;
}
.pagination a:hover, .pagination .active { background: #e63946; color: #fff; border-color: #e63946; text-decoration: none; }

/* ===== MOBILE NAV ===== */
@media (max-width: 768px) {
  .hamburger { display: flex; }
  nav { display: none; position: absolute; top: 65px; left: 0; right: 0; background: #fff; border-top: 1px solid #eee; padding: 16px 20px; box-shadow: 0 4px 12px rgba(0,0,0,0.1); }
  nav.open { display: block; }
  nav ul { flex-direction: column; gap: 0; }
  nav ul li a { display: block; padding: 10px 0; border-bottom: 1px solid #f0f0f0; }
  .hero h1 { font-size: 1.7rem; }
  .main-layout { grid-template-columns: 1fr; }
  .post-featured-img { height: 220px; font-size: 3rem; }
  .post-header h1 { font-size: 1.5rem; }
  .page-content { padding: 24px 16px; }
}
@media (max-width: 480px) {
  .hero h1 { font-size: 1.4rem; }
  .post-grid { grid-template-columns: 1fr; }
  .cat-grid { grid-template-columns: repeat(2, 1fr); }
}
