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

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  background: #F5F3EF;
  color: #2C2C2C;
  line-height: 1.5;
}

.container {
  max-width: 1024px;
  margin: 0 auto;
  padding: 0 1.5rem;
}

h1, h2, h3, .serif {
  font-family: 'Merriweather', 'Playfair Display', Georgia, serif;
  font-weight: 700;
  color: #2D4A3E;
}

h1 {
  font-size: 2.5rem;
  margin-bottom: 1rem;
}

h2 {
  font-size: 1.8rem;
  margin: 2rem 0 1rem;
  border-left: 4px solid #C96B3F;
  padding-left: 0.75rem;
}

h3 {
  font-size: 1.25rem;
  margin: 1.5rem 0 0.75rem;
}

p {
  margin-bottom: 1rem;
  color: #2C2C2C;
}

a {
  color: #2D4A3E;
  text-decoration: none;
  transition: color 0.2s;
}

a:hover {
  color: #C96B3F;
}

/* ========== Navigation ========== */
nav {
  background: #2D4A3E;
  padding: 1rem 1.5rem;
  position: sticky;
  top: 0;
  z-index: 100;
}
.nav-container {
  max-width: 1024px;
  margin: 0 auto;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
}
.logo {
  font-family: 'Merriweather', serif;
  font-size: 1.5rem;
  font-weight: 700;
  color: white;
}
.logo:hover {
  color: #F5F3EF;
}
.nav-links {
  display: flex;
  gap: 2rem;
  align-items: center;
}
.nav-links a {
  color: #E2E8F0;
  font-weight: 500;
}
.nav-links a:hover, .nav-links a.active {
  color: white;
  text-decoration: underline;
  text-underline-offset: 6px;
}
.menu-icon {
  display: none;
  font-size: 1.8rem;
  cursor: pointer;
  color: white;
}

/* ========== Buttons ========== */
.btn-primary {
  background: #2D4A3E;
  color: white;
  padding: 0.75rem 1.5rem;
  border-radius: 8px;
  border: none;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s;
  display: inline-block;
}
.btn-primary:hover {
  background: #3a5e4f;
  transform: translateY(-1px);
  box-shadow: 0 4px 8px rgba(0,0,0,0.1);
}
.btn-secondary {
  background: transparent;
  border: 1px solid #2D4A3E;
  color: #2D4A3E;
  padding: 0.75rem 1.5rem;
  border-radius: 8px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s;
}
.btn-secondary:hover {
  background: rgba(45,74,62,0.05);
}

/* ========== Cards & Grid ========== */
.tool-grid, .guide-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 2rem;
  margin: 2rem 0;
}
.card {
  background: white;
  border-radius: 12px;
  padding: 1.5rem;
  box-shadow: 0 2px 5px rgba(0,0,0,0.05);
  transition: transform 0.2s, box-shadow 0.2s;
}
.card:hover {
  transform: translateY(-3px);
  box-shadow: 0 8px 20px rgba(0,0,0,0.1);
}
.card-icon {
  background: #F5F3EF;
  width: 48px;
  height: 48px;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 1rem;
  font-size: 1.8rem;
}
.card h3 {
  margin: 0 0 0.5rem;
}
.card p {
  font-size: 0.9rem;
  color: #6B6B6B;
  margin-bottom: 1rem;
}
.tags {
  display: flex;
  gap: 0.5rem;
  margin-bottom: 1rem;
}
.tag {
  background: #F5F3EF;
  padding: 0.25rem 0.6rem;
  border-radius: 20px;
  font-size: 0.7rem;
  text-transform: uppercase;
}
.card-link {
  font-weight: 600;
}

/* ========== Tool Detail ========== */
.tool-container {
  background: white;
  border-radius: 20px;
  padding: 2rem;
  margin: 2rem 0;
  box-shadow: 0 2px 8px rgba(0,0,0,0.05);
}
.input-group {
  margin-bottom: 1.5rem;
}
label {
  display: block;
  font-weight: 600;
  margin-bottom: 0.5rem;
  color: #2D4A3E;
}
input, select {
  width: 100%;
  max-width: 400px;
  padding: 0.75rem;
  border: 1px solid #ddd;
  border-radius: 8px;
  font-size: 1rem;
}
input:focus, select:focus {
  outline: none;
  border-color: #C96B3F;
  box-shadow: 0 0 0 3px rgba(201,107,63,0.2);
}
.result-box {
  background: #F5F3EF;
  padding: 1.5rem;
  border-radius: 12px;
  margin-top: 1.5rem;
  border-left: 4px solid #C96B3F;
  display: none;
}
.result-box.show {
  display: block;
  animation: fadeIn 0.3s ease;
}
@keyframes fadeIn {
  from { opacity: 0; transform: translateY(5px);}
  to { opacity: 1; transform: translateY(0);}
}
.summary-block {
  background: #EFF5F2;
  padding: 1rem;
  border-radius: 10px;
  margin: 1.5rem 0;
  font-size: 0.9rem;
  border-left: 3px solid #2D4A3E;
}
.breadcrumb {
  font-size: 0.8rem;
  color: #6B6B6B;
  margin-bottom: 1rem;
}
.last-updated {
  font-size: 0.8rem;
  color: #6B6B6B;
  text-align: right;
  margin-top: 2rem;
  padding-top: 1rem;
  border-top: 1px solid #eee;
}
.hero {
  text-align: center;
  padding: 3rem 0 1rem;
}
.hero h1 {
  font-size: 3rem;
}
.stats {
  display: flex;
  justify-content: center;
  gap: 3rem;
  margin: 2rem 0;
}
.stat-item {
  text-align: center;
}
.stat-number {
  font-size: 2rem;
  font-weight: 700;
  color: #2D4A3E;
}
.stat-label {
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 1px;
}
.feature-cols {
  display: flex;
  gap: 2rem;
  margin: 3rem 0;
  flex-wrap: wrap;
}
.feature-col {
  flex: 1;
  background: white;
  padding: 1.5rem;
  border-radius: 16px;
}
footer {
  background: #2D4A3E;
  color: #CBD5E1;
  padding: 2rem 0;
  margin-top: 3rem;
  text-align: center;
}
footer a {
  color: #F5F3EF;
}

/* ========== Responsive ========== */
@media (max-width: 768px) {
  .container {
    padding: 0 1rem;
  }
  h1 {
    font-size: 2rem;
  }
  .nav-links {
    display: none;
    width: 100%;
    flex-direction: column;
    gap: 1rem;
    margin-top: 1rem;
  }
  .nav-links.show {
    display: flex;
  }
  .menu-icon {
    display: block;
  }
  .tool-grid, .guide-grid {
    grid-template-columns: 1fr;
  }
  .stats {
    gap: 1.5rem;
  }
  .hero h1 {
    font-size: 2rem;
  }
  input, select {
    max-width: 100%;
  }
}