:root {
  --bg-gradient: linear-gradient(135deg, #0c0712 0%, #1a0f26 50%, #0d0517 100%);
  --accent-pink: #ff4b82;
  --accent-purple: #9b51e0;
  --accent-gold: #ffd700;
  --card-bg: rgba(26, 16, 38, 0.7);
  --card-border: rgba(255, 75, 130, 0.25);
  --text-main: #ffffff;
  --text-muted: #b8a6ca;
  --success: #2ecc71;
  --error: #e74c3c;
}

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

body {
  font-family: 'Outfit', sans-serif;
  background: var(--bg-gradient);
  color: var(--text-main);
  min-height: 100vh;
  display: flex;
  justify-content: center;
  align-items: center;
  position: relative;
  overflow-x: hidden;
}

.background-glow {
  position: fixed;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 600px;
  height: 600px;
  background: radial-gradient(circle, rgba(255, 75, 130, 0.15) 0%, rgba(155, 81, 224, 0.1) 40%, transparent 70%);
  z-index: 0;
  pointer-events: none;
}

/* MUSIC CARD STYLES */
.music-card {
  border-color: rgba(255, 215, 0, 0.3);
  background: rgba(35, 18, 50, 0.75);
}

.player-body {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-bottom: 16px;
}

.disc-art {
  width: 64px;
  height: 64px;
  border-radius: 50%;
  background: radial-gradient(circle, #ff4b82 0%, #9b51e0 70%, #000 100%);
  border: 3px solid var(--accent-gold);
  display: flex;
  justify-content: center;
  align-items: center;
  font-size: 1.5rem;
  box-shadow: 0 0 15px rgba(255, 215, 0, 0.3);
  transition: transform 0.5s ease;
}

.disc-art.playing {
  animation: spin 3s linear infinite;
}

@keyframes spin {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}

.song-info h3 {
  font-size: 1.1rem;
  color: #fff;
  margin-bottom: 2px;
}

.song-info p {
  font-size: 0.85rem;
  color: var(--text-muted);
}

.btn-music-play {
  width: 100%;
  background: linear-gradient(135deg, #ffd700 0%, #ff4b82 100%);
  border: none;
  border-radius: 12px;
  padding: 12px;
  color: #000;
  font-weight: 700;
  font-size: 0.95rem;
  cursor: pointer;
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 8px;
  box-shadow: 0 4px 15px rgba(255, 215, 0, 0.3);
  transition: all 0.2s ease;
}

.btn-music-play:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(255, 215, 0, 0.5);
}

/* LOGIN OVERLAY */
.login-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background: rgba(12, 7, 18, 0.92);
  backdrop-filter: blur(12px);
  z-index: 999;
  display: flex;
  justify-content: center;
  align-items: center;
  padding: 20px;
}

.login-card {
  width: 100%;
  max-width: 420px;
  text-align: center;
  animation: fadeIn 0.4s ease;
}

.login-header .lock-icon {
  font-size: 2.8rem;
  margin-bottom: 8px;
  display: block;
}

.login-header h2 {
  font-family: 'Playfair Display', serif;
  color: var(--accent-gold);
  font-size: 1.8rem;
  margin-bottom: 8px;
}

.login-header p {
  color: var(--text-muted);
  font-size: 0.9rem;
  margin-bottom: 16px;
}

.auth-tabs {
  display: flex;
  gap: 10px;
  margin-bottom: 20px;
  border-bottom: 1px solid rgba(255,255,255,0.1);
  padding-bottom: 10px;
}

.tab-btn {
  flex: 1;
  background: none;
  border: none;
  color: var(--text-muted);
  font-size: 0.95rem;
  padding: 8px;
  cursor: pointer;
  border-radius: 8px;
  transition: all 0.2s;
}

.tab-btn.active {
  color: #fff;
  background: rgba(255, 75, 130, 0.2);
  font-weight: 600;
}

.btn-google {
  width: 100%;
  background: #ffffff;
  color: #333333;
  border: none;
  border-radius: 12px;
  padding: 12px;
  font-weight: 600;
  font-size: 0.95rem;
  cursor: pointer;
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 10px;
  transition: all 0.2s;
}

.btn-google img {
  width: 18px;
  height: 18px;
}

.btn-google:hover {
  background: #f1f1f1;
  transform: translateY(-1px);
}

.divider {
  display: flex;
  align-items: center;
  text-align: center;
  margin: 16px 0;
  color: var(--text-muted);
  font-size: 0.8rem;
}

.divider::before, .divider::after {
  content: '';
  flex: 1;
  border-bottom: 1px solid rgba(255,255,255,0.1);
}

.divider span {
  padding: 0 10px;
}

.logout-btn {
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.2);
  color: #fff;
  padding: 4px 10px;
  border-radius: 6px;
  font-size: 0.8rem;
  cursor: pointer;
  margin-left: 10px;
  transition: all 0.2s;
}

.logout-btn:hover {
  background: rgba(231, 76, 60, 0.3);
  border-color: var(--error);
}

.container {
  width: 100%;
  max-width: 600px;
  padding: 20px;
  z-index: 1;
}

.app-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 24px;
}

.logo h1 {
  font-family: 'Playfair Display', serif;
  font-size: 1.8rem;
  font-weight: 600;
}

