/*
Theme Name: FoodMarseille
Description: Thème personnalisé pour FoodMarseille.fr avec Apéro du 13 et Le Kiosque de Mami
Author: Carla
Version: 1.0
Text Domain: foodmarseille
*/

/* Import Google Fonts - Manrope */
@import url('https://fonts.googleapis.com/css2?family=Manrope:wght@200;300;400;500;600;700;800&display=swap');

/* Configuration de base */
@layer base {
  * {
    font-family: 'Manrope', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
  }
}

/* Couleurs Apéro du 13 définies dans apero-home.php pour priorité */

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

body {
  margin: 0;
  line-height: 1.6;
  color: #333;
  font-weight: 400;
}

/* Liens */
a {
  text-decoration: none;
  color: inherit;
}

a:hover {
  text-decoration: none;
}

/* Styles simples pour checkout emerald - surcharge WooCommerce */
.woocommerce-checkout {
  background: linear-gradient(135deg, #ecfdf5 0%, #f0fdfa 100%);
  min-height: 100vh;
  padding: 2rem 1rem;
}

.woocommerce-checkout form.checkout {
  max-width: 800px;
  margin: 0 auto;
  background: white;
  border-radius: 12px;
  box-shadow: 0 4px 6px rgba(0,0,0,0.1);
  overflow: hidden;
}

.woocommerce-billing-fields h3,
.woocommerce-shipping-fields h3,
.woocommerce-additional-fields h3,
#order_review_heading {
  color: #065f46;
  font-weight: 600;
  margin-bottom: 1rem;
}

.woocommerce-checkout-review-order-table th {
  background: #10b981 !important;
  color: white !important;
}

.woocommerce-checkout-review-order-table {
  border: 1px solid #d1fae5 !important;
}

.woocommerce .button,
.woocommerce button.button {
  background: #10b981 !important;
  color: white !important;
  border: none !important;
  border-radius: 8px !important;
  padding: 12px 24px !important;
  font-weight: 600 !important;
  transition: background 0.2s ease !important;
}

.woocommerce .button:hover,
.woocommerce button.button:hover {
  background: #059669 !important;
}

.woocommerce input[type="text"],
.woocommerce input[type="email"],
.woocommerce input[type="tel"],
.woocommerce input[type="password"],
.woocommerce textarea,
.woocommerce select {
  border: 2px solid #e2e8f0 !important;
  border-radius: 8px !important;
  padding: 12px 16px !important;
  transition: border-color 0.2s ease !important;
}

.woocommerce input:focus,
.woocommerce textarea:focus,
.woocommerce select:focus {
  border-color: #10b981 !important;
  outline: none !important;
  box-shadow: 0 0 0 3px rgba(16, 185, 129, 0.1) !important;
}

.wc_payment_methods .wc_payment_method {
  border: 2px solid #e2e8f0 !important;
  border-radius: 8px !important;
  margin-bottom: 1rem !important;
  background: white !important;
}

.wc_payment_methods .wc_payment_method:hover {
  border-color: #10b981 !important;
}

/* Style pour le contenu des pages */
.prose {
  color: #333333;
  line-height: 1.75;
}

.prose h1, .prose h2, .prose h3, .prose h4, .prose h5, .prose h6 {
  color: #1a1a1a;
  font-weight: 700;
  line-height: 1.3;
  margin-top: 2em;
  margin-bottom: 1em;
}

.prose h1 {
  font-size: 2.25rem;
}

.prose h2 {
  font-size: 1.875rem;
}

.prose h3 {
  font-size: 1.5rem;
}

.prose p {
  margin-bottom: 1.25em;
}

.prose ul, .prose ol {
  margin-top: 1.25em;
  margin-bottom: 1.25em;
  padding-left: 1.625em;
}

.prose li {
  margin-top: 0.5em;
  margin-bottom: 0.5em;
}

.prose a {
  color: #10b981;
  text-decoration: underline;
}

.prose a:hover {
  color: #059669;
}

.prose strong {
  font-weight: 700;
  color: #1a1a1a;
}

