/* ==================== Theme Variables ==================== */
:root {
  --bg-primary: #ffffff;
  --bg-card: #ffffff;
  --text-primary: #1a1a1a;
  --text-secondary: #666666;
  --border-color: #e0e0e0;
  --accent-primary: #667eea;
  --accent-secondary: #764ba2;
  --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.1);
  --shadow-md: 0 4px 12px rgba(0, 0, 0, 0.15);
}

[data-theme="dark"] {
  --bg-primary: #0f0f0f;
  --bg-card: #0f0f0f;
  --text-primary: #e8e8e8;
  --text-secondary: #a0a0a0;
  --border-color: #333333;
  --accent-primary: #818cf8;
  --accent-secondary: #a78bfa;
  --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.4);
  --shadow-md: 0 4px 12px rgba(0, 0, 0, 0.5);
}

/* ==================== Base Styles ==================== */
body {
  background-color: var(--bg-primary);
  color: var(--text-primary);
  transition: background-color 0.3s ease, color 0.3s ease;
  font-family: 'Google Sans', 'Noto Sans', sans-serif;
}

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

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

.hero.teaser {
  background-color: var(--bg-primary);
}

.hero-body {
  background-color: var(--bg-primary);
}

/* ==================== Theme Toggle Button ==================== */
.theme-toggle {
  position: fixed;
  top: 20px;
  right: 20px;
  width: 50px;
  height: 50px;
  border-radius: 50%;
  background: var(--bg-card);
  border: 2px solid var(--border-color);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 24px;
  transition: all 0.3s ease;
  z-index: 1000;
  box-shadow: var(--shadow-sm);
}

.theme-toggle:hover {
  transform: scale(1.1);
  box-shadow: var(--shadow-md);
}

/* ==================== Typography ==================== */
.title, .subtitle {
  color: var(--text-primary) !important;
}

.publication-title {
  font-size: 2.5rem;
  font-weight: 700;
  line-height: 1.2;
  margin-bottom: 1.5rem;
}

.publication-authors {
  color: var(--text-secondary);
  margin-bottom: 1rem;
}

.author-block a {
  color: var(--text-primary);
  transition: color 0.3s ease;
}

.author-block a:hover {
  color: var(--accent-primary);
}

.venue-badge {
  background: linear-gradient(135deg, var(--accent-primary), var(--accent-secondary));
  color: white;
  padding: 8px 20px;
  border-radius: 25px;
  font-weight: 600;
  display: inline-block;
  margin-top: 10px;
}

/* ==================== Camera3DMM Branding ==================== */
.camera3dmm-text {
  background: linear-gradient(135deg, var(--accent-primary), var(--accent-secondary));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  font-weight: 600;
}

/* ==================== Buttons & Links ==================== */
.button {
  background-color: var(--bg-card);
  color: var(--text-primary);
  border: 2px solid var(--border-color);
  transition: all 0.3s ease;
}

.button:hover {
  background-color: var(--accent-primary);
  color: white;
  border-color: var(--accent-primary);
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

.button.is-dark {
  background: linear-gradient(135deg, var(--accent-primary), var(--accent-secondary));
  color: white;
  border: none;
}

.button.is-dark:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
  opacity: 0.9;
}

.publication-links {
  display: flex;
  gap: 15px;
  justify-content: center;
  flex-wrap: wrap;
  margin-top: 30px;
}

.link-block {
  display: inline-block;
}

/* ==================== Content Sections ==================== */
.container {
  background-color: var(--bg-primary);
}

.content {
  color: var(--text-primary);
}

.content p {
  color: var(--text-secondary);
  line-height: 1.8;
  margin-bottom: 1rem;
}

.content h2, .content h3, .content h4 {
  color: var(--text-primary);
  margin-top: 2rem;
  margin-bottom: 1rem;
}

/* ==================== Images ==================== */
img {
  box-shadow: var(--shadow-sm);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

img:hover {
  transform: scale(1.02);
  box-shadow: var(--shadow-md);
}

/* ==================== Videos ==================== */
video {
  box-shadow: var(--shadow-sm);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

video:hover {
  transform: scale(1.01);
  box-shadow: var(--shadow-md);
}

/* ==================== Code Blocks ==================== */
pre {
  background-color: var(--bg-card) !important;
  border: 1px solid var(--border-color);
  border-radius: 10px;
  padding: 20px;
  overflow-x: auto;
}

code {
  background-color: var(--bg-card) !important;
  color: var(--text-primary) !important;
  padding: 2px 6px;
  border-radius: 4px;
}

pre code {
  background-color: transparent !important;
  padding: 0;
  color: var(--text-primary) !important;
}

/* ==================== Footer ==================== */
.footer {
  background-color: var(--bg-primary);
  color: var(--text-secondary);
  border-top: 1px solid var(--border-color);
  padding: 3rem 1.5rem;
}

.footer a {
  color: var(--accent-primary);
}

.footer a:hover {
  color: var(--accent-secondary);
}

/* ==================== Columns ==================== */
.column {
  background-color: var(--bg-primary);
}

/* ==================== Responsive Design ==================== */
@media screen and (max-width: 768px) {
  .publication-title {
    font-size: 1.8rem;
  }

  .theme-toggle {
    top: 10px;
    right: 10px;
    width: 40px;
    height: 40px;
    font-size: 20px;
  }

  .publication-links {
    flex-direction: column;
    align-items: center;
  }

  .link-block {
    width: 100%;
    max-width: 300px;
  }
}

/* ==================== Smooth Transitions ==================== */
* {
  transition: background-color 0.3s ease, color 0.3s ease, border-color 0.3s ease;
}

/* ==================== Selection ==================== */
::selection {
  background-color: var(--accent-primary);
  color: white;
}

::-moz-selection {
  background-color: var(--accent-primary);
  color: white;
}

/* ==================== Custom Scrollbar ==================== */
::-webkit-scrollbar {
  width: 12px;
}

::-webkit-scrollbar-track {
  background: var(--bg-primary);
}

::-webkit-scrollbar-thumb {
  background: var(--accent-primary);
  border-radius: 6px;
}

::-webkit-scrollbar-thumb:hover {
  background: var(--accent-secondary);
}

/* ==================== Card Styles ==================== */
.content-card {
  background-color: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: 12px;
  padding: 30px;
  margin-bottom: 30px;
  box-shadow: var(--shadow-sm);
}

.content-card:hover {
  box-shadow: var(--shadow-md);
  transform: translateY(-2px);
}