:root {
  --bg: #1a1f26;
  --text: #eef2f7;
  --muted: #d6dde6;
  --accent: #a7b3bf;
  --glass: rgba(12, 14, 16, 0.35);
  --glass-border: rgba(255, 255, 255, 0.18);
  --radius: 14px;
  --space: 16px;
  --space-lg: 24px;
  --maxw: 960px;
}

* { box-sizing: border-box; }
html, body { height: 100%; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font: 400 16px/1.6 Inter, system-ui, -apple-system, Segoe UI, Roboto, "Helvetica Neue", Arial, "Noto Sans", "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol";
}

/* Background image layer with subtle blur; glass adds more blur on top */
body::before {
  content: "";
  position: fixed;
  inset: 0;
  background: url('/bg.jpg') center / cover no-repeat;
  filter: blur(2px) saturate(110%);
  z-index: -1;
}

@media (max-width: 640px) {
  body::before { filter: blur(2px) saturate(110%); }
}

#app-root { min-height: 100vh; display: flex; flex-direction: column; }
#app { flex: 1; }

.container {
  width: 100%;
  max-width: var(--maxw);
  padding: 0 var(--space);
  margin: var(--space) auto;
}

/* Frosted glass utility */
.glass {
  background: var(--glass);
  border: 1px solid var(--glass-border);
  backdrop-filter: blur(16px) saturate(140%);
  -webkit-backdrop-filter: blur(16px) saturate(140%);
  border-radius: var(--radius);
  box-shadow: 0 8px 24px rgba(0,0,0,0.35);
}

/* Header */
#site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  margin: 0; padding: 10px 0;
  background: linear-gradient(to bottom, rgba(26,31,38,0.9), rgba(26,31,38,0.5) 50%, rgba(26,31,38,0));
}

.nav-shell {
  display: flex; align-items: center; justify-content: space-between;
}

.brand {
  font-weight: 700; letter-spacing: 0.1em; font-size: 1.1rem;
}

.nav-links { display: flex; gap: 20px; align-items: center; }
.nav-link {
  text-decoration: none; color: var(--text); text-transform: uppercase; font-size: 0.9rem;
  padding: 6px 0; border-bottom: 2px solid transparent; transition: border-color .2s ease, color .2s ease;
}
.nav-link:hover { color: #fff; border-color: var(--accent); }
.nav-link.active { border-color: #e2e8f0; }
.nav-link:focus-visible, .button:focus-visible, a:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; border-radius: 8px; }
.nav-link:focus-visible, .button:focus-visible, a:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; border-radius: 8px; }

.burger { display: none; background: none; color: var(--text); border: 1px solid var(--glass-border); padding: 8px 10px; border-radius: 10px; }

/* Footer */
#site-footer { margin-top: 0; padding: 10px 0; }
.footer-shell { position: relative; display: flex; align-items: center; justify-content: center; gap: var(--space); text-align: center; }
.footer-version { position: absolute; right: var(--space); color: var(--muted); font-size: 0.8rem; }
.footer-left { color: var(--muted); font-size: 0.9rem; }
.social { display: flex; gap: 12px; }
.social a { display: inline-flex; width: 24px; height: 24px; opacity: 0.9; }
.social a:hover { opacity: 1; }
.social img { width: 100%; height: 100%; filter: invert(85%); }

