@import url('https://fonts.googleapis.com/css2?family=Raleway:wght@300;400;500;600;700;800&family=Inter:wght@300;400;500;600&display=swap');

/* ─────────────────────────────────────────────
   CSS VARIABLES — MB Global Design System
   ───────────────────────────────────────────── */
:root {
  /* Backgrounds */
  --bg:             #0A0C2A;
  --bg-2:           #10133A;
  --surface:        #13163D;
  --surface-hover:  #1B1F52;
  --surface-2:      #191D4A;

  /* Accent (from origami logo mark) */
  --accent:         #E8EBF8;
  --accent-mid:     #6B6FA8;
  --accent-dim:     #252860;
  --accent-glow:    rgba(232, 235, 248, 0.08);

  /* Text */
  --text:           #F0F2FF;
  --text-secondary: #8B8EBB;
  --text-muted:     #4A4E7A;

  /* Borders & Lines */
  --border:         #1E2258;
  --border-light:   rgba(232, 235, 248, 0.1);

  /* Status */
  --success:        #4A9E7F;
  --error:          #C0496A;

  /* Layout */
  --tab-h:          72px;
  --top-h:          60px;
  --r-card:         16px;
  --r-sm:           10px;
  --r-pill:         100px;

  /* Shadows */
  --shadow-card:    0 4px 24px rgba(0,0,0,0.4);
  --shadow-float:   0 8px 32px rgba(0,0,0,0.6);
}

/* ─────────────────────────────────────────────
   RESET & BASE
   ───────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html, body {
  height: 100%;
  background: #060818;
}

body {
  font-family: 'Inter', system-ui, sans-serif;
  font-size: 15px;
  line-height: 1.5;
  color: var(--text);
  -webkit-font-smoothing: antialiased;
}

a { color: inherit; text-decoration: none; }
img { display: block; max-width: 100%; }
button { cursor: pointer; border: none; background: none; font-family: inherit; color: inherit; }

/* ─────────────────────────────────────────────
   PHONE FRAME — centers everything on desktop
   ───────────────────────────────────────────── */
.phone {
  position: relative;
  width: 390px;
  min-height: 100vh;
  margin: 0 auto;
  background: var(--bg);
  background-image: radial-gradient(ellipse 60% 50% at 50% 30%, var(--bg-2) 0%, var(--bg) 100%);
  overflow: hidden;
  box-shadow: 0 0 60px rgba(0,0,0,0.8);
}

/* Scrollable content between top bar and tab bar */
.page-content {
  position: absolute;
  top: var(--top-h);
  bottom: var(--tab-h);
  left: 0; right: 0;
  overflow-y: auto;
  overflow-x: hidden;
  -webkit-overflow-scrolling: touch;
  scroll-behavior: smooth;
}

.page-content::-webkit-scrollbar { display: none; }

/* ─────────────────────────────────────────────
   TOP BAR
   ───────────────────────────────────────────── */
.top-bar {
  position: absolute;
  top: 0; left: 0; right: 0;
  height: var(--top-h);
  display: flex;
  align-items: center;
  padding: 0 20px;
  gap: 10px;
  background: rgba(10, 12, 42, 0.85);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--border);
  z-index: 10;
}

.top-bar .logo-mark {
  width: 32px;
  height: 32px;
  flex-shrink: 0;
}

.top-bar .brand {
  font-family: 'Raleway', sans-serif;
  font-size: 18px;
  font-weight: 600;
  color: var(--accent);
  letter-spacing: 0.02em;
}

.top-bar .page-title {
  font-size: 17px;
  font-weight: 600;
  color: var(--text);
}

.top-bar .back-btn {
  display: flex;
  align-items: center;
  gap: 6px;
  color: var(--accent);
  font-size: 15px;
  font-weight: 500;
  margin-right: 4px;
  padding: 8px 0;
}

.top-bar .back-btn svg {
  width: 20px; height: 20px;
}

.top-bar .spacer { flex: 1; }

/* ─────────────────────────────────────────────
   BOTTOM TAB BAR
   ───────────────────────────────────────────── */
.tab-bar {
  position: absolute;
  bottom: 0; left: 0; right: 0;
  height: var(--tab-h);
  display: flex;
  background: rgba(13, 16, 45, 0.95);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-top: 1px solid var(--border);
  z-index: 10;
}

.tab-item {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 4px;
  padding-bottom: 8px;
  text-decoration: none;
  color: var(--text-muted);
  transition: color 0.2s;
}

.tab-item svg {
  width: 24px;
  height: 24px;
  stroke: currentColor;
  stroke-width: 1.8;
  fill: none;
}

.tab-item span {
  font-size: 10px;
  font-weight: 500;
  letter-spacing: 0.02em;
}

.tab-item.active {
  color: var(--accent);
}

