@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700;800&display=swap');
* { margin: 0; padding: 0; box-sizing: border-box; }

:root {
  --bg-primary: #0C0C10;
  --bg-secondary: #14141A;
  --bg-tertiary: #1C1C24;
  --accent: #6366f1;
  --accent-glow: rgba(99, 102, 241, 0.3);
  --text-primary: #FFFFFF;
  --text-secondary: #A0A0B0;
  --border-light: rgba(255, 255, 255, 0.06);
  --border-medium: rgba(255, 255, 255, 0.1);
}

body {
  font-family: 'Inter', sans-serif;
  background: var(--bg-primary);
  color: var(--text-primary);
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  line-height: 1.5;
}

/* Ambient Background */
.ambient-bg {
  position: fixed;
  inset: 0;
  background: 
    radial-gradient(circle at 20% 30%, rgba(99, 102, 241, 0.12) 0%, transparent 50%),
    radial-gradient(circle at 80% 70%, rgba(236, 72, 153, 0.12) 0%, transparent 50%);
  pointer-events: none;
  z-index: 0;
}

/* Main Container */
.app-container {
  width: 100%;
  max-width: 1440px;
  margin: 0 auto;
  padding: 2rem;
  position: relative;
  z-index: 10;
}

/* Centered Header */
.header-center {
  text-align: center;
  max-width: 600px;
  margin: 0 auto 3rem auto;
}

/* Card Styles */
.card {
  background: rgba(20, 20, 28, 0.7);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1px solid var(--border-light);
  border-radius: 28px;
  box-shadow: 0 25px 40px -15px rgba(0, 0, 0, 0.6);
  transition: transform 0.3s ease, border-color 0.2s ease;
}

.card:hover {
  border-color: var(--border-medium);
}

.card-header {
  padding: 1.5rem 1.5rem 0.5rem 1.5rem;
  font-weight: 600;
  font-size: 0.9rem;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: var(--text-secondary);
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.card-content {
  padding: 1rem 1.5rem 1.5rem 1.5rem;
}

/* Centered Grid Layout */
.main-grid {
  display: grid;
  grid-template-columns: repeat(12, 1fr);
  gap: 1.5rem;
  margin-bottom: 2rem;
}

/* Center Column - Primary Focus */
.center-column {
  grid-column: span 4;
}

/* Input Styling */
.input-wrapper {
  position: relative;
  width: 100%;
  max-width: 300px;
  margin: 0 auto 2rem auto;
}

.hex-input {
  width: 100%;
  background: rgba(18, 18, 24, 0.9);
  border: 2px solid var(--border-medium);
  border-radius: 60px;
  color: white;
  font-size: 1.5rem;
  font-weight: 600;
  letter-spacing: 2px;
  padding: 1rem 1.5rem 1rem 3rem;
  outline: none;
  transition: all 0.2s ease;
  text-align: center;
  font-family: 'Inter', monospace;
}

.hex-input:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 4px var(--accent-glow);
}

.hex-prefix {
  position: absolute;
  left: 1.2rem;
  top: 50%;
  transform: translateY(-50%);
  color: var(--text-secondary);
  font-size: 1.3rem;
  font-weight: 600;
}

/* Color Preview Circle */
.preview-circle {
  width: 180px;
  height: 180px;
  border-radius: 50%;
  margin: 0 auto 1.5rem auto;
  border: 4px solid rgba(255, 255, 255, 0.1);
  box-shadow: 0 20px 30px -10px rgba(0, 0, 0, 0.6);
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.preview-circle:hover {
  transform: scale(1.02);
  border-color: rgba(255, 255, 255, 0.2);
}

/* Color Values Grid */
.values-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 0.75rem;
  margin: 1.5rem 0;
}

.value-item {
  background: rgba(18, 18, 24, 0.6);
  border: 1px solid var(--border-light);
  border-radius: 16px;
  padding: 1rem;
  cursor: pointer;
  transition: all 0.2s ease;
  text-align: center;
}

.value-item:hover {
  background: rgba(28, 28, 36, 0.8);
  border-color: var(--accent);
  transform: translateY(-2px);
}

.value-label {
  font-size: 0.7rem;
  color: var(--text-secondary);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-bottom: 0.25rem;
}

.value-text {
  font-family: 'Inter', monospace;
  font-weight: 600;
  font-size: 0.9rem;
}

