/* ============================================
   NORDIC CAPSULE — Luxury Minimal Lookbook
   Scandinavian Minimalism · Quiet Luxury
   ============================================ */

:root {
  --bg: #fafafa;
  --bg-elevated: #ffffff;
  --text: #1a1a1a;
  --text-muted: #6b6b6b;
  --border: #e8e8e8;
  --accent: #2c2c2c;
  --accent-soft: #f0f0f0;
  --black: #0d0d0d;
  --chocolate: #3d2b1f;
  --khaki: #6b5c45;
  --graphite: #3a3a3a;
  --dark-grey: #4a4a4a;
  --milk: #f5f0e8;
  --olive: #4a5240;
  --radius: 12px;
  --radius-lg: 20px;
  --shadow: 0 4px 24px rgba(0,0,0,0.04);
  --shadow-hover: 0 12px 40px rgba(0,0,0,0.08);
  --transition: 0.35s cubic-bezier(0.25, 0.1, 0.25, 1);
  --font: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  --font-serif: 'Playfair Display', Georgia, serif;
  --header-h: 72px;
}

[data-theme="dark"] {
  --bg: #111111;
  --bg-elevated: #1a1a1a;
  --text: #f0f0f0;
  --text-muted: #9a9a9a;
  --border: #2a2a2a;
  --accent: #e8e8e8;
  --accent-soft: #222222;
  --shadow: 0 4px 24px rgba(0,0,0,0.3);
  --shadow-hover: 0 12px 40px rgba(0,0,0,0.45);
}

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

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

body {
  font-family: var(--font);
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

img {
  max-width: 100%;
  display: block;
  object-fit: cover;
}

a {
  color: inherit;
  text-decoration: none;
}

button {
  font-family: inherit;
  cursor: pointer;
  border: none;
  background: none;
  color: inherit;
}

ul {
  list-style: none;
}

.container {
  width: 100%;
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 24px;
}

/* ========== Header ========== */
.header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: var(--header-h);
  z-index: 1000;
  background: rgba(250, 250, 250, 0.8);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-bottom: 1px solid transparent;
  transition: var(--transition);
}

[data-theme="dark"] .header {
  background: rgba(17, 17, 17, 0.85);
}

.header.scrolled {
  border-bottom-color: var(--border);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 100%;
}

.logo {
  font-size: 0.85rem;
  font-weight: 600;
  letter-spacing: 0.15em;
  text-transform: uppercase;
}

.nav {
  display: flex;
  gap: 32px;
}

.nav a {
  font-size: 0.8rem;
  font-weight: 400;
  letter-spacing: 0.04em;
  color: var(--text-muted);
  transition: color var(--transition);
}

.nav a:hover {
  color: var(--text);
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 8px;
}

.icon-btn {
  position: relative;
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  transition: background var(--transition);
}

.icon-btn:hover {
  background: var(--accent-soft);
}

.badge {
  position: absolute;
  top: 4px;
  right: 4px;
  min-width: 16px;
  height: 16px;
  background: var(--text);
  color: var(--bg);
  font-size: 0.65rem;
  font-weight: 600;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  transform: scale(0.5);
  transition: var(--transition);
}

.badge.visible {
  opacity: 1;
  transform: scale(1);
}

.theme-toggle .moon { display: none; }
[data-theme="dark"] .theme-toggle .sun { display: none; }
[data-theme="dark"] .theme-toggle .moon { display: block; }

#themeToggle .moon { display: none; }
[data-theme="dark"] #themeToggle .sun { display: none; }
[data-theme="dark"] #themeToggle .moon { display: block; }

.mobile-menu {
  display: none;
  flex-direction: column;
  gap: 5px;
}

.mobile-menu span {
  width: 18px;
  height: 1.5px;
  background: var(--text);
  transition: var(--transition);
}

/* Search Panel */
.search-panel {
  position: absolute;
  top: 100%;
  left: 0;
  right: 0;
  background: var(--bg-elevated);
  border-bottom: 1px solid var(--border);
  padding: 20px 0;
  transform: translateY(-10px);
  opacity: 0;
  visibility: hidden;
  transition: var(--transition);
  box-shadow: var(--shadow);
}