.tab-item.active svg {
  filter: drop-shadow(0 0 6px rgba(232, 235, 248, 0.4));
}

/* ─────────────────────────────────────────────
   INNER PADDING
   ───────────────────────────────────────────── */
.inner { padding: 20px; }
.inner-sm { padding: 12px 20px; }

/* ─────────────────────────────────────────────
   SECTION HEADERS
   ───────────────────────────────────────────── */
.section-title {
  font-size: 12px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--text-muted);
  margin-bottom: 14px;
}

/* ─────────────────────────────────────────────
   CARDS
   ───────────────────────────────────────────── */
.card {
  background: var(--surface);
  border-radius: var(--r-card);
  border: 1px solid var(--border);
  overflow: hidden;
  transition: background 0.2s, border-color 0.2s, transform 0.15s;
}

.card:active {
  transform: scale(0.98);
  background: var(--surface-hover);
}

.card-link { display: block; }

/* Event Card */
.event-card {
  padding: 16px;
}

.event-card .event-date {
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--accent-mid);
  margin-bottom: 6px;
}

.event-card .event-city {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 11px;
  color: var(--text-muted);
  margin-bottom: 6px;
}

.event-card .event-title {
  font-family: 'Raleway', sans-serif;
  font-size: 17px;
  font-weight: 600;
  color: var(--text);
  margin-bottom: 8px;
  line-height: 1.3;
}

.event-card .event-desc {
  font-size: 13px;
  color: var(--text-secondary);
  line-height: 1.5;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.event-card .event-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: 12px;
}

/* Person Card */
.person-card {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 14px 16px;
}

.person-avatar {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: var(--accent-dim);
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: 'Raleway', sans-serif;
  font-size: 18px;
  font-weight: 600;
  color: var(--accent);
  overflow: hidden;
}

.person-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.person-info { flex: 1; min-width: 0; }

.person-name {
  font-weight: 600;
  font-size: 15px;
  color: var(--text);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.person-meta {
  font-size: 12px;
  color: var(--text-secondary);
  margin-top: 2px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.person-company {
  font-size: 12px;
  color: var(--text-muted);
  margin-top: 1px;
}

.person-chevron {
  color: var(--text-muted);
  flex-shrink: 0;
}

/* ─────────────────────────────────────────────
   TAGS / CHIPS
   ───────────────────────────────────────────── */
.tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.tag {
  display: inline-flex;
  align-items: center;
  padding: 4px 12px;
  border-radius: var(--r-pill);
  background: var(--accent-dim);
  color: var(--accent);
  font-size: 12px;
  font-weight: 500;
  border: 1px solid rgba(232, 235, 248, 0.15);
}

/* ─────────────────────────────────────────────
   BUTTONS
   ───────────────────────────────────────────── */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 13px 24px;
  border-radius: var(--r-pill);
  font-size: 14px;
  font-weight: 600;
  letter-spacing: 0.01em;
  transition: all 0.2s;
  cursor: pointer;
}

.btn-primary {
  background: var(--accent);
  color: var(--bg);
}

.btn-primary:active {
  opacity: 0.85;
  transform: scale(0.97);
}

.btn-outline {
  background: transparent;
  color: var(--accent);
  border: 1.5px solid rgba(232, 235, 248, 0.3);
}

.btn-outline:active {
  background: var(--accent-glow);
}

.btn-ghost {
  background: var(--surface);
  color: var(--text);
  border: 1px solid var(--border);
}

.btn-full { width: 100%; }

/* ─────────────────────────────────────────────
   SEARCH & FILTERS
   ───────────────────────────────────────────── */
.search-wrap {
  position: relative;
  margin-bottom: 12px;
}

.search-icon {
  position: absolute;
  left: 14px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--text-muted);
  width: 18px; height: 18px;
}

.search-input {
  width: 100%;
  padding: 12px 16px 12px 44px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r-sm);
  color: var(--text);
  font-family: inherit;
  font-size: 15px;
  outline: none;
  transition: border-color 0.2s;
}

.search-input::placeholder { color: var(--text-muted); }
.search-input:focus { border-color: var(--accent-mid); }

.filters-row {
  display: flex;
  gap: 8px;
  overflow-x: auto;
  padding-bottom: 2px;
}

.filters-row::-webkit-scrollbar { display: none; }

.filter-select {
  flex-shrink: 0;
  padding: 7px 14px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r-pill);
  color: var(--text-secondary);
  font-family: inherit;
  font-size: 13px;
  font-weight: 500;
  outline: none;
  appearance: none;
  cursor: pointer;
}

.filter-chip {
  flex-shrink: 0;
  padding: 7px 14px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r-pill);
  color: var(--text-secondary);
  font-size: 13px;
  font-weight: 500;
  cursor: pointer;
  white-space: nowrap;
  display: flex;
  align-items: center;
  gap: 5px;
}

