/* ============================================================
   MyLagosApp — Global Design System
   style.css | Mobile-First Premium City Guide App
   ============================================================ */

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

/* ── CSS Custom Properties ─────────────────────────────── */
:root {
  /* Brand Colors */
  --primary:        #FF9C20;
  --primary-dark:   #E08010;
  --primary-light:  #FFB84D;
  --primary-pale:   #FFF3E0;

  /* Neutral Palette */
  --black:          #0A0A0A;
  --dark:           #1A1A1A;
  --dark-2:         #2C2C2C;
  --gray-700:       #444444;
  --gray-600:       #666666;
  --gray-400:       #999999;
  --gray-200:       #D1D1D1;
  --gray-100:       #F0F0F0;
  --gray-50:        #F8F8F8;
  --white:          #FFFFFF;

  /* Semantic Colors */
  --success:        #22C55E;
  --success-bg:     #DCFCE7;
  --danger:         #EF4444;
  --danger-bg:      #FEE2E2;
  --warning:        #F59E0B;
  --warning-bg:     #FEF3C7;
  --info:           #3B82F6;
  --info-bg:        #DBEAFE;

  /* Traffic Status */
  --traffic-heavy:  #EF4444;
  --traffic-mod:    #F59E0B;
  --traffic-light:  #22C55E;

  /* Typography */
  --font:           'Poppins', -apple-system, BlinkMacSystemFont, sans-serif;
  --text-xs:        0.70rem;   /* 11.2px */
  --text-sm:        0.813rem;  /* 13px */
  --text-base:      0.938rem;  /* 15px */
  --text-md:        1rem;      /* 16px */
  --text-lg:        1.125rem;  /* 18px */
  --text-xl:        1.25rem;   /* 20px */
  --text-2xl:       1.5rem;    /* 24px */
  --text-3xl:       1.875rem;  /* 30px */
  --text-4xl:       2.25rem;   /* 36px */

  /* Spacing */
  --space-1:   4px;
  --space-2:   8px;
  --space-3:   12px;
  --space-4:   16px;
  --space-5:   20px;
  --space-6:   24px;
  --space-8:   32px;
  --space-10:  40px;
  --space-12:  48px;
  --space-16:  64px;

  /* Border Radius */
  --radius-sm:  6px;
  --radius-md:  12px;
  --radius-lg:  18px;
  --radius-xl:  24px;
  --radius-2xl: 32px;
  --radius-full: 9999px;

  /* Shadows */
  --shadow-sm:   0 1px 3px rgba(0,0,0,.08), 0 1px 2px rgba(0,0,0,.06);
  --shadow-md:   0 4px 16px rgba(0,0,0,.10), 0 2px 6px rgba(0,0,0,.06);
  --shadow-lg:   0 10px 30px rgba(0,0,0,.12), 0 4px 10px rgba(0,0,0,.08);
  --shadow-xl:   0 20px 50px rgba(0,0,0,.15), 0 8px 20px rgba(0,0,0,.10);
  --shadow-primary: 0 8px 24px rgba(255,156,32,.35);

  /* Z-index layers */
  --z-base:    1;
  --z-nav:     100;
  --z-modal:   200;
  --z-fab:     150;
  --z-overlay: 190;
  --z-toast:   300;

  /* Transitions */
  --ease:       cubic-bezier(0.4, 0, 0.2, 1);
  --ease-out:   cubic-bezier(0, 0, 0.2, 1);
  --ease-bounce: cubic-bezier(0.34, 1.56, 0.64, 1);
  --dur-fast:   150ms;
  --dur-base:   250ms;
  --dur-slow:   400ms;

  /* App Shell */
  --app-max-w:  430px;
  --top-bar-h:  60px;
  --bottom-nav-h: 68px;
}

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

