/* ── Theme Variables ──────────────────────────────────────────────────────── */
/* Default = OnlyMIP → authentic OnlyFans LIGHT UI (white cards, cyan accent) */
:root {
  --bg:               #f3f6f8;
  --card-bg:          #ffffff;
  --input-bg:         #f1f4f7;
  --hover-bg:         #e9eef3;
  --text-primary:     #16191c;
  --text-muted:       #5a6b76;
  --text-dim:         #7c8a95;
  --text-dimmer:      #a7b1ba;
  --placeholder:      #9aa6ad;
  --accent:           #00aff0;
  --accent-hover:     #0098d4;
  --accent-light:     #0090c9;
  --accent-rgb:       0, 175, 240;
  --border:           rgba(0, 0, 0, 0.10);
  --border-hover:     rgba(0, 0, 0, 0.16);
  --border-nav:       rgba(0, 0, 0, 0.12);
  --border-nav-hover: rgba(0, 175, 240, 0.55);
  --input-border:     rgba(0, 0, 0, 0.14);
  --border-subtle:    rgba(0, 0, 0, 0.07);
  --btn-sec-bg:       #e9eef3;
  --btn-sec-hover:    #dce3e9;
  --progress-bg:      #e2e8ed;
  --btn-primary-text: #ffffff;
}

[data-theme="ua"] {
  --bg:               #0a0f1e;
  --card-bg:          #0f1a2e;
  --input-bg:         #162238;
  --hover-bg:         #1e2f45;
  --text-primary:     #f0f4f8;
  --text-muted:       #9ab0cc;
  --text-dim:         #6b8aaa;
  --text-dimmer:      #4a6a8a;
  --placeholder:      #4a6a8a;
  --accent:           #FFD700;
  --accent-hover:     #e6c200;
  --accent-light:     #ffe566;
  --accent-rgb:       255, 215, 0;
  --border:           rgba(0, 87, 183, 0.3);
  --border-hover:     rgba(0, 87, 183, 0.5);
  --border-nav:       rgba(255, 215, 0, 0.25);
  --border-nav-hover: rgba(255, 215, 0, 0.5);
  --input-border:     rgba(0, 87, 183, 0.4);
  --border-subtle:    rgba(0, 87, 183, 0.2);
  --btn-sec-bg:       #162238;
  --btn-sec-hover:    #1e2f45;
  --progress-bg:      #1e2f45;
  --btn-primary-text: #0a0f1e;
}

[data-theme="tpb"] {
  --bg:               #0d0d0d;
  --card-bg:          #1a1a1a;
  --input-bg:         #222222;
  --hover-bg:         #2a2a2a;
  --text-primary:     #f0f0f0;
  --text-muted:       #999999;
  --text-dim:         #666666;
  --text-dimmer:      #444444;
  --placeholder:      #555555;
  --accent:           #f0c000;
  --accent-hover:     #d4a800;
  --accent-light:     #f5d040;
  --accent-rgb:       240, 192, 0;
  --border:           rgba(240, 192, 0, 0.15);
  --border-hover:     rgba(240, 192, 0, 0.28);
  --border-nav:       rgba(240, 192, 0, 0.2);
  --border-nav-hover: rgba(240, 192, 0, 0.45);
  --input-border:     rgba(240, 192, 0, 0.2);
  --border-subtle:    rgba(240, 192, 0, 0.1);
  --btn-sec-bg:       #2a2a2a;
  --btn-sec-hover:    #333333;
  --progress-bg:      #2a2a2a;
  --btn-primary-text: #0d0d0d;
}

