/* ==========================================================================
   How It Works — Page-Specific Styles
   Extends landing.css patterns
   ========================================================================== */

/* ---- Audience Selector Cards ---- */
.hiw-audience-cards{
  display: flex;
  gap: 16px;
  margin-top: 32px;
  justify-content: center;
}
.hiw-audience-card{
  flex: 1;
  max-width: 320px;
  padding: 28px 24px;
  background: var(--card);
  border: 2px solid var(--border);
  border-radius: var(--radius);
  text-align: center;
  text-decoration: none;
  color: var(--text);
  transition: transform .15s ease, border-color .15s ease, box-shadow .15s ease;
  cursor: pointer;
}
.hiw-audience-card:hover{
  transform: translateY(-3px);
  border-color: rgba(15,23,42,.25);
  box-shadow: var(--shadow2);
}
.hiw-audience-icon{
  width: 48px;
  height: 48px;
  border-radius: 14px;
  background: rgba(15,23,42,.04);
  border: 1px solid var(--border);
  display: inline-grid;
  place-items: center;
  margin-bottom: 14px;
}
.hiw-audience-icon svg{
  width: 22px;
  height: 22px;
  fill: none;
  stroke: var(--text);
  stroke-width: 1.6;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.hiw-audience-card h3{
  font-size: 17px;
  margin-bottom: 6px;
}
.hiw-audience-card p{
  font-size: 13px;
  color: var(--text-muted);
}

/* ---- Shared Value Props ---- */
.hiw-values{
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 14px;
  margin-top: 24px;
}
.hiw-value{
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 16px;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius2);
}
.hiw-value-check{
  width: 22px;
  height: 22px;
  flex-shrink: 0;
  border-radius: 50%;
  background: rgba(15,23,42,.06);
  display: grid;
  place-items: center;
  margin-top: 1px;
}
.hiw-value-check svg{
  width: 12px;
  height: 12px;
  fill: none;
  stroke: var(--text);
  stroke-width: 2.5;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.hiw-value strong{
  font-size: 14px;
  display: block;
  margin-bottom: 2px;
}
.hiw-value p{
  font-size: 13px;
  color: var(--text-muted);
}

/* ---- Track Sections ---- */
.hiw-track{
  padding: 56px 0;
  border-top: 1px solid var(--border);
}
.hiw-track-label{
  display: inline-block;
  padding: 5px 12px;
  border-radius: 8px;
  font-weight: 800;
  font-size: 11px;
  letter-spacing: .5px;
  text-transform: uppercase;
  margin-bottom: 14px;
}
.hiw-track-label--agents{
  background: rgba(15,95,255,.08);
  color: rgba(15,95,255,.85);
  border: 1px solid rgba(15,95,255,.15);
}
.hiw-track-label--lo{
  background: rgba(124,58,237,.08);
  color: rgba(124,58,237,.85);
  border: 1px solid rgba(124,58,237,.15);
}

/* ---- Problem Callout ---- */
.hiw-problem{
  margin-top: 20px;
  padding: 20px 24px;
  background: rgba(15,23,42,.025);
  border: 1px solid var(--border);
  border-radius: var(--radius2);
  border-left: 3px solid rgba(15,23,42,.15);
}
.hiw-problem p{
  font-size: 14px;
  color: var(--text-muted);
  line-height: 1.55;
}

/* ---- Feature Grid ---- */
.hiw-features-grid{
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 14px;
  margin-top: 24px;
}
.hiw-feature-card{
  padding: 20px;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius2);
  transition: transform .15s ease, box-shadow .15s ease;
}
.hiw-feature-card:hover{
  transform: translateY(-2px);
  box-shadow: var(--shadow2);
}
.hiw-feature-num{
  display: inline-block;
  width: 26px;
  height: 26px;
  border-radius: 8px;
  background: rgba(15,23,42,.04);
  border: 1px solid rgba(15,23,42,.08);
  font-weight: 900;
  font-size: 12px;
  text-align: center;
  line-height: 24px;
  color: var(--text-muted);
  margin-bottom: 10px;
}
.hiw-feature-card h3{
  font-size: 15px;
  margin-bottom: 6px;
}
.hiw-feature-card p{
  font-size: 13px;
  color: var(--text-muted);
  line-height: 1.5;
}

/* ---- Mini Steps (track-specific) ---- */
.hiw-mini-steps{
  margin-top: 28px;
  counter-reset: mini-step;
}
.hiw-mini-step{
  display: flex;
  align-items: flex-start;
  gap: 14px;
  padding: 14px 0;
  border-bottom: 1px solid rgba(15,23,42,.06);
  counter-increment: mini-step;
}
.hiw-mini-step:last-child{
  border-bottom: none;
}
.hiw-mini-step-num{
  width: 28px;
  height: 28px;
  flex-shrink: 0;
  border-radius: 50%;
  background: #111;
  color: #fff;
  display: grid;
  place-items: center;
  font-weight: 900;
  font-size: 12px;
}
.hiw-mini-step strong{
  font-size: 14px;
  display: block;
  margin-bottom: 2px;
}
.hiw-mini-step p{
  font-size: 13px;
  color: var(--text-muted);
}

