/* ProfilePro Styles - Dark Mode Dating Profile Audit Tool */

/* Import Google Fonts */
@import url('https://fonts.googleapis.com/css2?family=DM+Sans:wght@400;500;600;700&family=DM+Serif+Display&display=swap');

/* CSS Variables */
:root {
  --bg-primary: #0A0A0B;
  --bg-secondary: #141416;
  --bg-tertiary: #1C1C1F;
  --accent-gold: #E5A93D;
  --text-primary: #FAFAFA;
  --text-secondary: #A1A1A6;
  --success: #34C759;
  --warning: #FF9500;
  --error: #FF3B30;
  --card-radius: 16px;
  --button-radius: 8px;
  --container-max: 960px;
}

/* Reset */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

/* Base */
html {
  font-size: 16px;
  scroll-behavior: smooth;
}

body {
  font-family: 'DM Sans', -apple-system, BlinkMacSystemFont, sans-serif;
  background-color: var(--bg-primary);
  color: var(--text-primary);
  line-height: 1.6;
  min-height: 100vh;
}

/* Typography */
h1, h2, h3 {
  font-family: 'DM Serif Display', serif;
  line-height: 1.2;
}

h1 {
  font-size: 2.5rem;
}

h2 {
  font-size: 1.75rem;
}

h3 {
  font-size: 1.25rem;
}

p {
  color: var(--text-secondary);
}

/* Container */
.container {
  max-width: var(--container-max);
  margin: 0 auto;
  padding: 0 1.5rem;
}

/* Navigation */
.nav {
  padding: 1.5rem 0;
  border-bottom: 1px solid var(--bg-tertiary);
}

