/* ==========================================================================
   FLAYERCLOUD - OFFICIAL DESIGN SYSTEM & STYLESHEET
   Aesthetic: Dark Gaming Cloud, Cyan & Purple Neon Accents, Ultra-Crisp UI
   ========================================================================== */

:root {
  --bg-darkest: #050811;
  --bg-primary: #070c18;
  --bg-card: #0d1527;
  --bg-card-hover: #131e36;
  --bg-elevated: #16223d;
  --bg-input: #0a0f1d;
  
  --cyan-primary: #00f5ff;
  --cyan-glow: rgba(0, 245, 255, 0.35);
  --purple-primary: #9d00ff;
  --purple-glow: rgba(157, 0, 255, 0.35);
  --magenta: #ff007a;
  
  --accent-gradient: linear-gradient(135deg, #00f5ff 0%, #7928ca 50%, #ff007a 100%);
  --btn-gradient: linear-gradient(135deg, #00d2ff 0%, #7000ff 100%);
  --card-gradient: linear-gradient(180deg, rgba(22, 34, 61, 0.6) 0%, rgba(13, 21, 39, 0.8) 100%);
  
  --text-main: #f8fafc;
  --text-muted: #94a3b8;
  --text-dim: #64748b;
  --text-cyan: #38bdf8;
  
  --border-subtle: rgba(255, 255, 255, 0.08);
  --border-highlight: rgba(0, 245, 255, 0.28);
  --border-focus: #00f5ff;
  
  --success: #10b981;
  --success-bg: rgba(16, 185, 129, 0.12);
  --warning: #f59e0b;
  --warning-bg: rgba(245, 158, 11, 0.12);
  --danger: #ef4444;
  --danger-bg: rgba(239, 68, 68, 0.12);
  
  --radius-sm: 6px;
  --radius-md: 10px;
  --radius-lg: 16px;
  --radius-xl: 24px;
  
  --shadow-card: 0 10px 30px -10px rgba(0, 0, 0, 0.6);
  --shadow-glow: 0 0 25px rgba(0, 245, 255, 0.18);
  --transition: all 0.22s cubic-bezier(0.16, 1, 0.3, 1);
  --container-max: 1280px;
}

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

html {
  font-size: 16px;
  scroll-behavior: smooth;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", sans-serif;
  background-color: var(--bg-darkest);
  color: var(--text-main);
  line-height: 1.6;
  overflow-x: hidden;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

/* Base Typography */
h1, h2, h3, h4, h5, h6 {
  color: #ffffff;
  font-weight: 700;
  line-height: 1.25;
  letter-spacing: -0.02em;
}

h1 { font-size: clamp(2rem, 5vw, 3.4rem); font-weight: 800; }
h2 { font-size: clamp(1.6rem, 3.5vw, 2.3rem); }
h3 { font-size: clamp(1.2rem, 2.5vw, 1.5rem); }
p { color: var(--text-muted); }
a { color: inherit; text-decoration: none; transition: var(--transition); }

img {
  max-width: 100%;
  height: auto;
  display: block;
}

/* Layout Containers */
.container {
  width: 100%;
  max-width: var(--container-max);
  margin-left: auto;
  margin-right: auto;
  padding-left: 20px;
  padding-right: 20px;
}

/* Text Gradients */
.text-gradient {
  background: var(--accent-gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}
.text-cyan { color: var(--cyan-primary); }

/* Global Header & Navigation */
.site-header {
  position: sticky;
  top: 0;
  z-index: 1000;
  width: 100%;
  background: rgba(7, 12, 24, 0.92);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--border-subtle);
  height: 74px;
}

.nav-container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 100%;
}

.brand-link {
  display: flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
  flex-shrink: 0;
}

.brand-logo-img {
  height: 40px;
  width: auto;
  object-fit: contain;
}

.nav-menu {
  display: flex;
  align-items: center;
  gap: 6px;
  list-style: none;
}

.nav-item {
  position: relative;
}

.nav-link, .nav-dropdown-trigger {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 14px;
  font-size: 0.93rem;
  font-weight: 600;
  color: var(--text-muted);
  border-radius: var(--radius-sm);
  background: transparent;
  border: none;
  cursor: pointer;
  transition: var(--transition);
}

.nav-link:hover, .nav-dropdown-trigger:hover,
.nav-link.active, .nav-dropdown-trigger.active {
  color: #ffffff;
  background: rgba(255, 255, 255, 0.05);
}

.nav-dropdown-trigger svg.chevron {
  transition: transform 0.2s ease;
}

.nav-item.open .nav-dropdown-trigger svg.chevron {
  transform: rotate(180deg);
}

/* Dropdown Safe Bridge (prevents mouseleave during hover transit) */
.dropdown-menu::before {
  content: '';
  position: absolute;
  top: -16px;
  left: 0;
  right: 0;
  height: 18px;
  background: transparent;
}

/* Standard Dropdown Menus */
.dropdown-menu {
  position: absolute;
  top: calc(100% + 8px);
  left: 0;
  background: #0b1222;
  border: 1px solid var(--border-highlight);
  border-radius: var(--radius-md);
  box-shadow: 0 15px 35px rgba(0, 0, 0, 0.8), 0 0 20px rgba(0, 245, 255, 0.08);
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transform: translateY(8px);
  transition: opacity 0.18s ease, transform 0.18s ease, visibility 0.18s ease;
  z-index: 1050;
  padding: 10px;
  min-width: 220px;
}

.nav-item.open > .dropdown-menu {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
  transform: translateY(0);
}

.dropdown-link {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 14px;
  border-radius: var(--radius-sm);
  color: var(--text-muted);
  font-size: 0.9rem;
  font-weight: 500;
  transition: var(--transition);
}

.dropdown-link:hover {
  color: #ffffff;
  background: var(--bg-card-hover);
  border-left: 3px solid var(--cyan-primary);
  padding-left: 17px;
}

.dropdown-link .spec-tag {
  font-size: 0.72rem;
  color: var(--cyan-primary);
  background: rgba(0, 245, 255, 0.1);
  padding: 2px 6px;
  border-radius: 4px;
  margin-left: auto;
}

/* CRITICAL FIX: Game Hosting Mega Menu */
.game-hosting-dropdown {
  width: min(840px, calc(100vw - 32px));
  left: 50%;
  transform: translateX(-50%) translateY(8px);
  padding: 18px;
  max-height: min(640px, 80vh);
  display: flex;
  flex-direction: column;
}

.nav-item.open > .game-hosting-dropdown {
  transform: translateX(-50%) translateY(0);
}

/* Mega Menu Search Bar */
.game-search-box {
  position: relative;
  margin-bottom: 14px;
  flex-shrink: 0;
}

.game-search-input {
  width: 100%;
  background: #070c18;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: var(--radius-sm);
  padding: 10px 14px 10px 38px;
  color: #ffffff;
  font-size: 0.9rem;
  outline: none;
  transition: var(--transition);
}

.game-search-input:focus {
  border-color: var(--cyan-primary);
  box-shadow: 0 0 10px rgba(0, 245, 255, 0.25);
}

.game-search-icon {
  position: absolute;
  left: 12px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--text-dim);
  pointer-events: none;
}

.game-search-clear {
  position: absolute;
  right: 12px;
  top: 50%;
  transform: translateY(-50%);
  background: none;
  border: none;
  color: var(--text-dim);
  cursor: pointer;
  display: none;
}

/* Mega Menu Game Grid */
.game-menu-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(230px, 1fr));
  gap: 10px;
  overflow-y: auto;
  padding-right: 6px;
  max-height: 420px;
}

