:root {
  /* Tinder Brand Colors - Refined Palette */
  --tinder-pink: #fe3c72;
  --tinder-orange: #ff7854;
  --tinder-gradient: linear-gradient(262deg, #ff7854 0%, #fe3c72 100%);
  --bg-primary: #111418;
  --bg-secondary: #1a1e23;
  --bg-tertiary: #21262d;
  --text-primary: #ffffff;
  --text-secondary: #a0a0a0;
  --border-color: #30363d;
  --accent-blue: #2196f3;
  --accent-green: #4caf50;
  --accent-gold: #ffc107;
  
  --shadow-lg: 0 10px 30px rgba(0,0,0,0.5);
  --border-radius: 12px;
}

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

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  background-color: var(--bg-primary);
  color: var(--text-primary);
  line-height: 1.5;
  overflow: hidden; /* App feel */
  height: 100vh;
  display: flex;
}

/* Sidebar Navigation */
.sidebar {
  width: 375px;
  background-color: var(--bg-secondary);
  border-right: 1px solid var(--border-color);
  display: flex;
  flex-direction: column;
  height: 100vh;
  z-index: 100;
}

.sidebar-header {
  padding: 20px;
  background: var(--tinder-gradient);
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.profile-link {
  display: flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
  color: white;
  font-weight: 600;
}

.mini-avatar {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: #ccc;
  border: 2px solid white;
}

.sidebar-tabs {
  display: flex;
  padding: 10px 20px;
  gap: 20px;
  border-bottom: 1px solid var(--border-color);
}

.tab {
  padding: 10px 0;
  color: var(--text-secondary);
  text-decoration: none;
  font-weight: 600;
  font-size: 14px;
  position: relative;
}

.tab.active {
  color: var(--text-primary);
}

.tab.active::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  height: 3px;
  background: var(--tinder-pink);
  border-radius: 3px;
}

.matches-container {
  flex: 1;
  overflow-y: auto;
  padding: 15px;
}

.matches-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
  margin-bottom: 25px;
}

.match-item {
  aspect-ratio: 3/4;
  border-radius: 8px;
  background-color: var(--bg-tertiary);
  position: relative;
  overflow: hidden;
  cursor: pointer;
  transition: transform 0.2s;
}

.match-item:hover {
  transform: scale(1.05);
}

.match-name-overlay {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  padding: 5px;
  background: linear-gradient(transparent, rgba(0,0,0,0.8));
  font-size: 12px;
  font-weight: 600;
}

.messages-list {
  display: flex;
  flex-direction: column;
}

.message-preview {
  display: flex;
  align-items: center;
  gap: 15px;
  padding: 12px;
  border-radius: 8px;
  cursor: pointer;
  transition: background 0.2s;
  text-decoration: none;
  color: inherit;
}

.message-preview:hover, .message-preview.active {
  background: var(--bg-tertiary);
}

.message-avatar {
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background-color: var(--bg-tertiary);
  flex-shrink: 0;
}

.message-info {
  flex: 1;
  min-width: 0;
}

.message-name {
  font-weight: 700;
  font-size: 15px;
  margin-bottom: 2px;
}

