/* Shared layout + light/dark theme (Ultra-Sleek Dark Glassmorphism) */
:root,
html[data-theme="dark"] {
  --bg: #06070a;
  --bg-elevated: #0f121a;
  --panel: rgba(18, 22, 31, 0.72);
  --panel-solid: #12161f;
  --panel-2: rgba(25, 30, 42, 0.65);
  --ink: #f8fafc;
  --muted: #94a3b8;
  --line: rgba(255, 255, 255, 0.1);
  --line-strong: rgba(255, 255, 255, 0.18);
  --input: rgba(10, 13, 19, 0.75);
  --input-ink: #f8fafc;
  --accent: #ff6a00;
  --accent-hover: #ff7f24;
  --accent-gradient: linear-gradient(135deg, #ff6a00 0%, #ff2a54 50%, #9900ef 100%);
  --accent-soft: rgba(255, 106, 0, 0.18);
  --accent-glow: rgba(255, 106, 0, 0.35);
  --link: #60a5fa;
  --danger: #f87171;
  --header-bg: rgba(6, 7, 10, 0.8);
  --footer-bg: #080a0e;
  --shadow: 0 25px 60px -15px rgba(0, 0, 0, 0.75);
  --shadow-sm: 0 8px 24px -4px rgba(0, 0, 0, 0.5);
  --radius: 12px;
  --radius-lg: 20px;
  --font: 'Plus Jakarta Sans', system-ui, -apple-system, sans-serif;
  --font-display: 'Outfit', system-ui, -apple-system, sans-serif;
  color-scheme: dark;
}

html[data-theme="light"] {
  --bg: #f8fafc;
  --bg-elevated: #ffffff;
  --panel: rgba(255, 255, 255, 0.85);
  --panel-solid: #ffffff;
  --panel-2: rgba(241, 245, 249, 0.85);
  --ink: #0f172a;
  --muted: #64748b;
  --line: rgba(15, 23, 42, 0.08);
  --line-strong: rgba(15, 23, 42, 0.15);
  --input: #ffffff;
  --input-ink: #0f172a;
  --accent: #ff5e00;
  --accent-hover: #ea580c;
  --accent-gradient: linear-gradient(135deg, #ff5e00 0%, #ff2a54 55%, #7928ca 100%);
  --accent-soft: rgba(255, 94, 0, 0.12);
  --accent-glow: rgba(255, 94, 0, 0.25);
  --link: #2563eb;
  --danger: #dc2626;
  --header-bg: rgba(255, 255, 255, 0.85);
  --footer-bg: #0f172a;
  --shadow: 0 20px 45px -10px rgba(15, 23, 42, 0.12);
  --shadow-sm: 0 4px 16px -2px rgba(15, 23, 42, 0.08);
  color-scheme: light;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  font-family: var(--font);
  background: var(--bg);
  background-image: 
    radial-gradient(ellipse 90% 50% at 50% -20%, rgba(255, 106, 0, 0.12), transparent 70%),
    radial-gradient(ellipse 60% 40% at 85% 15%, rgba(138, 43, 226, 0.08), transparent 60%),
    radial-gradient(ellipse 50% 30% at 15% 35%, rgba(0, 180, 216, 0.05), transparent 50%);
  background-attachment: fixed;
  color: var(--ink);
  line-height: 1.6;
  display: flex;
  flex-direction: column;
  -webkit-font-smoothing: antialiased;
}

a {
  color: var(--link);
  transition: color 0.18s ease;
}

img {
  max-width: 100%;
}

/* Header Glassmorphism */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: var(--header-bg);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--line);
  transition: all 0.25s ease;
}

.header-inner {
  max-width: 1100px;
  margin: 0 auto;
  padding: 0.85rem 1.25rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.65rem;
  color: var(--ink);
  text-decoration: none;
  font-family: var(--font-display);
  font-size: 1.25rem;
  font-weight: 800;
  letter-spacing: -0.03em;
  flex-shrink: 0;
}

.brand img {
  border-radius: 9px;
  filter: drop-shadow(0 2px 8px rgba(255, 106, 0, 0.35));
  transition: transform 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}

.brand:hover img {
  transform: scale(1.08) rotate(4deg);
}