.game-menu-grid::-webkit-scrollbar {
  width: 6px;
}
.game-menu-grid::-webkit-scrollbar-track {
  background: rgba(0, 0, 0, 0.2);
  border-radius: 4px;
}
.game-menu-grid::-webkit-scrollbar-thumb {
  background: rgba(0, 245, 255, 0.2);
  border-radius: 4px;
}
.game-menu-grid::-webkit-scrollbar-thumb:hover {
  background: var(--cyan-primary);
}

.game-menu-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 10px;
  border-radius: var(--radius-sm);
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid transparent;
  transition: var(--transition);
  text-decoration: none;
}

.game-menu-item:hover, .game-menu-item:focus {
  background: var(--bg-card-hover);
  border-color: rgba(0, 245, 255, 0.3);
  transform: translateY(-1px);
}

.game-menu-thumb {
  width: 48px;
  height: 36px;
  border-radius: 4px;
  object-fit: cover;
  flex-shrink: 0;
  border: 1px solid var(--border-subtle);
}

.game-menu-info {
  flex-grow: 1;
  min-width: 0;
}

.game-menu-name {
  color: #ffffff;
  font-size: 0.86rem;
  font-weight: 600;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.game-menu-sub {
  color: var(--text-dim);
  font-size: 0.74rem;
}

.game-menu-arrow {
  color: var(--cyan-primary);
  opacity: 0;
  transform: translateX(-4px);
  transition: var(--transition);
  flex-shrink: 0;
}

.game-menu-item:hover .game-menu-arrow {
  opacity: 1;
  transform: translateX(0);
}

/* Mega Menu Footer */
.game-menu-footer {
  margin-top: 12px;
  padding-top: 10px;
  border-top: 1px solid var(--border-subtle);
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 0.85rem;
  flex-shrink: 0;
}

.game-menu-all-link {
  color: var(--cyan-primary);
  font-weight: 600;
  display: inline-flex;
  align-items: center;
  gap: 6px;
}
.game-menu-all-link:hover {
  text-decoration: underline;
}

/* Empty Search State */
.game-menu-empty {
  grid-column: 1 / -1;
  text-align: center;
  padding: 30px 10px;
  color: var(--text-dim);
  font-size: 0.9rem;
}

/* Nav Actions (Cart & CTA) */
.nav-actions {
  display: flex;
  align-items: center;
  gap: 12px;
}

.nav-cart-btn {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 42px;
  height: 42px;
  border-radius: var(--radius-sm);
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--border-subtle);
  color: #ffffff;
  cursor: pointer;
  transition: var(--transition);
}

