/* ==========================================================================
   ROSENGARD STOREFRONT - Dark Cyber Sigilism Core Design System
   ========================================================================== */

:root {
  /* Color Palette */
  --bg-base: #050507;
  --bg-surface: #09090d;
  --bg-card: #08080c;
  --bg-card-hover: #0d080b;

  --border-subtle: #1a0609;
  --border-muted: #2c090e;
  --border-active: #8a0303;
  --border-highlight: #ff1e1e;

  --primary: #8a0303;
  --primary-light: #b80d0d;
  --primary-glow: rgba(184, 13, 13, 0.4);

  --text-primary: #f0f0f0;
  --text-secondary: #dedede;
  --text-muted: #737373;
  --text-dark: #3a3a3a;

  /* Typography */
  --font-serif: 'Cinzel', serif;
  --font-sans: 'Space Grotesk', -apple-system, sans-serif;
  --font-mono: 'JetBrains Mono', monospace;

  /* Layout */
  --container-width: 1360px;
  --header-height: 72px;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  -webkit-tap-highlight-color: transparent;
}

html {
  font-size: 16px;
  background-color: var(--bg-base);
  color: var(--text-primary);
  font-family: var(--font-sans);
  scroll-behavior: smooth;
  overflow-x: hidden;
  scrollbar-gutter: stable;
  width: 100%;
}

body {
  min-height: 100vh;
  width: 100%;
  max-width: 100vw;
  background-color: transparent;
  overflow-x: hidden;
  line-height: 1.5;
  display: flex;
  flex-direction: column;
}

/* ==========================================================================
   Ambient Atmospheric Background System
   ========================================================================== */
.site-ambient-backdrop {
  position: fixed;
  inset: 0;
  width: 100vw;
  height: 100vh;
  z-index: 0;
  pointer-events: none;
  overflow: hidden;
  background-color: var(--bg-base);
  background-image: radial-gradient(rgba(138, 3, 3, 0.12) 1px, transparent 1px);
  background-size: 16px 16px;
}

.backdrop-art-layer {
  position: absolute;
  top: -14vh;
  left: -8vw;
  width: 116vw;
  height: 128vh;
  background-size: cover;
  background-position: center top;
  background-repeat: no-repeat;
  transition: opacity 0.5s cubic-bezier(0.16, 1, 0.3, 1), filter 0.5s ease;
  filter: contrast(1.18) brightness(1.28) saturate(1.3);
  opacity: 1;
  will-change: transform;
  transform: translate3d(0, 0, 0) scale(1.1);
  transform-origin: center center;
  z-index: 1;
}

.backdrop-video-layer {
  position: absolute;
  top: -14vh;
  left: -8vw;
  width: 116vw;
  height: 128vh;
  object-fit: cover;
  object-position: center top;
  pointer-events: none;
  transition: opacity 0.5s cubic-bezier(0.16, 1, 0.3, 1), filter 0.5s ease;
  filter: contrast(1.18) brightness(1.28) saturate(1.3);
  opacity: 1;
  will-change: transform;
  transform: translate3d(0, 0, 0) scale(1.1);
  transform-origin: center center;
  z-index: 1;
}

.backdrop-overlay-gradient {
  position: absolute;
  inset: 0;
  background: 
    radial-gradient(ellipse at 50% 25%, transparent 0%, rgba(5, 5, 7, 0.25) 55%, rgba(5, 5, 7, 0.7) 100%),
    linear-gradient(to bottom, rgba(5, 5, 7, 0.35) 0%, transparent 15%, transparent 70%, rgba(5, 5, 7, 0.65) 100%);
  pointer-events: none;
  z-index: 2;
}

/* Ambient Film Grain Canvas */
.film-grain-canvas {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 9999;
  mix-blend-mode: overlay;
  opacity: 0.08;
}

/* Container */
.container {
  width: 100%;
  max-width: var(--container-width);
  margin: 0 auto;
  padding: 0 1.25rem;
}

/* ==========================================================================
   Header & Navigation
   ========================================================================== */
