/* ===========================================================
   HOTELIUM — DESIGN SYSTEM V2 (Ultra-Modern SaaS)
   Conçu par Antigravity
   =========================================================== */

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

:root {
  /* Colors - Derived from DESIGN.md */
  --bg:             #F8FAFC;         /* colors.bg */
  --bg-2:           #F1F5F9;         /* colors.bg-2 */
  --surface:        #FFFFFF;         /* colors.surface */
  --surface-alpha:  rgba(255, 255, 255, 0.75);
  
  --ink:            #0F172A;         /* colors.ink */
  --ink-2:          #475569;         /* colors.ink-2 */
  
  --primary:        #020617;         /* colors.primary */
  --primary-hover:  #1E293B;         /* colors.primary-hover */
  --primary-soft:   rgba(2, 6, 23, 0.05); /* colors.primary-soft */
  
  --accent:         #10B981;         /* colors.accent */
  --accent-hover:   #059669;         /* colors.accent-hover */
  --accent-soft:    #D1FAE5;         /* colors.accent-soft */
  
  --line:           #E2E8F0;         /* colors.line */
  --line-2:         #CBD5E1;         /* colors.line-2 */
  
  /* Typography - Derived from DESIGN.md */
  --ff-heading:     'Outfit', sans-serif;
  --ff-body:        'Inter', sans-serif;
  
  --fs-h1:          clamp(3rem, 7vw, 4.5rem); 
  --fs-h2:          clamp(2rem, 4vw, 3rem);
  --fs-h3:          clamp(1.25rem, 2vw, 1.75rem);
  --fs-body:        1.125rem;

  /* Spacing - Derived from DESIGN.md */
  --spacing-sm:     16px;            /* spacing.sm */
  --spacing-md:     32px;            /* spacing.md */
  --spacing-lg:     128px;           /* spacing.lg - Increased for premium breathing room */

  /* Rounded - Derived from DESIGN.md */
  --radius-sm:      12px;            /* rounded.sm */
  --radius-md:      20px;            /* rounded.md */
  --radius-lg:      32px;            /* rounded.lg */
  --radius-pill:    999px;           /* rounded.pill */

  /* Layout */
  --maxw:           1200px;
  --nav-height:     80px;

  /* Advanced Gradients (WOW Factor) */
  --gradient-accent: linear-gradient(135deg, #34D399 0%, var(--accent) 100%);
  --gradient-primary: linear-gradient(135deg, var(--ink) 0%, var(--primary) 100%);
  --gradient-text: linear-gradient(135deg, var(--primary) 0%, var(--ink-2) 100%);
  --gradient-text-light: linear-gradient(135deg, #FFFFFF 0%, #CBD5E1 100%);

  /* Shadows - Premium & Tech rationale */
  --shadow-sm:      0 2px 4px rgba(2, 6, 23, 0.04);
  --shadow-md:      0 8px 16px -4px rgba(2, 6, 23, 0.08), 0 4px 8px -2px rgba(2, 6, 23, 0.04);
  --shadow-lg:      0 20px 40px -10px rgba(2, 6, 23, 0.12), 0 10px 20px -5px rgba(2, 6, 23, 0.06);
  --shadow-glow:    0 0 30px -5px rgba(16, 185, 129, 0.5), 0 0 15px -2px rgba(16, 185, 129, 0.3);
  
  /* Glassmorphism */
  --glass-bg:       rgba(255, 255, 255, 0.6);
  --glass-border:   rgba(255, 255, 255, 0.8);
  --glass-dark-bg:  rgba(2, 6, 23, 0.7);

  /* Transitions */
  --ease-spring:    cubic-bezier(0.175, 0.885, 0.32, 1.15);
  --ease-smooth:    cubic-bezier(0.25, 1, 0.5, 1);
}

/* ===========================================================
   RESET & BASES
   =========================================================== */
* { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; font-size: 16px; }

body {
  font-family: var(--ff-body);
  color: var(--ink);
  background: var(--bg);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}

h1, h2, h3, h4, h5, h6 {
  font-family: var(--ff-heading);
  font-weight: 700;
  color: var(--ink);
  line-height: 1.1;
  letter-spacing: -0.03em;
}

/* Fluid Typography - Base from DESIGN.md */
h1 { font-size: clamp(3rem, 7vw, var(--fs-h1)); margin-bottom: 0.3em; }
h2 { font-size: clamp(2rem, 4vw, var(--fs-h2)); margin-bottom: 0.5em; letter-spacing: -0.02em; }
h3 { font-size: clamp(1.25rem, 2vw, var(--fs-h3)); margin-bottom: 0.5em; }
p { font-size: var(--fs-body); color: var(--ink-2); margin-bottom: 1.5em; }

a { color: var(--accent); text-decoration: none; transition: color 0.2s ease; }
a:hover { color: var(--accent-hover); }

.container {
  width: 100%;
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 0 24px;
}
.text-center { text-align: center; }

/* ===========================================================
   UI COMPONENTS
   =========================================================== */

/* Text Gradients */
.text-gradient {
  background: var(--gradient-text);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}
.text-gradient-light {
  background: var(--gradient-text-light);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* Boutons Modernes */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 24px; /* Standardized baseline */
  font-family: var(--ff-body);
  font-size: 1rem;
  font-weight: 600;
  border-radius: var(--radius-pill);
  cursor: pointer;
  border: 1px solid transparent;
  transition: all 0.4s var(--ease-spring);
  text-decoration: none;
  position: relative;
  overflow: hidden;
  z-index: 1;
}
.btn-sm { padding: 10px 20px; font-size: 0.95rem; }
.btn-lg { padding: 18px 36px; font-size: 1.125rem; }

.btn::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0; bottom: 0;
  border-radius: inherit;
  z-index: -1;
  opacity: 0;
  transition: opacity 0.4s ease;
}

.btn-primary {
  background: var(--primary);
  color: var(--surface);
  box-shadow: 0 4px 10px rgba(2, 6, 23, 0.15);
}
.btn-primary::before {
  background: var(--gradient-primary);
}
.btn-primary:hover {
  transform: translateY(-3px);
  box-shadow: 0 12px 24px -8px rgba(2, 6, 23, 0.4);
  color: var(--surface);
}
.btn-primary:hover::before {
  opacity: 1;
}

.btn-accent {
  background: var(--gradient-accent);
  color: var(--surface);
  box-shadow: var(--shadow-md), 0 4px 15px rgba(16, 185, 129, 0.3);
  text-shadow: 0 1px 2px rgba(0,0,0,0.1);
}
.btn-accent:hover {
  transform: translateY(-3px) scale(1.02);
  box-shadow: var(--shadow-glow);
  color: var(--surface);
}

.btn-outline {
  background: var(--glass-bg);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  color: var(--ink);
  border: 1px solid rgba(2, 6, 23, 0.1);
  box-shadow: var(--shadow-sm);
}
.btn-outline:hover {
  background: var(--surface);
  border-color: var(--primary);
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

/* Badges */
.badge {
  display: inline-flex;
  align-items: center;
  padding: 6px 14px;
  border-radius: var(--radius-pill);
  font-family: var(--ff-heading);
  font-size: 0.85rem;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  background: var(--accent-soft);
  color: var(--accent-hover);
  font-weight: 700;
  margin-bottom: 1.5rem;
}

/* Cards Premium (Glassmorphism effect) */
.card {
  background: var(--surface);
  border: 1px solid rgba(255, 255, 255, 0.8);
  border-radius: var(--radius-lg);
  padding: 48px 40px;
  box-shadow: var(--shadow-md);
  transition: all 0.5s var(--ease-spring);
  position: relative;
  overflow: hidden;
  z-index: 1;
}

/* Subtle inner glow for cards */
.card::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0; bottom: 0;
  border-radius: inherit;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.5);
  pointer-events: none;
  z-index: 2;
}

