/* ==========================================================================
   TECH4HOSPITAL — Styles responsive
   Mobile < 768px | Tablette 768-1024px | Desktop > 1024px
   ========================================================================== */

/* --- Tablette (768px - 1024px) --- */
@media (max-width: 1024px) {
  .hero h1 {
    font-size: 2.5rem;
  }

  .stats-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .cards-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .advantages-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .workflow-steps {
    grid-template-columns: repeat(2, 1fr);
    gap: 2rem;
  }

  .workflow-steps::before {
    display: none;
  }

  .about-intro {
    grid-template-columns: 1fr;
    text-align: center;
  }

  .about-photo {
    margin: 0 auto;
  }

  .expertise-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .entities-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .projects-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .footer-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

/* --- Mobile (< 768px) --- */
@media (max-width: 768px) {
  html {
    font-size: 15px;
  }

  h1 { font-size: 2rem; }
  h2 { font-size: 1.5rem; }
  h3 { font-size: 1.25rem; }

  .container {
    padding: 0 1rem;
  }

  .section-padding {
    padding: 3rem 0;
  }

  /* Navigation mobile */
  .nav-links {
    position: fixed;
    top: 72px;
    left: 0;
    right: 0;
    background: var(--blanc);
    flex-direction: column;
    padding: 1.5rem;
    gap: 0;
    box-shadow: var(--shadow-lg);
    transform: translateY(-100%);
    opacity: 0;
    pointer-events: none;
    transition: all 0.3s ease;
    z-index: 999;
  }

  .nav-links.open {
    transform: translateY(0);
    opacity: 1;
    pointer-events: all;
  }

  .nav-links a {
    padding: 0.75rem 0;
    width: 100%;
    text-align: center;
    border-bottom: 1px solid var(--gris-border);
  }

  .nav-links a:last-child {
    border-bottom: none;
  }

  .hamburger {
    display: flex;
  }

  .nav-actions .btn {
    display: none;
  }

  /* Hero */
  .hero {
    padding: 7rem 0 4rem;
  }

  .hero h1 {
    font-size: 2rem;
  }

  .hero .hero-subtitle {
    font-size: 1rem;
  }

  .hero-buttons {
    flex-direction: column;
  }

  .hero-buttons .btn {
    width: 100%;
    justify-content: center;
  }

  /* Stats */
  .stats-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 1rem;
  }

  .stat-number {
    font-size: 2rem;
  }

  /* Cartes */
  .cards-grid {
    grid-template-columns: 1fr;
    gap: 1.5rem;
  }

  /* Avantages */
  .advantages-grid {
    grid-template-columns: 1fr;
    gap: 1.5rem;
  }

  /* Clients */
  .clients-logos {
    gap: 1rem;
  }

  .client-logo {
    font-size: 0.75rem;
    padding: 0.5rem 1rem;
  }

  /* Services */
  .paypal-banner {
    flex-direction: column;
    text-align: center;
    padding: 1.25rem;
  }

  .service-block {
    padding: 1.5rem;
  }

  .pricing-table {
    font-size: 0.8rem;
  }

  .pricing-table th,
  .pricing-table td {
    padding: 0.5rem 0.5rem;
  }

  /* Workflow vertical */
  .workflow-steps {
    grid-template-columns: 1fr;
    gap: 1.5rem;
  }

  .workflow-steps::before {
    display: none;
  }

  /* About */
  .about-intro {
    grid-template-columns: 1fr;
    text-align: center;
  }

  .about-photo {
    width: 200px;
    height: 250px;
    margin: 0 auto;
    font-size: 3rem;
  }

  .expertise-grid {
    grid-template-columns: 1fr;
  }

  .entities-grid {
    grid-template-columns: 1fr;
  }

  /* Projets */
  .projects-grid {
    grid-template-columns: 1fr;
  }

  /* Contact */
  .contact-grid {
    grid-template-columns: 1fr;
  }

  .contact-form {
    padding: 1.5rem;
  }

  /* Phone input group mobile */
  .phone-input-group {
    flex-wrap: nowrap;
  }

  .phone-country-select {
    width: 110px;
    flex-shrink: 0;
  }

  /* Footer */
  .footer-grid {
    grid-template-columns: 1fr;
    gap: 2rem;
  }

  .footer-bottom {
    flex-direction: column;
    gap: 0.75rem;
    text-align: center;
  }

  /* Page hero */
  .page-hero {
    padding: 6rem 0 2rem;
  }

  .page-hero h1 {
    font-size: 2rem;
  }

  /* CTA */
  .cta-buttons {
    flex-direction: column;
    align-items: center;
  }

  .cta-buttons .btn {
    width: 100%;
    max-width: 300px;
    justify-content: center;
  }

  /* Tables responsive — scroll horizontal */
  .table-responsive {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
  }

  .table-responsive table {
    min-width: 500px;
  }

  /* Diagramme interactif vertical sur mobile */
  .cycle-phases {
    flex-direction: column;
    align-items: stretch;
    gap: 0.5rem;
  }

  .cycle-phase {
    min-width: unset;
  }

  .cycle-phase::after {
    display: none;
  }

  .cycle-phase-box {
    padding: 0.75rem 1rem;
  }

  .service-details {
    grid-template-columns: 1fr;
  }

  .stats-grid.stats-grid-3 {
    grid-template-columns: 1fr 1fr 1fr;
  }
}

/* --- Très petit écran (< 480px) --- */
@media (max-width: 480px) {
  .stats-grid {
    grid-template-columns: 1fr 1fr;
  }

  .stat-number {
    font-size: 1.75rem;
  }

  .stat-label {
    font-size: 0.8rem;
  }

  .tier-header {
    flex-direction: column;
    align-items: flex-start;
  }

  .profile-band {
    flex-direction: column;
    text-align: center;
  }

  .phone-country-select {
    width: 100px;
    font-size: 0.8rem;
  }
}

/* --- Samsung Galaxy Fold et appareils pliables (< 360px plié) --- */
@media (max-width: 360px) {
  html {
    font-size: 14px;
  }

  .container {
    padding: 0 0.75rem;
  }

  .hero {
    padding: 6rem 0 3rem;
  }

  .hero h1 {
    font-size: 1.6rem;
  }

  .hero .hero-subtitle {
    font-size: 0.9rem;
  }

  .stat-number {
    font-size: 1.5rem;
  }

  .stats-grid.stats-grid-3 {
    grid-template-columns: 1fr;
    gap: 0.75rem;
  }

  .card {
    padding: 1.25rem;
  }

  .section-padding {
    padding: 2rem 0;
  }

  .page-hero {
    padding: 5rem 0 1.5rem;
  }

  .page-hero h1 {
    font-size: 1.6rem;
  }

  .contact-form {
    padding: 1rem;
  }

  .phone-input-group {
    flex-direction: column;
  }

  .phone-country-select {
    width: 100%;
    border-right: 1px solid var(--gris-border);
    border-radius: var(--radius) var(--radius) 0 0;
    border-bottom: none;
  }

  .phone-input-group input[type="tel"] {
    border-radius: 0 0 var(--radius) var(--radius);
  }

  .profile-band-photo {
    width: 60px;
    height: 60px;
  }

  .profile-band-text {
    font-size: 0.9rem;
  }

  .project-image {
    height: 150px;
  }

  .cycle-phase-box {
    padding: 0.5rem 0.5rem;
    font-size: 0.75rem;
  }
}