/* ==========================================================================
   LUMINA — LAYOUT & NAVIGATION (Fixed Header & Graphic Logo)
   ========================================================================== */

.container {
  width: 100%;
  max-width: var(--max-width-content);
  margin-left: auto;
  margin-right: auto;
  padding-left: var(--space-6);
  padding-right: var(--space-6);
}

.container-narrow {
  max-width: var(--max-width-article);
}

/* Header & Navigation Fix */
.header {
  position: sticky;
  top: 0;
  z-index: 100;
  background-color: rgba(226, 232, 240, 0.88);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--border-subtle);
  transition: background-color var(--transition-normal);
}

[data-theme="dark"] .header {
  background-color: rgba(9, 10, 12, 0.92);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 72px;
  gap: var(--space-4);
}

/* Standalone Graphic Logo — Sleek Cyber Aesthetics */
.brand-logo-link {
  display: inline-flex;
  align-items: center;
  text-decoration: none;
  color: var(--text-primary);
  transition: transform 0.25s cubic-bezier(0.4, 0, 0.2, 1);
}

.brand-logo-link:hover {
  transform: translateY(-1px) scale(1.02);
}

.brand-logo-container {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 6px 12px 6px 8px;
  border-radius: 10px;
  background: rgba(74, 222, 128, 0.03);
  border: 1px solid rgba(74, 222, 128, 0.12);
  box-shadow: 0 0 16px rgba(74, 222, 128, 0.06);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  position: relative;
  overflow: hidden;
}

.brand-logo-container::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0; bottom: 0;
  background: linear-gradient(135deg, rgba(74, 222, 128, 0.15) 0%, transparent 60%);
  opacity: 0;
  transition: opacity 0.3s ease;
  pointer-events: none;
}

.brand-logo-link:hover .brand-logo-container::before {
  opacity: 1;
}

.brand-logo-link:hover .brand-logo-container {
  border-color: rgba(74, 222, 128, 0.4);
  box-shadow: 0 0 24px rgba(74, 222, 128, 0.25), inset 0 0 12px rgba(74, 222, 128, 0.08);
  background: rgba(74, 222, 128, 0.06);
}

.brand-emblem-wrapper {
  height: 38px;
  display: flex;
  align-items: center;
  justify-content: center;
  filter: drop-shadow(0 0 10px rgba(74, 222, 128, 0.45));
  transition: filter 0.3s ease;
}

.brand-logo-link:hover .brand-emblem-wrapper {
  filter: drop-shadow(0 0 16px rgba(74, 222, 128, 0.85)) drop-shadow(0 0 25px rgba(34, 197, 94, 0.5));
}

.brand-emblem-img {
  height: 36px;
  width: auto;
  object-fit: contain;
  border-radius: 4px;
}

.brand-emblem-svg {
  width: 42px !important;
  height: 32px !important;
  display: inline-block !important;
  flex-shrink: 0;
  filter: drop-shadow(0 0 10px rgba(74, 222, 128, 0.7));
  transition: filter 0.3s ease;
}

.brand-logo-link:hover .brand-emblem-svg {
  filter: drop-shadow(0 0 16px rgba(74, 222, 128, 1)) drop-shadow(0 0 26px rgba(34, 197, 94, 0.7));
}

.brand-text-block {
  display: flex;
  flex-direction: column;
  line-height: 1;
  justify-content: center;
}

.brand-title {
  font-size: 1.28rem;
  font-weight: 900;
  letter-spacing: 0.15em;
  color: var(--text-primary);
  text-transform: uppercase;
  text-shadow: 0 0 12px rgba(255, 255, 255, 0.15);
}

.brand-subtitle {
  font-size: 0.64rem;
  font-weight: 800;
  letter-spacing: 0.32em;
  color: #4ADE80;
  text-transform: uppercase;
  margin-top: 3px;
  text-shadow: 0 0 10px rgba(74, 222, 128, 0.6);
}

/* Navigation Menu Fix — Single line, no wrapping, horizontal inline flex */
.nav-links {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  list-style: none;
  margin: 0;
  padding: 0;
}

.nav-item {
  display: inline-block;
  white-space: nowrap;
}

