/* AutoRent.ma Components */

/* ===== BUTTONS ===== */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  padding: 14px 28px; font-family: inherit; font-size: 16px; font-weight: 600;
  border-radius: var(--radius-md); border: 2px solid transparent; cursor: pointer;
  transition: all .2s ease; text-decoration: none; line-height: 1; white-space: nowrap;
}
.btn-sm { padding: 10px 18px; font-size: 14px; }
.btn-lg { padding: 18px 36px; font-size: 17px; }
.btn-primary { background: var(--primary); color: var(--white); box-shadow: var(--shadow-glow); }
.btn-primary:hover { background: var(--primary-dark); color: var(--white); transform: translateY(-2px); box-shadow: 0 0 50px rgba(79,70,229,0.45); }
.btn-secondary { background: var(--secondary); color: var(--white); }
.btn-secondary:hover { background: var(--secondary-dark); color: var(--white); transform: translateY(-2px); }
.btn-ghost { background: transparent; color: var(--text); border-color: var(--border); }
.btn-ghost:hover { border-color: var(--primary); color: var(--primary); }
.btn-ghost-white { background: transparent; color: var(--white); border-color: rgba(255,255,255,0.3); }
.btn-ghost-white:hover { background: rgba(255,255,255,0.1); color: var(--white); border-color: var(--white); }
.btn-white { background: var(--white); color: var(--primary); }
.btn-white:hover { background: var(--light); color: var(--primary-dark); transform: translateY(-2px); }
.btn-whatsapp { background: var(--whatsapp); color: var(--white); }
.btn-whatsapp:hover { background: #1ea952; color: var(--white); }
.btn-block { display: flex; width: 100%; }

/* ===== HEADER ===== */
.header {
  position: sticky; top: 0; z-index: 100;
  background: rgba(255,255,255,0.92); backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
}
.header-inner { display: flex; align-items: center; justify-content: space-between; height: 72px; }
.logo { font-size: 22px; font-weight: 800; color: var(--dark); letter-spacing: -0.02em; display: inline-flex; align-items: center; gap: 6px; }
.logo .dot { color: var(--primary); }
.nav-main { display: flex; align-items: center; gap: 32px; }
.nav-main a { color: var(--text); font-weight: 500; font-size: 15px; }
.nav-main a:hover { color: var(--primary); }
.nav-right { display: flex; align-items: center; gap: 16px; }
.lang-switch { display: inline-flex; gap: 4px; padding: 4px; background: var(--light); border-radius: var(--radius-pill); font-size: 13px; font-weight: 600; }
.lang-switch a { padding: 6px 12px; border-radius: var(--radius-pill); color: var(--muted); }
.lang-switch a.active { background: var(--white); color: var(--dark); box-shadow: var(--shadow-sm); }
.hamburger { display: none; background: transparent; border: 0; padding: 8px; cursor: pointer; }
.hamburger svg { width: 28px; height: 28px; }

@media (max-width: 1024px) {
  .nav-main, .nav-right .desktop-only { display: none; }
  .hamburger { display: block; }
}
.mobile-drawer {
  position: fixed; inset: 0; background: rgba(15,23,42,0.5); z-index: 200;
  display: none; opacity: 0; transition: opacity .2s;
}
.mobile-drawer.open { display: block; opacity: 1; }
.mobile-drawer-inner {
  position: absolute; right: 0; top: 0; bottom: 0; width: min(360px, 90vw);
  background: var(--white); padding: 24px; overflow-y: auto;
  transform: translateX(100%); transition: transform .25s ease;
}
.mobile-drawer.open .mobile-drawer-inner { transform: translateX(0); }
.mobile-drawer a { display: block; padding: 14px 0; font-size: 17px; color: var(--text); border-bottom: 1px solid var(--border); }

/* ===== FOOTER ===== */
.footer { background: var(--dark); color: rgba(255,255,255,0.75); padding: 64px 0 32px; }
.footer h4 { color: var(--white); font-size: 14px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.05em; margin-bottom: 20px; }
.footer-grid { display: grid; grid-template-columns: 1.4fr repeat(4, 1fr); gap: 48px; margin-bottom: 48px; }
.footer-brand p { color: rgba(255,255,255,0.6); font-size: 14px; max-width: 280px; }
.footer .logo { color: var(--white); }
.footer ul { list-style: none; padding: 0; margin: 0; }
.footer li { margin-bottom: 12px; }
.footer a { color: rgba(255,255,255,0.7); font-size: 14px; }
.footer a:hover { color: var(--white); }
.footer-bottom { padding-top: 32px; border-top: 1px solid rgba(255,255,255,0.1); display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 16px; font-size: 13px; }
.footer-bottom .powered { color: rgba(255,255,255,0.55); }
.footer-bottom .powered a { color: rgba(255,255,255,0.85); font-weight: 600; }
.footer-social { display: flex; gap: 12px; }
.footer-social a { width: 36px; height: 36px; display: inline-flex; align-items: center; justify-content: center; background: rgba(255,255,255,0.06); border-radius: 50%; }
.footer-social a:hover { background: var(--primary); }
.footer-social svg { width: 18px; height: 18px; }
@media (max-width: 1024px) { .footer-grid { grid-template-columns: 1fr 1fr; } }
@media (max-width: 640px) { .footer-grid { grid-template-columns: 1fr; gap: 32px; } }

/* ===== CARDS ===== */
.card { background: var(--white); border-radius: var(--radius-lg); padding: 32px; box-shadow: var(--shadow-sm); border: 1px solid var(--border); transition: all .25s ease; }
.card:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); border-color: rgba(79,70,229,0.2); }

