/**
 * Public styles — fully scoped under .iptvdash-root to avoid theme conflicts.
 */
.iptvdash-root {
  --iptvdash-bg: #f6f7f9;
  --iptvdash-surface: #ffffff;
  --iptvdash-text: #1a1d26;
  --iptvdash-muted: #5c6575;
  --iptvdash-border: #d8dde6;
  --iptvdash-accent: #1f6feb;
  --iptvdash-accent-soft: #e8f0fe;
  --iptvdash-success: #0f7b4a;
  --iptvdash-danger: #b42318;
  --iptvdash-radius: 10px;
  box-sizing: border-box;
  color: var(--iptvdash-text);
  font-family: Georgia, "Times New Roman", Times, serif;
  max-width: 1100px;
  margin: 0 auto;
  padding: 1rem;
}

.iptvdash-root *,
.iptvdash-root *::before,
.iptvdash-root *::after {
  box-sizing: border-box;
}

.iptvdash-root .iptvdash-card,
.iptvdash-root .form-container,
.iptvdash-root .package-card {
  background: var(--iptvdash-surface);
  border: 1px solid var(--iptvdash-border);
  border-radius: var(--iptvdash-radius);
  box-shadow: 0 8px 24px rgba(20, 24, 36, 0.06);
}

/* Trial form */
.iptvdash-root.iptv-dashboard-trial-form .form-container {
  padding: 1.5rem;
  max-width: 520px;
  margin: 0 auto;
}

.iptvdash-root.iptv-dashboard-trial-form h2 {
  margin: 0 0 0.35rem;
  font-size: 1.6rem;
  font-weight: 700;
}

.iptvdash-root.iptv-dashboard-trial-form > .form-container > p,
.iptvdash-root .iptvdash-lead {
  color: var(--iptvdash-muted);
  margin: 0 0 1.25rem;
}

.iptvdash-root .form-group {
  margin-bottom: 1rem;
}

.iptvdash-root .form-group label {
  display: block;
  font-weight: 600;
  margin-bottom: 0.35rem;
  font-size: 0.95rem;
}

.iptvdash-root .form-group input[type="email"],
.iptvdash-root .form-group input[type="text"] {
  width: 100%;
  padding: 0.7rem 0.85rem;
  border: 1px solid var(--iptvdash-border);
  border-radius: 8px;
  font-size: 1rem;
  background: #fff;
  color: var(--iptvdash-text);
}

.iptvdash-root .form-group input:focus {
  outline: none;
  border-color: var(--iptvdash-accent);
  box-shadow: 0 0 0 3px var(--iptvdash-accent-soft);
}

.iptvdash-root .captcha-container {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  margin-bottom: 0.5rem;
}

.iptvdash-root .captcha-container img {
  height: 48px;
  border-radius: 6px;
  border: 1px solid var(--iptvdash-border);
}

.iptvdash-root .refresh-captcha {
  border: 1px solid var(--iptvdash-border);
  background: var(--iptvdash-bg);
  border-radius: 8px;
  width: 40px;
  height: 40px;
  cursor: pointer;
}

.iptvdash-root .button.button-primary,
.iptvdash-root .iptvdash-btn-primary,
.iptvdash-root .trial-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  padding: 0.75rem 1rem;
  border: 0;
  border-radius: 8px;
  background: var(--iptvdash-accent);
  color: #fff !important;
  font-weight: 700;
  text-decoration: none !important;
  cursor: pointer;
  font-size: 1rem;
}

.iptvdash-root .button.button-primary:hover,
.iptvdash-root .trial-button:hover {
  filter: brightness(1.05);
}

.iptvdash-root .form-message {
  margin-top: 0.75rem;
  padding: 0.65rem 0.8rem;
  border-radius: 8px;
}

.iptvdash-root .form-message.error {
  background: #fde8e6;
  color: var(--iptvdash-danger);
}

.iptvdash-root .form-message.success {
  background: #e6f6ee;
  color: var(--iptvdash-success);
}

.iptvdash-root .trial-success-container {
  text-align: center;
  padding: 1rem 0;
}

/* Packages */
.iptvdash-root.iptv-dashboard-packages .packages-row {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 1rem;
}

.iptvdash-root .package-card {
  position: relative;
  padding: 1.25rem;
  display: flex;
  flex-direction: column;
  gap: 0.85rem;
}

.iptvdash-root .package-card.popular {
  border-color: var(--iptvdash-accent);
  box-shadow: 0 10px 28px rgba(31, 111, 235, 0.15);
}

.iptvdash-root .popular-badge {
  position: absolute;
  top: 10px;
  right: 10px;
  background: var(--iptvdash-accent);
  color: #fff;
  font-size: 0.7rem;
  font-weight: 700;
  padding: 0.2rem 0.5rem;
  border-radius: 999px;
}

.iptvdash-root .package-name {
  margin: 0;
  font-size: 1.2rem;
}

.iptvdash-root .package-price {
  font-size: 1.6rem;
  font-weight: 700;
}

.iptvdash-root .original-price {
  color: var(--iptvdash-muted);
  font-size: 0.95rem;
  margin-right: 0.35rem;
}

.iptvdash-root .discount-price {
  color: var(--iptvdash-success);
}

.iptvdash-root .package-features ul {
  list-style: none;
  margin: 0;
  padding: 0;
}

.iptvdash-root .package-features li {
  display: flex;
  justify-content: space-between;
  gap: 0.5rem;
  padding: 0.35rem 0;
  border-bottom: 1px dashed var(--iptvdash-border);
  font-size: 0.9rem;
}

.iptvdash-root .feature-label {
  color: var(--iptvdash-muted);
}

.iptvdash-root .package-footer {
  margin-top: auto;
}

.iptvdash-root .no-packages {
  grid-column: 1 / -1;
  text-align: center;
  color: var(--iptvdash-muted);
  padding: 2rem;
}

/* Channels (scoped) */
.iptvdash-root .iptvdash-channel-grid,
.iptvdash-root .channel-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
  gap: 1rem;
}

.iptvdash-root .channel-card {
  background: var(--iptvdash-surface);
  border: 1px solid var(--iptvdash-border);
  border-radius: var(--iptvdash-radius);
  padding: 1rem;
  text-align: center;
}

.iptvdash-root .channel-logo {
  width: 72px;
  height: 72px;
  object-fit: contain;
  margin: 0 auto 0.5rem;
}

@media (max-width: 600px) {
  .iptvdash-root {
    padding: 0.75rem;
  }
}