.search-panel.open {
  transform: translateY(0);
  opacity: 1;
  visibility: visible;
}

#searchInput {
  width: 100%;
  padding: 16px 20px;
  font-size: 1rem;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--bg);
  color: var(--text);
  outline: none;
  transition: border-color var(--transition);
}

#searchInput:focus {
  border-color: var(--text-muted);
}

.search-results {
  margin-top: 12px;
  max-height: 320px;
  overflow-y: auto;
}

.search-item {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 12px;
  border-radius: var(--radius);
  cursor: pointer;
  transition: background var(--transition);
}

.search-item:hover {
  background: var(--accent-soft);
}

.search-item img {
  width: 48px;
  height: 48px;
  border-radius: 8px;
  object-fit: cover;
}

.search-item-info h4 {
  font-size: 0.9rem;
  font-weight: 500;
}

.search-item-info span {
  font-size: 0.75rem;
  color: var(--text-muted);
}

/* ========== Hero ========== */
.hero {
  position: relative;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding-top: var(--header-h);
  overflow: hidden;
}

.hero-bg {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(135deg, rgba(250,250,250,0.92) 0%, rgba(245,240,232,0.85) 50%, rgba(250,250,250,0.9) 100%),
    url('https://images.unsplash.com/photo-1490481651871-ab68de25d43d?w=1600&q=80') center/cover no-repeat;
  z-index: 0;
}

[data-theme="dark"] .hero-bg {
  background:
    linear-gradient(135deg, rgba(17,17,17,0.92) 0%, rgba(30,25,20,0.88) 50%, rgba(17,17,17,0.9) 100%),
    url('https://images.unsplash.com/photo-1490481651871-ab68de25d43d?w=1600&q=80') center/cover no-repeat;
}

.hero-content {
  position: relative;
  z-index: 1;
  text-align: center;
  max-width: 720px;
}

.hero-label {
  font-size: 0.75rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--text-muted);
  margin-bottom: 24px;
  animation: fadeUp 0.8s ease both;
}

.hero-title {
  font-family: var(--font-serif);
  font-size: clamp(3.5rem, 10vw, 6.5rem);
  font-weight: 400;
  line-height: 1.05;
  letter-spacing: -0.02em;
  margin-bottom: 28px;
  animation: fadeUp 0.8s 0.1s ease both;
}

.hero-desc {
  font-size: 1.05rem;
  color: var(--text-muted);
  line-height: 1.7;
  margin-bottom: 40px;
  animation: fadeUp 0.8s 0.2s ease both;
}

.hero-actions {
  display: flex;
  gap: 16px;
  justify-content: center;
  flex-wrap: wrap;
  animation: fadeUp 0.8s 0.3s ease both;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 14px 32px;
  font-size: 0.8rem;
  font-weight: 500;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  border-radius: 100px;
  transition: var(--transition);
}

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

.btn-primary:hover {
  opacity: 0.85;
  transform: translateY(-2px);
}

.btn-ghost {
  border: 1px solid var(--border);
  color: var(--text);
}

.btn-ghost:hover {
  border-color: var(--text-muted);
  background: var(--accent-soft);
}

.scroll-hint {
  position: absolute;
  bottom: 40px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  font-size: 0.7rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--text-muted);
  animation: fadeUp 1s 0.6s ease both;
}

.scroll-line {
  width: 1px;
  height: 40px;
  background: linear-gradient(to bottom, var(--text-muted), transparent);
  animation: scrollPulse 2s ease infinite;
}

@keyframes fadeUp {
  from { opacity: 0; transform: translateY(24px); }
  to { opacity: 1; transform: translateY(0); }
}

@keyframes scrollPulse {
  0%, 100% { opacity: 0.4; transform: scaleY(1); }
  50% { opacity: 1; transform: scaleY(1.1); }
}

/* ========== Sections ========== */
.section {
  padding: 100px 0;
}

.section-header {
  margin-bottom: 56px;
}