.card:hover {
  transform: translateY(-8px);
  box-shadow: var(--shadow-lg), 0 15px 30px -5px rgba(16, 185, 129, 0.15);
  border-color: rgba(16, 185, 129, 0.3);
}

/* Glass panel utility */
.glass-panel {
  background: var(--glass-bg);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1px solid var(--glass-border);
  box-shadow: var(--shadow-md);
  border-radius: var(--radius-lg);
}

/* ===========================================================
   LAYOUT & GRID
   =========================================================== */
.section { padding: 120px 0; }
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 32px; }

/* ===========================================================
   NAVIGATION (NAVBAR)
   =========================================================== */
.navbar {
  position: fixed;
  top: 0; left: 0; right: 0;
  height: var(--nav-height);
  background: var(--glass-bg);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  z-index: 1000;
  display: flex;
  align-items: center;
  transition: all 0.4s var(--ease-spring);
}

.navbar.scrolled {
  background: rgba(255, 255, 255, 0.9);
  box-shadow: var(--shadow-sm);
  border-bottom-color: var(--line);
}

.nav-container {
  display: flex;
  justify-content: space-between;
  align-items: center;
  width: 100%;
}

.logo {
  font-family: var(--ff-heading);
  font-size: 1.5rem;
  font-weight: 800;
  color: var(--primary);
  display: flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
  letter-spacing: -0.04em;
  transition: transform 0.3s var(--ease-spring);
}
.logo:hover {
  transform: scale(1.05);
}
.logo svg {
  width: 32px;
  height: 32px;
  color: var(--accent);
}

