@charset "UTF-8";

/* Pretendard Web Font */
@import url('https://cdn.jsdelivr.net/gh/orioncactus/pretendard/dist/web/static/pretendard.css');

:root {
  /* Applied Men Brand Palette (extracted from all 5 channel images) */
  --am-burgundy: #7A0C1A;
  --am-burgundy-light: #9B1B2C;
  --am-burgundy-dark: #45060E;
  --am-joker-gold: #E5A918;
  --am-joker-amber: #F59E0B;
  --am-joker-green: #0D7F3E;
  --am-joker-emerald: #10B981;
  --am-joker-purple: #6D28D9;
  --am-joker-violet: #7C3AED;

  --bg-main: #06080C;
  --bg-card: #0E121B;
  --bg-card-hover: #161C2B;
  --text-main: #F3F4F6;
  --text-muted: #9CA3AF;
  --border-gold: rgba(229, 169, 24, 0.28);
  --border-burgundy: rgba(122, 12, 26, 0.55);
  --border-green: rgba(16, 185, 129, 0.28);
}

* {
  font-family: 'Pretendard', -apple-system, BlinkMacSystemFont, system-ui, Roboto, sans-serif;
  box-sizing: border-box;
}

body {
  background-color: var(--bg-main);
  color: var(--text-main);
  min-height: 100vh;
  margin: 0;
  padding: 0;
  overflow-x: hidden;
  background-image:
    radial-gradient(circle at 8% 12%, rgba(122, 12, 26, 0.24) 0%, transparent 42%),
    radial-gradient(circle at 92% 18%, rgba(13, 127, 62, 0.14) 0%, transparent 38%),
    radial-gradient(circle at 85% 88%, rgba(229, 169, 24, 0.12) 0%, transparent 42%),
    radial-gradient(circle at 18% 82%, rgba(109, 40, 217, 0.14) 0%, transparent 40%);
  background-attachment: fixed;
}

/* Applied Men Glassmorphism */
.glass-panel {
  background: rgba(14, 18, 27, 0.88);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1px solid var(--border-gold);
  border-radius: 1.5rem;
}

.glass-card {
  background: rgba(18, 24, 36, 0.78);
  backdrop-filter: blur(12px);
  border: 1px solid rgba(255, 255, 255, 0.08);
  transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}

.glass-card:hover {
  background: rgba(24, 31, 47, 0.94);
  border-color: rgba(229, 169, 24, 0.45);
  transform: translateY(-2px);
  box-shadow: 0 12px 28px -6px rgba(0, 0, 0, 0.7), 0 0 22px rgba(122, 12, 26, 0.35);
}

/* Applied Men Signature Surface Accents */
.am-hero-surface {
  background:
    linear-gradient(125deg, rgba(13, 127, 62, 0.22) 0%, rgba(122, 12, 26, 0.36) 48%, rgba(109, 40, 217, 0.22) 100%),
    #0B0E15;
  border: 1.5px solid rgba(229, 169, 24, 0.45);
  box-shadow: 0 20px 50px -12px rgba(0, 0, 0, 0.85), inset 0 1px 0 rgba(229, 169, 24, 0.2);
}

.am-card-burgundy {
  background: linear-gradient(165deg, rgba(122, 12, 26, 0.32) 0%, rgba(12, 15, 23, 0.96) 55%);
  border: 1px solid rgba(155, 27, 44, 0.55);
}

.am-card-emerald {
  background: linear-gradient(165deg, rgba(13, 127, 62, 0.26) 0%, rgba(109, 40, 217, 0.16) 45%, rgba(12, 15, 23, 0.97) 75%);
  border: 1.5px solid rgba(229, 169, 24, 0.48);
}

/* Custom Scrollbar */
::-webkit-scrollbar {
  width: 8px;
  height: 8px;
}
::-webkit-scrollbar-track {
  background: #06080C;
}
::-webkit-scrollbar-thumb {
  background: #252C3D;
  border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
  background: var(--am-burgundy-light);
}

