/* CSS Reset & Variables */
:root {
  /* Dark Mode Defaults */
  --mist-gray: #ECEFF1;
  --mist-gray-dim: rgba(236, 239, 241, 0.6);
  --midnight-blue: #191970;
  
  --bg-color: #0b0b1a;
  --panel-bg: rgba(25, 25, 112, 0.25);
  --panel-border: rgba(236, 239, 241, 0.1);
  --header-bg: rgba(11, 11, 26, 0.7);
  
  --text-main: var(--mist-gray);
  --text-muted: var(--mist-gray-dim);
  
  --btn-bg: var(--mist-gray);
  --btn-text: #111;
  
  --font-sans: "Pretendard Variable", Pretendard, -apple-system, system-ui, sans-serif;
}

[data-theme="light"] {
  --mist-gray: #191970;
  --mist-gray-dim: rgba(25, 25, 112, 0.6);
  --midnight-blue: #ECEFF1;
  
  --bg-color: #f4f6f8;
  --panel-bg: rgba(255, 255, 255, 0.7);
  --panel-border: rgba(25, 25, 112, 0.15);
  --header-bg: rgba(244, 246, 248, 0.7);
  
  --text-main: var(--mist-gray);
  --text-muted: var(--mist-gray-dim);
  
  --btn-bg: var(--mist-gray);
  --btn-text: #fff;
}

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

html { scroll-behavior: smooth; }

body {
  font-family: var(--font-sans);
  background-color: var(--bg-color);
  color: var(--text-main);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  transition: background-color 0.3s ease, color 0.3s ease;
}

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

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

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 12px 24px;
  font-size: 15px;
  font-weight: 600;
  border-radius: 8px;
  transition: all 0.2s ease;
  cursor: pointer;
}

.btn-large {
  padding: 16px 32px;
  font-size: 16px;
}

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

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

.text-btn {
  background: transparent;
  border: 1px solid var(--panel-border);
  font-size: 13px;
  color: var(--text-main);
  cursor: pointer;
  padding: 6px 12px;
  border-radius: 6px;
  transition: all 0.2s;
  font-weight: 600;
}

.text-btn:hover {
  background: rgba(236, 239, 241, 0.1);
}

.lang-select {
  background: transparent;
  border: 1px solid var(--panel-border);
  color: var(--text-main);
  font-size: 13px;
  padding: 6px 8px;
  border-radius: 6px;
  cursor: pointer;
  font-weight: 600;
  outline: none;
  font-family: inherit;
}

.lang-select option {
  background: var(--bg-color);
  color: var(--text-main);
}

/* Header */
.header {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  z-index: 100;
  padding: 20px 0;
  background: var(--header-bg);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--panel-border);
  transition: padding 0.3s ease, background-color 0.3s ease;
}

.header.scrolled { padding: 12px 0; }

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

.header-controls {
  display: flex;
  gap: 8px;
  align-items: center;
  margin-right: 16px;
}

.logo {
  display: flex;
  align-items: center;
  gap: 10px;
}

.logo-img { width: 32px; height: 32px; border-radius: 8px; }
.logo-img-small { width: 24px; height: 24px; border-radius: 6px; }

.logo-text {
  font-size: 20px;
  font-weight: 700;
  color: var(--text-main);
}

.nav {
  display: none;
  gap: 32px;
  margin-right: auto;
  margin-left: 40px;
}

.nav a {
  font-size: 15px;
  font-weight: 500;
  color: var(--text-muted);
  transition: color 0.2s;
}

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

@media (min-width: 768px) { .nav { display: flex; } }
@media (max-width: 767px) { .nav-cta { display: none; } }

/* Hero Section */
.hero {
  padding: 180px 0 120px;
  min-height: 90vh;
  display: flex;
  align-items: center;
  background: radial-gradient(circle at 50% 0%, var(--panel-bg) 0%, transparent 70%);
}

.hero-container {
  display: grid;
  grid-template-columns: 1fr;
  gap: 60px;
  align-items: center;
}

@media (min-width: 992px) {
  .hero-container { grid-template-columns: 1fr 1fr; }
}

.hero-title {
  font-size: clamp(38px, 5vw, 64px);
  font-weight: 800;
  line-height: 1.25;
  margin-bottom: 24px;
  letter-spacing: -0.02em;
}

.hero-description {
  font-size: 18px;
  color: var(--text-muted);
  margin-bottom: 48px;
  line-height: 1.7;
}

.preview-img {
  width: 100%;
  border-radius: 12px;
  box-shadow: 0 20px 40px rgba(0,0,0,0.2);
  border: 1px solid var(--panel-border);
  transform: perspective(1000px) rotateY(-5deg) rotateX(5deg);
  transition: transform 0.4s ease;
}

