/* ==========================================================================
   OPENSADDLE - DEDICATED MOBILE STYLESHEET (mobile.css)
   Tailored for Smartphones & Touchscreens (App-like UX)
   ========================================================================== */

@import url('https://fonts.googleapis.com/css2?family=Cinzel:wght@600;700;800;900&family=Plus+Jakarta+Sans:wght@400;500;600;700&display=swap');

:root {
  --bg-void: #07090e;
  --bg-dark: #0c1017;
  --bg-surface: #121722;
  --bg-surface-elevated: #171e2c;

  --brass: #c59b27;
  --brass-light: #e5b94c;
  --brass-glow: rgba(197, 155, 39, 0.3);

  --copper: #b87333;
  --ember: #e85d04;
  --steam-cyan: #38bdf8;

  --steel-border: #1e293b;
  --steel-highlight: #334155;

  --text-main: #f1f5f9;
  --text-muted: #94a3b8;
  --text-dark: #64748b;

  --font-serif: 'Cinzel', serif;
  --font-sans: 'Plus Jakarta Sans', sans-serif;
  --bottom-bar-height: 64px;
}

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

html {
  scroll-behavior: smooth;
  scroll-padding-top: 70px;
  background-color: var(--bg-void);
  color: var(--text-main);
  font-family: var(--font-sans);
  font-size: 15px;
  line-height: 1.5;
}

body {
  padding-bottom: calc(var(--bottom-bar-height) + 20px);
  background: radial-gradient(circle at 50% 0%, #151a24 0%, var(--bg-void) 50%, #05070a 100%);
  min-height: 100vh;
}

.m-container {
  padding: 0 1rem;
}

/* --------------------------------------------------------------------------
   STICKY APP TOP BAR
   -------------------------------------------------------------------------- */
.m-app-header {
  position: sticky;
  top: 0;
  z-index: 100;
  height: 60px;
  background: rgba(10, 14, 20, 0.95);
  backdrop-filter: blur(15px);
  border-bottom: 1px solid var(--steel-border);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 1rem;
}

.m-brand {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  text-decoration: none;
}

.m-brand img {
  height: 34px;
  width: auto;
}

.m-brand-text {
  font-family: var(--font-serif);
  font-size: 1.05rem;
  font-weight: 800;
  letter-spacing: 0.12em;
  color: #fff;
}

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

/* --------------------------------------------------------------------------
   BOTTOM NAVIGATION BAR (APP DOCK)
   -------------------------------------------------------------------------- */
.m-bottom-bar {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  height: var(--bottom-bar-height);
  background: rgba(9, 12, 18, 0.98);
  backdrop-filter: blur(20px);
  border-top: 1px solid var(--steel-border);
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  z-index: 900;
  box-shadow: 0 -5px 25px rgba(0, 0, 0, 0.7);
}

.m-nav-tab {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.25rem;
  color: var(--text-dark);
  text-decoration: none;
  font-size: 0.7rem;
  font-weight: 600;
  transition: color 0.2s ease;
}

.m-nav-tab svg {
  width: 20px;
  height: 20px;
}

.m-nav-tab.active,
.m-nav-tab:hover {
  color: var(--brass-light);
}

/* --------------------------------------------------------------------------
   HERO SECTION (MOBILE)
   -------------------------------------------------------------------------- */
.m-hero {
  position: relative;
  padding: 2rem 1rem 2.5rem 1rem;
  text-align: center;
  overflow: hidden;
  background: linear-gradient(180deg, rgba(18, 23, 34, 0.6) 0%, rgba(7, 9, 14, 0.95) 100%);
  border-bottom: 1px solid var(--steel-border);
}

.m-hero-bg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.22;
  filter: blur(1px);
  pointer-events: none;
}

.m-badge-row {
  display: flex;
  justify-content: center;
  gap: 0.4rem;
  flex-wrap: wrap;
  margin-bottom: 1rem;
  position: relative;
  z-index: 2;
}

.m-badge {
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  padding: 0.2rem 0.55rem;
  border-radius: 4px;
  background: rgba(18, 23, 34, 0.85);
  border: 1px solid var(--steel-border);
  color: var(--text-muted);
}