/* Cards and lists */
.grid { display: grid; gap: var(--space); grid-template-columns: repeat(1, minmax(0, 1fr)); }
@media (min-width: 720px) { .grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.card { padding: var(--space); border-radius: var(--radius); }
.split { display: grid; grid-template-columns: 1fr; gap: var(--space); }
@media (min-width: 880px) { .split { grid-template-columns: 3fr 2fr; } }
.card .thumb { width: 100%; aspect-ratio: 16 / 9; height: auto; object-fit: cover; border-radius: 10px; margin-bottom: 10px; opacity: 0.95; }
.card h3 { margin: 0 0 6px; font-weight: 600; }
.card p { margin: 0; color: var(--text); }
.card a { color: inherit; text-decoration: none; display: block; }
.card a:focus-visible { outline: 2px solid var(--accent); outline-offset: 4px; border-radius: 8px; }

/* Headings */
h1 { font-size: 3rem; line-height: 1.1; margin: 0 0 12px; font-weight: 700; text-shadow: 0 0 4px rgba(0,0,0,0.85); }
h2 { font-size: 1.6rem; margin: var(--space-lg) 0 var(--space); font-weight: 600; }
.section-title { font-size: 2.2rem; letter-spacing: .02em; }

.hero { display: grid; place-items: center; min-height: 12vh; text-align: center; gap: 2px; }
.hero p { color: var(--muted); margin: 0; }

.logo {
  width: 160px; height: auto; display: block; margin: 0 auto 6px; opacity: 0.95;
}

.brand-logo { height: 24px; width: auto; display: block; opacity: 0.95; }
.brand-text { color: var(--text); font-weight: 600; letter-spacing: .02em; }

.hero-logo { width: clamp(240px, 32vw, 520px); height: auto; display: inline-block; opacity: 0.98; filter: drop-shadow(0px 1px 3px rgba(0, 0, 0, 1)); }

.btns { display: flex; gap: 10px; flex-wrap: wrap; }
.button {
  display: inline-flex; align-items: center; gap: 8px; padding: 8px 12px; border-radius: 10px;
  background: var(--glass); border: 1px solid var(--glass-border); color: var(--text); text-decoration: none;
}
.button:hover { filter: brightness(1.1); }
.button[aria-disabled="true"] { opacity: 0.6; pointer-events: none; }
.store-btn img { height: 48px; width: auto; display: inline-block; }

/* Lightbox */
#lightbox-overlay { position: fixed; inset: 0; background: rgba(0,0,0,0.7); display: none; align-items: center; justify-content: center; z-index: 1000; }
#lightbox-overlay.open { display: flex; }
#lightbox-overlay .lb-content { position: relative; max-width: 90vw; max-height: 90vh; }
#lightbox-overlay img { max-width: 90vw; max-height: 80vh; border-radius: 12px; box-shadow: 0 10px 30px rgba(0,0,0,0.6); }
#lightbox-overlay .lb-close { position: absolute; top: -36px; right: -6px; background: none; border: none; color: #fff; font-size: 32px; cursor: pointer; }
#lightbox-overlay .lb-controls { position: absolute; inset: 0; display: flex; align-items: center; justify-content: space-between; pointer-events: none; }
#lightbox-overlay .lb-prev, #lightbox-overlay .lb-next { pointer-events: all; background: rgba(0,0,0,0.4); border: 1px solid var(--glass-border); color: #fff; width: 44px; height: 44px; border-radius: 22px; display: grid; place-items: center; margin: 0 8px; cursor: pointer; }

/* Utilities */
.hidden { display: none !important; }
.stack { display: grid; gap: var(--space); }
.inline { display: inline-flex; gap: 8px; align-items: center; }
.muted { color: var(--muted); }
.small { font-size: 0.8rem; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0, 0, 1px, 1px); border: 0; }

/* Mobile nav */
@media (max-width: 640px) {
  .nav-links { display: none; }
  .nav-links.open {
    display: flex; position: absolute; right: var(--space); top: 64px; flex-direction: column; gap: 12px; padding: 14px;
    background: rgba(20, 24, 30, 0.85); border: 1px solid rgba(255,255,255,0.2);
    backdrop-filter: blur(20px) saturate(150%);
    -webkit-backdrop-filter: blur(20px) saturate(150%);
    border-radius: 14px; box-shadow: 0 12px 32px rgba(0,0,0,0.45);
  }
  .burger { display: inline-flex; }
}
