:root {
  --brand-deep: #7A1C1C;
  --brand-main: #C62828;
  --brand-gold: #FFB300;
  --brand-light-gold: #FFE082;
  --bg-gradient: linear-gradient(135deg, #FFFDF9 0%, #FFF5E5 100%);
  --surface-glass: rgba(255, 255, 255, 0.85);
  --surface-card: #ffffff;
  --border-subtle: rgba(122, 28, 28, 0.12);
  --text-main: #2D2222;
  --text-muted: #615555;
  --tag-bg: #F5F0EB;
  --transition-smooth: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
  --transition-fast: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
}

.dark-theme {
  --bg-gradient: linear-gradient(135deg, #120C0C 0%, #1A1111 100%);
  --surface-glass: rgba(26, 17, 17, 0.85);
  --surface-card: #211515;
  --border-subtle: rgba(255, 179, 0, 0.15);
  --text-main: #F5F0EB;
  --text-muted: #BFAFAF;
  --tag-bg: #332121;
  --brand-deep: #FFC107;
}

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

html, body {
  height: 100%;
  width: 100%;
  overflow: hidden;
}

body {
  min-height: 100dvh;
  font-family: 'Plus Jakarta Sans', system-ui, -apple-system, sans-serif;
  color: var(--text-main);
  background: var(--bg-gradient);
  line-height: 1.6;
  transition: background 0.5s ease, color 0.5s ease;
}

/* ================= NAV ================= */

nav {
  display: flex;
  justify-content: space-between;
  align-items: center;
  background: var(--surface-glass);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  padding: 1.2rem 2.5rem;
  border-bottom: 1px solid var(--border-subtle);
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 70px;
  z-index: 10000;
}

nav.app-shell {
  box-shadow: 0 10px 30px rgba(0,0,0,0.08);
}

nav .logo {
  font-size: 1.35rem;
  font-weight: 800;
  color: var(--brand-deep);
  display: flex;
  align-items: center;
  gap: 8px;
}

/* ================= PILLS NAV ================= */

#nav-links {
  display: flex;
  list-style: none;
  gap: 12px;
  align-items: center;
}

#nav-links li a {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 18px;
  border-radius: 999px;
  text-decoration: none;
  font-weight: 700;
  color: var(--text-muted);
  transition: var(--transition-fast);
}

#nav-links li a:hover {
  background: var(--brand-light-gold);
  color: var(--brand-deep);
  transform: translateY(-2px);
}

#nav-links li a.active {
  background: var(--brand-main);
  color: white;
  box-shadow: 0 10px 25px rgba(198,40,40,0.25);
}

/* ================= IFAME FULLSCREEN APP AREA ================= */

iframe#appFrame {
  position: fixed;
  top: 70px;
  left: 0;
  width: 100%;
  height: calc(100vh - 70px);
  border: none;
  background: var(--surface-card);
}

/* ================= NAV CONTROLS ================= */

.nav-controls {
  display: flex;
  gap: 15px;
  align-items: center;
}

.hamburger {
  display: none;
  background: none;
  border: none;
  font-size: 1.5rem;
  cursor: pointer;
  color: var(--brand-main);
}

/* ================= MOBILE NAV ================= */

@media (max-width: 868px) {
  .hamburger {
    display: block;
  }

  #nav-links {
    display: none;
    flex-direction: column;
    position: fixed;
    top: 70px;
    left: 0;
    width: 100%;
    height: calc(100vh - 70px);
    background: var(--surface-card);
    padding: 40px 20px;
    gap: 20px;
    justify-content: center;
    align-items: center;
    z-index: 99999;
  }

  #nav-links.active {
    display: flex;
  }

  #nav-links li a {
    font-size: 1.4rem;
    padding: 14px 24px;
  }
}

/* ================= HERO ================= */

.hero-section {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 80px 20px;
  min-height: calc(100dvh - 70px);
}

.hero-card {
  background: var(--surface-card);
  padding: 60px 40px;
  border-radius: 32px;
  max-width: 680px;
  text-align: center;
  box-shadow: 0 30px 60px -15px rgba(0, 0, 0, 0.2);
  border: 1px solid var(--border-subtle);
}

/* ================= BUTTON ================= */

.btn-primary {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  background: var(--brand-main);
  color: white;
  padding: 16px 32px;
  border-radius: 16px;
  font-weight: 700;
  text-decoration: none;
  box-shadow: 0 12px 24px -6px rgba(198, 40, 40, 0.3);
}

.btn-primary:hover {
  transform: translateY(-3px);
  background: var(--brand-deep);
}

/* ================= SEARCH ================= */

#searchInput {
  width: 100%;
  padding: 18px 20px 18px 55px;
  border-radius: 20px;
  border: 2px solid var(--border-subtle);
  background: var(--surface-card);
  color: var(--text-main);
}

/* ================= CARDS ================= */

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

.card {
  background: var(--surface-card);
  border: 1px solid var(--border-subtle);
  border-radius: 28px;
  padding: 35px;
  opacity: 0;
  animation: fadeSlideUp 0.6s forwards;
}

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

.card:hover {
  transform: translateY(-8px);
}

/* ================= TAGS ================= */

.tag, .tag-highlight {
  padding: 6px 14px;
  border-radius: 50px;
  font-size: 0.8rem;
  font-weight: 700;
}

.tag {
  background: var(--tag-bg);
  color: var(--text-muted);
}

.tag-highlight {
  background: rgba(255, 179, 0, 0.15);
  color: #B27D00;
}

/* ================= MOBILE FIX ================= */

@media (max-width: 868px) {
  .hero-card {
    padding: 40px 24px;
  }
}