.section-num {
  display: block;
  font-size: 0.75rem;
  letter-spacing: 0.2em;
  color: var(--text-muted);
  margin-bottom: 12px;
}

.section-header h2 {
  font-family: var(--font-serif);
  font-size: clamp(2rem, 4vw, 2.75rem);
  font-weight: 400;
  letter-spacing: -0.01em;
}

.section-sub {
  margin-top: 12px;
  color: var(--text-muted);
  max-width: 560px;
  font-size: 0.95rem;
}

/* ========== About ========== */
.about-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 24px;
}

.about-card {
  padding: 32px;
  border-radius: var(--radius-lg);
  border: 1px solid var(--border);
  background: var(--bg-elevated);
  transition: var(--transition);
}

.about-card:hover {
  box-shadow: var(--shadow-hover);
}

.about-card h3 {
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  margin-bottom: 20px;
  color: var(--text-muted);
}

.info-list li {
  display: flex;
  justify-content: space-between;
  padding: 10px 0;
  border-bottom: 1px solid var(--border);
  font-size: 0.9rem;
}

.info-list li:last-child {
  border-bottom: none;
}

.info-list span {
  color: var(--text-muted);
}

.tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 20px;
}

.tag {
  padding: 6px 14px;
  font-size: 0.8rem;
  border: 1px solid var(--border);
  border-radius: 100px;
  background: var(--accent-soft);
}

.about-text {
  font-size: 0.95rem;
  color: var(--text-muted);
  line-height: 1.7;
}

.pref-list li {
  position: relative;
  padding: 8px 0 8px 18px;
  font-size: 0.9rem;
}

.pref-list li::before {
  content: '·';
  position: absolute;
  left: 0;
  color: var(--text-muted);
}

.pref-list.negative li::before {
  content: '×';
  color: #a05050;
}

/* ========== Concept ========== */
.concept-content {
  display: grid;
  grid-template-columns: 1.4fr 1fr;
  gap: 48px;
}

.concept-main h3 {
  font-family: var(--font-serif);
  font-size: 1.6rem;
  font-weight: 400;
  margin-bottom: 24px;
  line-height: 1.3;
}

.concept-main p {
  color: var(--text-muted);
  margin-bottom: 16px;
  font-size: 0.95rem;
  line-height: 1.75;
}

.concept-block {
  padding: 24px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  margin-bottom: 16px;
  background: var(--bg-elevated);
}

.concept-block h4 {
  font-size: 0.75rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  margin-bottom: 10px;
  color: var(--text-muted);
}

.concept-block p {
  font-size: 0.9rem;
  line-height: 1.6;
}

/* ========== Palette ========== */
.palette-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
  gap: 20px;
}

.color-card {
  border-radius: var(--radius-lg);
  overflow: hidden;
  border: 1px solid var(--border);
  transition: var(--transition);
  cursor: pointer;
}

.color-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-hover);
}

.color-swatch {
  height: 120px;
}

.color-info {
  padding: 16px;
  background: var(--bg-elevated);
}

.color-info h4 {
  font-size: 0.85rem;
  font-weight: 500;
  margin-bottom: 4px;
}

.color-info span {
  font-size: 0.75rem;
  color: var(--text-muted);
  font-family: ui-monospace, monospace;
}

/* ========== Filters ========== */
.filters {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 40px;
}

.filter-btn {
  padding: 10px 20px;
  font-size: 0.8rem;
  letter-spacing: 0.04em;
  border: 1px solid var(--border);
  border-radius: 100px;
  transition: var(--transition);
  background: var(--bg-elevated);
}

.filter-btn:hover,
.filter-btn.active {
  background: var(--text);
  color: var(--bg);
  border-color: var(--text);
}

/* ========== Products ========== */
.products-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 28px;
}

.product-card {
  background: var(--bg-elevated);
  border-radius: var(--radius-lg);
  border: 1px solid var(--border);
  overflow: hidden;
  transition: var(--transition);
  display: flex;
  flex-direction: column;
}

.product-card:hover {
  box-shadow: var(--shadow-hover);
  transform: translateY(-3px);
}