html {
  font-size: 16px;
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  font-family: var(--font);
  font-size: var(--text-base);
  color: var(--dark);
  background: #EFEFEF;
  min-height: 100vh;
  display: flex;
  justify-content: center;
  align-items: flex-start;
  overflow-x: hidden;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* ── App Shell Container ───────────────────────────────── */
.app-shell {
  width: 100%;
  max-width: var(--app-max-w);
  min-height: 100vh;
  background: var(--white);
  position: relative;
  overflow: hidden;
  box-shadow: 0 0 60px rgba(0,0,0,.18);
}

/* ── Typography ────────────────────────────────────────── */
h1, h2, h3, h4, h5, h6 {
  font-weight: 700;
  line-height: 1.25;
  color: var(--black);
}

h1 { font-size: var(--text-3xl); }
h2 { font-size: var(--text-2xl); }
h3 { font-size: var(--text-xl); }
h4 { font-size: var(--text-lg); }
h5 { font-size: var(--text-md); }
h6 { font-size: var(--text-base); }

p { line-height: 1.65; }

a {
  color: var(--primary);
  text-decoration: none;
  transition: color var(--dur-fast) var(--ease);
}

a:hover { color: var(--primary-dark); }

img {
  max-width: 100%;
  display: block;
  object-fit: cover;
}

button {
  font-family: var(--font);
  cursor: pointer;
  border: none;
  outline: none;
  background: none;
}

input, select, textarea {
  font-family: var(--font);
  outline: none;
  border: none;
}

ul, ol { list-style: none; }

/* ── Scrollable Page Content ───────────────────────────── */
.page-content {
  padding-top: var(--top-bar-h);
  padding-bottom: calc(var(--bottom-nav-h) + 16px);
  min-height: 100vh;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  scroll-behavior: smooth;
}

.page-content--no-nav {
  padding-top: 0;
  padding-bottom: 0;
}

.page-content--no-topbar {
  padding-top: 0;
}

/* ── Scrollbar ─────────────────────────────────────────── */
::-webkit-scrollbar { width: 0; height: 0; }

/* ── Utility Classes ───────────────────────────────────── */
.flex { display: flex; }
.flex-col { flex-direction: column; }
.items-center { align-items: center; }
.items-start { align-items: flex-start; }
.items-end { align-items: flex-end; }
.justify-center { justify-content: center; }
.justify-between { justify-content: space-between; }
.justify-end { justify-content: flex-end; }
.gap-1 { gap: var(--space-1); }
.gap-2 { gap: var(--space-2); }
.gap-3 { gap: var(--space-3); }
.gap-4 { gap: var(--space-4); }
.gap-6 { gap: var(--space-6); }
.grid { display: grid; }

.text-xs   { font-size: var(--text-xs); }
.text-sm   { font-size: var(--text-sm); }
.text-base { font-size: var(--text-base); }
.text-md   { font-size: var(--text-md); }
.text-lg   { font-size: var(--text-lg); }
.text-xl   { font-size: var(--text-xl); }
.text-2xl  { font-size: var(--text-2xl); }

.font-300 { font-weight: 300; }
.font-400 { font-weight: 400; }
.font-500 { font-weight: 500; }
.font-600 { font-weight: 600; }
.font-700 { font-weight: 700; }
.font-800 { font-weight: 800; }
.font-900 { font-weight: 900; }

.text-primary  { color: var(--primary); }
.text-black    { color: var(--black); }
.text-dark     { color: var(--dark); }
.text-gray     { color: var(--gray-600); }
.text-muted    { color: var(--gray-400); }
.text-white    { color: var(--white); }
.text-danger   { color: var(--danger); }
.text-success  { color: var(--success); }
.text-warning  { color: var(--warning); }
.text-center   { text-align: center; }
.text-right    { text-align: right; }

.bg-primary   { background: var(--primary); }
.bg-dark      { background: var(--dark); }
.bg-white     { background: var(--white); }
.bg-surface   { background: var(--gray-50); }
.bg-danger    { background: var(--danger); }
.bg-success   { background: var(--success); }

.w-full  { width: 100%; }
.h-full  { height: 100%; }
.relative { position: relative; }
.absolute { position: absolute; }
.overflow-hidden { overflow: hidden; }
.rounded-full { border-radius: var(--radius-full); }
.rounded-lg { border-radius: var(--radius-lg); }

.p-2 { padding: var(--space-2); }
.p-3 { padding: var(--space-3); }
.p-4 { padding: var(--space-4); }
.p-5 { padding: var(--space-5); }
.p-6 { padding: var(--space-6); }
.px-4 { padding-left: var(--space-4); padding-right: var(--space-4); }
.px-5 { padding-left: var(--space-5); padding-right: var(--space-5); }
.py-2 { padding-top: var(--space-2); padding-bottom: var(--space-2); }
.py-3 { padding-top: var(--space-3); padding-bottom: var(--space-3); }
.py-4 { padding-top: var(--space-4); padding-bottom: var(--space-4); }

.mt-1 { margin-top: var(--space-1); }
.mt-2 { margin-top: var(--space-2); }
.mt-3 { margin-top: var(--space-3); }
.mt-4 { margin-top: var(--space-4); }
.mb-2 { margin-bottom: var(--space-2); }
.mb-3 { margin-bottom: var(--space-3); }
.mb-4 { margin-bottom: var(--space-4); }

.truncate {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.line-clamp-2 {
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  overflow: hidden;
}

.line-clamp-3 {
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 3;
  overflow: hidden;
}

.hidden { display: none !important; }
.opacity-0 { opacity: 0; }
.pointer-events-none { pointer-events: none; }

/* ── Status Bar Spacer (simulate iOS safe area) ────────── */
.safe-area-top {
  height: env(safe-area-inset-top, 0px);
  background: var(--black);
}