.prose table {
  width: 100%;
  margin-top: 2em;
  margin-bottom: 2em;
  border-collapse: collapse;
}

.prose th, .prose td {
  padding: 0.75em 1em;
  border: 1px solid #e5e7eb;
}

.prose th {
  background-color: #f9fafb;
  font-weight: 700;
}

/* Logo personnalisé */
.custom-logo {
  max-height: 60px;
  width: auto;
  height: auto;
}

.custom-logo-link {
  display: flex;
  align-items: center;
}

/* Logo dans le header */
.site-header .custom-logo {
  max-height: 60px;
  max-width: 250px;
  object-fit: contain;
}

/* Logo dans le footer */
.site-footer .custom-logo {
  max-height: 40px;
  max-width: 120px;
  object-fit: contain;
}

/* Logo mobile */
@media (max-width: 768px) {
  .site-header .custom-logo {
    max-height: 45px;
    max-width: 180px;
  }

  .site-footer .custom-logo {
    max-height: 30px;
    max-width: 90px;
  }
}

/* Utility classes inspirées de Tailwind */
.container {
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 1rem;
}

.mx-auto { margin-left: auto; margin-right: auto; }
.px-4 { padding-left: 1rem; padding-right: 1rem; }
.px-6 { padding-left: 1.5rem; padding-right: 1.5rem; }
.px-8 { padding-left: 2rem; padding-right: 2rem; }
.py-3 { padding-top: 0.75rem; padding-bottom: 0.75rem; }
.py-4 { padding-top: 1rem; padding-bottom: 1rem; }
.py-6 { padding-top: 1.5rem; padding-bottom: 1.5rem; }
.py-8 { padding-top: 2rem; padding-bottom: 2rem; }
.py-16 { padding-top: 4rem; padding-bottom: 4rem; }

.mb-2 { margin-bottom: 0.5rem; }
.mb-4 { margin-bottom: 1rem; }
.mb-6 { margin-bottom: 1.5rem; }
.mb-8 { margin-bottom: 2rem; }
.mb-12 { margin-bottom: 3rem; }

.mt-4 { margin-top: 1rem; }

.text-center { text-align: center; }
.text-left { text-align: left; }
.text-right { text-align: right; }

