/* kiki.gay dating app — app chrome & components (loads after main site style.css) */

.app-body { display: flex; flex-direction: column; min-height: 100vh; }
.app-main { flex: 1; width: 100%; max-width: 1080px; padding: 34px 20px 60px; }

/* Nav */
.app-nav { background: rgba(22, 10, 46, 0.92); border-bottom: 1px solid rgba(196,181,232,0.15); position: sticky; top: 0; z-index: 50; backdrop-filter: blur(10px); }
.app-nav-inner { display: flex; align-items: center; justify-content: space-between; padding: 14px 20px; }
.app-logo { font-family: 'Sora', sans-serif; font-weight: 800; font-size: 1.35rem; color: #fff; text-decoration: none; letter-spacing: -0.02em; }
.app-logo span { color: var(--pink); }
.app-links { display: flex; align-items: center; gap: 22px; }
.app-links a { color: var(--muted); text-decoration: none; font-weight: 500; font-size: 0.95rem; position: relative; }
.app-links a:hover { color: #fff; }
.app-links .nav-cta { background: var(--grad-hot); color: #fff; padding: 9px 18px; border-radius: 999px; font-weight: 600; }
.nav-dot { position: absolute; top: -4px; right: -9px; width: 8px; height: 8px; border-radius: 50%; background: var(--pink); display: inline-block; }
@media (max-width: 720px) { .app-links { gap: 14px; } .app-links a:nth-child(3) { display: none; } }

/* Flash messages */
.flash { padding: 14px 20px; border-radius: 12px; margin-bottom: 22px; font-weight: 500; }
.flash-ok { background: rgba(61, 220, 151, 0.12); border: 1px solid rgba(61, 220, 151, 0.4); color: #9df0cf; }
.flash-error { background: rgba(255, 77, 141, 0.12); border: 1px solid rgba(255, 77, 141, 0.4); color: #ff8a9b; }

/* Cards & panels */
.panel { background: linear-gradient(160deg, #211048, #1a0c3c); border: 1px solid rgba(196,181,232,0.16); border-radius: 16px; padding: 30px; }
.panel h1, .panel h2 { margin-bottom: 8px; }
.panel .lead { color: var(--muted); margin-bottom: 22px; }

/* Forms */
.f-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.f-grid .full { grid-column: 1 / -1; }
.f-field label { display: block; font-size: 0.85rem; font-weight: 600; color: var(--muted); margin-bottom: 6px; }
.f-field input, .f-field select, .f-field textarea {
  width: 100%; padding: 12px 15px; border-radius: 10px; border: 1px solid rgba(196,181,232,0.22);
  background: rgba(255,255,255,0.04); color: #fff; font-family: inherit; font-size: 0.98rem; outline: none;
}
.f-field input:focus, .f-field select:focus, .f-field textarea:focus { border-color: var(--pink); }
.f-field textarea { min-height: 130px; resize: vertical; }
.f-hint { font-size: 0.78rem; color: var(--muted); margin-top: 5px; }
.f-error { color: #ff8a9b; font-size: 0.85rem; margin-top: 5px; font-weight: 600; }
@media (max-width: 680px) { .f-grid { grid-template-columns: 1fr; } }

/* Category chips (search + profile) */
.chip-row { display: flex; flex-wrap: wrap; gap: 8px; }
.chip { display: inline-flex; align-items: center; gap: 6px; padding: 8px 15px; border-radius: 999px; border: 1px solid rgba(196,181,232,0.22); background: rgba(255,255,255,0.05); font-size: 0.87rem; font-weight: 500; color: #fff; cursor: pointer; user-select: none; }
.chip input { display: none; }
.chip.on, .chip:has(input:checked) { background: rgba(255, 77, 141, 0.18); border-color: var(--pink); }

/* Search bar row */
.search-bar { display: flex; flex-wrap: wrap; gap: 12px; align-items: flex-end; }
.search-bar .f-field { min-width: 150px; }
.search-bar .f-field.grow { flex: 1; min-width: 220px; }

/* Result cards */
.result-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 18px; margin-top: 26px; }
.result-card { background: linear-gradient(160deg, #241049, #1a0c3c); border: 1px solid rgba(196,181,232,0.16); border-radius: 16px; padding: 22px; display: flex; gap: 16px; align-items: flex-start; transition: transform 0.15s ease, border-color 0.15s ease; }
.result-card:hover { transform: translateY(-2px); border-color: rgba(255,77,141,0.45); }
.result-card .avatar { width: 64px; height: 64px; border-radius: 50%; background: var(--grad-cool); display: flex; align-items: center; justify-content: center; font-weight: 800; font-size: 1.4rem; color: #fff; flex-shrink: 0; overflow: hidden; }
.result-card .avatar img { width: 100%; height: 100%; object-fit: cover; }
.result-card h3 { font-size: 1.05rem; margin-bottom: 2px; }
.result-card h3 a { color: #fff; text-decoration: none; }
.result-card h3 a:hover { color: var(--pink); }
.result-card .meta { font-size: 0.83rem; color: var(--muted); margin-bottom: 7px; }
.result-card .headline { font-size: 0.9rem; color: var(--ink); margin-bottom: 9px; }
.result-card .tags { display: flex; flex-wrap: wrap; gap: 6px; }
.result-card .tags span { font-size: 0.75rem; padding: 4px 10px; border-radius: 999px; background: rgba(139,92,246,0.16); border: 1px solid rgba(139,92,246,0.35); }

/* Profile view */
.profile-hero { display: flex; gap: 26px; align-items: flex-start; }
.profile-hero .avatar-big { width: 150px; height: 150px; border-radius: 20px; background: var(--grad-cool); display: flex; align-items: center; justify-content: center; font-size: 3rem; font-weight: 800; flex-shrink: 0; overflow: hidden; }
.profile-hero .avatar-big img { width: 100%; height: 100%; object-fit: cover; }
.profile-stats { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 10px; }
.profile-stats span { background: rgba(255,255,255,0.05); border: 1px solid rgba(196,181,232,0.2); padding: 6px 13px; border-radius: 999px; font-size: 0.83rem; color: var(--muted); }
@media (max-width: 640px) { .profile-hero { flex-direction: column; } }

/* Messaging */
.chat { display: flex; flex-direction: column; gap: 10px; max-height: 55vh; overflow-y: auto; padding: 6px; }
.bubble { max-width: 72%; padding: 11px 16px; border-radius: 16px; font-size: 0.95rem; line-height: 1.45; }
.bubble .when { display: block; font-size: 0.7rem; opacity: 0.6; margin-top: 4px; }
.bubble.them { background: rgba(255,255,255,0.06); border: 1px solid rgba(196,181,232,0.15); align-self: flex-start; }
.bubble.me { background: linear-gradient(135deg, #ff4d8d, #ff8a3d); align-self: flex-end; }
.thread-row { display: flex; justify-content: space-between; align-items: center; padding: 15px 18px; border-bottom: 1px solid rgba(196,181,232,0.1); text-decoration: none; color: #fff; }
.thread-row:hover { background: rgba(255,255,255,0.03); }
.thread-row .who { font-weight: 600; }
.thread-row .snippet { color: var(--muted); font-size: 0.87rem; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; max-width: 460px; }
.thread-row .when { font-size: 0.78rem; color: var(--muted); flex-shrink: 0; }
.unread-pill { background: var(--pink); color: #fff; font-size: 0.72rem; font-weight: 700; border-radius: 999px; padding: 2px 9px; margin-left: 8px; }

/* Membership / pricing */
.price-card { text-align: center; max-width: 420px; margin: 0 auto; }
.price-card .price { font-size: 3rem; font-weight: 800; font-family: 'Sora', sans-serif; letter-spacing: -0.03em; }
.price-card .per { color: var(--muted); margin-bottom: 20px; }
.price-card ul { list-style: none; text-align: left; margin: 20px 0 26px; display: flex; flex-direction: column; gap: 10px; }
.price-card ul li { padding-left: 26px; position: relative; color: var(--ink); font-size: 0.95rem; }
.price-card ul li::before { content: "✓"; position: absolute; left: 0; color: var(--green); font-weight: 700; }

/* Admin tables */
.a-table { width: 100%; border-collapse: collapse; font-size: 0.9rem; }
.a-table th { text-align: left; color: var(--muted); font-size: 0.78rem; text-transform: uppercase; letter-spacing: 0.06em; padding: 10px 12px; border-bottom: 1px solid rgba(196,181,232,0.2); }
.a-table td { padding: 10px 12px; border-bottom: 1px solid rgba(196,181,232,0.08); vertical-align: middle; }
.a-table form { display: inline; }
.a-btn { background: var(--grad-hot); color: #fff; border: none; padding: 7px 14px; border-radius: 999px; font-weight: 600; font-size: 0.82rem; cursor: pointer; font-family: inherit; }
.a-btn.ghost { background: rgba(255,255,255,0.07); border: 1px solid rgba(196,181,232,0.25); }

/* Misc */
.muted { color: var(--muted); }
.small { font-size: 0.85rem; }
.center { text-align: center; }
.mt-20 { margin-top: 20px; }
.mt-30 { margin-top: 30px; }
.app-footer { border-top: 1px solid rgba(196,181,232,0.12); padding: 22px 0; color: var(--muted); font-size: 0.85rem; }
.app-footer a { color: var(--muted); text-decoration: underline; }
.gate-blur { filter: blur(6px); pointer-events: none; user-select: none; }
.gate-overlay { text-align: center; padding: 40px 20px; border: 1px dashed rgba(255,77,141,0.4); border-radius: 16px; background: rgba(255,77,141,0.05); }

/* --- Dark dropdown lists (fixes white option popups) --- */
:root { color-scheme: dark; }
select option, select optgroup {
  background: #241342;
  color: #fff;
}
