:root {
  --color-primary: #1a2744;
  --color-primary-light: #2d3a52;
  --color-accent: #0d9488;
  --color-accent-light: #14b8a6;
  --color-bg: #faf9f7;
  --color-card: #ffffff;
  --color-border: #e5e2dc;
  --color-text: #1a2744;
  --color-text-muted: #64748b;
  --color-warning: #f59e0b;
  --color-warning-bg: #fef3c7;
  --color-success: #10b981;
  --color-success-bg: #d1fae5;
}

/* Base resets & typography */
.article-page {
  font-family: 'Heebo', system-ui, sans-serif;
  background-color: var(--color-bg);
  color: var(--color-text);
  line-height: 1.7;
  font-size: 17px;
}

.article-page * {
  box-sizing: border-box;
}

.article-page h1,
.article-page h2,
.article-page h3,
.article-page h4,
.article-page h5,
.article-page h6 {
  font-family: 'Heebo', system-ui, sans-serif;
}

/* Header - simplified or removed if using base.html, keeping for reference or if used in content */
/*
.header {
  background: var(--color-card);
  border-bottom: 1px solid var(--color-border);
  position: sticky;
  top: 0;
  z-index: 100;
}
*/

/* Hero */
.hero {
  background: linear-gradient(180deg, var(--color-card) 0%, var(--color-bg) 100%);
  padding: 4rem 2rem 1.5rem;
  text-align: center;
}

.hero-badge-meta {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  color: var(--color-accent);
  font-weight: 600;
}

.hero h1 {
  font-size: clamp(2rem, 5vw, 3rem);
  font-weight: 800;
  color: var(--color-primary);
  margin-bottom: 1rem;
  line-height: 1.2;
}

.hero-subtitle {
  font-size: 1.2rem;
  color: var(--color-text-muted);
  max-width: 700px;
  margin: 0 auto 1.5rem;
}

.hero-meta {
  display: flex;
  justify-content: center;
  gap: 2rem;
  flex-wrap: wrap;
  color: var(--color-text-muted);
  font-size: 0.9rem;
}

