/* Global layout */
html, body {
  height: 100%;
  margin: 0;
  padding: 0;
  scroll-behavior: smooth;
}

body {
  box-sizing: border-box;
  font-family: 'Inter', sans-serif;
  background: linear-gradient(135deg, #f093fb 0%, #f5576c 100%);
  min-height: 100%;
}

* {
  box-sizing: border-box;
}

/* Header */
.header {
  background: linear-gradient(135deg, #ec4899 0%, #ef4444 100%);
  backdrop-filter: blur(10px);
  position: sticky;
  top: 0;
  z-index: 1000;
  box-shadow: 0 4px 20px rgba(236, 72, 153, 0.15);
}

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

/* Brand */
.logo-area {
  display: flex;
  align-items: center;
}

.brand-link {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
}

.brand-logo {
  width: 36px;
  height: 36px;
  border-radius: 8px;
}

.brand-text {
  color: #ffffff;
  font-size: 1.1rem;
  font-weight: 700;
}

/* Desktop nav */
.desktop-nav {
  display: flex;
  align-items: center;
  gap: 1.75rem;
}

.nav-link {
  color: #ffffff;
  font-weight: 500;
  text-decoration: none;
  transition: all 0.25s ease;
  display: inline-block;
}

.nav-link:hover {
  color: #e5e7eb;
  transform: translateY(-1px);
}

/* Dropdown */
.dropdown {
  position: relative;
}

.dropdown-toggle {
  background: none;
  border: none;
  color: #ffffff;
  font-weight: 500;
  cursor: pointer;
  transition: color 0.25s ease;
}

.dropdown-toggle:hover {
  color: #e5e7eb;
}

.dropdown-content {
  display: none;
  position: absolute;
  top: 110%;
  right: 0;
  min-width: 220px;
  background: #ffffff;
  border-radius: 12px;
  box-shadow: 0 8px 30px rgba(0, 0, 0, 0.12);
  overflow: hidden;
  padding: 4px 0;
  animation: fadeInDown 0.25s ease;
  z-index: 1001;
}

.dropdown-content a {
  color: #4a5568;
  padding: 10px 18px;
  display: block;
  font-size: 14px;
  text-decoration: none;
  transition: all 0.2s ease;
}

.dropdown-content a:hover {
  background: linear-gradient(135deg, #f093fb 0%, #f5576c 100%);
  color: #ffffff;
  padding-left: 26px;
}

.dropdown-content.show {
  display: block;
}

@keyframes fadeInDown {
  from {
    opacity: 0;
    transform: translateY(-8px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Mobile menu */
.mobile-menu-btn {
  display: none;
  background: none;
  border: none;
  color: #ffffff;
  font-size: 1.8rem;
  cursor: pointer;
}

.mobile-menu {
  display: none;
  background: #16a34a;
  color: #ffffff;
  padding: 10px 0 16px;
  position: absolute;
  top: 100%;
  left: 0;
  right: 0;
  z-index: 999;
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.3s ease;
}

.mobile-menu a {
  display: block;
  padding: 10px 20px;
  text-decoration: none;
  color: #ffffff;
  font-weight: 500;
}

.mobile-menu a:hover {
  background: rgba(0, 0, 0, 0.14);
}

.mobile-menu.open {
  display: block;
  max-height: 400px;
}

/* Hero */
.page-header {
  background: linear-gradient(135deg, #f093fb 0%, #f5576c 100%);
  color: #ffffff;
  padding: 72px 20px 90px;
  text-align: center;
  position: relative;
  overflow: hidden;
}

.page-header::before {
  content: '';
  position: absolute;
  inset: 0;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 1200 120'%3E%3Cpath d='M0,0 Q300,60 600,30 T1200,0 L1200,120 L0,120 Z' fill='rgba(255,255,255,0.05)'/%3E%3C/svg%3E")
    repeat-x bottom;
  background-size: 1200px 120px;
  opacity: 0.3;
}

.page-header h1 {
  position: relative;
  z-index: 1;
  font-size: 2.8rem;
  font-weight: 900;
  margin-bottom: 12px;
  text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.25);
  animation: slideInDown 0.6s ease;
}

.page-header p {
  position: relative;
  z-index: 1;
  font-size: 1.1rem;
  animation: slideInUp 0.6s ease;
}

@keyframes slideInDown {
  from { opacity: 0; transform: translateY(-24px); }
  to   { opacity: 1; transform: translateY(0); }
}

@keyframes slideInUp {
  from { opacity: 0; transform: translateY(24px); }
  to   { opacity: 1; transform: translateY(0); }
}

@keyframes heartbeat {
  0%, 100% { transform: scale(1); }
  10%, 30% { transform: scale(1.1); }
  20%, 40% { transform: scale(1); }
}

.heartbeat-animation {
  animation: heartbeat 1.5s ease-in-out infinite;
}

/* Calculator layout */
.calculator-container {
  max-width: 1400px;
  margin: -60px auto 60px;
  padding: 0 20px;
  position: relative;
  z-index: 10;
}

.calculator-card {
  background: #ffffff;
  border-radius: 24px;
  padding: 40px;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.15);
  margin-bottom: 24px;
  animation: slideUp 0.6s ease;
}

@keyframes slideUp {
  from { opacity: 0; transform: translateY(30px); }
  to   { opacity: 1; transform: translateY(0); }
}

.card-title {
  font-size: 1.6rem;
  font-weight: 800;
  color: #ec4899;
  margin-bottom: 28px;
  display: flex;
  align-items: center;
  gap: 12px;
}

/* Inputs */
.input-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
  margin-bottom: 24px;
}

.input-group {
  background: linear-gradient(135deg, #fce7f3 0%, #fecaca 100%);
  padding: 22px;
  border-radius: 16px;
  border: 2px solid #ec4899;
  transition: all 0.3s ease;
}

.input-group:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 20px rgba(236, 72, 153, 0.2);
}

.input-label {
  font-weight: 700;
  color: #831843;
  margin-bottom: 10px;
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.input-field,
.select-field {
  width: 100%;
  padding: 12px 14px;
  border: 2px solid #ec4899;
  border-radius: 10px;
  font-size: 1rem;
  font-weight: 600;
  color: #1e293b;
  background: #ffffff;
  transition: all 0.3s ease;
}

.input-field:focus,
.select-field:focus {
  outline: none;
  border-color: #f5576c;
  box-shadow: 0 0 0 4px rgba(236, 72, 153, 0.15);
  transform: scale(1.02);
}

.helper-text {
  font-size: 0.75rem;
  color: #831843;
  margin-top: 8px;
}

/* Buttons */
.calculate-btn {
  width: 100%;
  padding: 16px;
  background: linear-gradient(135deg, #f093fb 0%, #f5576c 100%);
  color: #ffffff;
  border: none;
  border-radius: 12px;
  font-size: 1.1rem;
  font-weight: 700;
  cursor: pointer;
  margin-top: 6px;
  transition: all 0.3s ease;
}

.calculate-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 20px rgba(236, 72, 153, 0.4);
}

.download-buttons {
  display: flex;
  gap: 12px;
  margin-top: 24px;
}

.download-btn {
  flex: 1;
  padding: 14px 24px;
  background: linear-gradient(135deg, #f093fb 0%, #f5576c 100%);
  color: #ffffff;
  border: none;
  border-radius: 10px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}

.download-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(236, 72, 153, 0.3);
}

/* Results */
.result-display {
  background: linear-gradient(135deg, #f093fb 0%, #f5576c 100%);
  padding: 34px;
  border-radius: 20px;
  color: #ffffff;
  margin-bottom: 26px;
}

.hr-value {
  font-size: 3.4rem;
  font-weight: 900;
  margin-bottom: 6px;
  text-align: center;
}

.hr-label {
  font-size: 1.3rem;
  font-weight: 600;
  text-align: center;
  margin-bottom: 28px;
}

.stats-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
  margin-top: 12px;
}

.stat-card {
  background: rgba(255, 255, 255, 0.15);
  backdrop-filter: blur(10px);
  padding: 20px;
  border-radius: 16px;
  text-align: center;
  border: 2px solid rgba(255, 255, 255, 0.25);
  transition: all 0.3s ease;
}

.stat-card:hover {
  background: rgba(255, 255, 255, 0.25);
  transform: translateY(-4px);
}

.stat-title {
  font-size: 0.8rem;
  font-weight: 600;
  margin-bottom: 8px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.stat-value {
  font-size: 1.8rem;
  font-weight: 900;
}

.stat-subtitle {
  font-size: 0.8rem;
  margin-top: 6px;
}

/* Zones */
.zones-section {
  background: #f8fafc;
  padding: 24px;
  border-radius: 16px;
  margin-top: 26px;
}

.zones-heading {
  font-size: 1.3rem;
  font-weight: 700;
  color: #1e293b;
  margin-bottom: 18px;
  text-align: center;
}

.zone-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 18px;
  background: #ffffff;
  border-radius: 12px;
  margin-bottom: 14px;
  border-left: 6px solid;
  transition: all 0.3s ease;
}

.zone-item:hover {
  transform: translateX(6px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.zone-info {
  flex: 1;
  padding-right: 10px;
}

.zone-name {
  font-weight: 700;
  color: #1e293b;
  font-size: 1.05rem;
  margin-bottom: 4px;
}

.zone-description {
  font-size: 0.85rem;
  color: #64748b;
}

.zone-benefits {
  margin-top: 6px;
  font-weight: 600;
}

.zone-stats {
  text-align: right;
}

.zone-range {
  font-weight: 700;
  font-size: 1.05rem;
  color: #1e293b;
}

.zone-percentage {
  font-size: 0.85rem;
  color: #64748b;
  margin-top: 4px;
}

/* Tips */
.tips-section {
  background: #f8fafc;
  padding: 22px;
  border-radius: 12px;
  margin-top: 22px;
}

.tips-heading {
  font-size: 1.2rem;
  font-weight: 700;
  color: #1e293b;
  margin-bottom: 16px;
}

.tip-item {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  margin-bottom: 14px;
  padding: 14px;
  background: #ffffff;
  border-radius: 8px;
  border-left: 4px solid #ec4899;
}

.tip-icon {
  font-size: 1.5rem;
}

/* AdSense placeholder */
.adsense-container {
  background: #fce7f3;
  border-radius: 16px;
  padding: 20px;
  margin: 24px 0;
  min-height: 250px;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 2px dashed #f9a8d4;
}

.adsense-placeholder {
  text-align: center;
  color: #831843;
  font-size: 0.9rem;
}

/* Info box */
.info-box {
  background: #f8fafc;
  padding: 24px;
  border-radius: 12px;
}

.info-box h4 {
  font-weight: 700;
  color: #1e293b;
  margin-bottom: 8px;
}

.info-box p {
  color: #64748b;
  margin-bottom: 18px;
}

/* Blog section */
.blog-section {
  max-width: 900px;
  margin: 70px auto 40px;
  padding: 0 20px;
}

.blog-content {
  background: #ffffff;
  border-radius: 24px;
  padding: 50px 40px;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.1);
  line-height: 1.8;
}

.blog-content h2 {
  font-size: 2rem;
  font-weight: 900;
  color: #1a202c;
  margin-bottom: 24px;
  background: linear-gradient(135deg, #f093fb 0%, #f5576c 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.blog-content h3 {
  font-size: 1.4rem;
  font-weight: 700;
  color: #2d3748;
  margin-top: 32px;
  margin-bottom: 16px;
}

.blog-content p {
  color: #4a5568;
  font-size: 0.98rem;
  margin-bottom: 18px;
}

.blog-content ul {
  color: #4a5568;
  margin-left: 24px;
  margin-bottom: 18px;
}

.blog-content li {
  margin-bottom: 8px;
}

.blog-content a {
  color: #ec4899;
  text-decoration: underline;
}

/* FAQ section */
.faq-section {
  background: #f8fafc;
  padding: 40px 0 60px;
}

.faq-heading {
  font-size: 1.7rem;
  font-weight: 800;
  text-align: center;
  margin-bottom: 24px;
  color: #1e293b;
}

.faq-item {
  background: #ffffff;
  border-radius: 14px;
  margin-bottom: 16px;
  padding: 18px 20px;
  max-width: 900px;
  margin-left: auto;
  margin-right: auto;
  box-shadow: 0 4px 12px rgba(148, 163, 184, 0.2);
}

.faq-item h3 {
  font-size: 1.05rem;
  font-weight: 700;
  margin-bottom: 6px;
  color: #111827;
}

.faq-item p {
  font-size: 0.95rem;
  color: #4b5563;
}

/* Footer */
.footer {
  background: linear-gradient(135deg, #2d3748 0%, #1a202c 100%);
  color: #ffffff;
  padding: 60px 0 20px;
  margin-top: 40px;
}

.footer-column h3 {
  font-size: 0.95rem;
  font-weight: 700;
  margin-bottom: 16px;
  color: #a0aec0;
  text-transform: uppercase;
  letter-spacing: 1px;
}

.footer-column ul {
  list-style: none;
  padding: 0;
  margin: 0;
}

.footer-column ul li {
  margin-bottom: 10px;
}

.footer-column ul li a {
  color: #cbd5e0;
  text-decoration: none;
  transition: all 0.25s ease;
  display: inline-block;
}

.footer-column ul li a:hover {
  color: #ec4899;
  transform: translateX(4px);
}

.footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  margin-top: 32px;
  padding-top: 22px;
  text-align: center;
  color: #a0aec0;
  font-size: 0.85rem;
}

/* Responsive */
@media (max-width: 1024px) {
  .stats-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 768px) {
  .desktop-nav {
    display: none;
  }

  .mobile-menu-btn {
    display: block;
  }

  .page-header {
    padding: 60px 18px 70px;
  }

  .page-header h1 {
    font-size: 2rem;
  }

  .page-header p {
    font-size: 0.98rem;
  }

  .calculator-card {
    padding: 26px 22px;
  }

  .input-grid {
    grid-template-columns: 1fr;
  }

  .stats-grid {
    grid-template-columns: 1fr;
  }

  .download-buttons {
    flex-direction: column;
  }

  .blog-content {
    padding: 32px 22px;
  }

  .blog-content h2 {
    font-size: 1.7rem;
  }
}

@media (max-width: 480px) {
  .brand-text {
    font-size: 0.95rem;
  }

  .hr-value {
    font-size: 2.6rem;
  }
}
