/* ============================================================
   PLUGIN PAGES — /plugins/<name>/, /get/, /download/
   Loaded after style.css; reuses its header, footer, buttons,
   labels and palette. Everything plugin-specific hangs off one
   variable set on <body>:

     <body class="plugin-page" style="--plugin:#4dd0e1; --plugin-rgb:77,208,225">

   Brand actions (download, get key) stay amber (.btn--primary);
   the plugin colour is for identity: badge, tags, glow, cards.
   ============================================================ */

.plugin-page {
  --plugin: #4dd0e1;
  --plugin-rgb: 77, 208, 225;
  --plugin-dim: rgba(var(--plugin-rgb), .14);
  --plugin-line: rgba(var(--plugin-rgb), .35);
  --font-name: 'Auverbrix', var(--font-display);
}

/* ---------- hero ---------- */
.p-hero {
  position: relative;
  padding: clamp(56px, 9vw, 112px) 0 clamp(40px, 6vw, 72px);
  border-bottom: 1px solid var(--line);
  background:
    radial-gradient(ellipse 60% 55% at 85% 0%, var(--plugin-dim), transparent 70%),
    radial-gradient(ellipse 40% 40% at 0% 100%, rgba(255,174,31,.06), transparent 70%);
}
.p-hero--compact { padding-bottom: clamp(28px, 4vw, 44px); }

.p-name {
  margin-top: 18px;
  font-family: var(--font-name);
  font-weight: 400;
  font-size: clamp(52px, 13vw, 148px);
  line-height: .9;
  letter-spacing: -0.01em;
  text-transform: uppercase;
  color: var(--text);
}
.p-hero--compact .p-name { font-size: clamp(40px, 9vw, 92px); }

.p-meta {
  margin-top: 26px;
  display: flex; align-items: center; flex-wrap: wrap; gap: 10px 16px;
  font-family: var(--font-mono); font-size: 12px; letter-spacing: .12em; text-transform: uppercase;
  color: var(--muted);
}
.p-meta .sep { color: var(--muted-2); }

.p-badge {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 6px 12px;
  border: 1px solid var(--plugin-line); border-radius: 999px;
  background: var(--plugin-dim);
  color: var(--plugin);
  font-family: var(--font-mono); font-size: 12px; letter-spacing: .08em; font-weight: 500;
}
.p-badge .led { background: var(--plugin); box-shadow: 0 0 6px 2px rgba(var(--plugin-rgb), .55); }

.p-lead { margin-top: 26px; max-width: 56ch; font-size: clamp(16px, 1.6vw, 19px); color: var(--muted); }

.p-actions { margin-top: 36px; display: flex; flex-wrap: wrap; align-items: center; gap: 12px 20px; }
.p-actions .mono { color: var(--muted-2); }

/* ---------- plugin art (placeholder until a real screenshot exists) ---------- */
.p-art {
  position: relative;
  aspect-ratio: 16 / 9;
  border: 1px solid var(--line); border-radius: var(--radius);
  overflow: hidden;
  background: var(--bg-2);
}
.p-art img { width: 100%; height: 100%; object-fit: cover; }
.p-art .ui-art { padding: clamp(20px, 4vw, 44px); }
.plugin-page .ui-art {
  background:
    radial-gradient(ellipse at 15% 0%, var(--plugin-dim), transparent 55%),
    radial-gradient(ellipse at 100% 100%, rgba(255,174,31,.06), transparent 50%),
    var(--bg-2);
}
.plugin-page .ui-art__tap {
  background: linear-gradient(180deg, var(--plugin), rgba(var(--plugin-rgb), .55) 70%, rgba(var(--plugin-rgb), .12));
}
.p-art .ui-art__bar { font-size: 11px; }
.p-art .ui-art__taps { height: 48%; gap: 12px; }
.p-art .ui-art__knob { width: 40px; height: 40px; }
.p-art .ui-art__knob::after { top: 5px; height: 12px; transform-origin: 50% 15px; }