/* Color Wheel - Centered */
.wheel-container {
  width: 240px;
  height: 240px;
  margin: 0 auto 1rem auto;
  position: relative;
}

.wheel-canvas {
  width: 100%;
  height: 100%;
  border-radius: 50%;
  cursor: crosshair;
  box-shadow: 0 15px 30px -10px rgba(0, 0, 0, 0.5);
}

.wheel-cursor-center {
  position: absolute;
  width: 20px;
  height: 20px;
  border: 3px solid white;
  border-radius: 50%;
  transform: translate(-50%, -50%);
  pointer-events: none;
  box-shadow: 0 0 0 2px rgba(0, 0, 0, 0.2);
  transition: all 0.05s ease;
}

/* Slider */
.slider-center {
  width: 100%;
  max-width: 200px;
  margin: 1rem auto;
}

.brightness-slider {
  width: 100%;
  height: 6px;
  border-radius: 3px;
  background: linear-gradient(to right, #000, #fff);
  -webkit-appearance: none;
}

.brightness-slider::-webkit-slider-thumb {
  -webkit-appearance: none;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: white;
  border: 2px solid var(--accent);
  cursor: pointer;
  transition: transform 0.1s ease;
}

.brightness-slider::-webkit-slider-thumb:hover {
  transform: scale(1.2);
}

/* Selected Color Bar */
.selected-color-bar {
  background: rgba(18, 18, 24, 0.8);
  border: 1px solid var(--border-light);
  border-radius: 60px;
  padding: 0.5rem;
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin-top: 1rem;
}

.selected-swatch {
  width: 48px;
  height: 48px;
  border-radius: 40px;
  border: 2px solid rgba(255, 255, 255, 0.1);
}

/* Harmonies Grid */
.harmonies-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 0.75rem;
  margin-top: 1rem;
}

.harmony-card {
  background: rgba(18, 18, 24, 0.6);
  border: 1px solid var(--border-light);
  border-radius: 16px;
  padding: 0.75rem;
}

.harmony-title {
  font-size: 0.65rem;
  color: var(--text-secondary);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-bottom: 0.5rem;
}

.harmony-swatches {
  display: flex;
  gap: 0.25rem;
}

.harmony-swatch {
  width: 28px;
  height: 28px;
  border-radius: 8px;
  cursor: pointer;
  transition: transform 0.2s ease;
}

.harmony-swatch:hover {
  transform: scale(1.2);
}

/* Stats Grid */
.stats-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 0.75rem;
  margin-bottom: 1rem;
}

.stat-card {
  background: rgba(18, 18, 24, 0.6);
  border: 1px solid var(--border-light);
  border-radius: 20px;
  padding: 1rem;
  text-align: center;
}

.stat-value-large {
  font-size: 2rem;
  font-weight: 700;
  line-height: 1.2;
}

/* Shades Bar */
.shades-container {
  display: flex;
  gap: 2px;
  background: rgba(0, 0, 0, 0.3);
  padding: 4px;
  border-radius: 60px;
  margin: 1rem 0;
}

.shade-item {
  height: 40px;
  flex: 1;
  cursor: pointer;
  transition: all 0.2s ease;
  border-radius: 30px;
}

.shade-item:hover {
  transform: translateY(-4px);
  box-shadow: 0 8px 16px rgba(0, 0, 0, 0.3);
}

/* History Row */
.history-row {
  display: flex;
  gap: 0.5rem;
  flex-wrap: wrap;
  justify-content: center;
  margin: 1rem 0;
}

.history-item {
  width: 44px;
  height: 44px;
  border-radius: 16px;
  cursor: pointer;
  border: 2px solid var(--border-light);
  transition: all 0.2s ease;
}

.history-item:hover {
  transform: translateY(-4px) scale(1.1);
  border-color: white;
  box-shadow: 0 8px 16px rgba(0, 0, 0, 0.4);
}

/* Press Grid */
.press-section {
  margin-top: 2rem;
  padding: 2rem;
}

.press-header {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1rem;
  margin-bottom: 2rem;
  text-align: center;
}

.search-wrapper {
  position: relative;
  width: 100%;
  max-width: 300px;
}

.search-icon {
  position: absolute;
  left: 1rem;
  top: 50%;
  transform: translateY(-50%);
  color: var(--text-secondary);
  width: 16px;
  height: 16px;
}