/* ---- Outcomes List ---- */
.hiw-outcomes{
  margin-top: 24px;
  list-style: none;
  padding: 0;
}
.hiw-outcomes li{
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: 10px 0;
  font-size: 14px;
  font-weight: 600;
  line-height: 1.45;
}
.hiw-outcomes li::before{
  content: '\2713';
  flex-shrink: 0;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: rgba(18,183,106,.08);
  color: #065f46;
  display: grid;
  place-items: center;
  font-size: 11px;
  font-weight: 900;
}

/* ---- Comparison Table ---- */
.hiw-table-wrap{
  margin-top: 24px;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}
.hiw-table{
  width: 100%;
  border-collapse: collapse;
  min-width: 560px;
  border: 1px solid var(--border);
  border-radius: var(--radius2);
  overflow: hidden;
}
.hiw-table thead th{
  padding: 16px 20px;
  font-weight: 800;
  font-size: 14px;
  text-align: left;
  border-bottom: 2px solid var(--border);
}
.hiw-table thead th:first-child{
  width: 40%;
}
.hiw-table thead th:not(:first-child){
  text-align: center;
  width: 30%;
}
.hiw-table tbody td{
  padding: 14px 20px;
  font-size: 13px;
  font-weight: 600;
  border-bottom: 1px solid rgba(15,23,42,.06);
}
.hiw-table tbody td:not(:first-child){
  text-align: center;
}
.hiw-table tbody tr:last-child td{
  border-bottom: none;
}
.hiw-table tbody tr:nth-child(even){
  background: rgba(15,23,42,.015);
}
.hiw-table .check{
  color: #065f46;
  font-size: 16px;
}
.hiw-table .dash{
  color: var(--text-muted);
  opacity: .4;
}

/* ---- Trust Line ---- */
.hiw-trust{
  margin-top: 16px;
  font-size: 12px;
  font-weight: 700;
  color: var(--text-muted);
  text-align: center;
}

/* ═══════════════════════════════════════════
   RESPONSIVE
   ═══════════════════════════════════════════ */
@media (max-width: 880px){
  .hiw-features-grid{
    grid-template-columns: 1fr;
  }
}
@media (max-width: 640px){
  .hiw-audience-cards{
    flex-direction: column;
    align-items: center;
  }
  .hiw-audience-card{
    max-width: 100%;
    width: 100%;
  }
  .hiw-values{
    grid-template-columns: 1fr;
  }
  .hiw-track{
    padding: 40px 0;
  }
}

/* ═══════════════════════════════════════════
   DARK MODE
   ═══════════════════════════════════════════ */
[data-theme="dark"] .hiw-audience-card{
  background: var(--card);
  border-color: rgba(255,255,255,.10);
}
[data-theme="dark"] .hiw-audience-card:hover{
  border-color: rgba(255,255,255,.20);
  box-shadow: 0 10px 26px rgba(0,0,0,.35);
}
[data-theme="dark"] .hiw-audience-icon{
  background: rgba(255,255,255,.06);
  border-color: rgba(255,255,255,.10);
}
[data-theme="dark"] .hiw-audience-icon svg{
  stroke: #e4e4e4;
}

[data-theme="dark"] .hiw-value{
  background: var(--card);
  border-color: rgba(255,255,255,.08);
}
[data-theme="dark"] .hiw-value-check{
  background: rgba(255,255,255,.08);
}
[data-theme="dark"] .hiw-value-check svg{
  stroke: #e4e4e4;
}

[data-theme="dark"] .hiw-track{
  border-top-color: rgba(255,255,255,.08);
}
[data-theme="dark"] .hiw-track-label--agents{
  background: rgba(100,160,255,.10);
  color: rgba(130,180,255,.85);
  border-color: rgba(100,160,255,.20);
}
[data-theme="dark"] .hiw-track-label--lo{
  background: rgba(160,100,255,.10);
  color: rgba(180,140,255,.85);
  border-color: rgba(160,100,255,.20);
}

[data-theme="dark"] .hiw-problem{
  background: rgba(255,255,255,.025);
  border-color: rgba(255,255,255,.08);
  border-left-color: rgba(255,255,255,.15);
}

[data-theme="dark"] .hiw-feature-card{
  background: var(--card);
  border-color: rgba(255,255,255,.08);
}
[data-theme="dark"] .hiw-feature-card:hover{
  box-shadow: 0 10px 26px rgba(0,0,0,.35);
}
[data-theme="dark"] .hiw-feature-num{
  background: rgba(255,255,255,.06);
  border-color: rgba(255,255,255,.10);
}

[data-theme="dark"] .hiw-mini-step{
  border-bottom-color: rgba(255,255,255,.06);
}
[data-theme="dark"] .hiw-mini-step-num{
  background: #e4e4e4;
  color: #141414;
}

[data-theme="dark"] .hiw-outcomes li::before{
  background: rgba(18,183,106,.12);
  color: #a7f3d0;
}

[data-theme="dark"] .hiw-table{
  border-color: rgba(255,255,255,.08);
}
[data-theme="dark"] .hiw-table thead th{
  border-bottom-color: rgba(255,255,255,.10);
}
[data-theme="dark"] .hiw-table tbody td{
  border-bottom-color: rgba(255,255,255,.06);
}
[data-theme="dark"] .hiw-table tbody tr:nth-child(even){
  background: rgba(255,255,255,.02);
}
[data-theme="dark"] .hiw-table .check{
  color: #a7f3d0;
}