.nav-cart-btn:hover {
  background: rgba(0, 245, 255, 0.1);
  border-color: var(--border-highlight);
  color: var(--cyan-primary);
}

.cart-count-badge {
  position: absolute;
  top: -4px;
  right: -4px;
  background: var(--magenta);
  color: #ffffff;
  font-size: 0.72rem;
  font-weight: 700;
  min-width: 18px;
  height: 18px;
  padding: 0 5px;
  border-radius: 9px;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 0 8px rgba(255, 0, 122, 0.6);
  transition: transform 0.2s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.cart-bump {
  transform: scale(1.35);
}

.mobile-menu-toggle {
  display: none;
  background: none;
  border: none;
  color: #ffffff;
  cursor: pointer;
  padding: 8px;
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 10px 20px;
  font-size: 0.92rem;
  font-weight: 600;
  border-radius: var(--radius-sm);
  border: none;
  cursor: pointer;
  transition: var(--transition);
  text-decoration: none;
  white-space: nowrap;
}

.btn-primary {
  background: var(--btn-gradient);
  color: #ffffff;
  box-shadow: 0 4px 18px rgba(0, 210, 255, 0.3);
}

.btn-primary:hover {
  box-shadow: 0 6px 24px rgba(0, 210, 255, 0.55);
  transform: translateY(-2px);
  color: #ffffff;
}

.btn-buy {
  background: var(--btn-gradient);
  color: #ffffff;
  font-weight: 700;
  padding: 11px 22px;
  box-shadow: 0 4px 16px rgba(0, 245, 255, 0.25);
  width: 100%;
}

.btn-buy:hover {
  box-shadow: 0 6px 22px rgba(0, 245, 255, 0.5);
  transform: translateY(-2px);
  color: #ffffff;
}

.btn-secondary {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--border-subtle);
  color: #ffffff;
}

.btn-secondary:hover {
  background: rgba(255, 255, 255, 0.1);
  border-color: rgba(255, 255, 255, 0.2);
}

.btn-cyan {
  background: rgba(0, 245, 255, 0.12);
  border: 1px solid var(--border-highlight);
  color: var(--cyan-primary);
}
.btn-cyan:hover {
  background: var(--cyan-primary);
  color: #070c18;
  box-shadow: 0 0 20px rgba(0, 245, 255, 0.4);
}

.btn-discord {
  background: #5865F2;
  color: #ffffff;
}
.btn-discord:hover {
  background: #4752c4;
  box-shadow: 0 4px 20px rgba(88, 101, 242, 0.4);
  transform: translateY(-2px);
}

.btn-sm {
  padding: 6px 12px;
  font-size: 0.82rem;
}

.btn-lg {
  padding: 14px 28px;
  font-size: 1.05rem;
}