.nav-links {
  display: flex;
  gap: 40px;
  align-items: center;
}
.nav-links a:not(.btn) {
  color: var(--ink-2);
  font-weight: 500;
  font-size: 0.95rem;
  position: relative;
  padding-bottom: 4px;
}
.nav-links a:not(.btn)::after {
  content: '';
  position: absolute;
  bottom: 0; left: 0; right: 0;
  height: 2px;
  background: var(--gradient-accent);
  transform: scaleX(0);
  transform-origin: right;
  transition: transform 0.3s var(--ease-spring);
  border-radius: 2px;
}
.nav-links a:not(.btn):hover { 
  color: var(--primary); 
}
.nav-links a:not(.btn):hover::after,
.nav-links a:not(.btn).active::after {
  transform: scaleX(1);
  transform-origin: left;
}
.nav-links a:not(.btn).active {
  color: var(--primary);
}

.mobile-menu-btn {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  color: var(--ink);
}
.mobile-menu-btn svg { width: 28px; height: 28px; }

/* Mobile menu transitions */
.nav-links {
  transition: all 0.4s var(--ease-spring);
}

/* ===========================================================
   HERO ULTRA-MODERN
   =========================================================== */
.hero {
  position: relative;
  min-height: 100vh;
  display: flex;
  align-items: center;
  padding-top: var(--nav-height);
  overflow: hidden;
}

/* Gradients abstraits d'arrière plan (Glow effect) */
.hero-glow {
  position: absolute;
  top: -20%; right: -10%;
  width: 70vw; height: 70vw;
  background: radial-gradient(circle, rgba(16, 185, 129, 0.15) 0%, rgba(52, 211, 153, 0.05) 40%, transparent 70%);
  border-radius: 50%;
  filter: blur(60px);
  z-index: -1;
  animation: pulseGlow 12s infinite alternate ease-in-out;
}

.hero-glow-2 {
  position: absolute;
  bottom: -20%; left: -10%;
  width: 60vw; height: 60vw;
  background: radial-gradient(circle, rgba(2, 6, 23, 0.05) 0%, transparent 60%);
  border-radius: 50%;
  filter: blur(80px);
  z-index: -1;
  animation: pulseGlow2 15s infinite alternate ease-in-out;
}

/* Giant Animated 3D Background Logo */
.hero-bg-logo-scene {
  position: absolute;
  top: -10%;
  left: -5%;
  width: 800px;
  height: 800px;
  opacity: 0.25; /* Augmenté pour voir l'effet Chrome */
  z-index: 0;
  pointer-events: none;
  perspective: 1200px;
  transform-style: preserve-3d;
}

.bg-logo-circle-3d, .bg-logo-h-3d {
  position: absolute;
  top: 0; left: 0;
  width: 100%; height: 100%;
  transform-style: preserve-3d;
  transform-origin: center center;
}

.bg-logo-circle-3d {
  animation: spinCircleFull3D 20s linear infinite;
}

