/* AutoAlertMeli — minimal but clean */
:root {
  --fg:#1d1f23; --bg:#f6f7f9; --card:#fff; --muted:#6a6f78; --border:#e5e7eb;
  --accent:#1d1f23; --ok:#059669; --warn:#d97706; --danger:#dc2626; --dot-on:#10b981; --dot-off:#d1d5db;
}
* { box-sizing: border-box; }
html, body { margin:0; padding:0; }
body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  background: var(--bg); color: var(--fg); line-height: 1.5;
}
a { color: var(--fg); text-decoration: none; }
a:hover { text-decoration: underline; }

.topbar {
  display:flex; align-items:center; justify-content:space-between;
  padding: 14px 24px; background: #fff; border-bottom: 1px solid var(--border);
}
.brand { font-weight: 700; font-size: 17px; display:inline-flex; align-items:center; gap:8px; }
.brand-dot { width: 10px; height: 10px; border-radius: 50%; background: var(--accent); display:inline-block; }
.nav { display:flex; gap:14px; align-items:center; }
.nav a { font-size: 14px; color: var(--muted); }
.nav a:hover { color: var(--fg); }
.env-pill { background:#fef3c7; color:#92400e; padding:2px 8px; border-radius:999px; font-size:11px; font-weight:700; text-transform:uppercase; }

.container { max-width: 960px; margin: 0 auto; padding: 24px; }

.hero { text-align:center; padding: 40px 12px 24px; }
.hero h1 { font-size: 36px; margin: 0 0 12px; line-height:1.15; }
.hero .lead { color: var(--muted); font-size: 17px; max-width: 640px; margin: 0 auto 24px; }
.cta { display:flex; gap:10px; justify-content:center; flex-wrap:wrap; }

.features { display:grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 16px; padding: 24px 0; }
.feature { background:#fff; border:1px solid var(--border); border-radius:12px; padding:18px; }
.feature h3 { margin: 0 0 6px; font-size: 16px; }
.feature p { margin:0; color: var(--muted); font-size: 14px; }

.pricing { padding: 32px 0; }
.pricing h2 { text-align:center; }
.plans { display:grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 16px; padding: 12px 0; }
.plan { background:#fff; border:1px solid var(--border); border-radius:12px; padding:20px; }
.plan.featured { outline: 2px solid var(--accent); }
.plan h3 { margin: 0 0 6px; }
.plan .price { font-size: 28px; font-weight: 700; }
.plan .price span { font-size: 13px; color: var(--muted); font-weight: 400; }
.plan ul { padding-left: 18px; color: var(--muted); font-size: 14px; }
.trial-note { text-align:center; color:var(--muted); font-size: 13px; }

.btn { display:inline-block; padding: 10px 16px; border-radius: 10px; font-weight: 600; border: 1px solid var(--border); background: #fff; cursor: pointer; font-size: 14px; }
.btn:hover { border-color: #cbd5e1; text-decoration:none; }
.btn-primary { background: var(--accent); color: #fff; border-color: var(--accent); }
.btn-primary:hover { background: #000; }
.btn-primary[disabled] { opacity: .5; cursor: not-allowed; }
.btn-danger { background: var(--danger); color: #fff; border-color: var(--danger); }
.btn-ghost { background: transparent; }
.btn-sm { padding: 6px 10px; font-size: 13px; }
button.link { background:none; border:none; color: var(--muted); cursor:pointer; font-size: 13px; padding: 0; }
button.link:hover { color: var(--fg); text-decoration: underline; }
button.link.danger { color: var(--danger); }
.inline-form { display:inline-block; }

.auth-card { max-width: 420px; margin: 24px auto; background:#fff; border:1px solid var(--border); border-radius: 14px; padding: 24px; }
.auth-card h1 { margin-top: 0; }
.form { display:flex; flex-direction:column; gap:12px; }
.form label { display:flex; flex-direction:column; gap:4px; font-size: 13px; color: var(--muted); }
.form input[type="email"], .form input[type="text"], .form input[type="password"] {
  padding: 10px 12px; border-radius: 8px; border: 1px solid var(--border); font-size: 15px; color: var(--fg);
}
.form input:focus { outline: 2px solid #cbd5e1; outline-offset: 1px; }
.form .checkbox { flex-direction: row; align-items: center; gap: 8px; font-size: 13px; color: var(--fg); }
.muted { color: var(--muted); }
.small { font-size: 12px; }

.alert { padding: 10px 12px; border-radius: 8px; font-size: 14px; margin: 10px 0; }
.alert.error   { background:#fef2f2; color:#991b1b; border:1px solid #fecaca; }
.alert.success { background:#ecfdf5; color:#065f46; border:1px solid #a7f3d0; }
.alert.info    { background:#eff6ff; color:#1e40af; border:1px solid #bfdbfe; }

.dash-header { margin: 16px 0 18px; }
.dash-header h1 { margin: 0 0 6px; font-size: 24px; }
.sub-status { display:flex; gap:10px; align-items:center; flex-wrap:wrap; font-size: 14px; }

.badge { display:inline-block; padding: 2px 10px; border-radius: 999px; font-size: 11px; text-transform: uppercase; font-weight:700; }
.badge-trialing { background:#fef3c7; color:#92400e; }
.badge-active   { background:#dcfce7; color:#166534; }
.badge-none, .badge-canceled { background:#e5e7eb; color:#374151; }
.badge-past_due, .badge-paused { background:#fee2e2; color:#991b1b; }

.card { background:#fff; border:1px solid var(--border); border-radius:12px; padding: 18px; margin-bottom: 16px; }
.card-header { display:flex; align-items:center; justify-content:space-between; margin-bottom: 10px; }
.card-header h2 { margin: 0; font-size: 17px; }

.dot { display:inline-block; width: 8px; height: 8px; border-radius: 50%; margin-right: 6px; }
.dot.on { background: var(--dot-on); }
.dot.off { background: var(--dot-off); }

.searches-list, .hits { list-style:none; padding:0; margin:0; }
.searches-list li, .hits li { padding: 8px 0; border-bottom: 1px solid var(--border); }
.searches-list li:last-child, .hits li:last-child { border-bottom: 0; }

.data-table { width:100%; border-collapse: collapse; font-size: 14px; }
.data-table th, .data-table td { text-align:left; padding: 8px 6px; border-bottom: 1px solid var(--border); }
.data-table .row-actions { text-align:right; white-space:nowrap; }
.truncate { max-width: 360px; overflow:hidden; text-overflow: ellipsis; white-space: nowrap; display:block; }

.danger-zone { border-color: #fecaca; background: #fef9f9; }
.danger-zone h3 { color: var(--danger); margin-top: 0; }

.footer { max-width: 960px; margin: 30px auto 40px; padding: 0 24px;
          display:flex; justify-content:space-between; color: var(--muted); font-size: 12px; }
.footer a { color: var(--muted); }