/* feature list: reuses .principles; only the number takes the plugin colour */
.plugin-page .principles { grid-template-columns: repeat(4, 1fr); }
.plugin-page .principles .num { color: var(--plugin); }
@media (max-width: 960px) { .plugin-page .principles { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 560px) { .plugin-page .principles { grid-template-columns: 1fr; } }

/* ---------- key form (/get/) ---------- */
.p-form {
  max-width: 560px;
  padding: clamp(24px, 4vw, 36px);
  border: 1px solid var(--line); border-radius: var(--radius);
  background: var(--panel);
}
.p-form label.field {
  display: block; margin-bottom: 10px;
  font-family: var(--font-mono); font-size: 11px; letter-spacing: .16em; text-transform: uppercase;
  color: var(--muted);
}
.p-form input[type="email"] {
  width: 100%;
  padding: 14px 16px;
  border: 1px solid var(--line-2); border-radius: var(--radius);
  background: var(--bg);
  color: var(--text);
  font: 15px var(--font-mono);
  outline: none;
  transition: border-color .2s;
}
.p-form input[type="email"]:focus { border-color: var(--amber); }
.p-form input[type="email"]::placeholder { color: var(--muted-2); }

.p-check {
  margin: 20px 0 24px;
  display: flex; gap: 12px; align-items: flex-start;
  font-size: 14px; color: var(--muted); cursor: pointer;
}
.p-check input { margin-top: 4px; accent-color: var(--amber); flex: none; }

.p-form .btn { width: 100%; justify-content: center; }
.p-form .btn[disabled] { opacity: .5; pointer-events: none; }

.p-fine { margin-top: 18px; font-size: 13px; color: var(--muted-2); }
.p-fine a { color: var(--muted); border-bottom: 1px solid var(--line-2); }
.p-fine a:hover { color: var(--text); }

.p-msg { margin-top: 16px; font-size: 14px; }
.p-msg.error { color: var(--red); }

.p-sent {
  max-width: 560px;
  padding: clamp(24px, 4vw, 36px);
  border: 1px solid rgba(53,168,102,.35); border-radius: var(--radius);
  background:
    radial-gradient(ellipse at 0% 0%, var(--green-dim), transparent 60%),
    var(--panel);
}
.p-sent h2 { font-size: clamp(24px, 3vw, 32px); font-weight: 700; letter-spacing: -0.02em; }
.p-sent p { margin-top: 12px; color: var(--muted); }
.p-sent strong { color: var(--text); font-weight: 500; }
.p-sent a { color: var(--amber); }

/* ---------- download (/download/) ---------- */
.os-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
@media (max-width: 720px) { .os-grid { grid-template-columns: 1fr; } }

.os-card {
  display: flex; flex-direction: column;
  min-height: 320px;
  padding: clamp(22px, 3vw, 30px);
  border: 1px solid var(--line); border-radius: var(--radius);
  background: var(--panel);
  transition: border-color .2s, transform .2s;
}
.os-card--live { border-color: var(--plugin-line); box-shadow: 0 0 0 1px rgba(var(--plugin-rgb), .06), 0 24px 60px -30px rgba(var(--plugin-rgb), .35); }
.os-card--soon { opacity: .6; }
@media (max-width: 720px) { .os-card { min-height: 0; } }

.os-card__top { display: flex; justify-content: space-between; align-items: flex-start; gap: 16px; }
.os-card__icon { width: 30px; height: 30px; fill: var(--muted); }
.os-card--live .os-card__icon { fill: var(--plugin); }
.os-card__size { text-align: right; color: var(--muted-2); }
.os-card__size strong { display: block; margin-top: 4px; font-family: var(--font-display); font-size: 16px; letter-spacing: 0; text-transform: none; color: var(--text); }

.os-card h2 { margin-top: 28px; font-size: clamp(30px, 3.6vw, 40px); font-weight: 700; letter-spacing: -0.02em; line-height: 1; }
.os-card--soon h2 { color: var(--muted); }
.os-card__req { margin-top: 10px; color: var(--muted-2); }

.p-tags { margin-top: 18px; display: flex; flex-wrap: wrap; gap: 6px; }
.p-tag {
  padding: 4px 8px;
  border: 1px solid var(--line-2); border-radius: 4px;
  font-family: var(--font-mono); font-size: 11px; letter-spacing: .12em; text-transform: uppercase;
  color: var(--muted);
}
.p-tag--hl { border-color: var(--plugin-line); color: var(--plugin); }

.os-card .btn { margin-top: auto; width: 100%; justify-content: center; }
.os-card .p-tags + .btn { margin-top: 32px; }
.os-card__foot { margin-top: auto; padding-top: 32px; }
.os-card__foot .btn { margin-top: 0; }

.p-soon {
  padding: 4px 10px;
  border: 1px solid rgba(255,174,31,.35); border-radius: 999px;
  font-family: var(--font-mono); font-size: 11px; letter-spacing: .14em; text-transform: uppercase;
  color: var(--amber);
}

.p-note {
  margin-top: 12px;
  display: flex; gap: 16px; align-items: flex-start;
  padding: 20px 22px;
  border: 1px solid var(--line); border-radius: var(--radius);
  background: var(--panel);
  color: var(--muted); font-size: 15px;
}
.p-note svg { width: 22px; height: 22px; flex: none; margin-top: 2px; fill: none; stroke: var(--plugin); stroke-width: 1.8; stroke-linecap: round; }
.p-note strong { color: var(--text); font-weight: 500; }
.p-note a { color: var(--amber); }

.p-release {
  margin-top: 12px;
  display: flex; align-items: center; gap: 16px;
  padding: 16px 22px;
  border: 1px solid var(--line); border-radius: var(--radius);
  color: var(--muted-2);
}
.p-release strong { color: var(--text); font-weight: 500; }
.p-release .rule { flex: 1; height: 1px; background: var(--line); }
.p-release .sq { width: 8px; height: 8px; background: var(--plugin); flex: none; }
@media (max-width: 480px) { .p-release .rule { display: none; } .p-release { flex-wrap: wrap; } }