.m-badge.mature {
  color: #ff8c42;
  border-color: rgba(232, 93, 4, 0.4);
  background: rgba(232, 93, 4, 0.1);
}

.m-hero-logo {
  max-width: 240px;
  width: 70%;
  margin: 0 auto 1rem auto;
  position: relative;
  z-index: 2;
  filter: drop-shadow(0 10px 20px rgba(0,0,0,0.8));
}

.m-hero-title {
  font-family: var(--font-serif);
  font-size: 1.45rem;
  font-weight: 800;
  line-height: 1.3;
  color: #fff;
  margin-bottom: 0.75rem;
  position: relative;
  z-index: 2;
}

.m-hero-desc {
  font-size: 0.88rem;
  color: var(--text-muted);
  line-height: 1.6;
  margin-bottom: 1.5rem;
  position: relative;
  z-index: 2;
}

.m-hero-actions {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  position: relative;
  z-index: 2;
}

.m-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.85rem 1.25rem;
  font-family: var(--font-serif);
  font-size: 0.88rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  border-radius: 6px;
  text-decoration: none;
  cursor: pointer;
  border: none;
  min-height: 48px;
}

.m-btn-primary {
  background: linear-gradient(135deg, var(--brass) 0%, var(--copper) 100%);
  color: #07090e;
  border: 1px solid var(--brass-light);
  box-shadow: 0 4px 15px rgba(197, 155, 39, 0.3);
}

.m-btn-discord {
  background: #5865F2;
  color: #fff;
  border: 1px solid #7289DA;
}

.m-btn-secondary {
  background: var(--bg-surface);
  color: #fff;
  border: 1px solid var(--steel-border);
}

/* --------------------------------------------------------------------------
   SECTIONS & ACCORDIONS (MOBILE)
   -------------------------------------------------------------------------- */
.m-section {
  padding: 2.5rem 1rem;
  border-bottom: 1px solid var(--steel-border);
}

.m-section-header {
  text-align: center;
  margin-bottom: 1.75rem;
}

.m-section-tag {
  display: inline-block;
  font-family: var(--font-serif);
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--brass-light);
  margin-bottom: 0.4rem;
}

.m-section-title {
  font-family: var(--font-serif);
  font-size: 1.5rem;
  font-weight: 800;
  color: #fff;
  line-height: 1.25;
}

.m-card {
  background: var(--bg-surface);
  border: 1px solid var(--steel-border);
  border-radius: 8px;
  padding: 1.25rem;
  margin-bottom: 1rem;
}

/* Story Accordion */
.m-accordion-item {
  background: var(--bg-surface);
  border: 1px solid var(--steel-border);
  border-radius: 8px;
  margin-bottom: 0.75rem;
  overflow: hidden;
}

.m-accordion-header {
  padding: 1rem 1.25rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  cursor: pointer;
  background: rgba(255, 255, 255, 0.02);
}

.m-accordion-title {
  font-family: var(--font-serif);
  font-size: 0.95rem;
  font-weight: 700;
  color: #fff;
}

.m-accordion-icon {
  transition: transform 0.3s ease;
  color: var(--brass);
}

.m-accordion-item.active .m-accordion-icon {
  transform: rotate(180deg);
}

.m-accordion-body {
  padding: 0 1.25rem 1.25rem 1.25rem;
  font-size: 0.88rem;
  color: var(--text-muted);
  line-height: 1.6;
  display: none;
}

.m-accordion-item.active .m-accordion-body {
  display: block;
}

/* --------------------------------------------------------------------------
   GALLERY (MOBILE GRID & LIGHTBOX)
   -------------------------------------------------------------------------- */
.m-gallery-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1rem;
}

.m-gallery-item {
  position: relative;
  border-radius: 8px;
  overflow: hidden;
  border: 1px solid var(--steel-border);
  aspect-ratio: 16 / 9;
}

.m-gallery-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.m-gallery-caption {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  background: linear-gradient(180deg, transparent 0%, rgba(7, 9, 14, 0.95) 100%);
  padding: 1rem 0.75rem 0.5rem 0.75rem;
  font-family: var(--font-serif);
  font-size: 0.85rem;
  font-weight: 700;
  color: #fff;
}

