/* ================================================
   AIRSTEP - Styles principaux
   Variables globales, reset, et layout commun
   ================================================ */

:root {
  /* Couleurs principales */
  --bg: #ffffff;
  --text: #0f172a;
  --muted: #6b7280;
  --azure: #3CA7FF;
  --azure-soft: #EAF7FF;
  --azure-light: #DFF1FF;
  --border: #e5e7eb;
  
  /* Layout */
  --maxw: 1120px;
  --radius-lg: 1.25rem;
  --shadow-soft: 0 20px 45px rgba(15, 23, 42, 0.08);
  
  /* Safe area (notch support) */
  --safe-left: env(safe-area-inset-left);
  --safe-right: env(safe-area-inset-right);
}

/* Reset et base */
* {
  box-sizing: border-box;
}

html {
  width: 100%;
  overflow-x: hidden;
}

body {
  margin: 0;
  font-family: system-ui, -apple-system, sans-serif;
  color: var(--text);
  background: var(--bg);
  overflow-x: hidden;
}

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

/* Layout commun */
.page {
  min-height: 100vh;
}

.shell {
  width: 100%;
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 1.5rem calc(1.5rem + var(--safe-right)) 4rem calc(1.5rem + var(--safe-left));
}

@media (max-width: 520px) {
  .shell {
    padding-left: calc(1rem + var(--safe-left));
    padding-right: calc(1rem + var(--safe-right));
  }
}

@media (min-width: 1024px) {
  .shell {
    padding: 2.5rem 0 5rem;
  }
}

/* Header commun */
.site-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 2.5rem;
}

.brand {
  font-size: 1.15rem;
  font-weight: 800;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--text);
  text-decoration: none;
  line-height: 1;
  padding: 0.25rem 0;
}

.brand:hover {
  opacity: 0.85;
}

.top-nav {
  display: flex;
  align-items: center;
  gap: 0.9rem;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.top-nav a {
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--text);
  text-decoration: none;
  padding: 0.55rem 0.9rem;
  border-radius: 999px;
  border: 1px solid rgba(226, 232, 240, 0.9);
  background: rgba(255, 255, 255, 0.7);
  backdrop-filter: blur(3px);
  transition: 0.15s ease;
}

.top-nav a:hover {
  background: var(--azure-soft);
  border-color: #d4e9ff;
}

@media (max-width: 520px) {
  .site-header {
    flex-direction: column;
    align-items: flex-start;
  }
  
  .top-nav {
    width: 100%;
    justify-content: flex-start;
  }
  
  .top-nav a {
    width: 100%;
    text-align: center;
  }
}

/* Boutons communs */
.cta-btn {
  padding: 0.85rem 1.5rem;
  border-radius: 999px;
  font-weight: 600;
  font-size: 0.95rem;
  cursor: pointer;
  transition: 0.15s ease;
  border: none;
}

.cta-primary {
  background: var(--azure);
  color: white;
  box-shadow: 0 15px 30px rgba(60, 167, 255, 0.35);
}

.cta-primary:hover {
  background: #1F95F5;
}

.cta-secondary {
  background: var(--azure-soft);
  border: 1px solid #d4e9ff;
  color: var(--text);
}

.cta-secondary:hover {
  background: var(--azure-light);
}

/* Utilitaires */
.loading {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  gap: 20px;
}

.spinner {
  width: 50px;
  height: 50px;
  border: 4px solid var(--azure-light);
  border-top: 4px solid var(--azure);
  border-radius: 50%;
  animation: spin 1s linear infinite;
}

@keyframes spin {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}
