/**
 * HabiWise Landing Page Styles
 */

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

:root {
  --primary: #667eea;
  --primary-dark: #764ba2;
  --secondary: #f093fb;
  --success: #2ecc71;
  --warning: #f39c12;
  --danger: #e74c3c;
  --text: #2c3e50;
  --text-light: #7f8c8d;
  --bg-light: #f9f9f9;
  --border: #e0e0e0;
}

body {
  font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
  line-height: 1.6;
  color: var(--text);
}

.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
}

/* Hero Section */
.hero {
  background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
  color: white;
  padding: 80px 20px;
  text-align: center;
}

.logo h1 {
  font-size: 3rem;
  margin-bottom: 0.5rem;
}

.tagline {
  font-size: 1.1rem;
  opacity: 0.9;
  margin-bottom: 3rem;
}

.headline {
  font-size: 2.5rem;
  margin-bottom: 1rem;
  font-weight: 600;
}

.subheadline {
  font-size: 1.3rem;
  margin-bottom: 2rem;
  opacity: 0.95;
}

.cta-button {
  display: inline-block;
  background: white;
  color: var(--primary);
  padding: 15px 40px;
  text-decoration: none;
  border-radius: 50px;
  font-size: 1.1rem;
  font-weight: 600;
  transition: transform 0.3s, box-shadow 0.3s;
  border: none;
  cursor: pointer;
}

.cta-button:hover {
  transform: translateY(-2px);
  box-shadow: 0 10px 20px rgba(0,0,0,0.2);
}

/* Problem Section */
.problem {
  padding: 60px 20px;
  background: var(--bg-light);
}

.problem h2 {
  text-align: center;
  font-size: 2.5rem;
  margin-bottom: 1rem;
}

.problem > .container > p {
  text-align: center;
  font-size: 1.2rem;
  max-width: 800px;
  margin: 0 auto 3rem;
  color: var(--text-light);
}

.problem-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 2rem;
}

.problem-item {
  background: white;
  padding: 2rem;
  border-radius: 10px;
  text-align: center;
  box-shadow: 0 2px 10px rgba(0,0,0,0.05);
}

.problem-item .icon {
  font-size: 3rem;
  display: block;
  margin-bottom: 1rem;
}

.problem-item h3 {
  margin-bottom: 0.5rem;
  color: var(--primary);
}

/* Solution Section */
.solution {
  padding: 60px 20px;
}

.solution h2 {
  text-align: center;
  font-size: 2.5rem;
  margin-bottom: 1rem;
}

.solution > .container > p {
  text-align: center;
  font-size: 1.2rem;
  max-width: 800px;
  margin: 0 auto 3rem;
  color: var(--text-light);
}

.features {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 2rem;
}

.feature {
  text-align: center;
  padding: 2rem;
}

.feature .icon {
  font-size: 3rem;
  display: block;
  margin-bottom: 1rem;
}

.feature h3 {
  margin-bottom: 0.5rem;
  color: var(--primary);
}

/* Comparison Section */
.comparison {
  padding: 60px 20px;
  background: var(--bg-light);
}

.comparison h2 {
  text-align: center;
  font-size: 2.5rem;
  margin-bottom: 2rem;
}

.comparison-table {
  width: 100%;
  max-width: 800px;
  margin: 0 auto 2rem;
  background: white;
  border-radius: 10px;
  overflow: hidden;
  box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

.comparison-table th,
.comparison-table td {
  padding: 1rem;
  text-align: center;
}

.comparison-table thead {
  background: var(--primary);
  color: white;
}

.comparison-table tbody tr:nth-child(even) {
  background: var(--bg-light);
}

.comparison-table tbody tr td:first-child {
  text-align: left;
  font-weight: 500;
}

.price {
  text-align: center;
  font-size: 1.5rem;
  margin-top: 2rem;
}

.price strong {
  color: var(--primary);
  font-size: 2rem;
}

/* Calculator Section */
.calculator {
  padding: 60px 20px;
}

.calculator h2 {
  text-align: center;
  font-size: 2.5rem;
  margin-bottom: 2rem;
}

#analysisForm {
  max-width: 600px;
  margin: 0 auto;
  background: white;
  padding: 2rem;
  border-radius: 10px;
  box-shadow: 0 2px 20px rgba(0,0,0,0.1);
}