.filter-chip.active {
  background: var(--accent-dim);
  border-color: rgba(232,235,248,0.2);
  color: var(--accent);
}

/* ─────────────────────────────────────────────
   TABS (Upcoming / Past)
   ───────────────────────────────────────────── */
.tabs {
  display: flex;
  background: var(--surface);
  border-radius: var(--r-sm);
  padding: 3px;
  gap: 2px;
}

.tab-btn {
  flex: 1;
  padding: 9px;
  border-radius: 8px;
  font-size: 13px;
  font-weight: 600;
  color: var(--text-muted);
  text-align: center;
  transition: all 0.2s;
  cursor: pointer;
}

.tab-btn.active {
  background: var(--accent-dim);
  color: var(--accent);
}

/* ─────────────────────────────────────────────
   DIVIDERS & LISTS
   ───────────────────────────────────────────── */
.card-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.card-list-compact .card + .card {
  margin-top: 1px;
  border-radius: 0;
}

.card-list-compact .card:first-child {
  border-radius: var(--r-card) var(--r-card) 0 0;
}

.card-list-compact .card:last-child {
  border-radius: 0 0 var(--r-card) var(--r-card);
}

.divider {
  height: 1px;
  background: var(--border);
  margin: 20px 0;
}

/* ─────────────────────────────────────────────
   PROFILE PAGE
   ───────────────────────────────────────────── */
.profile-header {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 32px 20px 24px;
  text-align: center;
}

.profile-avatar {
  width: 100px;
  height: 100px;
  border-radius: 50%;
  background: var(--accent-dim);
  border: 3px solid rgba(232, 235, 248, 0.15);
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: 'Raleway', sans-serif;
  font-size: 36px;
  font-weight: 600;
  color: var(--accent);
  margin-bottom: 16px;
  overflow: hidden;
}

.profile-name {
  font-family: 'Raleway', sans-serif;
  font-size: 24px;
  font-weight: 600;
  color: var(--text);
  margin-bottom: 4px;
}

.profile-position {
  font-size: 14px;
  color: var(--text-secondary);
  margin-bottom: 4px;
}

.profile-location {
  font-size: 13px;
  color: var(--text-muted);
}

.profile-links {
  display: flex;
  gap: 10px;
  margin-top: 16px;
}

.profile-link-btn {
  display: flex;
  align-items: center;
  gap: 7px;
  padding: 9px 18px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r-pill);
  font-size: 13px;
  font-weight: 500;
  color: var(--text-secondary);
}

.profile-link-btn svg {
  width: 16px; height: 16px;
  color: var(--accent-mid);
}

/* Profile sections */
.profile-section {
  padding: 16px 20px;
  border-top: 1px solid var(--border);
}

.profile-section-label {
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--text-muted);
  margin-bottom: 10px;
}

.profile-section-text {
  font-size: 14px;
  color: var(--text-secondary);
  line-height: 1.6;
}

/* ─────────────────────────────────────────────
   EVENT DETAIL
   ───────────────────────────────────────────── */
.event-cover {
  width: 100%;
  aspect-ratio: 16/9;
  background: linear-gradient(135deg, var(--surface) 0%, var(--accent-dim) 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--accent-mid);
  font-size: 13px;
}

.event-detail-meta {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 12px;
  flex-wrap: wrap;
}

.event-detail-meta-item {
  display: flex;
  align-items: center;
  gap: 5px;
  font-size: 13px;
  color: var(--text-secondary);
}

.event-detail-meta-item svg {
  width: 15px; height: 15px;
  color: var(--accent-mid);
}

.event-detail-title {
  font-family: 'Raleway', sans-serif;
  font-size: 24px;
  font-weight: 700;
  color: var(--text);
  line-height: 1.25;
  margin-bottom: 16px;
}

.event-detail-desc {
  font-size: 15px;
  color: var(--text-secondary);
  line-height: 1.7;
}

.event-detail-desc a {
  color: var(--accent);
  text-decoration: underline;
  text-underline-offset: 2px;
}

/* ─────────────────────────────────────────────
   ABOUT PAGE
   ───────────────────────────────────────────── */
.photo-gallery {
  display: flex;
  overflow-x: auto;
  gap: 10px;
  padding: 0 20px;
  scroll-snap-type: x mandatory;
  -webkit-overflow-scrolling: touch;
}

.photo-gallery::-webkit-scrollbar { display: none; }

.gallery-photo {
  flex-shrink: 0;
  width: 280px;
  height: 180px;
  border-radius: var(--r-card);
  overflow: hidden;
  scroll-snap-align: start;
  background: var(--surface);
  border: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-muted);
  font-size: 13px;
}

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