.text-white { color: white; }
.text-gray-600 { color: #718096; }
.text-gray-800 { color: #2d3748; }
.text-blue-600 { color: #2563eb; }
.text-orange-600 { color: #ea580c; }

.font-semibold { font-weight: 600; }
.font-bold { font-weight: 700; }

.text-xl { font-size: 1.25rem; line-height: 1.75rem; }
.text-2xl { font-size: 1.5rem; line-height: 2rem; }
.text-3xl { font-size: 1.875rem; line-height: 2.25rem; }
.text-4xl { font-size: 2.25rem; line-height: 2.5rem; }

.leading-relaxed { line-height: 1.625; }

/* Flexbox utilities */
.flex { display: flex; }
.inline-flex { display: inline-flex; }
.items-center { align-items: center; }
.justify-center { justify-content: center; }
.justify-between { justify-content: space-between; }
.space-x-4 > * + * { margin-left: 1rem; }
.space-x-6 > * + * { margin-left: 1.5rem; }
.space-y-2 > * + * { margin-top: 0.5rem; }

.flex-col { flex-direction: column; }
.flex-row { flex-direction: row; }

/* Grid utilities */
.grid { display: grid; }
.grid-cols-1 { grid-template-columns: repeat(1, minmax(0, 1fr)); }
.grid-cols-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.grid-cols-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.grid-cols-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }

.gap-4 { gap: 1rem; }
.gap-8 { gap: 2rem; }
.gap-12 { gap: 3rem; }

/* Layout */
.max-w-md { max-width: 28rem; }
.max-w-2xl { max-width: 42rem; }
.max-w-3xl { max-width: 48rem; }
.max-w-4xl { max-width: 56rem; }
.max-w-full { max-width: 100%; }

.w-full { width: 100%; }
.h-full { height: 100%; }
.h-16 { height: 4rem; }
.h-24 { height: 6rem; }
.h-32 { height: 8rem; }
.h-48 { height: 12rem; }

.min-h-screen { min-height: 100vh; }

.object-contain { object-fit: contain; }
.max-h-full { max-height: 100%; }

/* Background colors */
.bg-white { background-color: white; }
.bg-brown-600 { background-color: #623010; }
.bg-brown-700 { background-color: #4a2410; }
.bg-orange-50 { background-color: #fff7ed; }
.bg-orange-600 { background-color: #ea580c; }
.bg-orange-700 { background-color: #c2410c; }
.bg-gray-50 { background-color: #f9fafb; }
.bg-gray-100 { background-color: #f3f4f6; }
.bg-gray-600 { background-color: #4b5563; }

/* Background opacity */
.bg-brown-600\/70 { background-color: rgba(98, 48, 16, 0.7); }
.bg-orange-600\/70 { background-color: rgba(234, 88, 12, 0.7); }

/* Hover states */
.hover\:bg-brown-700:hover { background-color: #4a2410; }
.hover\:bg-orange-700:hover { background-color: #c2410c; }
.hover\:text-brown-600:hover { color: #623010; }
.hover\:text-brown-700:hover { color: #4a2410; }

/* Opacity utilities */
.bg-opacity-70 { opacity: 0.7; }

/* Transitions */
.transition { transition-property: color, background-color, border-color, text-decoration-color, fill, stroke, opacity, box-shadow, transform, filter, backdrop-filter; transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1); transition-duration: 150ms; }
.duration-300 { transition-duration: 300ms; }

/* Shadows */
.shadow-lg { box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05); }
.shadow-xl { box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04); }

/* Borders */
.border { border-width: 1px; }
.border-gray-300 { border-color: #d1d5db; }
.border-gray-200 { border-color: #e5e7eb; }
.border-l-4 { border-left-width: 4px; }
.border-yellow-400 { border-color: #fbbf24; }
.border-t { border-top-width: 1px; }

/* Border radius */
.rounded { border-radius: 0.25rem; }
.rounded-md { border-radius: 0.375rem; }
.rounded-lg { border-radius: 0.5rem; }
.rounded-full { border-radius: 9999px; }

/* Display */
.block { display: block; }
.inline-block { display: inline-block; }
.hidden { display: none; }

/* Overflow */
.overflow-hidden { overflow: hidden; }

/* Position */
.relative { position: relative; }
.absolute { position: absolute; }
.sticky { position: static; }
.inset-0 { top: 0; right: 0; bottom: 0; left: 0; }

/* Z-index */
.z-10 { z-index: 10; }

/* Gradients */
.bg-gradient-to-r { background-image: linear-gradient(to right, var(--tw-gradient-stops)); }
.from-gray-100 { --tw-gradient-from: #f3f4f6; --tw-gradient-stops: var(--tw-gradient-from), var(--tw-gradient-to, rgba(243, 244, 246, 0)); }
.to-gray-200 { --tw-gradient-to: #e5e7eb; }
.from-blue-600 { --tw-gradient-from: #2563eb; --tw-gradient-stops: var(--tw-gradient-from), var(--tw-gradient-to, rgba(37, 99, 235, 0)); }
.to-blue-800 { --tw-gradient-to: #1e40af; }
.from-orange-500 { --tw-gradient-from: #f97316; --tw-gradient-stops: var(--tw-gradient-from), var(--tw-gradient-to, rgba(249, 115, 22, 0)); }
.to-orange-600 { --tw-gradient-to: #ea580c; }

/* Hover effects */
.hover\:shadow-xl:hover { box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04); }

/* Screen reader only */
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* Animations */
@keyframes pulse {
  50% {
    opacity: .5;
  }
}
.animate-pulse {
  animation: pulse 2s cubic-bezier(0.4, 0, 0.6, 1) infinite;
}

/* Additional padding */
.p-6 { padding: 1.5rem; }

/* Overflow */
.overflow-hidden { overflow: hidden; }

/* Responsive */
@media (min-width: 768px) {
  .md\:block { display: block; }
  .md\:hidden { display: none; }
  .md\:grid-cols-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .md\:grid-cols-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .md\:grid-cols-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
  .md\:flex-row { flex-direction: row; }
  .md\:justify-between { justify-content: space-between; }
  .md\:text-4xl { font-size: 2.25rem; line-height: 2.5rem; }
  .md\:text-5xl { font-size: 3rem; line-height: 1; }
  .md\:text-6xl { font-size: 3.75rem; line-height: 1; }
}

@media (min-width: 1024px) {
  .lg\:grid-cols-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (min-width: 640px) {
  .sm\:flex-row { flex-direction: row; }
  .sm\:justify-center { justify-content: center; }
}

/* Variables CSS pour les couleurs */
:root {
  /* Couleurs Apéro du 13 */
  --apero-primary: #623010;
  --apero-secondary: #F5A623;
  --apero-accent: #7ED321;

  /* Couleurs Kiosque de Mami */
  --kiosque-primary: #FA934A;
  --kiosque-secondary: #8B4513;
  --kiosque-accent: #D2691E;
}

/* Styles de base */
body {
  font-family: 'Inter', sans-serif;
  line-height: 1.6;
}

/* Styles pour les pages d'accueil */
.apero-theme {
  --primary-color: var(--apero-primary);
  --secondary-color: var(--apero-secondary);
  --accent-color: var(--apero-accent);
}

.kiosque-theme {
  --primary-color: var(--kiosque-primary);
  --secondary-color: var(--kiosque-secondary);
  --accent-color: var(--kiosque-accent);
}

/* Header styles */
.site-header {
  background: white;
  box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

/* Footer styles */
.site-footer {
  background: #f8f9fa;
  border-top: 1px solid #e9ecef;
}

/* Navigation */
.main-navigation ul {
  list-style: none;
  margin: 0;
  padding: 0;
}

.main-navigation li {
  display: inline-block;
  margin-right: 20px;
}

.main-navigation a {
  text-decoration: none;
  color: #333;
  font-weight: 500;
  transition: color 0.3s ease;
}

.main-navigation a:hover {
  color: var(--primary-color);
}

/* Responsive */
@media (max-width: 768px) {
  .main-navigation li {
    display: block;
    margin: 10px 0;
  }
}

/* WooCommerce compatibility */
.woocommerce .button {
  background: var(--primary-color) !important;
  border-color: var(--primary-color) !important;
}

.woocommerce .button:hover {
  background: var(--secondary-color) !important;
  border-color: var(--secondary-color) !important;
}

/* Line clamp utilities pour le shop */
.line-clamp-2 {
  display: -webkit-box;
  -webkit-line-clamp: 2;
  line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

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

/* Accordion rotation utility */
.rotate-180 {
  transform: rotate(180deg);
}

/* =============================================
   YITH POINTS & REWARDS - NOTICE MODERNE
   ============================================= */

/* Notice principale des points de récompense */
#yith-par-message-reward-cart.woocommerce-info {
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%) !important;
  border: none !important;
  border-radius: 16px !important;
  padding: 24px 28px !important;
  margin: 20px 0 !important;
  box-shadow: 0 10px 30px rgba(102, 126, 234, 0.25) !important;
  color: #ffffff !important;
  position: relative;
  overflow: hidden;
}

#yith-par-message-reward-cart.woocommerce-info::before {
  content: '🎁';
  position: absolute;
  top: -20px;
  right: -20px;
  font-size: 120px;
  opacity: 0.1;
  line-height: 1;
}

#yith-par-message-reward-cart.woocommerce-info::after {
  display: none !important;
}

/* Texte dans la notice */
#yith-par-message-reward-cart strong {
  color: #ffd700 !important;
  font-weight: 700 !important;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.2);
}

/* Formulaire */
#yith-par-message-reward-cart .ywpar_apply_discounts {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 16px;
}

/* Wrapper du champ de saisie */
#yith-par-message-reward-cart .ywpar_apply_discounts > span:first-of-type {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

/* Champ de saisie des points */
#yith-par-message-reward-cart input[name="ywpar_input_points"] {
  background: rgba(255, 255, 255, 0.95) !important;
  border: 2px solid rgba(255, 255, 255, 0.3) !important;
  border-radius: 10px !important;
  padding: 10px 16px !important;
  font-size: 16px !important;
  font-weight: 600 !important;
  color: #667eea !important;
  width: 120px !important;
  text-align: center !important;
  transition: all 0.3s ease !important;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1) !important;
}

#yith-par-message-reward-cart input[name="ywpar_input_points"]:focus {
  outline: none !important;
  border-color: #ffd700 !important;
  background: #ffffff !important;
  transform: scale(1.05) !important;
  box-shadow: 0 6px 20px rgba(255, 215, 0, 0.3) !important;
}

/* Bouton d'application */
#yith-par-message-reward-cart button.ywpar_apply_discounts {
  background: linear-gradient(135deg, #ffd700 0%, #ffed4e 100%) !important;
  border: none !important;
  border-radius: 10px !important;
  padding: 12px 28px !important;
  font-size: 15px !important;
  font-weight: 700 !important;
  color: #667eea !important;
  cursor: pointer !important;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1) !important;
  box-shadow: 0 4px 15px rgba(255, 215, 0, 0.4) !important;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  position: relative;
  overflow: hidden;
}

#yith-par-message-reward-cart button.ywpar_apply_discounts::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.4), transparent);
  transition: left 0.5s;
}

#yith-par-message-reward-cart button.ywpar_apply_discounts:hover {
  transform: translateY(-2px) !important;
  box-shadow: 0 8px 25px rgba(255, 215, 0, 0.6) !important;
}

#yith-par-message-reward-cart button.ywpar_apply_discounts:hover::before {
  left: 100%;
}

#yith-par-message-reward-cart button.ywpar_apply_discounts:active {
  transform: translateY(0) !important;
  box-shadow: 0 2px 10px rgba(255, 215, 0, 0.4) !important;
}

/* Montant de la remise */
#yith-par-message-reward-cart .woocommerce-Price-amount {
  color: #ffd700 !important;
  font-weight: 700 !important;
  font-size: 18px !important;
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

/* Message d'erreur */
#yith-par-message-reward-cart .ywpar_min_reedem_value_error {
  background: rgba(255, 255, 255, 0.2);
  border-left: 4px solid #ff6b6b;
  padding: 12px 16px;
  border-radius: 8px;
  margin-top: 12px;
  color: #ffffff;
  font-weight: 500;
}

/* Clear fix */
#yith-par-message-reward-cart .clear {
  clear: both;
}

/* Responsive Design */
@media (max-width: 768px) {
  #yith-par-message-reward-cart.woocommerce-info {
    padding: 20px 16px !important;
    border-radius: 12px !important;
  }

  #yith-par-message-reward-cart .ywpar_apply_discounts {
    flex-direction: column;
    align-items: stretch;
    gap: 12px;
  }

  #yith-par-message-reward-cart input[name="ywpar_input_points"] {
    width: 100% !important;
    max-width: 200px;
    margin: 0 auto;
  }

  #yith-par-message-reward-cart button.ywpar_apply_discounts {
    width: 100%;
    max-width: 300px;
    margin: 0 auto;
  }

  #yith-par-message-reward-cart.woocommerce-info::before {
    font-size: 80px;
    top: -10px;
    right: -10px;
  }
}

@media (max-width: 480px) {
  #yith-par-message-reward-cart.woocommerce-info {
    font-size: 14px !important;
    padding: 16px 12px !important;
  }

  #yith-par-message-reward-cart .woocommerce-Price-amount {
    font-size: 16px !important;
  }

  #yith-par-message-reward-cart input[name="ywpar_input_points"],
  #yith-par-message-reward-cart button.ywpar_apply_discounts {
    font-size: 14px !important;
    padding: 10px 16px !important;
  }
}

/* Animation d'apparition */
@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

#yith-par-message-reward-cart.woocommerce-info {
  animation: fadeInUp 0.5s ease-out;
}