.bg-logo-h-3d {
  animation: spinHFull3D 12s linear infinite;
}

.bg-logo-circle-3d svg, .bg-logo-h-3d svg {
  position: absolute;
  top: 0; left: 0;
  width: 100%; height: 100%;
  filter: drop-shadow(0 2px 5px rgba(2, 6, 23, 0.2));
}

@keyframes spinCircleFull3D {
  0% { transform: rotateX(25deg) rotateY(0deg) rotateZ(0deg); }
  100% { transform: rotateX(25deg) rotateY(360deg) rotateZ(360deg); }
}

@keyframes spinHFull3D {
  0% { transform: translateZ(-20px) rotateX(-15deg) rotateY(0deg); }
  100% { transform: translateZ(-20px) rotateX(-15deg) rotateY(-360deg); }
}

@keyframes pulseGlow {
  0% { transform: scale(1) translate(0, 0); opacity: 0.6; }
  100% { transform: scale(1.1) translate(-2%, 2%); opacity: 1; }
}

@keyframes pulseGlow2 {
  0% { transform: scale(1) translate(0, 0); }
  100% { transform: scale(1.15) translate(2%, -2%); }
}

.hero-content {
  position: relative;
  z-index: 2;
  max-width: 900px;
  text-align: center;
  margin: 0 auto;
}

.hero h1 {
  background: var(--gradient-text);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  line-height: 1.1;
  padding-bottom: 0.1em; /* Empêche le bas des lettres d'être coupé avec background-clip */
}

.hero p.lead {
  font-size: clamp(1.125rem, 2vw, 1.35rem);
  color: var(--ink-2);
  max-width: 700px;
  margin: 0 auto 40px;
}

.hero-actions {
  display: flex;
  gap: 16px;
  justify-content: center;
  flex-wrap: wrap;
}

/* ===========================================================
   BENTO GRID SYSTEM
   =========================================================== */
.bento-grid {
  display: grid;
  grid-template-columns: repeat(12, 1fr);
  gap: var(--spacing-sm);
  margin-top: var(--spacing-lg);
}

.bento-item {
  background: var(--surface);
  border: 1px solid rgba(255, 255, 255, 0.8);
  border-radius: var(--radius-lg);
  padding: 32px;
  box-shadow: var(--shadow-sm);
  position: relative;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: all 0.4s var(--ease-spring);
}
.bento-item:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
  border-color: rgba(16, 185, 129, 0.2);
}

/* Specific Bento Sizes */
.bento-large { grid-column: span 8; }
.bento-small { grid-column: span 4; }
.bento-half  { grid-column: span 6; }

@media (max-width: 900px) {
  .bento-large, .bento-small, .bento-half { grid-column: span 12; }
}

/* ===========================================================
   CSS UI MOCKUPS (SHOW DON'T TELL)
   =========================================================== */
.ui-mockup-wrapper {
  position: relative;
  width: 100%;
  height: 100%;
  min-height: 400px;
  perspective: 1000px;
}