.gallery-dots {
  display: flex;
  justify-content: center;
  gap: 6px;
  margin-top: 12px;
}

.gallery-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--border);
}

.gallery-dot.active {
  background: var(--accent-mid);
  width: 20px;
  border-radius: 3px;
}

.about-text {
  font-size: 15px;
  color: var(--text-secondary);
  line-height: 1.75;
}

.about-text h3 {
  font-family: 'Raleway', sans-serif;
  font-size: 19px;
  font-weight: 600;
  color: var(--text);
  margin-top: 24px;
  margin-bottom: 10px;
}

.about-text h3:first-child { margin-top: 0; }

.about-text p { margin-bottom: 14px; }
.about-text p:last-child { margin-bottom: 0; }

.about-text strong {
  color: var(--accent);
  font-weight: 600;
}

.about-text a {
  color: var(--accent);
  text-decoration: underline;
  text-underline-offset: 3px;
}

/* ─────────────────────────────────────────────
   HERO BLOCK
   ───────────────────────────────────────────── */
.hero {
  padding: 36px 24px 32px;
  background: linear-gradient(180deg, rgba(16,19,58,0.6) 0%, transparent 100%);
  border-bottom: 1px solid var(--border-light);
  margin-bottom: 4px;
}

.hero-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--accent-mid);
  margin-bottom: 16px;
}

.hero-eyebrow::before {
  content: '';
  display: block;
  width: 20px;
  height: 1px;
  background: var(--accent-mid);
}

.hero h1 {
  font-family: 'Raleway', sans-serif;
  font-size: 26px;
  font-weight: 800;
  color: var(--accent);
  line-height: 1.2;
  letter-spacing: -0.01em;
  margin-bottom: 8px;
}

.hero h2 {
  font-family: 'Inter', sans-serif;
  font-size: 14px;
  font-weight: 500;
  color: var(--text-secondary);
  letter-spacing: 0.05em;
  margin-bottom: 14px;
}

.hero p {
  font-size: 14px;
  color: var(--text-muted);
  line-height: 1.6;
  font-style: italic;
}

/* ─────────────────────────────────────────────
   NAV BUTTONS (Home page)
   ───────────────────────────────────────────── */
.nav-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin-bottom: 10px;
}

.nav-grid .btn:last-child:nth-child(odd) {
  grid-column: 1 / -1;
}

.nav-card {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 16px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r-card);
  transition: all 0.2s;
  cursor: pointer;
  text-decoration: none;
}

.nav-card:active {
  background: var(--surface-hover);
  transform: scale(0.97);
}

.nav-card-icon {
  width: 40px;
  height: 40px;
  border-radius: 10px;
  background: var(--accent-dim);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.nav-card-icon svg {
  width: 20px; height: 20px;
  stroke: var(--accent);
  stroke-width: 1.8;
  fill: none;
}

.nav-card-text strong {
  display: block;
  font-size: 14px;
  font-weight: 600;
  color: var(--text);
}

.nav-card-text span {
  font-size: 12px;
  color: var(--text-muted);
}

/* Arrow badge */
.arrow-icon {
  margin-left: auto;
  color: var(--text-muted);
  width: 16px; height: 16px;
}

/* ─────────────────────────────────────────────
   EMPTY STATE
   ───────────────────────────────────────────── */
.empty-state {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 60px 20px;
  text-align: center;
  color: var(--text-muted);
  font-size: 14px;
  gap: 8px;
}

.empty-state svg {
  width: 40px; height: 40px;
  opacity: 0.4;
  margin-bottom: 8px;
}

/* ─────────────────────────────────────────────
   UTILITIES
   ───────────────────────────────────────────── */
.mt-4 { margin-top: 4px; }
.mt-8 { margin-top: 8px; }
.mt-12 { margin-top: 12px; }
.mt-16 { margin-top: 16px; }
.mt-20 { margin-top: 20px; }
.mb-16 { margin-bottom: 16px; }
.mb-20 { margin-bottom: 20px; }
.gap-10 { gap: 10px; }
.flex { display: flex; }
.flex-col { flex-direction: column; }
.items-center { align-items: center; }
.justify-between { justify-content: space-between; }
.text-accent { color: var(--accent); }
.text-muted { color: var(--text-muted); }
.text-sm { font-size: 13px; }
.font-serif { font-family: 'Raleway', sans-serif; }
.w-full { width: 100%; }

/* Desktop note */
@media (min-width: 430px) {
  body::before {
    content: 'MB Global — Prototype Preview';
    position: fixed;
    top: 12px;
    left: 50%;
    transform: translateX(-50%);
    font-size: 11px;
    color: rgba(255,255,255,0.2);
    letter-spacing: 0.1em;
    text-transform: uppercase;
    pointer-events: none;
  }
}

@media (max-width: 389px) {
  .phone { width: 100%; }
}