.form-group {
  margin-bottom: 1.5rem;
}

.form-group label {
  display: block;
  margin-bottom: 0.5rem;
  font-weight: 500;
}

.form-group input {
  width: 100%;
  padding: 0.75rem;
  border: 2px solid var(--border);
  border-radius: 5px;
  font-size: 1rem;
  transition: border-color 0.3s;
}

.form-group input:focus {
  outline: none;
  border-color: var(--primary);
}

.form-group small {
  display: block;
  margin-top: 0.25rem;
  color: var(--text-light);
  font-size: 0.9rem;
}

.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
}

.submit-button {
  width: 100%;
  padding: 1rem;
  background: var(--primary);
  color: white;
  border: none;
  border-radius: 5px;
  font-size: 1.1rem;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.3s;
}

.submit-button:hover {
  background: var(--primary-dark);
}

.submit-button:disabled {
  background: var(--text-light);
  cursor: not-allowed;
}

/* Results Section */
.results {
  max-width: 600px;
  margin: 3rem auto 0;
  padding: 2rem;
  background: white;
  border-radius: 10px;
  box-shadow: 0 2px 20px rgba(0,0,0,0.1);
}

.results.hidden {
  display: none;
}

.results h3 {
  text-align: center;
  margin-bottom: 1.5rem;
  color: var(--primary);
}

.result-content {
  margin-bottom: 2rem;
}

.status-badge {
  display: inline-block;
  padding: 0.5rem 1.5rem;
  border-radius: 50px;
  font-weight: 600;
  font-size: 1.2rem;
  margin-bottom: 1rem;
}

.status-badge.green {
  background: var(--success);
  color: white;
}

.status-badge.yellow {
  background: var(--warning);
  color: white;
}

.status-badge.red {
  background: var(--danger);
  color: white;
}

.result-message {
  margin: 1.5rem 0;
  padding: 1rem;
  background: var(--bg-light);
  border-left: 4px solid var(--primary);
  border-radius: 5px;
}

.upgrade-section {
  background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
  color: white;
  padding: 2rem;
  border-radius: 10px;
  text-align: center;
}

.upgrade-section h4 {
  margin-bottom: 1rem;
  font-size: 1.5rem;
}

.upgrade-section p {
  margin-bottom: 1.5rem;
  opacity: 0.95;
}

.upgrade-section .form-group {
  margin-bottom: 1.5rem;
  text-align: left;
}

.upgrade-section .form-group label {
  color: white;
}

.upgrade-section .cta-button {
  background: white;
  color: var(--primary);
}

/* Legal Section */
.legal {
  padding: 60px 20px;
  background: var(--bg-light);
}

.legal h2 {
  text-align: center;
  margin-bottom: 1rem;
}

.legal p {
  max-width: 800px;
  margin: 0 auto 1rem;
  text-align: justify;
  color: var(--text-light);
}

/* Footer */
footer {
  background: var(--text);
  color: white;
  padding: 2rem 20px;
  text-align: center;
}

/* Loading spinner */
.loading {
  display: inline-block;
  width: 20px;
  height: 20px;
  border: 3px solid rgba(255,255,255,.3);
  border-radius: 50%;
  border-top-color: white;
  animation: spin 1s ease-in-out infinite;
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

/* Responsive */
@media (max-width: 768px) {
  .headline {
    font-size: 2rem;
  }
  
  .subheadline {
    font-size: 1.1rem;
  }
  
  .form-row {
    grid-template-columns: 1fr;
  }
  
  .comparison-table {
    font-size: 0.9rem;
  }
  
  .comparison-table th,
  .comparison-table td {
    padding: 0.5rem;
  }
}