/* Full-Body Visual Anatomy Diagram (도식 UI) */
.diagram-scanner-frame {
  position: relative;
  border-radius: 1.5rem;
  overflow: hidden;
  border: 1.5px solid rgba(229, 169, 24, 0.5);
  background: radial-gradient(circle at 50% 45%, rgba(122, 12, 26, 0.22) 0%, rgba(10, 13, 20, 0.98) 75%);
  box-shadow: 0 20px 45px -10px rgba(0, 0, 0, 0.85), 0 0 25px rgba(229, 169, 24, 0.12);
}

/* Subtle HUD Grid overlay behind/around diagram */
.diagram-hud-grid {
  background-image:
    linear-gradient(rgba(229, 169, 24, 0.05) 1px, transparent 1px),
    linear-gradient(90deg, rgba(229, 169, 24, 0.05) 1px, transparent 1px);
  background-size: 24px 24px;
}

/* Animated scanner sweep bar */
@keyframes hud-scan {
  0% {
    top: 4%;
    opacity: 0;
  }
  15% {
    opacity: 0.7;
  }
  85% {
    opacity: 0.7;
  }
  100% {
    top: 94%;
    opacity: 0;
  }
}

.diagram-scanline {
  position: absolute;
  left: 0;
  right: 0;
  height: 2px;
  background: linear-gradient(90deg, transparent 0%, rgba(16, 185, 129, 0.8) 25%, rgba(229, 169, 24, 0.95) 50%, rgba(16, 185, 129, 0.8) 75%, transparent 100%);
  box-shadow: 0 0 12px rgba(229, 169, 24, 0.65);
  animation: hud-scan 4.5s ease-in-out infinite;
  pointer-events: none;
  z-index: 15;
}

/* Interactive Numbered Callout Pins over Full-Body Image */
.diagram-pin {
  position: absolute;
  transform: translate(-50%, -50%);
  width: 22px;
  height: 22px;
  border-radius: 9999px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 10px;
  font-weight: 900;
  color: #07090E;
  background: linear-gradient(135deg, #F59E0B, #E5A918);
  border: 1.5px solid #FFFFFF;
  box-shadow: 0 0 0 2px rgba(122, 12, 26, 0.55), 0 3px 10px rgba(0, 0, 0, 0.8);
  cursor: pointer;
  z-index: 20;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.diagram-pin:hover,
.diagram-pin.active {
  transform: translate(-50%, -50%) scale(1.15);
  background: linear-gradient(135deg, #10B981, #34D399);
  color: #04130B;
  box-shadow: 0 0 0 3px rgba(16, 185, 129, 0.3), 0 0 12px rgba(16, 185, 129, 0.75);
}

/* Desktop Callout Connector Cards */
.diagram-callout {
  position: relative;
  transition: all 0.22s ease;
}

.diagram-callout.active,
.diagram-callout:hover {
  border-color: rgba(229, 169, 24, 0.8) !important;
  background: rgba(22, 28, 44, 0.96) !important;
  box-shadow: 0 8px 24px -6px rgba(0, 0, 0, 0.75), 0 0 16px rgba(229, 169, 24, 0.22);
  transform: translateY(-1px);
}

@media (min-width: 1024px) {
  .callout-left::after {
    content: "";
    position: absolute;
    top: 50%;
    right: -18px;
    width: 18px;
    height: 2px;
    background: linear-gradient(90deg, rgba(229, 169, 24, 0.55), rgba(16, 185, 129, 0.9));
    transform: translateY(-50%);
    pointer-events: none;
  }

  .callout-right::before {
    content: "";
    position: absolute;
    top: 50%;
    left: -18px;
    width: 18px;
    height: 2px;
    background: linear-gradient(270deg, rgba(229, 169, 24, 0.55), rgba(16, 185, 129, 0.9));
    transform: translateY(-50%);
    pointer-events: none;
  }
}

/* Option Card Active State */
.option-card {
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
}
.option-card:hover {
  border-color: var(--am-joker-gold);
}

/* Encyclopedia Single-Screen 4x2 Grid */
.encyclopedia-grid {
  display: grid;
  grid-template-columns: repeat(1, minmax(0, 1fr));
  gap: 0.75rem;
  align-items: stretch;
}

@media (min-width: 560px) {
  .encyclopedia-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (min-width: 768px) {
  .encyclopedia-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }
}

.encyclopedia-thumb {
  height: clamp(165px, 24.5vh, 235px);
}