.nav-content {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.logo {
  font-family: 'DM Serif Display', serif;
  font-size: 1.5rem;
  color: var(--text-primary);
  text-decoration: none;
}

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

.nav-link {
  color: var(--text-secondary);
  text-decoration: none;
  font-weight: 500;
  transition: color 0.2s ease;
}

.nav-link:hover {
  color: var(--accent-gold);
}

/* Hero Section */
.hero {
  padding: 6rem 0 4rem;
  text-align: center;
}

.hero-content {
  animation: fadeUp 0.8s ease-out;
}

.hero h1 {
  margin-bottom: 1.5rem;
  font-size: 2.5rem;
}

.hero h1 span {
  color: var(--accent-gold);
}

.hero-subtitle {
  font-size: 1.25rem;
  color: var(--text-secondary);
  margin-bottom: 2.5rem;
  max-width: 600px;
  margin-left: auto;
  margin-right: auto;
}

/* Credentials Bar */
.credentials {
  display: flex;
  justify-content: center;
  gap: 2rem;
  flex-wrap: wrap;
  margin-bottom: 3rem;
  padding: 1.5rem;
  background: var(--bg-secondary);
  border-radius: var(--card-radius);
}

.credential {
  display: flex;
  flex-direction: column;
  align-items: center;
}

.credential-value {
  font-family: 'DM Serif Display', serif;
  font-size: 1.5rem;
  color: var(--accent-gold);
}

.credential-label {
  font-size: 0.875rem;
  color: var(--text-secondary);
}

/* Buttons */
.btn {
  display: inline-block;
  padding: 1rem 2rem;
  font-size: 1rem;
  font-weight: 600;
  text-decoration: none;
  border-radius: var(--button-radius);
  cursor: pointer;
  transition: all 0.2s ease;
  border: none;
  font-family: inherit;
}

.btn-primary {
  background: var(--accent-gold);
  color: var(--bg-primary);
}

.btn-primary:hover {
  background: #d49a2d;
  transform: translateY(-2px);
}

.btn-primary:disabled {
  background: var(--bg-tertiary);
  color: var(--text-secondary);
  cursor: not-allowed;
  transform: none;
}

.btn-secondary {
  background: var(--bg-secondary);
  color: var(--text-primary);
  border: 1px solid var(--bg-tertiary);
}

.btn-secondary:hover {
  background: var(--bg-tertiary);
}

/* How It Works Section */
.how-it-works {
  padding: 4rem 0;
}

.how-it-works h2 {
  text-align: center;
  margin-bottom: 3rem;
}

.steps {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 2rem;
}

.step {
  background: var(--bg-secondary);
  padding: 2rem;
  border-radius: var(--card-radius);
  text-align: center;
}

.step-number {
  width: 48px;
  height: 48px;
  background: var(--accent-gold);
  color: var(--bg-primary);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: 'DM Serif Display', serif;
  font-size: 1.25rem;
  margin: 0 auto 1rem;
}

.step h3 {
  margin-bottom: 0.75rem;
}

.step p {
  font-size: 0.9375rem;
}

/* Audit Page */
.audit-container {
  padding: 3rem 0;
  min-height: calc(100vh - 80px);
}

.audit-header {
  text-align: center;
  margin-bottom: 3rem;
}

.audit-header h1 {
  margin-bottom: 0.75rem;
}

/* Form Styles */
.audit-form {
  background: var(--bg-secondary);
  padding: 2rem;
  border-radius: var(--card-radius);
  max-width: 600px;
  margin: 0 auto;
}

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

.form-label {
  display: block;
  font-weight: 500;
  margin-bottom: 0.5rem;
  color: var(--text-primary);
}

.form-hint {
  font-size: 0.875rem;
  color: var(--text-secondary);
  margin-top: 0.25rem;
}

/* Photo Upload Zone */
.upload-zone {
  border: 2px dashed var(--bg-tertiary);
  border-radius: var(--card-radius);
  padding: 3rem 2rem;
  text-align: center;
  cursor: pointer;
  transition: all 0.2s ease;
  background: var(--bg-primary);
}

.upload-zone:hover,
.upload-zone.dragover {
  border-color: var(--accent-gold);
  background: rgba(229, 169, 61, 0.05);
}

.upload-zone-icon {
  font-size: 3rem;
  margin-bottom: 1rem;
}

.upload-zone h3 {
  margin-bottom: 0.5rem;
}

.upload-zone p {
  font-size: 0.875rem;
}

.file-input {
  display: none;
}

/* Photo Previews */
.photo-previews {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1rem;
  margin-top: 1rem;
}

.photo-preview {
  position: relative;
  aspect-ratio: 1;
  border-radius: 8px;
  overflow: hidden;
}

.photo-preview img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.photo-remove {
  position: absolute;
  top: 8px;
  right: 8px;
  width: 24px;
  height: 24px;
  background: var(--error);
  border: none;
  border-radius: 50%;
  color: white;
  font-size: 1rem;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  line-height: 1;
}

/* Bio Textarea */
.bio-textarea {
  width: 100%;
  min-height: 150px;
  padding: 1rem;
  background: var(--bg-primary);
  border: 1px solid var(--bg-tertiary);
  border-radius: var(--button-radius);
  color: var(--text-primary);
  font-family: inherit;
  font-size: 1rem;
  resize: vertical;
  transition: border-color 0.2s ease;
}

.bio-textarea:focus {
  outline: none;
  border-color: var(--accent-gold);
}

.bio-textarea::placeholder {
  color: var(--text-secondary);
}

/* Character Counter */
.char-counter {
  text-align: right;
  font-size: 0.75rem;
  color: var(--text-secondary);
  margin-top: 0.25rem;
}

/* Loading State */
.loading-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(10, 10, 11, 0.9);
  display: none;
  justify-content: center;
  align-items: center;
  z-index: 1000;
}

.loading-overlay.active {
  display: flex;
}

.loading-content {
  text-align: center;
}

.spinner {
  width: 60px;
  height: 60px;
  border: 3px solid var(--bg-tertiary);
  border-top-color: var(--accent-gold);
  border-radius: 50%;
  animation: spin 1s linear infinite;
  margin: 0 auto 1.5rem;
}

/* Results Section */
.results-section {
  display: none;
  max-width: 700px;
  margin: 0 auto;
}

.results-section.active {
  display: block;
  animation: fadeUp 0.6s ease-out;
}

/* Score Circle */
.score-container {
  display: flex;
  flex-direction: column;
  align-items: center;
  margin-bottom: 2rem;
}

.score-circle {
  position: relative;
  width: 180px;
  height: 180px;
}

.score-circle svg {
  transform: rotate(-90deg);
  width: 100%;
  height: 100%;
}

.score-circle circle {
  fill: none;
  stroke-width: 10;
  stroke-linecap: round;
}

.score-bg {
  stroke: var(--bg-tertiary);
}

.score-progress {
  stroke: var(--accent-gold);
  stroke-dasharray: 502;
  stroke-dashoffset: 502;
  transition: stroke-dashoffset 1.5s ease-out;
}

.score-value {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  text-align: center;
}

.score-number {
  font-family: 'DM Serif Display', serif;
  font-size: 3.5rem;
  color: var(--text-primary);
  line-height: 1;
}