.hero-meta span {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

/* Article Container */
.article-container {
  max-width: 800px;
  margin: 0 auto;
  padding: 1rem 2rem 3rem;
}

/* Table of Contents */
.toc {
  background: var(--color-card);
  border: 1px solid var(--color-border);
  border-radius: 12px;
  padding: 1.5rem 2rem;
  margin-bottom: 3rem;
}

.toc-title {
  font-size: 1rem;
  font-weight: 700;
  color: var(--color-primary);
  margin-bottom: 1rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.toc ol {
  list-style: none;
  counter-reset: toc-counter;
  padding-right: 0;
  /* Override default padding */
}

.toc li {
  counter-increment: toc-counter;
  margin-bottom: 0.5rem;
}

.toc li::before {
  content: counter(toc-counter) ".";
  color: var(--color-accent);
  font-weight: 600;
  margin-left: 0.5rem;
}

.toc a {
  color: var(--color-text);
  text-decoration: none;
  font-size: 0.95rem;
  transition: color 0.2s;
}

.toc a:hover {
  color: var(--color-accent);
}

/* Content Sections */
.intro {
  font-size: 1.15rem;
  color: var(--color-text);
  margin-bottom: 2rem;
  padding-bottom: 2rem;
  border-bottom: 1px solid var(--color-border);
}

.intro strong {
  color: var(--color-accent);
}

.article-container h2 {
  font-size: 1.75rem;
  font-weight: 700;
  color: var(--color-primary);
  margin: 3rem 0 1.5rem;
  padding-top: 1rem;
}

.article-container h3 {
  font-size: 1.25rem;
  font-weight: 600;
  color: var(--color-primary);
  margin: 2rem 0 1rem;
}

.article-container p {
  margin-bottom: 1.25rem;
}

/* Info Boxes */
.info-box {
  background: var(--color-card);
  border: 1px solid var(--color-border);
  border-radius: 12px;
  padding: 1.5rem;
  margin: 2rem 0;
}

.info-box.highlight {
  border-right: 4px solid var(--color-accent);
}

.info-box.warning {
  background: var(--color-warning-bg);
  border-color: var(--color-warning);
  border-right: 4px solid var(--color-warning);
}

.info-box.success {
  background: var(--color-success-bg);
  border-color: var(--color-success);
  border-right: 4px solid var(--color-success);
}

.info-box-title {
  font-weight: 700;
  margin-bottom: 0.75rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.info-box.warning .info-box-title {
  color: #b45309;
}

.info-box.success .info-box-title {
  color: #047857;
}

/* Comparison Cards */
.comparison-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 1.5rem;
  margin: 2rem 0;
}

.comparison-card {
  background: var(--color-card);
  border: 1px solid var(--color-border);
  border-radius: 12px;
  padding: 1.5rem;
}

.comparison-card.osek {
  border-top: 4px solid #94a3b8;
}

.comparison-card.company {
  border-top: 4px solid var(--color-accent);
}

.comparison-card h4 {
  font-size: 1.1rem;
  font-weight: 700;
  margin-bottom: 1rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.comparison-card.osek h4 {
  color: #475569;
}

.comparison-card.company h4 {
  color: var(--color-accent);
}

.comparison-card ul {
  list-style: none;
  padding-right: 0;
}

.comparison-card li {
  padding: 0.5rem 0;
  padding-right: 1.5rem;
  position: relative;
  font-size: 0.95rem;
}

.comparison-card li::before {
  content: "•";
  position: absolute;
  right: 0;
  color: var(--color-text-muted);
}

/* Advantages List */
.advantages-list {
  counter-reset: advantage-counter;
}

.advantage-item {
  background: var(--color-card);
  border: 1px solid var(--color-border);
  border-radius: 12px;
  padding: 1.5rem;
  margin-bottom: 1.5rem;
  position: relative;
}

.advantage-item::before {
  counter-increment: advantage-counter;
  content: counter(advantage-counter);
  position: absolute;
  top: -12px;
  right: 20px;
  width: 32px;
  height: 32px;
  background: var(--color-accent);
  color: white;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 0.9rem;
}

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

/* Data Table */
.table-wrapper {
  overflow-x: auto;
  margin: 2rem 0;
  border-radius: 12px;
  border: 1px solid var(--color-border);
}

.table-wrapper table {
  width: 100%;
  border-collapse: collapse;
  background: var(--color-card);
  font-size: 0.95rem;
}

.table-wrapper th {
  background: var(--color-primary);
  color: white;
  padding: 1rem;
  text-align: right;
  font-weight: 600;
}

.table-wrapper td {
  padding: 1rem;
  border-bottom: 1px solid var(--color-border);
  vertical-align: top;
}

.table-wrapper tr:last-child td {
  border-bottom: none;
}

.table-wrapper tr:nth-child(even) {
  background: #fafaf9;
}

.table-wrapper td:first-child {
  font-weight: 600;
  color: var(--color-primary);
  background: #f8f7f5;
}

/* CTA Box */
.cta-box {
  background: linear-gradient(135deg, var(--color-primary) 0%, var(--color-primary-light) 100%);
  border-radius: 16px;
  padding: 2.5rem;
  text-align: center;
  margin: 3rem 0;
  color: white;
}

.cta-box h3 {
  color: white;
  font-size: 1.5rem;
  margin-bottom: 1rem;
}

.cta-box p {
  opacity: 0.9;
  margin-bottom: 1.5rem;
}

.cta-button {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  background: var(--color-accent);
  color: white;
  padding: 1rem 2rem;
  border-radius: 8px;
  text-decoration: none;
  font-weight: 600;
  transition: all 0.2s;
}

.cta-button:hover {
  background: var(--color-accent-light);
  transform: translateY(-2px);
  color: white;
}

/* Stats Grid */
.stats-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1rem;
  margin: 2rem 0;
}

.stat-item {
  background: var(--color-card);
  border: 1px solid var(--color-border);
  border-radius: 12px;
  padding: 1.25rem;
  text-align: center;
}

.stat-value {
  font-size: 2rem;
  font-weight: 800;
  color: var(--color-accent);
  line-height: 1;
}

.stat-label {
  font-size: 0.85rem;
  color: var(--color-text-muted);
  margin-top: 0.5rem;
}

/* Conclusion */
.conclusion {
  background: var(--color-card);
  border: 2px solid var(--color-accent);
  border-radius: 16px;
  padding: 2rem;
  margin: 3rem 0;
}

.conclusion h2 {
  margin-top: 0;
  color: var(--color-accent);
}

/* Responsive */
@media (max-width: 768px) {
  .hero {
    padding: 2rem 1rem;
  }

  .article-container {
    padding: 2rem 1rem;
  }

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

  .stat-item {
    display: flex;
    align-items: center;
    gap: 1rem;
    text-align: right;
  }

  .stat-value {
    font-size: 1.5rem;
  }

  .article-container h2 {
    font-size: 1.5rem;
  }

  .cta-box {
    padding: 1.5rem;
  }

  .table-wrapper table {
    font-size: 0.85rem;
  }

  .table-wrapper th,
  .table-wrapper td {
    padding: 0.75rem 0.5rem;
  }
}

/* קונטיינר הטיזר */
.calculator-teaser-box {
  margin: 3rem 0;
  border: 1px solid #e5e7eb;
  border-radius: 16px;
  background: #ffffff;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.03);
  overflow: hidden;
  display: flex;
  flex-direction: row-reverse;
  /* RTL: Image (1st) on Left (End), Text (2nd) on Right (Start) */
  align-items: center;
  /* גובה מוגבל יותר כדי להקטין את הכל */
  max-height: 280px;
  background-color: #f8fafc;
}

/* אזור התמונה */
.teaser-visual {
  width: 30%;
  height: 100%;
  /* רקע ניטרלי */
  background: #f8fafc;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1rem;
  border-right: 1px solid #f1f5f9;
  /* הפרדה עדינה בין התמונה לטקסט - צד ימין */
  border-left: none;
  /* איפוס למקרה של שינוי כיוון */
}

.teaser-mask-img {
  width: auto;
  max-width: 100%;
  height: auto;
  max-height: 100%;
  object-fit: contain;
  /* מציג את כל התמונה ללא חיתוך */
  border: 1px solid #e2e8f0;
  /* מסגרת דקה לתמונה */
  border-radius: 8px;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.05);
}

/* ביטול הגרדיאנט */
.teaser-fade-gradient {
  display: none;
}

/* תוכן הטקסט */
.teaser-body {
  width: 60%;
  padding: 1.5rem 2rem;
  display: flex;
  flex-direction: column;
  justify-content: center;
  text-align: right;
  z-index: 5;
}

.teaser-body h3 {
  font-size: 1.35rem;
  /* קצת יותר קטן */
  color: #111827;
  margin-bottom: 0.5rem;
  line-height: 1.2;
}

.teaser-body p {
  color: #4b5563;
  margin-bottom: 1.25rem;
  font-size: 0.95rem;
  line-height: 1.5;
}

/* כפתור */
.secondary-glow {
  align-self: flex-start;
  box-shadow: 0 0 10px rgba(34, 197, 94, 0.15);
  transition: transform 0.2s ease;
  padding: 0.75rem 1.5rem;
  /* כפתור קצת יותר קטן */
  font-size: 0.95rem;
}

.secondary-glow:hover {
  transform: translateY(-2px);
}

/* התאמה למובייל */
@media (max-width: 640px) {
  .calculator-teaser-box {
    flex-direction: column;
    max-height: none;
    /* ביטול הגבלת הגובה במובייל */
  }

  .teaser-visual {
    width: 100%;
    height: auto;
    border-right: none;
    /* איפוס גבול במובייל */
    border-bottom: 1px solid #f1f5f9;
    padding: 1.5rem;
  }

  .teaser-mask-img {
    max-height: 200px;
  }

  .teaser-body {
    width: 100%;
    padding: 1.5rem;
    text-align: center;
    align-items: center;
  }

  .secondary-glow {
    align-self: center;
  }
}