/* Badges */
.badge {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 3px 9px;
  border-radius: 9999px;
  font-size: 0.74rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.badge-popular {
  background: linear-gradient(135deg, #ff007a 0%, #7928ca 100%);
  color: #ffffff;
  box-shadow: 0 2px 10px rgba(255, 0, 122, 0.4);
}

.badge-cyan {
  background: rgba(0, 245, 255, 0.15);
  color: var(--cyan-primary);
  border: 1px solid rgba(0, 245, 255, 0.3);
}

.badge-status-pending {
  background: var(--warning-bg);
  color: var(--warning);
  border: 1px solid rgba(245, 158, 11, 0.3);
}

.badge-status-submitted {
  background: rgba(56, 189, 248, 0.15);
  color: #38bdf8;
  border: 1px solid rgba(56, 189, 248, 0.3);
}

.badge-status-paid {
  background: var(--success-bg);
  color: var(--success);
  border: 1px solid rgba(16, 185, 129, 0.3);
}

/* Hero Section */
.hero {
  position: relative;
  padding: 80px 0 60px;
  overflow: hidden;
  background: radial-gradient(circle at 50% 20%, rgba(0, 245, 255, 0.08) 0%, rgba(157, 0, 255, 0.05) 35%, transparent 70%);
}

.hero-content {
  text-align: center;
  max-width: 820px;
  margin: 0 auto;
}

.hero-subtitle {
  font-size: 1.15rem;
  color: var(--text-muted);
  margin-top: 18px;
  margin-bottom: 30px;
}

.hero-actions {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 16px;
  flex-wrap: wrap;
}

/* Cards & Grids */
.section-padding {
  padding: 70px 0;
}

.section-header {
  text-align: center;
  max-width: 680px;
  margin: 0 auto 50px;
}

.section-tag {
  color: var(--cyan-primary);
  font-size: 0.85rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  margin-bottom: 10px;
  display: block;
}

.grid-3 {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 24px;
}

.grid-4 {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 20px;
}

/* Plan Cards */
.plan-card {
  position: relative;
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  padding: 28px;
  display: flex;
  flex-direction: column;
  transition: var(--transition);
  box-shadow: var(--shadow-card);
}

.plan-card:hover {
  transform: translateY(-4px);
  border-color: var(--border-highlight);
  background: var(--bg-card-hover);
  box-shadow: 0 16px 36px rgba(0, 0, 0, 0.7), 0 0 20px rgba(0, 245, 255, 0.1);
}

.plan-card.featured {
  border-color: rgba(0, 245, 255, 0.5);
  background: linear-gradient(180deg, #131e36 0%, #0d1527 100%);
}

.plan-header {
  margin-bottom: 20px;
}

.plan-title {
  font-size: 1.35rem;
  font-weight: 700;
  margin-top: 4px;
}

.plan-price-box {
  display: flex;
  align-items: baseline;
  gap: 6px;
  margin: 16px 0 6px;
}

.plan-currency {
  font-size: 1.4rem;
  font-weight: 700;
  color: var(--cyan-primary);
}

.plan-amount {
  font-size: 2.6rem;
  font-weight: 800;
  color: #ffffff;
  line-height: 1;
}

.plan-cycle {
  color: var(--text-dim);
  font-size: 0.9rem;
}

.plan-usd-estimate {
  font-size: 0.8rem;
  color: var(--text-dim);
  margin-bottom: 20px;
}

.plan-specs-list {
  list-style: none;
  margin-bottom: 28px;
  flex-grow: 1;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.plan-spec-item {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 0.92rem;
  color: var(--text-muted);
}

.plan-spec-item svg {
  color: var(--cyan-primary);
  flex-shrink: 0;
}

/* Game Cards with Image Zoom on Hover */
.game-card {
  position: relative;
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  overflow: hidden;
  transition: var(--transition);
  display: flex;
  flex-direction: column;
}

.game-card:hover {
  transform: translateY(-4px);
  border-color: var(--border-highlight);
  box-shadow: 0 14px 30px rgba(0, 0, 0, 0.7);
}

.game-card-img-wrapper {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  background: #070c18;
}

.game-card-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.35s ease;
}

.game-card:hover .game-card-img {
  transform: scale(1.07);
}

.game-card-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, transparent 40%, rgba(13, 21, 39, 0.95) 100%);
  pointer-events: none;
}

.game-card-body {
  padding: 18px;
  display: flex;
  flex-direction: column;
  flex-grow: 1;
}

.game-card-title {
  font-size: 1.15rem;
  font-weight: 700;
  color: #ffffff;
  margin-bottom: 6px;
}

.game-card-desc {
  font-size: 0.84rem;
  color: var(--text-dim);
  margin-bottom: 16px;
  flex-grow: 1;
}

.game-card-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: auto;
  padding-top: 12px;
  border-top: 1px solid var(--border-subtle);
}