.message-text {
  font-size: 13px;
  color: var(--text-secondary);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* Main Swipe Area */
.main-content {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 40px;
  position: relative;
  background: radial-gradient(circle at center, #1a1e23 0%, #111418 100%);
}

/* Chat Styling */
.chat-window {
  flex: 1;
  display: flex;
  flex-direction: column;
  height: 100vh;
  background: var(--bg-primary);
}

.chat-header {
  padding: 20px;
  border-bottom: 1px solid var(--border-color);
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: var(--bg-secondary);
}

.chat-user {
  display: flex;
  align-items: center;
  gap: 15px;
}

.chat-messages {
  flex: 1;
  overflow-y: auto;
  padding: 20px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.msg-bubble {
  max-width: 70%;
  padding: 12px 16px;
  border-radius: 18px;
  font-size: 15px;
}

.msg-bubble.received {
  background: var(--bg-tertiary);
  align-self: flex-start;
  border-bottom-left-radius: 4px;
}

.msg-bubble.sent {
  background: var(--tinder-gradient);
  color: white;
  align-self: flex-end;
  border-bottom-right-radius: 4px;
}

.chat-input-area {
  padding: 20px;
  border-top: 1px solid var(--border-color);
  display: flex;
  gap: 15px;
  background: var(--bg-secondary);
}

.chat-input {
  flex: 1;
  background: var(--bg-tertiary);
  border: 1px solid var(--border-color);
  border-radius: 25px;
  padding: 12px 20px;
  color: white;
  outline: none;
}

.chat-send-btn {
  width: auto;
  height: auto;
  border: none;
  background: transparent;
  color: var(--tinder-pink);
  font-weight: 700;
  cursor: pointer;
  padding: 0 10px;
}

.chat-avatar-small {
  width: 40px;
  height: 40px;
}

.chat-status-text {
  font-size: 12px;
  color: var(--accent-green);
}

.card-stack {
  position: relative;
  width: 100%;
  max-width: 400px;
  height: 600px;
  perspective: 1000px;
}

.swipe-card {
  position: absolute;
  width: 100%;
  height: 100%;
  border-radius: 12px;
  background-color: var(--bg-tertiary);
  box-shadow: var(--shadow-lg);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: transform 0.5s cubic-bezier(0.175, 0.885, 0.32, 1.275);
  cursor: grab;
}

.swipe-card:active {
  cursor: grabbing;
}

.card-profile-placeholder {
  font-size: 100px; 
  color: rgba(255,255,255,0.1);
}

.card-image-container {
  flex: 1;
  position: relative;
  background-size: cover;
  background-position: center;
}

.card-info-overlay {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  padding: 40px 20px 20px;
  background: linear-gradient(transparent, rgba(0,0,0,0.9));
  color: white;
}

.card-title {
  font-size: 32px;
  font-weight: 800;
  margin-bottom: 4px;
}

.card-meta {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 16px;
  margin-bottom: 12px;
}

.zodiac-badge {
  display: flex;
  align-items: center;
  gap: 6px;
  background: rgba(255,255,255,0.2);
  padding: 4px 10px;
  border-radius: 20px;
  font-size: 13px;
  font-weight: 500;
}

.zodiac-badge img {
  width: 18px;
  height: 18px;
  filter: invert(1);
}

.card-actions {
  display: flex;
  justify-content: center;
  gap: 15px;
  padding: 20px;
  z-index: 10;
}

.action-btn {
  width: 60px;
  height: 60px;
  border-radius: 50%;
  border: 1px solid var(--border-color);
  background: var(--bg-secondary);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: transform 0.1s, border-color 0.2s;
  color: var(--text-primary);
}

.action-btn:hover {
  transform: scale(1.1);
}

.action-btn.undo { color: var(--accent-gold); }
.action-btn.dislike { color: var(--tinder-pink); font-size: 24px; }
.action-btn.star { color: var(--accent-blue); }
.action-btn.like { color: var(--accent-green); font-size: 24px; }
.action-btn.boost { color: #9c27b0; }

.action-btn.large {
  width: 70px;
  height: 70px;
}

/* Placeholders */
.placeholder-image {
  width: 100%;
  height: 100%;
  background: linear-gradient(45deg, #2c343f, #1a1e23);
  display: flex;
  align-items: center;
  justify-content: center;
}

.placeholder-icon {
  opacity: 0.3;
}

/* Utilities */
.status-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--accent-green);
  display: inline-block;
  margin-right: 4px;
}

/* Swiping states - Simulated for wireframe */
.card-swipe-right {
  transform: translate(150%, -20%) rotate(20deg);
  opacity: 0;
}

.card-swipe-left {
  transform: translate(-150%, -20%) rotate(-20deg);
  opacity: 0;
}

/* Keyboard Hints */
.keyboard-hints {
  position: absolute;
  bottom: 20px;
  display: flex;
  gap: 30px;
  color: var(--text-secondary);
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 1px;
}

.key-hint {
  display: flex;
  align-items: center;
  gap: 8px;
}

.key-cap {
  padding: 2px 6px;
  border: 1px solid var(--border-color);
  border-radius: 4px;
  background: var(--bg-tertiary);
}

.card-bio {
  font-size: 14px;
  opacity: 0.9;
}

.tinder-logo {
  height: 32px;
  margin-right: 10px;
}

.brand-section {
  display: flex;
  align-items: center;
  margin-bottom: 20px;
}

.new-matches-title {
  margin-bottom: 10px; 
  font-size: 14px; 
  font-weight: 700; 
  color: var(--tinder-pink); 
  text-transform: uppercase; 
  letter-spacing: 1px;
}

.sidebar-footer {
  padding: 20px;
  border-top: 1px solid var(--border-color);
  font-size: 11px;
  color: var(--text-secondary);
  text-align: center;
}

/* Responsive */
@media (max-width: 900px) {
  .sidebar {
    width: 100px;
  }
  .sidebar-header h2, .profile-link span, .tab span, .message-info {
    display: none;
  }
  .matches-grid {
    grid-template-columns: 1fr;
  }
}
