/* =======================
   Ariadne Clew Core Styles
   ======================= */

/* Variables */
:root {
  --bg: #ffffff;
  --panel: rgba(248, 249, 250, 0.9);
  --text: #212529;
  --muted: #6c757d;
  --accent: #d4a017; /* gold thread */
  --accent-2: #6f42c1;
  --accent-glow: rgba(212, 160, 23, 0.5);
  --danger: #dc3545;
  --border: rgba(0, 0, 0, 0.1);
  --input-bg: #ffffff;
}

[data-theme='dark'] {
  --bg: #0f1115;
  --panel: rgba(21, 25, 34, 0.9);
  --text: #e6e7ea;
  --muted: #a6adbb;
  --accent: #8f6aff; /* violet thread */
  --accent-2: #6aa9ff;
  --accent-glow: rgba(143, 106, 255, 0.5);
  --danger: #ff6a85;
  --border: rgba(255, 255, 255, 0.1);
  --input-bg: #0e121a;
}

/* Base Layout */
body {
  margin: 0;
  font-family: "Poppins", sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
  background-attachment: fixed;
  background-size: cover;
}

.container {
  max-width: 960px;
  margin: 0 auto;
  padding: 2rem;
}

/* Hero Header */
header.hero {
  text-align: center;
  padding: 3rem 1rem 2rem;
  position: relative;
}

header.hero h1 {
  font-size: 2.5rem;
  margin: 0;
}

header.hero .subtitle {
  color: var(--muted);
  font-size: 1.1rem;
  margin-top: 0.5rem;
}

header.hero .tagline {
  font-style: italic;
  color: var(--accent-2);
  margin-top: 0.5rem;
}

/* Labyrinth thread line */
header.hero::after {
  content: "";
  position: absolute;
  bottom: 0;
  left: 50%;
  width: 200px;
  height: 4px;
  background: linear-gradient(90deg, var(--accent), var(--accent-2));
  border-radius: 4px;
  transform: translateX(-50%);
  animation: pulseThread 3s infinite alternate;
}

@keyframes pulseThread {
  from { opacity: 0.4; }
  to { opacity: 1; }
}

/* Form */
form#recap-form {
  background: var(--panel);
  padding: 2rem;
  border-radius: 12px;
  box-shadow: 0 0 15px var(--accent-glow);
}

label {
  font-weight: 500;
}

input[type="text"], input[type="file"] {
  width: 100%;
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 0.6rem 0.8rem;
  margin-top: 0.5rem;
  background: var(--input-bg);
  color: var(--text);
}

input:focus {
  border-color: var(--accent);
  outline: none;
  box-shadow: 0 0 6px var(--accent-glow);
}

/* Drop Zone */
#drop-zone {
  border: 2px dashed var(--border);
  background: var(--panel);
  color: var(--muted);
  padding: 2rem;
  text-align: center;
  border-radius: 12px;
  margin-top: 1rem;
  transition: all 0.3s ease;
}

#drop-zone.highlight {
  border-color: var(--accent);
  color: var(--accent);
  box-shadow: 0 0 12px var(--accent-glow);
}

/* Buttons */
button {
  border: 1px solid var(--border);
  background: transparent;
  color: var(--text);
  padding: 0.6rem 1.2rem;
  margin: 0.3rem;
  border-radius: 999px;
  font-weight: 500;
  cursor: pointer;
  transition: color 0.3s, box-shadow 0.3s;
  position: relative;
}

button:hover {
  color: var(--accent);
  box-shadow: 0 0 12px var(--accent-glow);
}

/* Panels */
.panel {
  background: var(--panel);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 1.5rem;
  margin-top: 1.5rem;
  box-shadow: 0 0 15px var(--accent-glow);
  font-family: "Source Code Pro", monospace;
  white-space: pre-wrap;
  overflow-x: auto;
}

/* Footer */
footer {
  text-align: center;
  margin-top: 3rem;
  padding: 1.5rem 1rem;
  font-size: 0.9rem;
  color: var(--muted);
}

/* Theme Toggle */
.switch {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  margin-bottom: 1rem;
}

.switch input {
  opacity: 0;
  width: 0;
  height: 0;
}

.slider {
  position: relative;
  cursor: pointer;
  width: 50px;
  height: 24px;
  background-color: var(--border);
  border-radius: 24px;
  transition: background-color 0.3s;
  box-shadow: 0 0 6px var(--accent-glow);
}

.slider:before {
  content: "";
  position: absolute;
  height: 18px;
  width: 18px;
  left: 3px;
  top: 3px;
  background-color: white;
  border-radius: 50%;
  transition: transform 0.3s;
}

input:checked + .slider {
  background-color: var(--accent);
}

input:checked + .slider:before {
  transform: translateX(26px);
}