.game-card-price {
  font-size: 0.85rem;
  color: var(--text-muted);
}
.game-card-price strong {
  font-size: 1.15rem;
  color: var(--cyan-primary);
}

/* Shopping Cart Drawer */
.cart-drawer-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.75);
  backdrop-filter: blur(6px);
  z-index: 2000;
  opacity: 0;
  visibility: hidden;
  transition: var(--transition);
}

.cart-drawer-overlay.open {
  opacity: 1;
  visibility: visible;
}

.cart-drawer {
  position: fixed;
  top: 0;
  right: 0;
  bottom: 0;
  width: min(440px, 100vw);
  background: #0b1222;
  border-left: 1px solid var(--border-highlight);
  box-shadow: -10px 0 40px rgba(0, 0, 0, 0.8);
  z-index: 2001;
  display: flex;
  flex-direction: column;
  transform: translateX(100%);
  transition: transform 0.28s cubic-bezier(0.16, 1, 0.3, 1);
}

.cart-drawer.open {
  transform: translateX(0);
}

.cart-drawer-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 20px;
  border-bottom: 1px solid var(--border-subtle);
}

.cart-drawer-close {
  background: none;
  border: none;
  color: var(--text-muted);
  cursor: pointer;
  padding: 6px;
  border-radius: var(--radius-sm);
}
.cart-drawer-close:hover {
  color: #ffffff;
  background: rgba(255, 255, 255, 0.05);
}

.cart-drawer-body {
  flex-grow: 1;
  overflow-y: auto;
  padding: 20px;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.cart-item {
  display: flex;
  gap: 12px;
  padding: 14px;
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  position: relative;
}

.cart-item-img {
  width: 64px;
  height: 48px;
  border-radius: var(--radius-sm);
  object-fit: cover;
  flex-shrink: 0;
}

.cart-item-details {
  flex-grow: 1;
  min-width: 0;
}

.cart-item-title {
  font-size: 0.92rem;
  font-weight: 700;
  color: #ffffff;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.cart-item-plan {
  font-size: 0.8rem;
  color: var(--cyan-primary);
  margin-bottom: 4px;
}

.cart-item-specs {
  font-size: 0.74rem;
  color: var(--text-dim);
  line-height: 1.3;
}

.cart-item-pricing {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: 10px;
}

.cart-qty-ctrls {
  display: flex;
  align-items: center;
  gap: 6px;
}

.cart-qty-btn {
  width: 24px;
  height: 24px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--border-subtle);
  border-radius: 4px;
  color: #ffffff;
  cursor: pointer;
}

.cart-qty-val {
  font-size: 0.85rem;
  font-weight: 600;
  min-width: 20px;
  text-align: center;
}

.cart-item-price {
  font-size: 0.95rem;
  font-weight: 700;
  color: #ffffff;
}

.cart-item-remove {
  background: none;
  border: none;
  color: var(--text-dim);
  cursor: pointer;
  padding: 4px;
}
.cart-item-remove:hover {
  color: var(--danger);
}

.cart-drawer-footer {
  padding: 20px;
  border-top: 1px solid var(--border-subtle);
  background: #080d19;
}

.cart-summary-row {
  display: flex;
  justify-content: space-between;
  margin-bottom: 10px;
  font-size: 0.9rem;
  color: var(--text-muted);
}

.cart-total-row {
  display: flex;
  justify-content: space-between;
  margin-bottom: 18px;
  font-size: 1.25rem;
  font-weight: 700;
  color: #ffffff;
}
.cart-total-row strong {
  color: var(--cyan-primary);
}

.cart-empty-state {
  text-align: center;
  padding: 50px 20px;
  color: var(--text-dim);
}
.cart-empty-state svg {
  margin-bottom: 14px;
  color: var(--text-dim);
}

