:root {
  --bg-dark: #0a0b0e;
  --bg-card: rgba(18, 20, 29, 0.75);
  --bg-card-hover: rgba(28, 31, 46, 0.85);
  --accent-red: #e50914;
  --accent-red-hover: #f40612;
  --accent-blue: #0070f3;
  --text-main: #f8fafc;
  --text-muted: #94a3b8;
  --border: rgba(255, 255, 255, 0.08);
  --border-focus: rgba(229, 9, 20, 0.5);
  --font: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  font-family: var(--font);
  -webkit-font-smoothing: antialiased;
}

body {
  background-color: var(--bg-dark);
  color: var(--text-main);
  min-height: 100vh;
  overflow-x: hidden;
  background-image: 
    radial-gradient(at 0% 0%, rgba(229, 9, 20, 0.12) 0px, transparent 50%),
    radial-gradient(at 100% 100%, rgba(0, 112, 243, 0.08) 0px, transparent 50%);
}

/* Header & Nav */
header {
  position: sticky;
  top: 0;
  z-index: 100;
  backdrop-filter: blur(20px);
  background: rgba(10, 11, 14, 0.8);
  border-bottom: 1px solid var(--border);
  padding: 0.8rem 2rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.brand {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  font-size: 1.4rem;
  font-weight: 800;
  letter-spacing: -0.5px;
  color: #fff;
  text-decoration: none;
}

.brand span {
  color: var(--accent-red);
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 1.2rem;
}

.nav-link {
  color: var(--text-muted);
  text-decoration: none;
  font-size: 0.95rem;
  font-weight: 500;
  transition: color 0.2s;
  cursor: pointer;
  padding: 0.4rem 0.6rem;
  border-radius: 6px;
}

.nav-link:hover, .nav-link.active {
  color: #fff;
  background: rgba(255, 255, 255, 0.05);
}

.user-badge {
  display: flex;
  align-items: center;
  gap: 0.8rem;
}

.plan-pill {
  padding: 0.2rem 0.6rem;
  border-radius: 12px;
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.plan-pill.premium { background: rgba(229, 9, 20, 0.2); color: #ff4d4d; border: 1px solid rgba(229, 9, 20, 0.4); }
.plan-pill.trial { background: rgba(245, 158, 11, 0.2); color: #fbbf24; border: 1px solid rgba(245, 158, 11, 0.4); }
.plan-pill.free { background: rgba(148, 163, 184, 0.2); color: #cbd5e1; border: 1px solid rgba(148, 163, 184, 0.4); }

/* Main Container */
.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 2.5rem 1.5rem;
}

/* Auth Cards */
.auth-box {
  max-width: 440px;
  margin: 4rem auto;
  background: var(--bg-card);
  backdrop-filter: blur(16px);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 2.5rem;
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.5);
}

.auth-tabs {
  display: flex;
  gap: 0.5rem;
  margin-bottom: 2rem;
  background: rgba(0, 0, 0, 0.3);
  padding: 0.3rem;
  border-radius: 10px;
}

.auth-tab {
  flex: 1;
  text-align: center;
  padding: 0.6rem;
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--text-muted);
  cursor: pointer;
  border-radius: 8px;
  transition: all 0.2s;
}

.auth-tab.active {
  background: var(--bg-card-hover);
  color: #fff;
  box-shadow: 0 2px 8px rgba(0,0,0,0.3);
}

.form-group {
  margin-bottom: 1.2rem;
}

.form-group label {
  display: block;
  font-size: 0.85rem;
  font-weight: 500;
  color: var(--text-muted);
  margin-bottom: 0.4rem;
}

.form-control {
  width: 100%;
  padding: 0.75rem 1rem;
  background: rgba(0, 0, 0, 0.4);
  border: 1px solid var(--border);
  border-radius: 8px;
  color: #fff;
  font-size: 0.95rem;
  transition: all 0.2s;
}

.form-control:focus {
  outline: none;
  border-color: var(--border-focus);
  box-shadow: 0 0 0 2px rgba(229, 9, 20, 0.2);
}

.btn {
  width: 100%;
  padding: 0.8rem 1.2rem;
  border: none;
  border-radius: 8px;
  font-size: 0.95rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
}

.btn-primary {
  background: var(--accent-red);
  color: #fff;
}

.btn-primary:hover {
  background: var(--accent-red-hover);
  transform: translateY(-1px);
}

.btn-secondary {
  background: rgba(255, 255, 255, 0.1);
  color: #fff;
}

.btn-secondary:hover {
  background: rgba(255, 255, 255, 0.15);
}

/* Netflix Profiles */
.profile-selection {
  text-align: center;
  padding: 3rem 1rem;
}

.profile-selection h1 {
  font-size: 2.5rem;
  font-weight: 700;
  margin-bottom: 2.5rem;
}

.profiles-grid {
  display: flex;
  justify-content: center;
  gap: 2rem;
  flex-wrap: wrap;
  margin-bottom: 3rem;
}

.profile-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.8rem;
  cursor: pointer;
  transition: transform 0.2s;
}

.profile-card:hover {
  transform: scale(1.08);
}

.profile-avatar {
  width: 130px;
  height: 130px;
  border-radius: 8px;
  background-size: cover;
  background-position: center;
  border: 3px solid transparent;
  transition: border-color 0.2s;
  box-shadow: 0 8px 16px rgba(0,0,0,0.4);
}

.profile-card:hover .profile-avatar {
  border-color: #fff;
}

.profile-name {
  font-size: 1.1rem;
  color: var(--text-muted);
  font-weight: 500;
}

.profile-card:hover .profile-name {
  color: #fff;
}

/* Grid & Cards */
.grid-2 { display: grid; grid-template-columns: repeat(auto-fit, minmax(320px, 1fr)); gap: 1.5rem; }
.grid-3 { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 1.5rem; }

.card {
  background: var(--bg-card);
  backdrop-filter: blur(16px);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 1.5rem;
}

.card-title {
  font-size: 1.2rem;
  font-weight: 700;
  margin-bottom: 1rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

/* Toast */
.toast {
  position: fixed;
  bottom: 2rem;
  right: 2rem;
  background: rgba(18, 20, 29, 0.95);
  border: 1px solid var(--border);
  padding: 1rem 1.5rem;
  border-radius: 8px;
  box-shadow: 0 10px 25px rgba(0,0,0,0.5);
  z-index: 1000;
  display: none;
  font-size: 0.9rem;
}

.toast.show { display: block; animation: slideUp 0.3s forwards; }
@keyframes slideUp { from { transform: translateY(20px); opacity: 0; } to { transform: translateY(0); opacity: 1; } }