.product-image {
  position: relative;
  aspect-ratio: 3/4;
  overflow: hidden;
  background: var(--accent-soft);
  cursor: zoom-in;
}

.product-image img {
  width: 100%;
  height: 100%;
  transition: transform 0.6s ease;
}

.product-card:hover .product-image img {
  transform: scale(1.04);
}

.product-fav {
  position: absolute;
  top: 12px;
  right: 12px;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: rgba(255,255,255,0.9);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: var(--transition);
  z-index: 2;
}

[data-theme="dark"] .product-fav {
  background: rgba(30,30,30,0.9);
}

.product-fav:hover,
.product-fav.active {
  background: var(--text);
  color: var(--bg);
}

.product-fav.active svg {
  fill: currentColor;
}

.product-body {
  padding: 20px;
  flex: 1;
  display: flex;
  flex-direction: column;
}

.product-brand {
  font-size: 0.7rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--text-muted);
  margin-bottom: 6px;
}

.product-name {
  font-size: 1rem;
  font-weight: 500;
  margin-bottom: 8px;
  line-height: 1.3;
}

.product-meta {
  display: flex;
  gap: 12px;
  font-size: 0.8rem;
  color: var(--text-muted);
  margin-bottom: 12px;
}

.product-desc {
  font-size: 0.85rem;
  color: var(--text-muted);
  line-height: 1.55;
  margin-bottom: 12px;
  flex: 1;
}

.product-why {
  font-size: 0.8rem;
  padding: 10px 12px;
  background: var(--accent-soft);
  border-radius: 8px;
  margin-bottom: 12px;
  line-height: 1.45;
}

.product-why strong {
  display: block;
  font-size: 0.7rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  margin-bottom: 4px;
  color: var(--text-muted);
}

.product-pairs {
  font-size: 0.8rem;
  color: var(--text-muted);
  margin-bottom: 16px;
}

.product-pairs span {
  color: var(--text);
}

.product-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding-top: 12px;
  border-top: 1px solid var(--border);
}

.product-price {
  font-size: 1rem;
  font-weight: 500;
}

.product-actions {
  display: flex;
  gap: 6px;
}

.product-actions .btn-sm {
  padding: 8px 14px;
  font-size: 0.7rem;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  border-radius: 100px;
  border: 1px solid var(--border);
  transition: var(--transition);
}

.product-actions .btn-sm:hover {
  background: var(--text);
  color: var(--bg);
  border-color: var(--text);
}

.product-actions .btn-copy {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  border: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: var(--transition);
}

.product-actions .btn-copy:hover {
  background: var(--accent-soft);
}

/* ========== Looks ========== */
.looks-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 28px;
}

.look-card {
  background: var(--bg-elevated);
  border-radius: var(--radius-lg);
  border: 1px solid var(--border);
  overflow: hidden;
  transition: var(--transition);
}

.look-card:hover {
  box-shadow: var(--shadow-hover);
  transform: translateY(-3px);
}

.look-image {
  aspect-ratio: 4/5;
  overflow: hidden;
  background: var(--accent-soft);
  cursor: zoom-in;
}

.look-image img {
  width: 100%;
  height: 100%;
  transition: transform 0.6s ease;
}

.look-card:hover .look-image img {
  transform: scale(1.03);
}

.look-body {
  padding: 20px;
}

.look-num {
  font-size: 0.7rem;
  letter-spacing: 0.15em;
  color: var(--text-muted);
  margin-bottom: 8px;
}

.look-title {
  font-size: 1.05rem;
  font-weight: 500;
  margin-bottom: 12px;
}

.look-items {
  font-size: 0.85rem;
  color: var(--text-muted);
  margin-bottom: 12px;
  line-height: 1.5;
}

.look-when {
  font-size: 0.8rem;
  margin-bottom: 8px;
}

.look-when strong {
  font-weight: 500;
}

.look-why {
  font-size: 0.8rem;
  color: var(--text-muted);
  line-height: 1.5;
  padding-top: 10px;
  border-top: 1px solid var(--border);
}