/* Toast Notifications */
.flayer-toast {
  position: fixed;
  bottom: 24px;
  right: 24px;
  background: #0d172c;
  border: 1px solid var(--cyan-primary);
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.7), 0 0 15px rgba(0, 245, 255, 0.3);
  border-radius: var(--radius-md);
  padding: 14px 20px;
  display: flex;
  align-items: center;
  gap: 12px;
  z-index: 3000;
  transform: translateY(100px);
  opacity: 0;
  transition: transform 0.25s ease, opacity 0.25s ease;
}

.flayer-toast.show {
  transform: translateY(0);
  opacity: 1;
}

/* Invoice Presentation Styles */
.invoice-container {
  max-width: 880px;
  margin: 40px auto;
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  padding: 36px;
  box-shadow: var(--shadow-card);
}

.invoice-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  border-bottom: 1px solid var(--border-subtle);
  padding-bottom: 24px;
  margin-bottom: 24px;
}

.invoice-meta-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 20px;
  margin-bottom: 30px;
  padding: 18px;
  background: var(--bg-primary);
  border-radius: var(--radius-md);
}

.invoice-table {
  width: 100%;
  border-collapse: collapse;
  margin-bottom: 28px;
}

.invoice-table th, .invoice-table td {
  padding: 12px 16px;
  text-align: left;
  border-bottom: 1px solid var(--border-subtle);
}

.invoice-table th {
  color: var(--text-dim);
  font-size: 0.82rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.invoice-table td {
  color: #ffffff;
  font-size: 0.94rem;
}

.invoice-payment-box {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
  padding: 24px;
  background: #080d1a;
  border: 1px solid var(--border-highlight);
  border-radius: var(--radius-md);
  margin-top: 30px;
}

.qr-display-card {
  text-align: center;
  padding: 16px;
  background: #ffffff;
  border-radius: var(--radius-md);
  color: #0b1222;
}

.qr-image-display {
  width: 220px;
  height: 220px;
  margin: 0 auto 12px;
  display: block;
  object-fit: contain;
}

/* Forms */
.form-group {
  margin-bottom: 18px;
}

.form-label {
  display: block;
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--text-main);
  margin-bottom: 6px;
}

.form-input, .form-select, .form-textarea {
  width: 100%;
  background: var(--bg-input);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-sm);
  padding: 11px 14px;
  color: #ffffff;
  font-size: 0.92rem;
  outline: none;
  transition: var(--transition);
}

.form-input:focus, .form-select:focus, .form-textarea:focus {
  border-color: var(--cyan-primary);
  box-shadow: 0 0 10px rgba(0, 245, 255, 0.2);
}

/* Footer */
.site-footer {
  background: #04060c;
  border-top: 1px solid var(--border-subtle);
  padding: 60px 0 30px;
  margin-top: auto;
}

.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 36px;
  margin-bottom: 40px;
}

.footer-col h4 {
  color: #ffffff;
  font-size: 0.95rem;
  font-weight: 700;
  margin-bottom: 16px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.footer-links {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.footer-links a {
  color: var(--text-dim);
  font-size: 0.88rem;
}
.footer-links a:hover {
  color: var(--cyan-primary);
}

.footer-bottom {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-top: 24px;
  border-top: 1px solid rgba(255, 255, 255, 0.04);
  font-size: 0.82rem;
  color: var(--text-dim);
}

/* Responsive Rules */
@media (max-width: 1024px) {
  .footer-grid {
    grid-template-columns: 1fr 1fr;
  }
}

@media (max-width: 860px) {
  .nav-menu {
    display: none;
  }
  .mobile-menu-toggle {
    display: block;
  }
  .invoice-payment-box {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 640px) {
  .footer-grid {
    grid-template-columns: 1fr;
  }
  .invoice-container {
    padding: 20px;
  }
  .footer-bottom {
    flex-direction: column;
    gap: 10px;
    text-align: center;
  }
}

/* Print Stylesheet for Invoices */
@media print {
  body {
    background: #ffffff !important;
    color: #000000 !important;
  }
  .site-header, .site-footer, .nav-actions, .btn-print, .flayer-toast, .cart-drawer, .cart-drawer-overlay, .admin-controls {
    display: none !important;
  }
  .invoice-container {
    border: none !important;
    box-shadow: none !important;
    padding: 0 !important;
    max-width: 100% !important;
  }
  .invoice-table td, .invoice-table th, h1, h2, h3, p {
    color: #000000 !important;
  }
  .invoice-payment-box {
    border: 1px solid #ccc !important;
    background: #f8fafc !important;
  }
}