.logo h1 span {
  color: var(--accent-pink);
}

.heart-icon {
  font-size: 1.5rem;
  margin-right: 8px;
}

.user-status {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.85rem;
  color: var(--text-muted);
  background: rgba(255, 255, 255, 0.05);
  padding: 6px 12px;
  border-radius: 20px;
  border: 1px solid rgba(255, 255, 255, 0.1);
}

.status-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #7f8c8d;
}

.status-dot.connected {
  background: var(--success);
  box-shadow: 0 0 8px var(--success);
}

.card {
  background: var(--card-bg);
  backdrop-filter: blur(16px);
  border: 1px solid var(--card-border);
  border-radius: 24px;
  padding: 24px;
  margin-bottom: 20px;
  box-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.37);
}

.card-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 16px;
}

.card-header h2 {
  font-size: 1.2rem;
  font-weight: 600;
}

.badge {
  font-size: 0.75rem;
  background: rgba(255, 75, 130, 0.15);
  color: var(--accent-pink);
  padding: 4px 10px;
  border-radius: 12px;
  border: 1px solid rgba(255, 75, 130, 0.3);
}

.presets-label {
  font-size: 0.85rem;
  color: var(--text-muted);
  margin-bottom: 8px;
}

.presets-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  margin-bottom: 20px;
}

.preset-btn {
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.1);
  color: var(--text-main);
  padding: 8px 12px;
  border-radius: 10px;
  font-size: 0.85rem;
  cursor: pointer;
  transition: all 0.2s ease;
  text-align: left;
}

.preset-btn:hover {
  background: rgba(255, 75, 130, 0.15);
  border-color: var(--accent-pink);
  transform: translateY(-1px);
}

.input-group {
  margin-bottom: 16px;
  display: flex;
  flex-direction: column;
  gap: 6px;
  text-align: left;
}

.input-group label {
  font-size: 0.85rem;
  color: var(--text-muted);
}

input[type="text"], input[type="email"], input[type="password"], textarea {
  width: 100%;
  background: rgba(0, 0, 0, 0.2);
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: 12px;
  padding: 12px;
  color: #fff;
  font-family: inherit;
  font-size: 0.95rem;
  outline: none;
  transition: border-color 0.2s;
}

input[type="text"]:focus, input[type="email"]:focus, input[type="password"]:focus, textarea:focus {
  border-color: var(--accent-pink);
  box-shadow: 0 0 10px rgba(255, 75, 130, 0.2);
}

.char-count {
  font-size: 0.75rem;
  color: var(--text-muted);
  text-align: right;
  margin-top: 4px;
}

.preview-box {
  background: rgba(0, 0, 0, 0.3);
  border: 1px dashed rgba(255, 255, 255, 0.15);
  border-radius: 16px;
  padding: 12px;
  margin-bottom: 20px;
}

.preview-title {
  font-size: 0.75rem;
  color: var(--accent-gold);
  margin-bottom: 8px;
}

.screen-mockup {
  background: #000;
  border: 2px solid var(--accent-pink);
  border-radius: 12px;
  padding: 12px;
  min-height: 90px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.mockup-header {
  font-size: 0.75rem;
  color: var(--accent-gold);
}

.mockup-text {
  font-size: 0.95rem;
  color: #fff;
  word-break: break-word;
  margin: 6px 0;
}

.mockup-sender {
  font-size: 0.75rem;
  color: var(--accent-pink);
  text-align: right;
}

.btn-primary {
  width: 100%;
  background: linear-gradient(135deg, var(--accent-pink) 0%, var(--accent-purple) 100%);
  border: none;
  border-radius: 12px;
  padding: 14px;
  color: #fff;
  font-weight: 600;
  font-size: 1rem;
  cursor: pointer;
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 8px;
  box-shadow: 0 4px 15px rgba(255, 75, 130, 0.4);
  transition: all 0.2s ease;
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(255, 75, 130, 0.6);
}

.btn-primary:disabled {
  opacity: 0.6;
  cursor: not-allowed;
}

.success-msg {
  margin-top: 12px;
  padding: 10px;
  background: rgba(46, 204, 113, 0.15);
  border: 1px solid var(--success);
  color: var(--success);
  border-radius: 10px;
  font-size: 0.85rem;
  text-align: center;
}

.error-msg {
  margin-bottom: 12px;
  padding: 10px;
  background: rgba(231, 76, 60, 0.15);
  border: 1px solid var(--error);
  color: var(--error);
  border-radius: 10px;
  font-size: 0.85rem;
  text-align: center;
}

.hidden {
  display: none !important;
}

.history-card h3 {
  font-size: 1rem;
  margin-bottom: 12px;
}

.history-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.history-item {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 10px;
  padding: 10px 12px;
}

.msg-text {
  font-size: 0.9rem;
  margin-bottom: 4px;
}

.msg-meta {
  display: flex;
  justify-content: space-between;
  font-size: 0.75rem;
  color: var(--text-muted);
}

footer {
  text-align: center;
  font-size: 0.8rem;
  color: var(--text-muted);
  margin-top: 20px;
}

@keyframes fadeIn {
  from { opacity: 0; transform: scale(0.95); }
  to { opacity: 1; transform: scale(1); }
}