.card-feature .icon-wrap { width: 56px; height: 56px; border-radius: var(--radius-md); background: linear-gradient(135deg, rgba(79,70,229,0.12), rgba(16,185,129,0.12)); display: inline-flex; align-items: center; justify-content: center; color: var(--primary); margin-bottom: 20px; }
.card-feature .icon-wrap svg { width: 28px; height: 28px; }
.card-feature h3 { font-size: 20px; margin-bottom: 12px; }
.card-feature p { font-size: 15px; color: var(--muted); margin: 0 0 16px; }
.card-feature .learn-more { font-size: 14px; font-weight: 600; color: var(--primary); display: inline-flex; align-items: center; gap: 4px; }

.card-pricing { display: flex; flex-direction: column; height: 100%; padding: 36px 32px; position: relative; }
.card-pricing.popular { border-color: var(--primary); box-shadow: var(--shadow-glow); }
.card-pricing .badge-popular { position: absolute; top: -14px; left: 50%; transform: translateX(-50%); background: var(--primary); color: var(--white); font-size: 12px; font-weight: 700; padding: 6px 14px; border-radius: var(--radius-pill); letter-spacing: 0.04em; }
.card-pricing .plan-name { font-size: 14px; font-weight: 700; color: var(--primary); text-transform: uppercase; letter-spacing: 0.06em; margin-bottom: 8px; }
.card-pricing .plan-tagline { font-size: 14px; color: var(--muted); margin-bottom: 24px; }
.card-pricing .price { font-size: 48px; font-weight: 800; color: var(--dark); line-height: 1; }
.card-pricing .price small { font-size: 16px; font-weight: 500; color: var(--muted); }
.card-pricing .price-period { font-size: 14px; color: var(--muted); margin-top: 4px; margin-bottom: 28px; }
.card-pricing ul.features { list-style: none; padding: 0; margin: 0 0 32px; flex: 1; }
.card-pricing ul.features li { display: flex; align-items: flex-start; gap: 10px; padding: 8px 0; font-size: 15px; color: var(--text); }
.card-pricing ul.features li svg { flex-shrink: 0; width: 20px; height: 20px; color: var(--secondary); margin-top: 2px; }
.card-pricing ul.features li.disabled { color: var(--muted); }
.card-pricing ul.features li.disabled svg { color: var(--border); }