.search-input {
  width: 100%;
  background: rgba(18, 18, 24, 0.9);
  border: 1px solid var(--border-light);
  border-radius: 40px;
  color: white;
  padding: 0.75rem 1rem 0.75rem 2.5rem;
  outline: none;
  transition: all 0.2s ease;
}

.search-input:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-glow);
}

/* Category Tabs */
.tabs-center {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  justify-content: center;
  margin-bottom: 2rem;
}

.tab-btn-center {
  padding: 0.5rem 1.2rem;
  border-radius: 40px;
  font-size: 0.85rem;
  font-weight: 500;
  background: rgba(18, 18, 24, 0.8);
  border: 1px solid var(--border-light);
  color: var(--text-secondary);
  cursor: pointer;
  transition: all 0.2s ease;
}

.tab-btn-center:hover {
  background: rgba(28, 28, 36, 0.9);
  color: white;
  border-color: rgba(255, 255, 255, 0.2);
}

.tab-btn-center.active {
  background: var(--accent);
  border-color: var(--accent);
  color: white;
  box-shadow: 0 8px 16px -4px var(--accent-glow);
}

/* Press Grid Items */
.press-grid-center {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
  gap: 1rem;
  max-width: 1000px;
  margin: 0 auto;
}

.press-item {
  background: rgba(18, 18, 24, 0.7);
  border: 1px solid var(--border-light);
  border-radius: 20px;
  overflow: hidden;
  cursor: pointer;
  transition: all 0.2s ease;
}

.press-item:hover {
  transform: translateY(-4px);
  border-color: var(--accent);
  box-shadow: 0 16px 24px -8px rgba(0, 0, 0, 0.5);
}

.press-color {
  height: 80px;
  width: 100%;
  transition: transform 0.3s ease;
}

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

.press-info {
  padding: 0.75rem;
  text-align: center;
}

.press-name {
  font-size: 0.8rem;
  font-weight: 500;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.press-hex {
  font-size: 0.7rem;
  color: var(--text-secondary);
  font-family: monospace;
  margin-top: 0.25rem;
}

/* Toast Notification */
.toast-center {
  position: fixed;
  bottom: 2rem;
  left: 50%;
  transform: translateX(-50%) translateY(100px);
  background: #1E1E28;
  color: white;
  padding: 0.75rem 1.5rem;
  border-radius: 60px;
  font-size: 0.9rem;
  font-weight: 500;
  z-index: 999;
  opacity: 0;
  transition: all 0.4s cubic-bezier(0.68, -0.55, 0.265, 1.55);
  backdrop-filter: blur(20px);
  border: 1px solid rgba(255, 255, 255, 0.1);
  box-shadow: 0 20px 35px -8px rgba(0, 0, 0, 0.6);
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.toast-center.show {
  transform: translateX(-50%) translateY(0);
  opacity: 1;
}

.toast-icon {
  background: #10b981;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 14px;
}

/* Typography */
h1 {
  font-size: 3.5rem;
  font-weight: 800;
  letter-spacing: -0.02em;
  background: linear-gradient(135deg, #fff, #a0a0ff, #ffa0a0);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  margin-bottom: 0.5rem;
}

.subtitle {
  color: var(--text-secondary);
  font-size: 0.95rem;
  max-width: 500px;
  margin: 0 auto;
}

.section-title-center {
  font-size: 1rem;
  font-weight: 600;
  letter-spacing: 1px;
  text-transform: uppercase;
  color: var(--text-secondary);
  margin-bottom: 1.5rem;
  text-align: center;
}

/* Contrast Boxes */
.contrast-row {
  display: flex;
  gap: 0.75rem;
  margin-bottom: 1rem;
}

.contrast-box {
  flex: 1;
  height: 60px;
  border-radius: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.25rem;
  font-weight: 700;
}

/* Divider */
.divider {
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.1), transparent);
  margin: 2rem 0;
}

/* Responsive */
@media (max-width: 1024px) {
  .main-grid {
    grid-template-columns: repeat(1, 1fr);
  }
  
  .center-column {
    grid-column: span 1;
  }
  
  .app-container {
    padding: 1rem;
  }
  
  h1 {
    font-size: 2.5rem;
  }
}
button.px-10.pt-6.pb-6.py-2.bg-indigo-600.hover\:bg-indigo-500.rounded-full.text-sm.font-medium.transition-all.hover\:scale-105 {
    padding: 13px 32px;
}
pre#cssUsage {
    padding: 14px;
}