/* ===== CSS Variables & Reset ===== */
:root {
  --bg-gradient: linear-gradient(145deg, #10161a 0%, #1a252c 100%);
  --text-main: #eef4ff;
  --accent-gold: #e4b363;
  --accent-hover: #f5cd8c;
  --card-bg: rgba(255, 255, 255, 0.04);
  --border-color: rgba(255, 255, 255, 0.06);
  --footer-bg: rgba(25, 38, 46, 0.85);
  --focus-ring: rgba(228, 179, 99, 0.4);
}

body.light-theme {
  --bg-gradient: linear-gradient(145deg, #f0f2f5 0%, #e4e8ed 100%);
  --text-main: #1a1a2e;
  --accent-gold: #c0392b;
  --accent-hover: #e74c3c;
  --card-bg: rgba(255, 255, 255, 0.7);
  --border-color: rgba(0, 0, 0, 0.06);
  --footer-bg: rgba(255, 255, 255, 0.85);
  --focus-ring: rgba(192, 57, 43, 0.3);
}

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

body {
  background: var(--bg-gradient);
  font-family: 'Inter', system-ui, -apple-system, 'Segoe UI', sans-serif;
  min-height: 100vh;
  padding: 2rem 1.5rem;
  color: var(--text-main);
  transition: background 0.3s ease, color 0.3s ease;
}

.arsenal-container {
  max-width: auto;
  margin: 0 auto;
}

/* ===== Accessibility & Interactive Focus ===== */
button,
a,
input,
select {
  outline: none;
}

button:focus-visible,
a:focus-visible,
input:focus-visible,
select:focus-visible {
  outline: 2px solid var(--accent-gold);
  outline-offset: 2px;
}

button {
  border: none;
  font-weight: 600;
  padding: 0.85rem 1.8rem;
  border-radius: 60px;
  font-size: 0.95rem;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  transition: transform 0.1s ease, background 0.2s;
}

button:active {
  transform: scale(0.97);
}

/* ===== Theme Toggle ===== */
.theme-toggle-btn {
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.15);
  color: #e0e0e0;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  cursor: pointer;
  font-size: 1.2rem;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.3s ease;
  flex-shrink: 0;
  padding: 0;
}

.theme-toggle-btn:hover {
  background: rgba(255, 255, 255, 0.18);
  transform: scale(1.08) rotate(10deg);
}

.theme-toggle-btn:active {
  transform: scale(0.92);
}

body.light-theme .theme-toggle-btn {
  background: rgba(0, 0, 0, 0.06);
  border: 1px solid rgba(0, 0, 0, 0.12);
  color: var(--text-main);
}

body.light-theme .theme-toggle-btn:hover {
  background: rgba(0, 0, 0, 0.12);
  transform: scale(1.08) rotate(-10deg);
}

/* ===== Hub Header ===== */
.hub-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 1.5rem;
  margin-bottom: 2.5rem;
  padding-bottom: 0.75rem;
  border-bottom: 1px solid var(--border-color);
}

.hub-header h1 {
  font-weight: 600;
  font-size: 2rem;
  letter-spacing: -0.02em;
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.hub-header h1 i {
  color: var(--accent-gold);
  font-size: 2rem;
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 1rem;
}

/* ===== Single Column Link List ===== */
.hub-link-list {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  margin: 1.5rem 0 2.5rem;
}

.hub-link-item {
  display: flex;
  align-items: center;
  gap: 1.2rem;
  background: var(--card-bg);
  backdrop-filter: blur(2px);
  border: 1px solid var(--border-color);
  border-radius: 20px;
  padding: 1.2rem 1.8rem;
  transition: background 0.15s ease, border-color 0.15s ease;
  box-shadow: 0 4px 12px -6px rgba(0, 0, 0, 0.3);
  text-decoration: none;
  color: inherit;
}

.hub-link-item:hover {
  background: rgba(255, 255, 255, 0.09);
  border-color: rgba(228, 179, 99, 0.3);
}

body.light-theme .hub-link-item:hover {
  background: rgba(255, 255, 255, 0.9);
  border-color: rgba(192, 57, 43, 0.25);
}

.link-icon {
  font-size: 1.6rem;
  color: var(--accent-gold);
  width: 2.4rem;
  text-align: center;
  flex-shrink: 0;
}

.link-content {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 0.15rem;
}

.link-title {
  font-weight: 600;
  font-size: 1.15rem;
  letter-spacing: -0.01em;
}

.link-desc {
  font-size: 0.85rem;
  opacity: 0.6;
}

.link-arrow {
  color: #7e95ab;
  font-size: 1rem;
  opacity: 0.5;
  transition: opacity 0.2s, transform 0.2s;
  flex-shrink: 0;
}

.hub-link-item:hover .link-arrow {
  opacity: 1;
  transform: translateX(4px);
}

body.light-theme .link-arrow {
  color: #4a5568;
}

/* ===== Footer ===== */
.hub-footer {
  margin-top: 40px;
  padding: 20px 0;
  background: var(--footer-bg);
  backdrop-filter: blur(8px);
  border-radius: 28px;
  border: 1px solid var(--border-color);
  transition: all 0.3s ease;
}

.footer-content {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0 24px;
  flex-wrap: wrap;
  gap: 16px;
}

.footer-left {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}

.footer-brand {
  font-weight: 600;
  color: var(--text-main);
  display: flex;
  align-items: center;
  gap: 8px;
}

.footer-brand i {
  color: var(--accent-gold);
}

.footer-divider {
  color: #7e95ab;
  opacity: 0.3;
}

.footer-year {
  color: #7e95ab;
  font-size: 0.9rem;
}

.footer-right {
  display: flex;
  align-items: center;
}

body.light-theme .footer-divider,
body.light-theme .footer-year {
  color: #8a94a0;
}

/* ===== Responsive Rules ===== */
@media (max-width: 768px) {
  .footer-content {
    flex-direction: column;
    align-items: center;
    text-align: center;
    gap: 12px;
    padding: 0 16px;
  }
  .footer-left { justify-content: center; }
}

@media (max-width: 680px) {
  body { padding: 1rem; }
  .hub-header h1 { font-size: 1.6rem; }
  .hub-link-item { padding: 1rem 1.2rem; }
}

@media (max-width: 480px) {
  .hub-header { flex-direction: column; align-items: flex-start; }
  .header-actions { width: 100%; justify-content: flex-start; }
  .link-icon { font-size: 1.3rem; width: 1.8rem; }
  .link-title { font-size: 1rem; }
  .footer-left { flex-direction: column; gap: 4px; }
  .footer-divider { display: none; }
}

@media (prefers-reduced-motion: reduce) {
  *, ::before, ::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}