.preview-img:hover { transform: perspective(1000px) rotateY(0deg) rotateX(0deg); }

/* Features */
.features { padding: 120px 0; }

.section-header { margin-bottom: 80px; text-align: center; }
.section-title { font-size: 36px; font-weight: 800; margin-bottom: 16px; letter-spacing: -0.02em; }
.section-description { font-size: 18px; color: var(--text-muted); }

.features-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 32px;
}

@media (min-width: 768px) {
  .features-grid { grid-template-columns: 1fr 1fr; }
}

.feature-card {
  background: var(--panel-bg);
  border: 1px solid var(--panel-border);
  border-radius: 16px;
  padding: 48px;
  transition: transform 0.3s ease, border-color 0.3s ease, background-color 0.3s ease;
}

.feature-card:hover {
  transform: translateY(-4px);
  border-color: rgba(120, 120, 120, 0.4);
}

.feature-title { font-size: 24px; font-weight: 700; margin-bottom: 16px; letter-spacing: -0.01em; }
.feature-desc { color: var(--text-muted); margin-bottom: 40px; font-size: 16px; line-height: 1.6; }
.feature-img { width: 100%; border-radius: 8px; box-shadow: 0 10px 20px rgba(0,0,0,0.15); }

/* Highlight */
.highlight-section { padding: 80px 0 160px; text-align: center; }
.highlight-container {
  padding: 100px 40px;
  background: var(--panel-bg);
  border-radius: 24px;
  border: 1px solid var(--panel-border);
}
.highlight-title { font-size: clamp(32px, 4vw, 40px); font-weight: 800; margin-bottom: 40px; letter-spacing: -0.02em; }

/* Footer */
.footer {
  border-top: 1px solid var(--panel-border);
  padding: 60px 0;
  background: var(--header-bg);
}

.footer-container {
  display: flex;
  flex-direction: column;
  gap: 32px;
  align-items: center;
}

@media (min-width: 768px) {
  .footer-container {
    flex-direction: row;
    justify-content: space-between;
  }
}

.footer-brand { display: flex; flex-direction: column; gap: 12px; align-items: center; }
@media (min-width: 768px) { .footer-brand { align-items: flex-start; } }

.footer-copy { color: var(--text-muted); font-size: 14px; }
.footer-links { display: flex; gap: 24px; }
.footer-links a { font-size: 14px; color: var(--text-muted); transition: color 0.2s; }
.footer-links a:hover { color: var(--text-main); }

/* Reveal Animations */
.reveal {
  opacity: 0;
  transform: translateY(30px);
  transition: all 0.6s ease-out;
}
.reveal.active {
  opacity: 1;
  transform: translateY(0);
}