.site-header {
  position: sticky;
  top: 0;
  z-index: 200;
  height: var(--header-height);
  background: rgba(5, 5, 7, 0.94);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--border-subtle);
  display: flex;
  align-items: center;
  padding: 0 2.5rem;
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  gap: 1.5rem;
}

.brand-group {
  display: flex;
  align-items: center;
  gap: 1.15rem;
  text-decoration: none;
  color: inherit;
  transition: transform 0.2s ease;
}

.brand-group:hover {
  transform: translateX(2px);
}

.brand-logo-img {
  height: 52px;
  width: auto;
  max-width: 105px;
  object-fit: contain;
  filter: drop-shadow(0 2px 8px rgba(0, 0, 0, 0.9));
  transition: transform 0.25s cubic-bezier(0.16, 1, 0.3, 1), filter 0.25s ease;
}

.brand-group:hover .brand-logo-img {
  transform: scale(1.06);
  filter: drop-shadow(0 2px 12px rgba(0, 0, 0, 0.95)) brightness(1.1);
}

.brand-text {
  display: flex;
  flex-direction: column;
  gap: 0.15rem;
}

.brand-title {
  font-family: var(--font-serif);
  font-size: 1.65rem;
  font-weight: 900;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: #dedede;
  line-height: 1;
}

.brand-title span {
  color: var(--primary-light);
}

.brand-subtitle {
  font-family: var(--font-mono);
  font-size: 0.65rem;
  color: var(--text-muted);
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

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

/* Currency & Language Switcher Buttons */
.currency-toggle,
.lang-toggle {
  display: flex;
  background: #09090d;
  border: 1px solid var(--border-subtle);
}

.currency-btn,
.lang-btn {
  background: transparent;
  border: none;
  color: var(--text-muted);
  font-family: var(--font-mono);
  font-size: 0.74rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  padding: 0.4rem 0.65rem;
  cursor: pointer;
  transition: all 0.15s ease;
}

.currency-btn:hover,
.lang-btn:hover {
  color: var(--text-primary);
}

.currency-btn.active,
.lang-btn.active {
  background: var(--primary);
  color: #ffffff;
}

/* Telegram Direct Contact Link in Header */
.header-contact-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  background: #0c0507;
  border: 1px solid var(--border-active);
  color: var(--text-primary);
  font-family: var(--font-mono);
  font-size: 0.74rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  padding: 0.42rem 0.85rem;
  text-decoration: none;
  transition: all 0.2s ease;
  clip-path: polygon(4px 0, 100% 0, 100% calc(100% - 4px), calc(100% - 4px) 100%, 0 100%, 0 4px);
}

.header-contact-btn:hover {
  background: var(--primary);
  border-color: var(--border-highlight);
  box-shadow: 0 0 18px var(--primary-glow);
}

/* ==========================================================================
   Hero Section
   ========================================================================== */
.site-hero {
  padding: 3rem 0 2rem 0;
  border-bottom: 1px solid var(--border-subtle);
  position: relative;
  overflow: hidden;
}

.hero-content {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.hero-sigil-tag {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-family: var(--font-mono);
  font-size: 0.72rem;
  color: var(--primary-light);
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.hero-sigil-dot {
  width: 6px;
  height: 6px;
  background: var(--primary);
  clip-path: polygon(50% 0%, 100% 50%, 50% 100%, 0% 50%);
}

.hero-title {
  font-family: var(--font-serif);
  font-size: clamp(2rem, 5vw, 3.5rem);
  font-weight: 900;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-primary);
  line-height: 1.1;
}

.hero-description {
  color: var(--text-muted);
  font-size: clamp(0.85rem, 2vw, 1rem);
  max-width: 680px;
  font-family: var(--font-mono);
  letter-spacing: 0.04em;
  line-height: 1.6;
}

/* ==========================================================================
   Footer
   ========================================================================== */
.site-footer {
  margin-top: auto;
  border-top: 1px solid var(--border-subtle);
  padding: 2.5rem 0;
  background: #040406;
}

.footer-inner {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.footer-top-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 1.25rem;
}

.footer-brand {
  font-family: var(--font-serif);
  font-size: 1.25rem;
  font-weight: 900;
  letter-spacing: 0.1em;
  color: var(--text-secondary);
  text-transform: uppercase;
}

.footer-brand span {
  color: var(--primary);
}

.footer-links {
  display: flex;
  gap: 1.5rem;
  list-style: none;
}

.footer-link {
  color: var(--text-muted);
  text-decoration: none;
  font-family: var(--font-mono);
  font-size: 0.78rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  transition: color 0.15s ease;
}

.footer-link:hover {
  color: var(--primary-light);
}

.footer-bottom-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-top: 1px solid #110406;
  padding-top: 1.25rem;
  font-family: var(--font-mono);
  font-size: 0.68rem;
  color: #4a4a4a;
  letter-spacing: 0.08em;
  flex-wrap: wrap;
  gap: 0.75rem;
}