.card-testimonial { padding: 32px; }
.card-testimonial .quote { font-size: 16px; line-height: 1.7; color: var(--text); margin-bottom: 24px; }
.card-testimonial .author { display: flex; align-items: center; gap: 12px; }
.card-testimonial .avatar { width: 48px; height: 48px; border-radius: 50%; object-fit: cover; }
.card-testimonial .author-name { font-weight: 600; color: var(--dark); font-size: 15px; }
.card-testimonial .author-role { font-size: 13px; color: var(--muted); }
.stars { display: flex; gap: 2px; color: var(--accent); margin-bottom: 12px; }
.stars svg { width: 18px; height: 18px; }

/* ===== BADGES ===== */
.badge { display: inline-flex; align-items: center; gap: 6px; padding: 4px 12px; border-radius: var(--radius-pill); font-size: 12px; font-weight: 600; }
.badge-trial { background: rgba(16,185,129,0.12); color: var(--secondary-dark); }
.badge-new { background: rgba(245,158,11,0.15); color: #B45309; }

/* ===== STATS BAR ===== */
.section-stats { padding: 48px 0; background: var(--white); border-bottom: 1px solid var(--border); }
.stats-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 32px; text-align: center; }
.stats-grid .stat-num { font-size: 40px; font-weight: 800; color: var(--dark); line-height: 1; margin-bottom: 8px; letter-spacing: -0.02em; }
.stats-grid .stat-label { font-size: 14px; color: var(--muted); }
@media (max-width: 768px) { .stats-grid { grid-template-columns: repeat(2, 1fr); gap: 24px; } .stats-grid .stat-num { font-size: 32px; } }