.ui-window {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-lg);
  overflow: hidden;
  display: flex;
  flex-direction: column;
}
.ui-window-header {
  height: 40px;
  border-bottom: 1px solid var(--line);
  display: flex;
  align-items: center;
  padding: 0 16px;
  gap: 8px;
  background: var(--bg-2);
}
.ui-dot {
  width: 10px; height: 10px;
  border-radius: 50%;
  background: var(--line-2);
}
.ui-dot:nth-child(1) { background: #FF5F56; }
.ui-dot:nth-child(2) { background: #FFBD2E; }
.ui-dot:nth-child(3) { background: #27C93F; }

/* Dashboard Elements */
.ui-card-floating {
  position: absolute;
  background: rgba(255, 255, 255, 0.9);
  backdrop-filter: blur(12px);
  border: 1px solid rgba(255, 255, 255, 1);
  border-radius: var(--radius-md);
  padding: 20px;
  box-shadow: 0 20px 40px -10px rgba(0, 0, 0, 0.1);
  animation: float 6s ease-in-out infinite;
}

.ui-chart-bar-container {
  display: flex;
  align-items: flex-end;
  gap: 8px;
  height: 100px;
  margin-top: 16px;
}
.ui-chart-bar {
  flex: 1;
  background: var(--line-2);
  border-radius: 4px 4px 0 0;
  transition: height 1s ease;
}
.ui-chart-bar.active {
  background: var(--gradient-accent);
}

.ui-skeleton-text {
  height: 12px;
  background: var(--line);
  border-radius: 4px;
  margin-bottom: 8px;
}
.ui-skeleton-text.short { width: 40%; }
.ui-skeleton-text.long { width: 80%; }

@keyframes float {
  0% { transform: translateY(0px); }
  50% { transform: translateY(-10px); }
  100% { transform: translateY(0px); }
}

/* ===========================================================
   FOOTER (PREMIUM DARK)
   =========================================================== */
.footer {
  background: var(--primary);
  color: var(--surface);
  padding: var(--spacing-lg) 0 var(--spacing-md);
  border-top: 1px solid rgba(255, 255, 255, 0.05);
  position: relative;
  overflow: hidden;
}

.footer::before {
  content: '';
  position: absolute;
  top: 0; left: 50%;
  transform: translateX(-50%);
  width: 100%; height: 1px;
  background: linear-gradient(90deg, transparent, var(--accent), transparent);
  opacity: 0.3;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.5fr 1fr 1fr 1fr;
  gap: var(--spacing-lg);
  margin-bottom: var(--spacing-lg);
}

.footer-col .logo {
  color: var(--surface);
  margin-bottom: var(--spacing-sm);
}

.footer-col p {
  color: var(--ink-2); /* We'll override this below for dark context */
  font-size: 1rem;
  max-width: 300px;
}
.footer-col p { color: rgba(255, 255, 255, 0.6); }

.footer-col h4 {
  font-family: var(--ff-heading);
  font-size: 1.125rem;
  color: var(--surface);
  margin-bottom: var(--spacing-md);
  position: relative;
  display: inline-block;
}
.footer-col h4::after {
  content: '';
  position: absolute;
  bottom: -8px; left: 0;
  width: 20px; height: 2px;
  background: var(--accent);
  border-radius: 2px;
}

.footer-col ul {
  list-style: none;
  padding: 0; margin: 0;
}
.footer-col ul li {
  margin-bottom: 12px;
}
.footer-col ul a {
  color: rgba(255, 255, 255, 0.6);
  font-size: 0.95rem;
  transition: all 0.3s ease;
}
.footer-col ul a:hover {
  color: var(--accent);
  padding-left: 4px;
}

.footer-bottom {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-top: var(--spacing-md);
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  color: rgba(255, 255, 255, 0.4);
  font-size: 0.85rem;
}
.footer-bottom a {
  color: rgba(255, 255, 255, 0.4);
}
.footer-bottom a:hover {
  color: var(--surface);
}

/* ===========================================================
   RESPONSIVE (MOBILE)
   =========================================================== */
@media (max-width: 900px) {
  .grid-3 { grid-template-columns: 1fr; gap: 24px; }
  .section { padding: 80px 0; }
  .footer-grid { grid-template-columns: 1fr; gap: var(--spacing-md); }
  .footer-bottom { flex-direction: column; gap: 16px; text-align: center; }

  /* Hero two-column collapses to single column on mobile */
  .hero .container[style*="grid-template-columns: 1fr 1fr"],
  .hero .container {
    grid-template-columns: 1fr !important;
  }
  .ui-mockup-wrapper {
    display: none;
  }
  
  .nav-links {
    position: absolute;
    top: var(--nav-height);
    left: 0; right: 0;
    background: var(--surface-alpha);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    flex-direction: column;
    padding: 32px;
    border-bottom: 1px solid var(--line);
    box-shadow: var(--shadow-lg);
    
    /* Animation base */
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    pointer-events: none;
    display: flex; /* Always flex but hidden */
  }
  .nav-links.active { 
    opacity: 1; 
    visibility: visible; 
    transform: translateY(0);
    pointer-events: all;
  }
  .nav-links .btn { width: 100%; margin-top: 16px; }
  
  .mobile-menu-btn { display: block; }
}