.score-label {
  font-size: 0.875rem;
  color: var(--text-secondary);
}

/* Feedback Cards */
.feedback-card {
  background: var(--bg-secondary);
  border-radius: var(--card-radius);
  padding: 1.5rem;
  margin-bottom: 1.5rem;
}

.feedback-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 1rem;
}

.feedback-header h3 {
  font-family: 'DM Sans', sans-serif;
  font-weight: 600;
}

.score-dots {
  display: flex;
  gap: 6px;
}

.score-dot {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: var(--bg-tertiary);
}

.score-dot.filled {
  background: var(--accent-gold);
}

.feedback-items {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.feedback-item {
  display: flex;
  align-items: flex-start;
  gap: 0.75rem;
  padding: 0.75rem;
  background: var(--bg-primary);
  border-radius: 8px;
  opacity: 0;
  animation: fadeInItem 0.4s ease-out forwards;
}

.feedback-item:nth-child(1) { animation-delay: 0.1s; }
.feedback-item:nth-child(2) { animation-delay: 0.2s; }
.feedback-item:nth-child(3) { animation-delay: 0.3s; }
.feedback-item:nth-child(4) { animation-delay: 0.4s; }
.feedback-item:nth-child(5) { animation-delay: 0.5s; }

.feedback-icon {
  width: 20px;
  height: 20px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.75rem;
  flex-shrink: 0;
}

.feedback-icon.positive {
  background: rgba(52, 199, 89, 0.2);
  color: var(--success);
}

.feedback-icon.warning {
  background: rgba(255, 149, 0, 0.2);
  color: var(--warning);
}

.feedback-icon.negative {
  background: rgba(255, 59, 48, 0.2);
  color: var(--error);
}

.feedback-text {
  color: var(--text-primary);
  font-size: 0.9375rem;
}

/* Suggestions */
.suggestions-card {
  background: var(--bg-secondary);
  border-radius: var(--card-radius);
  padding: 1.5rem;
  margin-bottom: 2rem;
}

.suggestions-card h3 {
  font-family: 'DM Sans', sans-serif;
  font-weight: 600;
  margin-bottom: 1rem;
}

.suggestion-list {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.suggestion-item {
  display: flex;
  align-items: flex-start;
  gap: 0.75rem;
  opacity: 0;
  animation: fadeInItem 0.4s ease-out forwards;
}

.suggestion-item:nth-child(1) { animation-delay: 0.6s; }
.suggestion-item:nth-child(2) { animation-delay: 0.7s; }
.suggestion-item:nth-child(3) { animation-delay: 0.8s; }
.suggestion-item:nth-child(4) { animation-delay: 0.9s; }
.suggestion-item:nth-child(5) { animation-delay: 1s; }

.suggestion-number {
  width: 24px;
  height: 24px;
  background: var(--accent-gold);
  color: var(--bg-primary);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.75rem;
  font-weight: 600;
  flex-shrink: 0;
}

.suggestion-text {
  color: var(--text-primary);
  font-size: 0.9375rem;
  line-height: 1.5;
}

/* Retry Button Container */
.retry-container {
  text-align: center;
  margin-top: 2rem;
}

/* Footer */
.footer {
  padding: 2rem 0;
  border-top: 1px solid var(--bg-tertiary);
  text-align: center;
  margin-top: auto;
}

.footer p {
  font-size: 0.875rem;
}

/* Animations */
@keyframes fadeUp {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

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

@keyframes fadeInItem {
  from {
    opacity: 0;
    transform: translateX(-10px);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

/* Responsive */
@media (min-width: 768px) {
  h1 {
    font-size: 3.5rem;
  }

  .hero {
    padding: 8rem 0 5rem;
  }

  .hero h1 {
    font-size: 3.5rem;
  }

  .credentials {
    gap: 3rem;
  }

  .audit-form {
    padding: 2.5rem;
  }
}

@media (max-width: 480px) {
  .credentials {
    flex-direction: column;
    gap: 1rem;
  }

  .photo-previews {
    grid-template-columns: repeat(2, 1fr);
  }

  .score-circle {
    width: 150px;
    height: 150px;
  }

  .score-number {
    font-size: 2.75rem;
  }
}

/* Error State */
.error-message {
  background: rgba(255, 59, 48, 0.1);
  border: 1px solid var(--error);
  color: var(--error);
  padding: 1rem;
  border-radius: var(--button-radius);
  margin-bottom: 1.5rem;
  text-align: center;
  display: none;
}

.error-message.active {
  display: block;
}