/* ==========================================================================
   Scrollbar & Utilities
   ========================================================================== */
::-webkit-scrollbar {
  width: 4px;
  height: 4px;
}
::-webkit-scrollbar-track {
  background: #050507;
}
::-webkit-scrollbar-thumb {
  background: #8a0303;
}
::-webkit-scrollbar-thumb:hover {
  background: #b80d0d;
}

/* ==========================================================================
   Responsive Adaptations for Tablets & Smartphones
   ========================================================================== */
@media (max-width: 991px) {
  :root {
    --header-height: 64px;
  }

  .site-header {
    padding: 0 1.25rem;
  }

  .header-inner {
    gap: 0.75rem;
  }

  .brand-group {
    gap: 0.85rem;
  }

  .brand-logo-img {
    height: 42px;
    max-width: 85px;
  }

  .brand-title {
    font-size: 1.35rem;
    letter-spacing: 0.08em;
  }

  .brand-subtitle {
    font-size: 0.58rem;
  }
}

@media (max-width: 768px) {
  :root {
    --header-height: 62px;
  }

  .site-header {
    padding: 0 1rem;
  }

  .header-inner {
    gap: 0.75rem;
  }

  .brand-group {
    gap: 0.75rem;
  }

  .brand-logo-img {
    height: 40px;
    max-width: 80px;
  }

  .brand-title {
    font-size: 1.25rem;
    letter-spacing: 0.08em;
  }

  .brand-subtitle {
    font-size: 0.55rem;
    letter-spacing: 0.1em;
  }

  .header-actions {
    gap: 0.5rem;
  }

  .currency-btn,
  .lang-btn {
    font-size: 0.7rem;
    padding: 0.35rem 0.5rem;
  }

  .header-contact-btn {
    font-size: 0.7rem;
    padding: 0.35rem 0.65rem;
    gap: 0.35rem;
  }

  .site-footer {
    padding: 2rem 0;
  }

  .footer-top-row {
    flex-direction: column;
    align-items: flex-start;
    gap: 1.25rem;
  }

  .footer-links {
    flex-wrap: wrap;
    gap: 1rem;
  }

  .footer-bottom-row {
    flex-direction: column;
    align-items: flex-start;
    gap: 0.5rem;
  }
}

@media (max-width: 440px) {
  .site-header {
    padding: 0 0.75rem;
  }

  .header-inner {
    gap: 0.45rem;
  }

  .brand-group {
    gap: 0.55rem;
  }

  .brand-logo-img {
    height: 36px;
    max-width: 70px;
  }

  .brand-title {
    font-size: 1.12rem;
  }

  .brand-subtitle {
    display: none;
  }

  .header-actions {
    gap: 0.35rem;
  }

  .currency-btn,
  .lang-btn {
    font-size: 0.65rem;
    padding: 0.28rem 0.42rem;
  }

  .header-contact-btn {
    font-size: 0.65rem;
    padding: 0.32rem 0.5rem;
    gap: 0.25rem;
  }

  .header-contact-btn span {
    display: none;
  }
}

