* { margin: 0; padding: 0; box-sizing: border-box; }
body { font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif; background: #1a1a2e; color: #eee; min-height: 100vh; }

/* Landing */
.landing { background: linear-gradient(135deg, #1a1a2e 0%, #0f0f23 100%); }
.landing-nav, nav.landing-nav { display: flex; justify-content: space-between; align-items: center; padding: 1.25rem 2rem; background: rgba(22,33,62,0.95); backdrop-filter: blur(10px); border-bottom: 1px solid #0f3460; position: sticky; top: 0; z-index: 100; }
.nav-brand { color: #e94560; font-size: 1.4rem; font-weight: 700; }
.nav-links { display: flex; gap: 1.5rem; align-items: center; }
.nav-links a { color: #ccc; text-decoration: none; font-size: 0.95rem; transition: color 0.2s; }
.nav-links a:hover { color: #e94560; }

.hero { text-align: center; padding: 6rem 2rem 4rem; }
.hero h1 { font-size: 3rem; color: #fff; line-height: 1.2; margin-bottom: 1rem; }
.hero p { color: #aaa; font-size: 1.2rem; line-height: 1.6; margin-bottom: 2.5rem; }
.hero-buttons { display: flex; gap: 1rem; justify-content: center; flex-wrap: wrap; }

.features, .how-it-works, .pricing, .cta { padding: 5rem 2rem; max-width: 1200px; margin: 0 auto; }
.features h2, .how-it-works h2, .pricing h2, .cta h2 { text-align: center; font-size: 2rem; color: #fff; margin-bottom: 3rem; }

.features-grid, .pricing-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 1.5rem; }
.feature-card { background: #16213e; padding: 2rem; border-radius: 12px; border: 1px solid #0f3460; transition: transform 0.2s; }
.feature-card:hover { transform: translateY(-4px); border-color: #e94560; }
.feature-card h3 { color: #e94560; margin-bottom: 0.75rem; }

.steps { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 2rem; }
.step { text-align: center; }
.step-num { width: 50px; height: 50px; background: #e94560; color: #fff; border-radius: 50%; display: flex; align-items: center; justify-content: center; font-size: 1.3rem; font-weight: 700; margin: 0 auto 1rem; }
.step h3 { color: #fff; margin-bottom: 0.5rem; }

.pricing-subtitle { text-align: center; color: #888; margin-bottom: 3rem; margin-top: -1.5rem; }
.pricing-card { background: #16213e; padding: 2.5rem 2rem; border-radius: 12px; border: 1px solid #0f3460; text-align: center; display: flex; flex-direction: column; }
.pricing-card.featured { border-color: #e94560; transform: scale(1.03); }
.pricing-card h3 { color: #fff; font-size: 1.3rem; margin-bottom: 1rem; }
.price { font-size: 2.5rem; color: #e94560; font-weight: 700; margin-bottom: 1.5rem; }
.price span { font-size: 1rem; color: #888; }
.pricing-card ul { list-style: none; margin-bottom: 2rem; flex: 1; }
.pricing-card ul li { padding: 0.5rem 0; color: #bbb; border-bottom: 1px solid #0f3460; }
.popular { background: #e94560; color: #fff; padding: 0.3rem 1rem; border-radius: 20px; font-size: 0.8rem; font-weight: 700; display: inline-block; margin-bottom: 1rem; }

.cta { text-align: center; }
.cta p { color: #aaa; margin-bottom: 2rem; }

.landing-footer { text-align: center; padding: 2rem; color: #666; font-size: 0.85rem; border-top: 1px solid #0f3460; }

/* Buttons */
.btn { padding: 0.6rem 1.25rem; border: none; border-radius: 6px; cursor: pointer; font-size: 0.95rem; font-weight: 600; transition: all 0.2s; }
.btn:hover { opacity: 0.85; }
.btn-primary { background: #e94560; color: #fff; }
.btn-secondary { background: #0f3460; color: #eee; }
.btn-outline { background: transparent; border: 2px solid #e94560; color: #e94560; }
.btn-danger { background: #dc3545; color: #fff; }
.btn-lg { padding: 0.85rem 2rem; font-size: 1.1rem; }
.btn-sm { padding: 0.35rem 0.75rem; font-size: 0.8rem; }
.btn-icon { background: none; border: none; color: #e94560; font-size: 1.5rem; cursor: pointer; padding: 0 0.5rem; }

/* Auth */
.auth-container { display: flex; justify-content: center; align-items: center; padding: 4rem 1rem; }
.auth-box { background: #16213e; padding: 2rem; border-radius: 12px; width: 100%; max-width: 420px; box-shadow: 0 10px 40px rgba(0,0,0,0.3); }
.auth-box h1 { color: #e94560; text-align: center; font-size: 1.8rem; margin-bottom: 0.3rem; }
.subtitle { text-align: center; color: #888; margin-bottom: 1.5rem; }
.auth-tabs { display: flex; gap: 0; margin-bottom: 1.5rem; }
.auth-tab { flex: 1; padding: 0.6rem; background: #0f3460; border: none; color: #888; cursor: pointer; font-size: 0.95rem; transition: 0.2s; }
.auth-tab:first-child { border-radius: 6px 0 0 6px; }
.auth-tab:last-child { border-radius: 0 6px 6px 0; }
.auth-tab.active { background: #e94560; color: #fff; }
.auth-form input { width: 100%; padding: 0.75rem; margin-bottom: 0.75rem; background: #0f3460; border: 1px solid transparent; border-radius: 6px; color: #eee; font-size: 0.95rem; }
.auth-form input:focus { outline: none; border-color: #e94560; }
.auth-form button { width: 100%; }
.error-message { color: #e94560; text-align: center; margin-bottom: 1rem; font-size: 0.9rem; }

/* App Layout */
.app-container { display: flex; height: calc(100vh - 56px); position: fixed; top: 56px; left: 0; right: 0; bottom: 0; }
.app-sidebar { width: 260px; background: #16213e; border-right: 1px solid #0f3460; display: flex; flex-direction: column; }
.sidebar-header { display: flex; justify-content: space-between; align-items: center; padding: 1rem; border-bottom: 1px solid #0f3460; }
.sidebar-header h3 { color: #e94560; font-size: 0.9rem; }
.room-list { flex: 1; overflow-y: auto; padding: 0.5rem; }
.room-item { padding: 0.75rem 1rem; border-radius: 6px; cursor: pointer; margin-bottom: 2px; transition: 0.15s; }
.room-item:hover { background: #0f3460; }
.room-item.active { background: #e94560; }
.room-item span { display: block; font-weight: 600; }
.room-item small { display: block; color: #888; font-size: 0.75rem; margin-top: 2px; }
.room-item.active small { color: rgba(255,255,255,0.7); }
.sidebar-footer { padding: 1rem; border-top: 1px solid #0f3460; }
.user-info { display: flex; justify-content: space-between; align-items: center; font-size: 0.9rem; }

.app-main { flex: 1; display: flex; flex-direction: column; background: #1a1a2e; }
.chat-header { display: flex; align-items: center; gap: 1rem; padding: 0.75rem 1.5rem; background: #16213e; border-bottom: 1px solid #0f3460; }
.chat-header h3 { color: #e94560; flex: 1; }
.chat-header span { color: #888; font-size: 0.85rem; }

.messages { flex: 1; overflow-y: auto; padding: 1rem 1.5rem; display: flex; flex-direction: column; gap: 0.5rem; }
.message { background: #16213e; padding: 0.75rem 1rem; border-radius: 8px; max-width: 75%; }
.msg-header { display: flex; justify-content: space-between; margin-bottom: 0.25rem; }
.msg-user { color: #e94560; font-weight: 700; font-size: 0.85rem; }
.msg-time { color: #555; font-size: 0.7rem; }
.msg-content { color: #ddd; line-height: 1.45; word-wrap: break-word; }

.message-input { display: flex; gap: 0.5rem; padding: 1rem 1.5rem; background: #16213e; border-top: 1px solid #0f3460; }
.message-input input { flex: 1; padding: 0.75rem; background: #0f3460; border: none; border-radius: 6px; color: #eee; font-size: 0.95rem; }
.message-input input:focus { outline: 1px solid #e94560; }
.message-input button { padding: 0.75rem 1.5rem; background: #e94560; color: #fff; border: none; border-radius: 6px; cursor: pointer; font-weight: 700; }
.message-input button:hover { background: #c73e54; }

/* Modals */
.modal { display: none; position: fixed; top: 0; left: 0; width: 100%; height: 100%; background: rgba(0,0,0,0.7); z-index: 200; justify-content: center; align-items: center; }
.modal-content { background: #16213e; padding: 2rem; border-radius: 12px; width: 90%; max-width: 500px; max-height: 80vh; overflow-y: auto; border: 1px solid #0f3460; }
.modal-content h3 { color: #e94560; margin-bottom: 1.25rem; }
.modal-buttons { display: flex; gap: 0.75rem; justify-content: flex-end; margin-top: 1.5rem; }
.form-group { margin-bottom: 1rem; }
.form-group label { display: block; margin-bottom: 0.4rem; color: #aaa; font-size: 0.9rem; }
.form-group input, .form-group textarea, .form-group select { width: 100%; padding: 0.7rem; background: #0f3460; border: 1px solid transparent; border-radius: 6px; color: #eee; font-size: 0.95rem; }
.form-group input:focus, .form-group textarea:focus { outline: none; border-color: #e94560; }
.form-group textarea { min-height: 80px; resize: vertical; }
.form-group input[type="checkbox"] { width: auto; margin-right: 0.5rem; }
.invite-code-box { background: #0f3460; padding: 1rem; border-radius: 6px; font-family: monospace; font-size: 1.3rem; color: #e94560; text-align: center; margin: 1rem 0; word-break: break-all; }

.member-row { display: flex; justify-content: space-between; align-items: center; padding: 0.5rem 0; border-bottom: 1px solid #0f3460; }

.org-card { background: #0f3460; padding: 0.75rem; border-radius: 6px; margin-bottom: 0.5rem; display: flex; justify-content: space-between; align-items: center; gap: 0.5rem; }

.badge { padding: 0.2rem 0.6rem; border-radius: 12px; font-size: 0.75rem; font-weight: 700; }
.badge-free { background: #0f3460; color: #888; }
.badge-starter { background: #2d6a4f; color: #95d5b2; }
.badge-pro { background: #7b2d8b; color: #d4a5e5; }
.badge-enterprise { background: #8b6914; color: #ffd700; }

/* Admin Dashboard */
.admin-dash { display: flex; min-height: calc(100vh - 56px); }
.admin-sidebar { width: 220px; background: #16213e; border-right: 1px solid #0f3460; padding: 1rem; }
.admin-sidebar h3 { color: #e94560; margin-bottom: 1rem; }
.admin-nav-item { padding: 0.6rem 0.8rem; border-radius: 4px; cursor: pointer; margin-bottom: 2px; font-size: 0.9rem; transition: 0.15s; }
.admin-nav-item:hover { background: #0f3460; }
.admin-nav-item.active { background: #e94560; }
.admin-main { flex: 1; padding: 2rem; }
.admin-main h2 { color: #e94560; margin-bottom: 1.5rem; }
.stats-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: 1rem; margin-bottom: 2rem; }
.stat-card { background: #16213e; padding: 1.25rem; border-radius: 8px; border: 1px solid #0f3460; }
.stat-card .stat-label { color: #888; font-size: 0.8rem; margin-bottom: 0.3rem; }
.stat-card .stat-value { color: #e94560; font-size: 1.8rem; font-weight: 700; }
.data-table { width: 100%; border-collapse: collapse; background: #16213e; border-radius: 8px; overflow: hidden; }
.data-table th, .data-table td { padding: 0.75rem 1rem; text-align: left; border-bottom: 1px solid #0f3460; }
.data-table th { background: #0f3460; color: #e94560; font-size: 0.85rem; }
.data-table tr:hover { background: #1a1a3e; }
.settings-group { display: flex; flex-direction: column; gap: 1rem; max-width: 600px; }
.setting-row { display: flex; justify-content: space-between; align-items: center; background: #16213e; padding: 0.75rem 1rem; border-radius: 6px; border: 1px solid #0f3460; }
.setting-row .setting-key { color: #ccc; font-size: 0.9rem; }
.setting-row input, .setting-row select { background: #0f3460; border: none; color: #eee; padding: 0.4rem 0.6rem; border-radius: 4px; width: 200px; text-align: right; }

/* Directory */
.search-box { display: flex; gap: 1rem; margin-bottom: 2rem; }
.search-box input { flex: 1; padding: 0.75rem 1rem; background: #16213e; border: 1px solid #0f3460; border-radius: 6px; color: #eee; font-size: 1rem; }
.search-box input:focus { outline: none; border-color: #e94560; }
.rooms-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 1.25rem; }
.room-card-dir { background: #16213e; border-radius: 10px; border: 1px solid #0f3460; padding: 1.5rem; cursor: pointer; transition: 0.2s; }
.room-card-dir:hover { border-color: #e94560; transform: translateY(-2px); }
.room-card-dir h3 { color: #e94560; margin-bottom: 0.4rem; }
.room-card-dir .slug { color: #888; font-size: 0.85rem; margin-bottom: 0.5rem; }
.room-card-dir .desc { color: #bbb; line-height: 1.4; }
.room-card-dir .meta { margin-top: 0.75rem; color: #666; font-size: 0.8rem; }

/* Responsive */
@media (max-width: 768px) {
    .hero h1 { font-size: 2rem; }
    .app-sidebar { width: 200px; }
    .admin-sidebar { display: none; }
    .features-grid, .pricing-grid, .steps { grid-template-columns: 1fr; }
}