/* ========== Favorites Panel ========== */
.favorites-panel {
  position: fixed;
  top: 0;
  right: 0;
  width: 380px;
  max-width: 100%;
  height: 100%;
  background: var(--bg-elevated);
  border-left: 1px solid var(--border);
  z-index: 1100;
  transform: translateX(100%);
  transition: transform 0.4s cubic-bezier(0.25, 0.1, 0.25, 1);
  display: flex;
  flex-direction: column;
  box-shadow: -8px 0 40px rgba(0,0,0,0.08);
}

.favorites-panel.open {
  transform: translateX(0);
}

.favorites-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 24px;
  border-bottom: 1px solid var(--border);
}

.favorites-header h3 {
  font-size: 1rem;
  font-weight: 500;
}

.favorites-header .icon-btn {
  font-size: 1.5rem;
  line-height: 1;
}

.favorites-list {
  flex: 1;
  overflow-y: auto;
  padding: 16px;
}

.fav-item {
  display: flex;
  gap: 12px;
  padding: 12px;
  border-radius: var(--radius);
  margin-bottom: 8px;
  border: 1px solid var(--border);
}

.fav-item img {
  width: 64px;
  height: 80px;
  border-radius: 8px;
  object-fit: cover;
}

.fav-item-info {
  flex: 1;
}

.fav-item-info h4 {
  font-size: 0.85rem;
  font-weight: 500;
  margin-bottom: 4px;
}

.fav-item-info span {
  font-size: 0.75rem;
  color: var(--text-muted);
}

.fav-remove {
  align-self: flex-start;
  font-size: 1.2rem;
  color: var(--text-muted);
  padding: 4px;
}

.favorites-empty {
  padding: 40px 24px;
  text-align: center;
  color: var(--text-muted);
  font-size: 0.9rem;
}

/* ========== Lightbox ========== */
.lightbox {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.92);
  z-index: 2000;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  visibility: hidden;
  transition: var(--transition);
  padding: 40px;
}

.lightbox.open {
  opacity: 1;
  visibility: visible;
}

.lightbox img {
  max-width: 90vw;
  max-height: 90vh;
  object-fit: contain;
  border-radius: 8px;
}

.lightbox-close {
  position: absolute;
  top: 24px;
  right: 32px;
  font-size: 2rem;
  color: #fff;
  width: 48px;
  height: 48px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  transition: background 0.2s;
}

.lightbox-close:hover {
  background: rgba(255,255,255,0.1);
}

/* ========== Footer ========== */
.footer {
  padding: 60px 0 40px;
  border-top: 1px solid var(--border);
}

.footer-inner {
  display: flex;
  justify-content: space-between;
  gap: 40px;
  margin-bottom: 40px;
  flex-wrap: wrap;
}

.footer .logo {
  margin-bottom: 12px;
}

.footer p {
  font-size: 0.85rem;
  color: var(--text-muted);
  line-height: 1.6;
}

.footer-note {
  max-width: 420px;
}

.copyright {
  font-size: 0.75rem;
  color: var(--text-muted);
  letter-spacing: 0.04em;
}

/* ========== Glass ========== */
.glass {
  background: rgba(255,255,255,0.6);
  backdrop-filter: blur(12px);
}

[data-theme="dark"] .glass {
  background: rgba(26,26,26,0.7);
}

/* ========== Responsive ========== */
@media (max-width: 900px) {
  .nav {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    flex-direction: column;
    background: var(--bg-elevated);
    padding: 20px 24px;
    border-bottom: 1px solid var(--border);
    gap: 16px;
  }

  .nav.open {
    display: flex;
  }

  .mobile-menu {
    display: flex;
  }

  .about-grid {
    grid-template-columns: 1fr;
  }

  .concept-content {
    grid-template-columns: 1fr;
  }

  .products-grid {
    grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  }
}

@media (max-width: 600px) {
  .section {
    padding: 64px 0;
  }

  .hero-title {
    font-size: 3rem;
  }

  .products-grid,
  .looks-grid {
    grid-template-columns: 1fr;
  }

  .favorites-panel {
    width: 100%;
  }

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

/* Utility */
.hidden {
  display: none !important;
}