/* --------------------------------------------------------------------------
   COMMUNITY & SOCIAL CARDS (MOBILE)
   -------------------------------------------------------------------------- */
.m-comm-card {
  padding: 1.5rem;
  border-radius: 8px;
  margin-bottom: 1.25rem;
}

.m-comm-card.discord {
  background: linear-gradient(145deg, rgba(88, 101, 242, 0.15) 0%, var(--bg-surface) 100%);
  border: 1px solid rgba(88, 101, 242, 0.4);
}

.m-comm-card.youtube {
  background: linear-gradient(145deg, rgba(255, 0, 0, 0.1) 0%, var(--bg-surface) 100%);
  border: 1px solid rgba(255, 0, 0, 0.3);
}

.m-comm-card.instagram {
  background: linear-gradient(145deg, rgba(220, 39, 67, 0.1) 0%, var(--bg-surface) 100%);
  border: 1px solid rgba(220, 39, 67, 0.3);
}

/* --------------------------------------------------------------------------
   CONTACT CARD & FORM (MOBILE)
   -------------------------------------------------------------------------- */
.m-contact-card {
  background: #111724;
  border: 1px solid var(--steel-border);
  border-radius: 8px;
  padding: 1.5rem;
  margin-bottom: 1.5rem;
}

.m-contact-card h3 {
  font-family: var(--font-serif);
  font-size: 1.35rem;
  color: #fff;
  margin-bottom: 0.5rem;
}

.m-form-group {
  margin-bottom: 1.1rem;
}

.m-form-label {
  display: block;
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--text-muted);
  margin-bottom: 0.35rem;
}

.m-form-control {
  width: 100%;
  background: var(--bg-void);
  border: 1px solid var(--steel-border);
  border-radius: 6px;
  padding: 0.8rem 1rem;
  color: #fff;
  font-size: 0.95rem;
  min-height: 48px;
}

.m-form-control:focus {
  outline: none;
  border-color: var(--brass);
}

textarea.m-form-control {
  min-height: 120px;
}

/* --------------------------------------------------------------------------
   FOOTER & BOTTOM-SHEET MODALS (MOBILE)
   -------------------------------------------------------------------------- */
.m-footer {
  padding: 3rem 1rem 2rem 1rem;
  text-align: center;
  background: #05070a;
}

.m-desktop-switch-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  background: var(--bg-surface-elevated);
  border: 1px solid var(--steel-highlight);
  color: var(--brass-light);
  padding: 0.75rem 1.25rem;
  border-radius: 6px;
  font-size: 0.85rem;
  font-weight: 700;
  cursor: pointer;
  margin-bottom: 1.5rem;
}

.m-bottom-sheet {
  position: fixed;
  inset: 0;
  z-index: 1000;
  background: rgba(4, 5, 8, 0.85);
  display: none;
  align-items: flex-end;
}

.m-bottom-sheet.active {
  display: flex;
}

.m-bottom-sheet-content {
  width: 100%;
  max-height: 85vh;
  background: var(--bg-surface);
  border-top: 1px solid var(--steel-highlight);
  border-radius: 16px 16px 0 0;
  padding: 1.5rem;
  overflow-y: auto;
}

.m-sheet-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 1.25rem;
  padding-bottom: 0.75rem;
  border-bottom: 1px solid var(--steel-border);
}

.m-sheet-title {
  font-family: var(--font-serif);
  font-size: 1.25rem;
  color: #fff;
}

.m-sheet-close {
  background: var(--bg-void);
  border: 1px solid var(--steel-border);
  color: var(--text-muted);
  width: 36px;
  height: 36px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
}

/* Mobile Channel Filter Tabs */
.channel-filter-bar {
  display: flex !important;
  flex-wrap: nowrap !important;
  overflow-x: auto !important;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
  max-width: 100%;
  padding: 0.35rem 0.5rem !important;
  gap: 0.4rem !important;
  border-radius: 9999px !important;
}

.channel-filter-bar::-webkit-scrollbar {
  display: none;
}

.channel-tab-btn {
  font-size: 0.76rem !important;
  padding: 0.4rem 0.85rem !important;
  white-space: nowrap !important;
  flex-shrink: 0 !important;
}
