/* ================================================================
   DPIA Planes Modal — Pricing Comparison (Free vs Premium)
   Inspired by Google Workspace comparison modal style
   ================================================================ */

/* ---------- Overlay & wrapper ---------- */
.dpia-planes-modal {
  position: fixed;
  inset: 0;
  z-index: 9999;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
}

.dpia-planes-overlay {
  position: absolute;
  inset: 0;
  background: rgba(13, 15, 18, 0.55);
  backdrop-filter: blur(4px);
}

/* ---------- Card ---------- */
.dpia-planes-card {
  position: relative;
  background: var(--dpia-card-bg, #fff);
  border-radius: 20px;
  box-shadow: 0 8px 48px rgba(13, 15, 18, 0.18);
  width: 100%;
  max-width: 620px;
  max-height: 92vh;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  animation: dpia-slideUp 0.28s ease;
}

/* ---------- Header ---------- */
.dpia-planes-header {
  padding: 28px 28px 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  position: relative;
}

.dpia-planes-close {
  position: absolute;
  top: 0;
  right: 0;
  background: none;
  border: none;
  cursor: pointer;
  padding: 8px;
  color: var(--dpia-mid, #6b6860);
  border-radius: 50%;
  transition: background 0.2s;
  display: flex;
  align-items: center;
  justify-content: center;
}
.dpia-planes-close:hover {
  background: var(--dpia-cream, #ede9e0);
  color: var(--dpia-ink, #0d0f12);
}
.dpia-planes-close svg { width: 22px; height: 22px; }

.dpia-planes-logo {
  font-size: 1.5rem;
  font-weight: 800;
  color: var(--dpia-ink, #0d0f12);
  font-family: var(--dpia-font-display, 'Syne', sans-serif);
  letter-spacing: -0.5px;
  margin-bottom: 6px;
}
.dpia-planes-logo span {
  color: var(--dpia-accent, #d4521a);
}

.dpia-planes-title {
  font-size: 1.45rem;
  font-weight: 700;
  color: var(--dpia-ink, #0d0f12);
  font-family: var(--dpia-font-display, 'Syne', sans-serif);
  margin: 0 0 4px;
}

.dpia-planes-subtitle {
  font-size: 0.88rem;
  color: var(--dpia-mid, #6b6860);
  margin: 0 0 20px;
}

/* ---------- Tab switcher (Usuarios / Negocios) ---------- */
.dpia-planes-tabs {
  display: flex;
  background: var(--dpia-cream, #ede9e0);
  border-radius: 12px;
  padding: 4px;
  gap: 4px;
  margin: 0 28px 0;
  width: calc(100% - 56px);
}

.dpia-planes-tab {
  flex: 1;
  padding: 8px 12px;
  background: none;
  border: none;
  border-radius: 9px;
  font-size: 0.88rem;
  font-weight: 600;
  cursor: pointer;
  color: var(--dpia-mid, #6b6860);
  transition: background 0.2s, color 0.2s;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
}
.dpia-planes-tab svg { width: 16px; height: 16px; flex-shrink: 0; }
.dpia-planes-tab.active {
  background: #fff;
  color: var(--dpia-ink, #0d0f12);
  box-shadow: 0 1px 6px rgba(13, 15, 18, 0.1);
}

/* ---------- Column headers ---------- */
.dpia-planes-col-headers {
  display: grid;
  grid-template-columns: 1fr 120px 140px;
  gap: 0;
  padding: 18px 28px 10px;
  align-items: end;
}

.dpia-planes-col-headers .col-empty { /* spacer */ }

.dpia-planes-col-free {
  text-align: center;
  font-size: 0.82rem;
  font-weight: 700;
  color: var(--dpia-mid, #6b6860);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.dpia-planes-col-premium {
  text-align: center;
  background: var(--primary, #1f4e79);
  color: #fff;
  border-radius: 10px 10px 0 0;
  padding: 10px 8px 8px;
}
.dpia-planes-col-premium .col-label {
  font-size: 0.78rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  opacity: 0.85;
}
.dpia-planes-col-premium .col-upgrade {
  font-size: 0.85rem;
  font-weight: 800;
  margin-top: 2px;
  color: #fff;
}

/* ---------- Feature rows ---------- */
.dpia-planes-body {
  padding: 0 28px 8px;
}

.dpia-planes-section-title {
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.7px;
  color: var(--dpia-mid, #6b6860);
  padding: 12px 0 6px;
}

.dpia-planes-row {
  display: grid;
  grid-template-columns: 1fr 120px 140px;
  align-items: center;
  min-height: 44px;
  border-top: 1px solid var(--dpia-border, rgba(13,15,18,.1));
}
.dpia-planes-row:last-child {
  border-bottom: 1px solid var(--dpia-border, rgba(13,15,18,.1));
}

.dpia-planes-row-label {
  font-size: 0.88rem;
  color: var(--dpia-ink, #0d0f12);
  padding: 10px 0;
  line-height: 1.4;
}

.dpia-planes-cell {
  text-align: center;
  font-size: 0.88rem;
  color: var(--dpia-mid, #6b6860);
  padding: 10px 8px;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* Premium column highlight */
.dpia-planes-cell.premium-col {
  background: rgba(31, 78, 121, 0.06);
}

.dpia-planes-row:last-child .dpia-planes-cell.premium-col {
  border-radius: 0 0 0 0;
}

/* Icons */
.dpia-check {
  color: #22c55e;
  display: flex;
  align-items: center;
  justify-content: center;
}
.dpia-check svg { width: 19px; height: 19px; }

.dpia-cross {
  color: #d1d5db;
  display: flex;
  align-items: center;
  justify-content: center;
}
.dpia-cross svg { width: 17px; height: 17px; }

.dpia-value {
  font-weight: 600;
  font-size: 0.82rem;
  color: var(--dpia-ink, #0d0f12);
}

.dpia-value-premium {
  font-weight: 700;
  font-size: 0.82rem;
  color: var(--primary, #1f4e79);
}

/* ---------- Footer ---------- */
.dpia-planes-footer {
  padding: 16px 28px 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  border-top: 1px solid var(--dpia-border, rgba(13,15,18,.1));
  flex-wrap: wrap;
}

.dpia-planes-footer-info {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.83rem;
  color: var(--dpia-mid, #6b6860);
}
.dpia-planes-footer-info svg { width: 18px; height: 18px; color: var(--dpia-accent, #d4521a); }

.dpia-planes-cta {
  background: var(--primary, #1f4e79);
  color: #fff;
  border: none;
  border-radius: 10px;
  padding: 11px 24px;
  font-size: 0.9rem;
  font-weight: 700;
  cursor: pointer;
  transition: background 0.2s, transform 0.15s;
  display: flex;
  align-items: center;
  gap: 7px;
  white-space: nowrap;
}
.dpia-planes-cta:hover {
  background: var(--primary-dark, #153a5c);
  transform: translateY(-1px);
}
.dpia-planes-cta svg { width: 17px; height: 17px; }

/* ---------- Tab panels ---------- */
.dpia-planes-panel { display: none; }
.dpia-planes-panel.active { display: block; }

/* ---------- Responsive ---------- */
@media (max-width: 520px) {
  .dpia-planes-card {
    border-radius: 16px;
    max-height: 95vh;
  }
  .dpia-planes-header,
  .dpia-planes-body,
  .dpia-planes-footer {
    padding-left: 18px;
    padding-right: 18px;
  }
  .dpia-planes-tabs {
    margin: 0 18px;
    width: calc(100% - 36px);
  }
  .dpia-planes-col-headers {
    padding: 14px 18px 8px;
    grid-template-columns: 1fr 90px 110px;
  }
  .dpia-planes-row {
    grid-template-columns: 1fr 90px 110px;
  }
  .dpia-planes-title { font-size: 1.2rem; }
  .dpia-planes-footer {
    flex-direction: column;
    align-items: stretch;
    text-align: center;
  }
  .dpia-planes-cta { justify-content: center; }
}