.nav-item a {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 14px;
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--text-secondary);
  border-radius: var(--radius-full);
  text-decoration: none;
  white-space: nowrap;
  transition: all var(--transition-fast);
}

.nav-item a:hover {
  color: var(--text-primary);
  background-color: var(--bg-surface-hover);
}

.nav-item a.active {
  color: var(--text-primary);
  background-color: var(--bg-surface-hover);
}

/* Header Action Controls */
.header-actions {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  white-space: nowrap;
}

.btn-author-mode {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 14px;
  border-radius: var(--radius-full);
  background-color: var(--accent-subtle);
  color: var(--accent-subtle-text);
  border: 1px solid var(--accent-subtle-text);
  font-size: 0.8rem;
  font-weight: 700;
  white-space: nowrap;
  transition: all var(--transition-fast);
}

.btn-editor-open {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 16px;
  border-radius: var(--radius-full);
  background-color: var(--text-primary);
  color: var(--bg-canvas);
  font-size: 0.85rem;
  font-weight: 700;
  white-space: nowrap;
  transition: opacity var(--transition-fast);
}

.btn-editor-open:hover { opacity: 0.9; }

.command-trigger {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  padding: 6px var(--space-4);
  height: 38px;
  border-radius: var(--radius-full);
  background-color: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  color: var(--text-muted);
  font-size: 0.85rem;
  font-weight: 500;
  white-space: nowrap;
  transition: all var(--transition-fast);
}

.command-trigger:hover {
  border-color: var(--border-strong);
  color: var(--text-primary);
  background-color: var(--bg-surface-hover);
}

.command-kbd {
  font-family: var(--font-mono);
  font-size: 0.7rem;
  padding: 2px 6px;
  background-color: var(--bg-elevated);
  border-radius: var(--radius-xs);
  color: var(--text-muted);
}

.btn-icon {
  width: 38px;
  height: 38px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--radius-full);
  color: var(--text-secondary);
  border: 1px solid var(--border-subtle);
  background-color: var(--bg-surface);
  transition: all var(--transition-fast);
}

.btn-icon:hover {
  color: var(--text-primary);
  border-color: var(--border-strong);
  background-color: var(--bg-surface-hover);
}

/* Main Layout Wrapper */
.main-wrapper {
  flex: 1;
  padding-top: var(--space-8);
  padding-bottom: var(--space-16);
}

.section-header {
  margin-bottom: var(--space-8);
  padding-bottom: var(--space-4);
  border-bottom: 1px solid var(--border-subtle);
}

.section-title {
  font-size: 1.65rem;
  font-weight: 800;
  letter-spacing: -0.025em;
  color: var(--text-primary);
  margin-bottom: var(--space-1);
}

.section-subtitle {
  font-size: 0.9rem;
  color: var(--text-muted);
}

/* Footer Layout */
.footer {
  background-color: var(--bg-surface);
  border-top: 1px solid var(--border-subtle);
  padding-top: var(--space-16);
  padding-bottom: var(--space-12);
  margin-top: auto;
}

.footer-grid {
  display: grid;
  grid-template-columns: 2.5fr 1fr;
  gap: var(--space-8);
  margin-bottom: var(--space-12);
}

.footer-brand {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  font-size: 1.2rem;
  font-weight: 800;
  margin-bottom: var(--space-4);
}

.footer-desc {
  font-size: 0.875rem;
  color: var(--text-muted);
  max-width: 320px;
  line-height: 1.6;
}

.footer-heading {
  font-size: 0.8rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--text-primary);
  margin-bottom: var(--space-4);
}

.footer-links {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: var(--space-2);
}

.footer-links a {
  font-size: 0.875rem;
  color: var(--text-secondary);
  transition: color var(--transition-fast);
}

.footer-links a:hover {
  color: var(--text-primary);
}

.footer-bottom {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-top: var(--space-6);
  border-top: 1px solid var(--border-subtle);
  font-size: 0.8rem;
  color: var(--text-muted);
}

@media (max-width: 900px) {
  .nav-links { display: none; }
  .command-text { display: none; }
  .footer-grid { grid-template-columns: 1fr; gap: var(--space-6); }
}