/* ===== CTA SECTION ===== */
.cta-section { background: linear-gradient(135deg, var(--dark) 0%, #1E1B4B 100%); color: var(--white); border-radius: 24px; padding: 80px 48px; text-align: center; position: relative; overflow: hidden; }
.cta-section::before { content: ''; position: absolute; top: -100px; left: 50%; transform: translateX(-50%); width: 800px; height: 400px; background: radial-gradient(ellipse, rgba(79,70,229,0.4) 0%, transparent 60%); pointer-events: none; }
.cta-section > * { position: relative; z-index: 1; }
.cta-section h2 { color: var(--white); margin-bottom: 16px; }
.cta-section p { color: rgba(255,255,255,0.8); font-size: 18px; max-width: 560px; margin: 0 auto 32px; }
.cta-section .cta-buttons { display: inline-flex; gap: 16px; flex-wrap: wrap; justify-content: center; }
@media (max-width: 768px) { .cta-section { padding: 56px 24px; } .cta-section .cta-buttons { flex-direction: column; align-items: stretch; width: 100%; } }

/* ===== FORMS ===== */
.form-group { margin-bottom: 20px; }
.form-label { display: block; font-size: 14px; font-weight: 600; color: var(--dark); margin-bottom: 8px; }
.form-control, .form-select {
  width: 100%; padding: 14px 16px; font-family: inherit; font-size: 16px;
  border: 1.5px solid var(--border); border-radius: var(--radius-sm); background: var(--white);
  transition: all .15s ease; color: var(--text);
}
.form-control:focus, .form-select:focus { outline: none; border-color: var(--primary); box-shadow: 0 0 0 4px rgba(79,70,229,0.12); }
.form-help { font-size: 13px; color: var(--muted); margin-top: 6px; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
@media (max-width: 640px) { .form-row { grid-template-columns: 1fr; } }
.form-phone { display: flex; gap: 8px; }
.form-phone .form-select { width: 110px; flex-shrink: 0; }

/* ===== WHATSAPP FLOAT ===== */
.wa-float {
  position: fixed; bottom: 24px; right: 24px; width: 56px; height: 56px;
  background: var(--whatsapp); color: var(--white); border-radius: 50%;
  display: inline-flex; align-items: center; justify-content: center;
  box-shadow: 0 6px 20px rgba(37,211,102,0.4); z-index: 90;
  transition: transform .2s ease;
}
.wa-float:hover { transform: scale(1.08); color: var(--white); }
.wa-float svg { width: 28px; height: 28px; }
.wa-float::after { content: ''; position: absolute; inset: -4px; border-radius: 50%; border: 2px solid var(--whatsapp); animation: wa-pulse 2s infinite; }
@keyframes wa-pulse { 0% { transform: scale(1); opacity: 1; } 100% { transform: scale(1.4); opacity: 0; } }

/* ===== FAQ ACCORDION ===== */
.faq-list { max-width: 820px; margin: 0 auto; }
.faq-item { background: var(--white); border: 1px solid var(--border); border-radius: var(--radius-md); margin-bottom: 12px; overflow: hidden; transition: all .2s; }
.faq-item[open] { border-color: var(--primary); box-shadow: var(--shadow-md); }
.faq-item summary { list-style: none; padding: 20px 24px; font-weight: 600; font-size: 16px; color: var(--dark); cursor: pointer; display: flex; justify-content: space-between; align-items: center; gap: 16px; }
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary::after { content: '+'; font-size: 24px; color: var(--primary); font-weight: 400; transition: transform .2s; }
.faq-item[open] summary::after { transform: rotate(45deg); }
.faq-item .faq-answer { padding: 0 24px 20px; color: var(--muted); }

/* ===== HERO ===== */
.hero { padding: 96px 0 64px; }
.hero h1 { margin-bottom: 24px; }
.hero .lead { font-size: 20px; color: var(--muted); max-width: 600px; margin: 0 0 32px; }
.hero-cta { display: flex; gap: 12px; flex-wrap: wrap; margin-bottom: 24px; }
.hero-trust { display: flex; align-items: center; gap: 16px; font-size: 14px; color: var(--muted); flex-wrap: wrap; }
.hero-trust span { display: inline-flex; align-items: center; gap: 6px; }
.hero-trust svg { width: 16px; height: 16px; color: var(--secondary); }
.hero-grid { display: grid; grid-template-columns: 1.05fr 1fr; gap: 64px; align-items: center; }
@media (max-width: 1024px) { .hero-grid { grid-template-columns: 1fr; gap: 40px; } .hero { padding: 56px 0 32px; } .hero .lead { font-size: 17px; } }
.hero-image { perspective: 1500px; }
.hero-image img, .hero-image .mock { transform: rotateY(-8deg) rotateX(4deg); border-radius: var(--radius-lg); box-shadow: var(--shadow-lg); }

/* ===== LOGOS BAR ===== */
.logos-bar { display: flex; flex-wrap: wrap; gap: 48px; justify-content: center; align-items: center; opacity: 0.6; }
.logos-bar .logo-item { font-family: serif; font-size: 22px; font-weight: 700; color: var(--muted); filter: grayscale(1); transition: all .2s; }
.logos-bar .logo-item:hover { filter: grayscale(0); opacity: 1; color: var(--dark); }

/* ===== TIMELINE (HOW IT WORKS) ===== */
.timeline { display: grid; grid-template-columns: repeat(3, 1fr); gap: 32px; position: relative; }
.timeline-step { text-align: center; padding: 0 16px; }
.timeline-step .step-num { width: 56px; height: 56px; border-radius: 50%; background: linear-gradient(135deg, var(--primary), var(--primary-light)); color: var(--white); font-weight: 800; font-size: 22px; display: inline-flex; align-items: center; justify-content: center; margin-bottom: 20px; box-shadow: var(--shadow-glow); }
.timeline-step h3 { font-size: 22px; margin-bottom: 8px; }
.timeline-step p { color: var(--muted); }
@media (max-width: 768px) { .timeline { grid-template-columns: 1fr; } }

/* ===== TABS ===== */
.tabs-nav { display: inline-flex; gap: 4px; padding: 6px; background: var(--light); border-radius: var(--radius-pill); margin-bottom: 32px; }
.tabs-nav button { padding: 10px 20px; background: transparent; border: 0; border-radius: var(--radius-pill); font-weight: 600; color: var(--muted); cursor: pointer; font-family: inherit; font-size: 14px; transition: all .15s; }
.tabs-nav button.active { background: var(--white); color: var(--dark); box-shadow: var(--shadow-sm); }
.tab-panel { display: none; }
.tab-panel.active { display: block; }

/* ===== COOKIE BANNER ===== */
.cookie-banner { position: fixed; bottom: 16px; left: 16px; right: 16px; max-width: 600px; margin: 0 auto; background: var(--dark); color: var(--white); padding: 20px 24px; border-radius: var(--radius-lg); box-shadow: var(--shadow-lg); display: none; z-index: 80; }
.cookie-banner.show { display: flex; align-items: center; gap: 16px; flex-wrap: wrap; }
.cookie-banner p { color: rgba(255,255,255,0.85); margin: 0; font-size: 14px; flex: 1 1 280px; }
.cookie-banner .btn { padding: 10px 18px; font-size: 14px; }

/* ===== TABLES ===== */
.compare-table { width: 100%; border-collapse: collapse; background: var(--white); border-radius: var(--radius-lg); overflow: hidden; box-shadow: var(--shadow-md); }
.compare-table th, .compare-table td { padding: 16px 20px; text-align: left; border-bottom: 1px solid var(--border); font-size: 14px; }
.compare-table thead th { background: var(--light); font-weight: 700; color: var(--dark); }
.compare-table tbody td.center { text-align: center; }
.compare-table tbody td svg { width: 20px; height: 20px; }
.compare-table tbody td .yes { color: var(--secondary); }
.compare-table tbody td .no { color: var(--border); }
.compare-table .popular-col { background: rgba(79,70,229,0.04); }

/* ===== BREADCRUMB ===== */
.breadcrumb { padding: 16px 0; font-size: 13px; color: var(--muted); }
.breadcrumb a { color: var(--muted); }
.breadcrumb a:hover { color: var(--primary); }
.breadcrumb .sep { margin: 0 8px; }

/* ===== PRICING TOGGLE ===== */
.pricing-toggle {
  display: inline-flex; align-items: center; gap: 12px;
  padding: 8px; background: white; border-radius: 999px;
  box-shadow: var(--shadow-sm);
}
.pricing-toggle .toggle-label {
  font-size: 14px; font-weight: 600; padding: 0 16px;
  color: var(--muted); cursor: pointer; user-select: none;
}
.pricing-toggle .toggle-label.active { color: var(--dark); }
.toggle-switch {
  position: relative; display: inline-block; width: 48px; height: 26px;
  flex-shrink: 0;
}
.toggle-switch input {
  position: absolute; opacity: 0; width: 100%; height: 100%; margin: 0; cursor: pointer; z-index: 2;
}
.toggle-track {
  position: absolute; inset: 0;
  background: var(--border); border-radius: 999px;
  transition: background .25s ease;
}
.toggle-thumb {
  position: absolute; top: 3px; left: 3px;
  width: 20px; height: 20px; background: white;
  border-radius: 50%; transition: transform .25s ease;
  box-shadow: 0 2px 4px rgba(0,0,0,0.15);
}
.toggle-switch input:checked ~ .toggle-track { background: var(--primary); }
.toggle-switch input:checked ~ .toggle-track .toggle-thumb { transform: translateX(22px); }

/* ===== UTILS ===== */
.mt-8 { margin-top: 32px; } .mt-12 { margin-top: 48px; } .mt-16 { margin-top: 64px; }
.mb-4 { margin-bottom: 16px; } .mb-8 { margin-bottom: 32px; } .mb-12 { margin-bottom: 48px; }
