/* =============================================
   Charge Me — Static Site Stylesheet
   ============================================= */

/* ---------- Reset & Base ---------- */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

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

body {
  font-family: 'Merriweather', Georgia, serif;
  background-color: #1a2332;
  color: #c8d0da;
  line-height: 1.75;
  min-height: 100vh;
}

a {
  color: #7eb8e0;
  text-decoration: none;
  transition: color 0.2s ease;
}

a:hover {
  color: #a8d4f0;
}

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

/* ---------- Typography ---------- */
h1, h2, h3, h4 {
  font-family: 'Lato', 'Helvetica Neue', Arial, sans-serif;
  color: #e8edf3;
  line-height: 1.3;
}

h1 { font-size: 2rem; margin-bottom: 0.5em; }
h2 { font-size: 1.6rem; margin-bottom: 0.5em; }
h3 { font-size: 1.25rem; margin-bottom: 0.4em; }

p {
  margin-bottom: 1.2em;
}

/* ---------- Layout ---------- */
.site-wrapper {
  display: flex;
  min-height: 100vh;
}

/* ---------- Sidebar ---------- */
.sidebar {
  width: 320px;
  min-width: 320px;
  background-color: #1e2a3a;
  padding: 60px 40px 40px;
  display: flex;
  flex-direction: column;
  border-right: 1px solid #2a3a4e;
}

.site-branding {
  margin-bottom: 50px;
}

.site-branding h1 {
  font-size: 2rem;
  font-weight: 700;
  color: #ffffff;
  margin-bottom: 8px;
}

.site-branding h1 a {
  color: #ffffff;
}

.site-branding h1 a:hover {
  color: #7eb8e0;
}

.site-tagline {
  font-size: 0.9rem;
  color: #8899aa;
  font-style: italic;
}

/* Navigation */
.main-nav {
  margin-bottom: 40px;
}

.main-nav ul {
  list-style: none;
}

.main-nav li {
  border-bottom: 1px solid #2a3a4e;
}

.main-nav li:first-child {
  border-top: 1px solid #2a3a4e;
}

.main-nav a {
  display: block;
  padding: 12px 0;
  color: #c8d0da;
  font-family: 'Lato', sans-serif;
  font-size: 0.95rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.main-nav a:hover,
.main-nav a.active {
  color: #ffffff;
}

/* Search */
.sidebar-search {
  margin-bottom: 40px;
}

.sidebar-search input {
  width: 100%;
  padding: 10px 14px;
  background: #15202e;
  border: 1px solid #2a3a4e;
  border-radius: 3px;
  color: #c8d0da;
  font-family: 'Lato', sans-serif;
  font-size: 0.9rem;
}

.sidebar-search input::placeholder {
  color: #5c6d7e;
}

.sidebar-search input:focus {
  outline: none;
  border-color: #7eb8e0;
}

/* Categories */
.sidebar-section {
  margin-bottom: 35px;
}

.sidebar-section h3 {
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  color: #8899aa;
  margin-bottom: 15px;
  font-weight: 700;
}

.sidebar-section ul {
  list-style: none;
}

.sidebar-section li {
  margin-bottom: 8px;
}

.sidebar-section li a {
  color: #a0aebb;
  font-size: 0.9rem;
}

.sidebar-section li a:hover {
  color: #ffffff;
}

/* ---------- Main Content ---------- */
.main-content {
  flex: 1;
  background-color: #1a2332;
  padding: 60px 50px;
  max-width: 900px;
}

/* ---------- Post Card ---------- */
.post-card {
  background-color: #212d3d;
  border-radius: 4px;
  margin-bottom: 40px;
  overflow: hidden;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.post-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 30px rgba(0,0,0,0.3);
}

.post-card-image img {
  width: 100%;
  height: 280px;
  object-fit: cover;
}

.post-card-body {
  padding: 35px 40px 30px;
}

.post-card-body h2 {
  margin-bottom: 0.6em;
}

.post-card-body h2 a {
  color: #e8edf3;
}

.post-card-body h2 a:hover {
  color: #7eb8e0;
}

.post-meta {
  font-size: 0.8rem;
  color: #6b7d8e;
  margin-bottom: 15px;
  font-family: 'Lato', sans-serif;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.post-excerpt {
  color: #a0aebb;
  font-size: 0.95rem;
}

.read-more {
  display: inline-block;
  margin-top: 12px;
  font-family: 'Lato', sans-serif;
  font-size: 0.85rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: #7eb8e0;
  border-bottom: 2px solid transparent;
  padding-bottom: 2px;
}

.read-more:hover {
  border-bottom-color: #7eb8e0;
}

/* ---------- Single Post / Page ---------- */
.page-content {
  background-color: #212d3d;
  border-radius: 4px;
  padding: 45px 50px;
}

.page-content h1 {
  margin-bottom: 0.3em;
}

.page-content h2 {
  margin-top: 1.5em;
}

.page-content p {
  color: #a0aebb;
}

.page-content ul, .page-content ol {
  margin: 0 0 1.2em 1.5em;
  color: #a0aebb;
}

.page-content li {
  margin-bottom: 0.5em;
}

/* ---------- Contact Form ---------- */
.contact-form {
  margin-top: 30px;
}

.form-group {
  margin-bottom: 20px;
}

.form-group label {
  display: block;
  font-family: 'Lato', sans-serif;
  font-size: 0.85rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  color: #8899aa;
  margin-bottom: 8px;
}

.form-group input,
.form-group textarea {
  width: 100%;
  padding: 12px 16px;
  background: #15202e;
  border: 1px solid #2a3a4e;
  border-radius: 3px;
  color: #c8d0da;
  font-family: 'Merriweather', serif;
  font-size: 0.9rem;
  transition: border-color 0.2s;
}

.form-group input:focus,
.form-group textarea:focus {
  outline: none;
  border-color: #7eb8e0;
}

.form-group textarea {
  min-height: 160px;
  resize: vertical;
}

.btn {
  display: inline-block;
  padding: 12px 30px;
  background-color: #7eb8e0;
  color: #15202e;
  font-family: 'Lato', sans-serif;
  font-weight: 700;
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 1px;
  border: none;
  border-radius: 3px;
  cursor: pointer;
  transition: background-color 0.2s;
}

.btn:hover {
  background-color: #a8d4f0;
}

/* ---------- Footer ---------- */
.site-footer {
  margin-top: auto;
  padding-top: 40px;
  border-top: 1px solid #2a3a4e;
  font-size: 0.8rem;
  color: #5c6d7e;
  font-family: 'Lato', sans-serif;
}

/* ---------- Responsive ---------- */
@media (max-width: 900px) {
  .site-wrapper {
    flex-direction: column;
  }

  .sidebar {
    width: 100%;
    min-width: unset;
    padding: 30px 25px;
    border-right: none;
    border-bottom: 1px solid #2a3a4e;
  }

  .site-branding {
    margin-bottom: 25px;
  }

  .main-content {
    padding: 30px 25px;
  }

  .post-card-body {
    padding: 25px;
  }

  .page-content {
    padding: 30px 25px;
  }
}

/* ---------- Mobile Nav Toggle ---------- */
.nav-toggle {
  display: none;
  background: none;
  border: none;
  color: #c8d0da;
  font-size: 1.5rem;
  cursor: pointer;
  padding: 5px;
}

@media (max-width: 900px) {
  .nav-toggle {
    display: block;
    position: absolute;
    top: 25px;
    right: 25px;
  }

  .sidebar {
    position: relative;
  }
}