.brand span {
  background: linear-gradient(135deg, #ffffff 40%, rgba(255, 255, 255, 0.75) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

html[data-theme="light"] .brand span {
  background: none;
  -webkit-text-fill-color: initial;
  color: #0f172a;
}

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

.header-nav {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.header-nav a {
  color: var(--muted);
  text-decoration: none;
  font-size: 0.92rem;
  font-weight: 600;
  padding: 0.45rem 0.8rem;
  border-radius: 8px;
  transition: all 0.18s ease;
}

.header-nav a:hover {
  color: var(--ink);
  background: rgba(255, 255, 255, 0.06);
}

html[data-theme="light"] .header-nav a:hover {
  background: rgba(15, 23, 42, 0.05);
}

.header-nav a.is-active {
  color: #fff;
  background: var(--accent-soft);
  border: 1px solid rgba(255, 106, 0, 0.25);
}

html[data-theme="light"] .header-nav a.is-active {
  color: var(--accent);
}

.theme-toggle {
  border: 1px solid var(--line);
  background: var(--panel);
  backdrop-filter: blur(12px);
  color: var(--ink);
  border-radius: 999px;
  width: 2.35rem;
  height: 2.35rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  flex-shrink: 0;
  transition: all 0.2s ease;
}

.theme-toggle:hover {
  border-color: var(--accent);
  transform: rotate(15deg);
  box-shadow: 0 0 16px var(--accent-glow);
}

.theme-toggle .icon-sun,
html[data-theme="light"] .theme-toggle .icon-moon {
  display: none;
}

html[data-theme="light"] .theme-toggle .icon-sun,
html[data-theme="dark"] .theme-toggle .icon-moon {
  display: block;
}

.site-main {
  flex: 1;
  width: 100%;
  max-width: 1100px;
  margin: 0 auto;
  padding: 2rem 1.25rem 4rem;
}

/* Footer Glassmorphism */
.site-footer {
  background: var(--footer-bg);
  color: #cbd5e1;
  border-top: 1px solid var(--line);
  margin-top: auto;
  position: relative;
}

.footer-inner {
  max-width: 1100px;
  margin: 0 auto;
  padding: 3rem 1.25rem 1.5rem;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr 1fr;
  gap: 2rem;
  margin-bottom: 2.5rem;
}

.footer-brand {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.footer-brand .brand {
  color: #fff;
}

.footer-brand p {
  margin: 0;
  color: #e2e8f0;
  font-size: 0.92rem;
  line-height: 1.55;
  max-width: 22rem;
}

.footer-col h3,
.footer-heading {
  margin: 0 0 0.85rem;
  color: #fff;
  font-family: var(--font-display);
  font-size: 0.98rem;
  font-weight: 700;
  letter-spacing: 0.02em;
}

.footer-col a {
  display: block;
  color: #cbd5e1;
  text-decoration: none;
  font-weight: 500;
  font-size: 0.9rem;
  margin-bottom: 0.5rem;
  transition: all 0.18s ease;
}

.footer-col a:hover {
  color: #fff;
  transform: translateX(3px);
}

.footer-bottom {
  border-top: 1px solid var(--line);
  padding-top: 1.25rem;
  display: flex;
  flex-wrap: wrap;
  gap: 0.85rem;
  justify-content: space-between;
  align-items: center;
  color: #cbd5e1;
  font-size: 0.86rem;
}

.footer-bottom a {
  color: #e2e8f0;
  text-decoration: none;
  font-weight: 600;
}

.footer-bottom a:hover {
  color: #fff;
}

@media (max-width: 860px) {
  .footer-grid {
    grid-template-columns: 1fr 1fr;
  }

  .header-nav a:not(.is-active):nth-child(n + 4) {
    display: none;
  }
}

@media (max-width: 560px) {
  .footer-grid {
    grid-template-columns: 1fr;
  }

  .header-inner {
    flex-wrap: wrap;
  }
}

/* Cookie consent glass */
.cookie-banner {
  position: fixed;
  left: 1.25rem;
  right: 1.25rem;
  bottom: 1.25rem;
  z-index: 100;
  max-width: 42rem;
  margin: 0 auto;
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  align-items: center;
  justify-content: space-between;
  padding: 1.1rem 1.35rem;
  border-radius: var(--radius-lg);
  background: var(--panel);
  backdrop-filter: blur(24px);
  -webkit-backdrop-filter: blur(24px);
  border: 1px solid var(--line-strong);
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.6);
  color: var(--ink);
  font-size: 0.92rem;
  animation: slideUp 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

.cookie-banner p {
  margin: 0;
  flex: 1 1 14rem;
  color: #e2e8f0;
}

.cookie-banner a {
  color: var(--accent);
}

.cookie-banner button {
  border: 0;
  border-radius: 9px;
  background: var(--accent);
  color: #fff;
  font: inherit;
  font-weight: 700;
  padding: 0.6rem 1.25rem;
  cursor: pointer;
  transition: all 0.2s ease;
}

.cookie-banner button:hover {
  background: var(--accent-hover);
  transform: translateY(-1px);
}

@keyframes slideUp {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}