[data-theme="ph"] {
  --bg:               #1b1b1b;
  --card-bg:          #242424;
  --input-bg:         #2e2e2e;
  --hover-bg:         #383838;
  --text-primary:     #ffffff;
  --text-muted:       #999999;
  --text-dim:         #777777;
  --text-dimmer:      #555555;
  --placeholder:      #606060;
  --accent:           #ff9000;
  --accent-hover:     #e68000;
  --accent-light:     #ffaa33;
  --accent-rgb:       255, 144, 0;
  --border:           rgba(255, 144, 0, 0.15);
  --border-hover:     rgba(255, 144, 0, 0.28);
  --border-nav:       rgba(255, 144, 0, 0.2);
  --border-nav-hover: rgba(255, 144, 0, 0.45);
  --input-border:     rgba(255, 144, 0, 0.2);
  --border-subtle:    rgba(255, 144, 0, 0.1);
  --btn-sec-bg:       #333333;
  --btn-sec-hover:    #404040;
  --progress-bg:      #333333;
  --btn-primary-text: #fff;
}

[data-theme="spo"] {
  --bg:               #121212;
  --card-bg:          #181818;
  --input-bg:         #242424;
  --hover-bg:         #2a2a2a;
  --text-primary:     #ffffff;
  --text-muted:       #b3b3b3;
  --text-dim:         #8a8a8a;
  --text-dimmer:      #5a5a5a;
  --placeholder:      #6a6a6a;
  --accent:           #1ed760;
  --accent-hover:     #1fdf64;
  --accent-light:     #45e57f;
  --accent-rgb:       30, 215, 96;
  --border:           rgba(30, 215, 96, 0.15);
  --border-hover:     rgba(30, 215, 96, 0.30);
  --border-nav:       rgba(30, 215, 96, 0.22);
  --border-nav-hover: rgba(30, 215, 96, 0.50);
  --input-border:     rgba(30, 215, 96, 0.20);
  --border-subtle:    rgba(30, 215, 96, 0.10);
  --btn-sec-bg:       #242424;
  --btn-sec-hover:    #2e2e2e;
  --progress-bg:      #2a2a2a;
  --btn-primary-text: #06210f;
}

[data-theme="yt"] {
  --bg:               #f9f9f9;
  --card-bg:          #ffffff;
  --input-bg:         #f2f2f2;
  --hover-bg:         #ececec;
  --text-primary:     #0f0f0f;
  --text-muted:       #606060;
  --text-dim:         #808080;
  --text-dimmer:      #aaaaaa;
  --placeholder:      #909090;
  --accent:           #ff0000;
  --accent-hover:     #cc0000;
  --accent-light:     #ff3333;
  --accent-rgb:       255, 0, 0;
  --border:           rgba(0, 0, 0, 0.10);
  --border-hover:     rgba(255, 0, 0, 0.40);
  --border-nav:       rgba(0, 0, 0, 0.12);
  --border-nav-hover: rgba(255, 0, 0, 0.55);
  --input-border:     rgba(0, 0, 0, 0.14);
  --border-subtle:    rgba(0, 0, 0, 0.07);
  --btn-sec-bg:       #f2f2f2;
  --btn-sec-hover:    #e5e5e5;
  --progress-bg:      #e5e5e5;
  --btn-primary-text: #ffffff;
}

/* ── Reset ────────────────────────────────────────────────────────────────── */
* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', sans-serif;
  background: var(--bg);
  color: var(--text-primary);
  min-height: 100vh;
  padding: 20px;
}

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

h1 {
  text-align: center;
  font-size: 2rem;
  margin-bottom: 8px;
  color: var(--text-primary);
}

/* Page Header with nav */
.page-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 8px;
}

.page-header h1 {
  margin-bottom: 0;
}

.header-nav {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-shrink: 0;
}

.nav-link {
  color: var(--text-muted);
  text-decoration: none;
  font-size: 0.85rem;
  font-weight: 500;
  padding: 6px 14px;
  border-radius: 1000px;
  border: 1px solid var(--border-nav);
  transition: all 0.2s;
  white-space: nowrap;
}

.nav-link:hover {
  color: var(--text-primary);
  border-color: var(--border-nav-hover);
  background: var(--input-bg);
}

.title-link {
  color: var(--text-primary);
  text-decoration: none;
  transition: color 0.2s;
}

.title-link:hover {
  color: var(--accent);
}