/* Discord Mockup UI */
.commands-section { padding: 100px 0; background: var(--bg-color); }
.discord-mockup {
  max-width: 800px;
  margin: 40px auto 0;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.4);
  background: #313338;
  color: #dbdee1;
  font-family: "gg sans", "Noto Sans", "Helvetica Neue", Helvetica, Arial, sans-serif;
  text-align: left;
}
.discord-header {
  background: #2b2d31;
  padding: 12px 16px;
  border-bottom: 1px solid #1e1f22;
  display: flex;
  align-items: center;
  gap: 8px;
  font-weight: 600;
  font-size: 16px;
}
.discord-header .hash { color: #80848e; font-size: 20px; font-weight: 400; }
.discord-body { padding: 16px; display: flex; flex-direction: column; gap: 20px; }
.discord-messages { display: flex; flex-direction: column; gap: 16px; min-height: 100px; justify-content: flex-end; }
.discord-message { display: flex; gap: 16px; }
.discord-avatar { width: 40px; height: 40px; border-radius: 50%; }
.discord-msg-content { display: flex; flex-direction: column; gap: 4px; }
.discord-author { font-size: 15px; font-weight: 500; color: #f2f3f5; display: flex; align-items: center; gap: 6px; }
.bot-tag { background: #5865f2; color: #fff; font-size: 10px; padding: 2px 4px; border-radius: 3px; font-weight: 600; }
.discord-time { font-size: 12px; color: #949ba4; font-weight: 400; margin-left: 4px; }
.discord-text { font-size: 15px; line-height: 1.4; color: #dbdee1; }

.discord-input-container { position: relative; margin-top: 10px; }
.discord-autocomplete {
  position: absolute;
  bottom: calc(100% + 8px);
  left: 0;
  width: 100%;
  background: #2b2d31;
  border-radius: 8px;
  padding: 8px;
  box-shadow: 0 8px 24px rgba(0,0,0,0.4);
  opacity: 0;
  transform: translateY(10px);
  pointer-events: none;
  transition: all 0.2s ease;
  z-index: 10;
}
.discord-autocomplete.show {
  opacity: 1;
  transform: translateY(0);
  pointer-events: auto;
}
.autocomplete-header {
  font-size: 12px;
  font-weight: 700;
  color: #949ba4;
  text-transform: uppercase;
  padding: 4px 8px;
  margin-bottom: 4px;
}
.autocomplete-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 8px;
  border-radius: 4px;
}
.autocomplete-item.active { background: rgba(71, 82, 196, 0.6); }
.ac-icon img { width: 32px; height: 32px; border-radius: 50%; }
.ac-content { display: flex; flex-direction: column; }
.ac-cmd { font-weight: 600; color: #f2f3f5; font-size: 15px; }
.ac-desc { font-size: 13px; color: #b5bac1; }

.discord-input {
  background: #383a40;
  border-radius: 8px;
  display: flex;
  align-items: center;
  padding: 0 16px;
  height: 44px;
}
.plus-btn {
  width: 24px;
  height: 24px;
  background: #b5bac1;
  color: #383a40;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 18px;
  margin-right: 12px;
}
.input-text {
  font-size: 15px;
  color: #dbdee1;
  position: relative;
}
.input-text::after {
  content: '|';
  position: absolute;
  right: -8px;
  animation: blink 1s step-start infinite;
}
@keyframes blink { 50% { opacity: 0; } }

.autocomplete-item { cursor: pointer; transition: background 0.2s; }
.autocomplete-item:hover, .autocomplete-item.active { background: rgba(71, 82, 196, 0.6); }

.discord-embed-group {
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.discord-embed {
  background: #2b2d31;
  border-left: 4px solid #202225;
  border-radius: 4px;
  padding: 12px 16px;
  margin-top: 4px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  max-width: 450px;
  position: relative;
  min-height: 50px;
}
.cmd-mention {
  background: rgba(88, 101, 242, 0.3);
  color: #c9cdfb;
  padding: 0 4px;
  border-radius: 3px;
  font-weight: 500;
}
.embed-author { font-size: 14px; font-weight: 600; color: #ffffff; }
.embed-title { font-size: 16px; font-weight: 700; color: #00a8fc; margin-right: 70px; }
.embed-description { font-size: 14px; color: #dbdee1; line-height: 1.5; margin-right: 70px; }
.embed-thumbnail {
  position: absolute;
  right: 16px;
  top: 50%;
  transform: translateY(-50%);
  width: 64px;
  height: 48px;
  object-fit: contain;
}
.embed-fields { display: flex; flex-direction: column; gap: 12px; margin-top: 8px; }
.embed-field-row { display: flex; gap: 16px; }
.embed-field { flex: 1; display: flex; flex-direction: column; gap: 4px; }
.embed-field-name { font-size: 13px; font-weight: 700; color: #ffffff; }
.embed-field-value { font-size: 13px; color: #dbdee1; line-height: 1.4; }

.discord-components {
  display: flex;
  gap: 8px;
  margin-top: 4px;
}
.discord-button {
  background: #4e5058;
  color: #dbdee1;
  font-size: 14px;
  font-weight: 500;
  padding: 6px 16px;
  border-radius: 4px;
  cursor: pointer;
  transition: background 0.2s;
}
.discord-button:hover {
  background: #6d6f78;
}
.discord-button.primary {
  background: #5865f2;
  color: white;
}
.discord-button.primary:hover {
  background: #4752c4;
}

/* Status Section */
.status-section { padding: 100px 0; background: var(--header-bg); }
.status-dashboard { margin-top: 40px; }
.status-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 20px;
}
.status-card {
  background: var(--card-bg);
  border: 1px solid var(--border-color);
  border-radius: 16px;
  padding: 24px;
  display: flex;
  align-items: center;
  gap: 16px;
  box-shadow: 0 4px 16px rgba(0,0,0,0.05);
  transition: transform 0.3s ease;
}
.status-card:hover {
  transform: translateY(-2px);
}
.status-card.highlight-card {
  grid-column: 1 / -1;
  background: rgba(88, 101, 242, 0.05);
  border-color: rgba(88, 101, 242, 0.2);
}
.status-indicator {
  width: 14px;
  height: 14px;
  background-color: #23a559;
  border-radius: 50%;
  flex-shrink: 0;
}
.status-indicator.pulse {
  box-shadow: 0 0 0 0 rgba(35, 165, 89, 0.7);
  animation: pulse-green 2s infinite;
}
.status-indicator.error {
  background-color: #da373c;
  box-shadow: 0 0 0 0 rgba(218, 55, 60, 0.7);
  animation: pulse-red 2s infinite;
}
@keyframes pulse-green {
  0% { transform: scale(0.95); box-shadow: 0 0 0 0 rgba(35, 165, 89, 0.7); }
  70% { transform: scale(1); box-shadow: 0 0 0 10px rgba(35, 165, 89, 0); }
  100% { transform: scale(0.95); box-shadow: 0 0 0 0 rgba(35, 165, 89, 0); }
}
@keyframes pulse-red {
  0% { transform: scale(0.95); box-shadow: 0 0 0 0 rgba(218, 55, 60, 0.7); }
  70% { transform: scale(1); box-shadow: 0 0 0 10px rgba(218, 55, 60, 0); }
  100% { transform: scale(0.95); box-shadow: 0 0 0 0 rgba(218, 55, 60, 0); }
}
.status-icon {
  font-size: 28px;
  width: 48px;
  height: 48px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(128,128,128,0.1);
  border-radius: 12px;
  flex-shrink: 0;
}
.status-info h3 {
  font-size: 14px;
  color: var(--text-color-muted);
  margin-bottom: 4px;
  font-weight: 500;
}
.status-info p {
  font-size: 20px;
  color: var(--text-color);
  font-weight: 700;
  margin: 0;
}
.highlight-card .status-info p { color: #23a559; }
.highlight-card.error-card .status-info p { color: #da373c; }

/* Credits (ID Card) Section */
.credits-section { padding: 100px 0; background: var(--bg-color); }
.id-card-wrapper {
  display: flex;
  justify-content: center;
  margin-top: 40px;
  gap: 32px;
  flex-wrap: wrap;
}
.id-card {
  width: 320px;
  background: linear-gradient(135deg, #1e1e2f 0%, #151522 100%);
  border-radius: 16px;
  box-shadow: 0 24px 48px rgba(0, 0, 0, 0.5), inset 0 2px 1px rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.05);
  display: flex;
  flex-direction: column;
  position: relative;
  overflow: hidden;
  color: #fff;
}
.id-card-hole {
  width: 60px;
  height: 12px;
  background: var(--bg-color);
  border-radius: 8px;
  position: absolute;
  top: 16px;
  left: 50%;
  transform: translateX(-50%);
  box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.8);
  border: 1px solid rgba(255, 255, 255, 0.05);
}
.id-card-header {
  background: #5865F2; /* Blurple */
  padding: 48px 0 16px;
  text-align: center;
}
.id-card-header h3 {
  font-size: 14px;
  letter-spacing: 4px;
  margin: 0;
  font-weight: 700;
  color: rgba(255,255,255,0.9);
}
.id-card-body {
  padding: 32px 24px;
  display: flex;
  flex-direction: column;
  align-items: center;
  position: relative;
}
.id-avatar-wrapper {
  position: relative;
  width: 120px;
  height: 120px;
  margin-bottom: 20px;
  border-radius: 50%;
  padding: 4px;
  background: linear-gradient(135deg, #5865F2, #eb459e);
}
.id-avatar-wrapper img {
  width: 100%;
  height: 100%;
  border-radius: 50%;
  object-fit: cover;
  background: #2b2d31;
  border: 4px solid #151522;
}
.id-status-indicator {
  position: absolute;
  bottom: 6px;
  right: 6px;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background-color: #80848e; /* offline by default */
  border: 4px solid #151522;
}
.id-status-indicator.online { background-color: #23a559; }
.id-status-indicator.idle { background-color: #f0b232; }
.id-status-indicator.dnd { background-color: #f23f43; }

.id-name { font-size: 24px; font-weight: 800; margin: 0 0 4px; letter-spacing: -0.5px; }
.id-title { font-size: 14px; color: #b5bac1; text-transform: uppercase; letter-spacing: 1px; font-weight: 600; margin-bottom: 24px; }
.id-details { width: 100%; display: flex; flex-direction: column; gap: 8px; border-top: 1px dashed rgba(255,255,255,0.1); padding-top: 16px; }
.id-row { display: flex; justify-content: space-between; font-size: 12px; color: #dbdee1; font-family: monospace; }
.id-row span { color: #949ba4; }

.id-card-footer {
  background: rgba(0,0,0,0.2);
  padding: 12px;
  text-align: center;
  font-size: 11px;
  letter-spacing: 2px;
  color: rgba(255,255,255,0.5);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}
.id-logo-small { width: 16px; height: 16px; opacity: 0.5; }