/* Logo */
.logo-img {
  height: 2.8em;
  width: auto;
  max-height: 2.8em;
  vertical-align: middle;
  margin-right: 8px;
  border-radius: 8px;
}

/* Theme select dropdown */
.theme-select {
  background: none;
  cursor: pointer;
  font-family: inherit;
  appearance: none;
  -webkit-appearance: none;
  padding-right: 28px;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='6' viewBox='0 0 10 6'%3E%3Cpath d='M0 0l5 6 5-6z' fill='%238a96a3'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 10px center;
}

/* Footer */
.footer {
  text-align: center;
  padding: 24px 0 12px;
  font-size: 0.8rem;
}

.footer a {
  color: var(--text-dimmer);
  text-decoration: none;
  transition: color 0.2s;
}

.footer a:hover {
  color: var(--text-muted);
}

h2 {
  font-size: 1.3rem;
  margin-bottom: 12px;
  color: var(--text-primary);
}

.subtitle {
  text-align: center;
  color: var(--text-muted);
  margin-bottom: 24px;
}

.card {
  background: var(--card-bg);
  border-radius: 16px;
  padding: 20px;
  margin-bottom: 16px;
  border: 1px solid var(--border);
  transition: border-color 0.2s;
}

.card:hover {
  border-color: var(--border-hover);
}

/* ── Link Hub ─────────────────────────────────────────────────────────────── */
.link-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 16px;
}

.link-card {
  display: block;
  text-decoration: none;
  color: var(--text-primary);
  background: var(--card-bg);
  border-radius: 16px;
  padding: 20px;
  border: 1px solid var(--border);
  transition: border-color 0.2s, transform 0.15s;
}

.link-card:hover {
  border-color: var(--border-nav-hover);
  transform: translateY(-2px);
}

.link-card h2 {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 8px;
}

.link-card .link-emoji {
  font-size: 1.4rem;
  line-height: 1;
}

.link-card .link-desc {
  color: var(--text-muted);
  font-size: 0.92rem;
  margin-bottom: 10px;
}

.link-card .link-url {
  color: var(--accent);
  font-size: 0.85rem;
  font-weight: 500;
  word-break: break-all;
}

@media (max-width: 640px) {
  .link-grid {
    grid-template-columns: 1fr;
  }
  .page-header {
    flex-direction: column;
    gap: 12px;
  }
}

/* ── System-follow (Auto) ─────────────────────────────────────────────────── */
/* OnlyMIP brand in dark: same cyan accent on dark surfaces. Used when the
   visitor has no explicit theme choice and their OS prefers dark. */
[data-theme="dark-auto"] {
  --bg:               #101418;
  --card-bg:          #171d23;
  --input-bg:         #1d242b;
  --hover-bg:         #242d35;
  --text-primary:     #e6ebef;
  --text-muted:       #93a2ad;
  --text-dim:         #6f7f8a;
  --text-dimmer:      #4e5c66;
  --placeholder:      #5c6b75;
  --accent:           #00aff0;
  --accent-hover:     #33c1f5;
  --accent-light:     #66d1f8;
  --accent-rgb:       0, 175, 240;
  --border:           rgba(255, 255, 255, 0.10);
  --border-hover:     rgba(255, 255, 255, 0.16);
  --border-nav:       rgba(255, 255, 255, 0.12);
  --border-nav-hover: rgba(0, 175, 240, 0.55);
  --input-border:     rgba(255, 255, 255, 0.14);
  --border-subtle:    rgba(255, 255, 255, 0.07);
  --btn-sec-bg:       #1d242b;
  --btn-sec-hover:    #242d35;
  --progress-bg:      #242d35;
  --btn-primary-text: #ffffff;
}

/* Native form controls / scrollbars follow the active theme */
:root { color-scheme: light; }
[data-theme="yt"] { color-scheme: light; }
[data-theme="ua"], [data-theme="tpb"], [data-theme="ph"],
[data-theme="spo"], [data-theme="dark-auto"] { color-scheme: dark; }
