* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto,
    "Helvetica Neue", Arial, sans-serif;
  background: #fdfcfbff;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow-x: hidden;
  position: relative;
}

.background-pattern {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-image: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" width="103" height="103" viewBox="0 0 103 103"><defs><g id="cee-logo"><path d="M51.5 8.583333333333334 C 72.92399999999999 8.583333333333334, 94.45100000000001 30.075999999999997, 94.45100000000001 51.5 C 94.45100000000001 72.92399999999999, 72.92399999999999 94.45100000000001, 51.5 94.45100000000001 C 30.075999999999997 94.45100000000001, 8.583333333333334 72.92399999999999, 8.583333333333334 51.5 C 8.583333333333334 30.075999999999997, 30.075999999999997 8.583333333333334, 51.5 8.583333333333334 Z" fill="%23ffffff" stroke="%23cccfc9" stroke-width="2" opacity="0.15"/><circle cx="51.5" cy="51.5" r="30.075999999999997" fill="%23ffffff" stroke="%23333" stroke-width="2" stroke-dasharray="2,2" opacity="0.15"/><text x="51.5" y="60.049" font-family="Arial, sans-serif" font-size="17.166666666666668" font-weight="bold" text-anchor="middle" fill="%23c2c2c2" opacity="0.22499999999999998">CEE</text></g></defs><use href="%23cee-logo" x="0" y="0"/></svg>');
  background-repeat: repeat;

  z-index: -1;
}

.container {
  max-width: 1200px;
  width: 100%;
  padding: 10px 0 0 0;
  text-align: center;
}

.logo-section {
  position: relative;
}

.header {
  margin-bottom: 0px;
  animation: slideInDown 0.8s ease-out;
}

.tagline {
  font-size: 25px;
  margin-top: 15px;
  margin-left: 10px;
  margin-right: 10px;
  background: #0e3064;
  border-radius: 10px;
  color: white;
  text-transform: uppercase;
  font-weight: bold;
  padding: 10px;
  letter-spacing: 3px;
}

.choose {
  font-size: 40px;
  margin-top: 40px;
  margin-left: 67px;
  font-weight: normal;
  margin-bottom: 50px;
  color: #e26818;
  letter-spacing: 5px;
}

.logo-ted {
  background: white;
  border-radius: 38px;
  box-shadow: 2px 2px #052a5f87;
  height: 90px;
  float: left;
  margin-top: -22px;
  margin-left: 27px;
  border: 1px solid #0e3064;
}

.logo-edf {
  width: 113px;
  left: 24px;
  top: 87px;
  position: absolute;
}

.selector-container {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 1.5rem;
  margin: 10px;
  animation: slideInUp 0.8s ease-out 0.3s both;
}

.category-wrapper {
  background: linear-gradient(135deg, #012a68 0%, #4a90e2 50%, #002c67 100%);
  border-radius: 25px;
  padding: 10px;
  transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  position: relative;
  overflow: hidden;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
}

.category-wrapper::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 4px;
  background: linear-gradient(90deg, #e26818, #e26818);
  transform: scaleX(0);
  transition: transform 0.4s ease;
}

.category-wrapper:hover::before {
  transform: scaleX(1);
}

.category-wrapper:hover {
  background: linear-gradient(135deg, #2d5aa0 0%, #1e4788 100%);
  transform: translateY(-10px);
  box-shadow: 0 25px 50px rgba(0, 0, 0, 0.2);
}

.category-section {
  background: transparent;
}

.category-title {
  color: white;
  font-weight: 700;
  margin-bottom: 38px;
  font-size: 28px;
  text-transform: uppercase;
  letter-spacing: 4px;
  text-align: center;
  position: relative;
}

.category-title::after {
  content: "";
  position: absolute;
  bottom: -8px;
  left: 50%;
  transform: translateX(-50%);
  width: 60px;
  height: 3px;
  background: #e26818;
  border-radius: 2px;
}

.region-grid {
  display: grid;
  gap: 1.5rem;
}

.region-tile {
  background: linear-gradient(
    135deg,
    rgba(255, 255, 255, 0.1),
    rgba(255, 255, 255, 0.05)
  );
  border: 2px solid rgba(255, 255, 255, 1);
  border-radius: 20px;
  cursor: pointer;
  transition: all 0.5s cubic-bezier(0.4, 0, 0.2, 1);
  position: relative;
  overflow: hidden;
  text-decoration: none;
  display: block;
  height: 500px;
  background-size: cover;
  background-repeat: no-repeat;
  background-position: center;
  transform-style: preserve-3d;
  perspective: 1000px;
}

@media (max-width: 768px) {
    .region-tile {
        height: 400px;
    }
}

/* Effet de brillance qui traverse */
.region-tile::before {
  content: "";
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(
    90deg,
    transparent 30%,
    rgba(255, 255, 255, 0.2) 50%,
    transparent 70%
  );
  transition: all 0.6s ease;
  z-index: 3;
}

/* Overlay coloré */
.region-tile::after {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(
    135deg,
    rgba(226, 104, 24, 0) 0%,
    rgba(226, 104, 24, 0.1) 50%,
    rgba(226, 104, 24, 0.2) 100%
  );
  opacity: 0;
  transition: all 0.5s ease;
  z-index: 1;
}

.region-tile:hover::before {
  left: 100%;
}

.region-tile:hover::after {
  opacity: 1;
}

.region-tile:hover {
  transform: translateY(-10px) scale(1.02);
  border-color: #e26818;
  box-shadow: 0 20px 40px rgba(226, 104, 24, 0.3),
    0 0 20px rgba(226, 104, 24, 0.2);
}

/* Animation pulsante pour les bordures */
.region-tile:hover {
  animation: pulse-border 2s infinite;
}

@keyframes pulse-border {
  0%,
  100% {
    border-color: #e26818;
  }
  50% {
    border-color: rgba(226, 104, 24, 0.5);
  }
}

.region-header {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 1rem;
  background: rgba(255, 255, 255, 0.95);
  margin: 0;
  padding: 12px;
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  z-index: 2;
  transition: all 0.3s ease;
  transform: translateY(0);
  overflow: hidden;
  border-radius: 20px 20px 0 0;
}

.region-tile:hover .region-header {
  background: rgba(226, 104, 24, 0.95);
  transform: translateY(-5px);
}

.region-name {
  color: #012a68;
  font-size: 20px;
  font-weight: 700;
  text-align: center;
  text-transform: uppercase;
  letter-spacing: 3px;
  transition: all 0.3s ease;
}

.region-tile:hover .region-name {
  color: white;
  transform: scale(1.05);
}

.cta-text {
  color: #e26818;
  font-size: 18px;
  font-weight: 600;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  opacity: 0;
  transform: translateY(30px);
  transition: all 0.5s cubic-bezier(0.68, -0.55, 0.265, 1.55);
  background: rgba(255, 255, 255, 0.95);
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  padding: 15px;
  z-index: 2;
  overflow: hidden;
  border-radius: 0 0 20px 20px;
}

.region-tile:hover .cta-text {
  opacity: 1;
  transform: translateY(0) scale(1.02);
  background: rgba(226, 104, 24, 0.95);
  color: white;
}

.cta-text::after {
  content: "→";
  transition: transform 0.3s ease;
  display: inline-block;
}

.region-tile:hover .cta-text::after {
  transform: translateX(10px) scale(1.2);
  animation: bounce-arrow 1s infinite;
}

@keyframes bounce-arrow {
  0%,
  100% {
    transform: translateX(10px) scale(1.2);
  }
  50% {
    transform: translateX(15px) scale(1.2);
  }
}

/* Images avec effet de zoom */
.pro .region-tile.paca {
  background-image: url(./Assets/pro-paca.png);
}

.pro .region-tile.idf {
  background-image: url(./Assets/pro-idf.png);
}

.particulier .region-tile.paca {
  background-image: url(./Assets/particulier-paca.png);
}

.particulier .region-tile.idf {
  background-image: url(./Assets/particulier-idf.png);
}

.tertiaire .region-tile.paca {
  background-image: url(./Assets/tertiaire-paca.png);
}

.tertiaire .region-tile.idf {
  background-image: url(./Assets/tertiaire-idf.png);
}

.region-tile:hover {
  background-size: 400%;
}

/* Effet de particules au survol */
.region-tile:hover {
  position: relative;
}

.region-tile:hover::before {
  animation: shimmer 1.5s infinite;
}

/* Suppression de l'animation shimmer problématique */
@keyframes shimmer {
  0% {
    left: -100%;
  }
  100% {
    left: 100%;
  }
}

.sub-footer {
  color: #333;
  margin-top: 28px;
}

.sub-footer a {
  color: #333;
}

@keyframes slideInDown {
  from {
    opacity: 0;
    transform: translateY(-50px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes slideInUp {
  from {
    opacity: 0;
    transform: translateY(50px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@media (max-width: 768px) {
  .container {
    padding: 1rem;
  }

  .selector-container {
    grid-template-columns: 1fr;
    gap: 2rem;
  }

  .category-title {
    font-size: 1.8rem;
  }

  .region-tile:hover {
    transform: translateY(-10px) scale(1.02);
  }
}

@media (max-width: 1200px) {
  .container {
    max-width: 1200px;
    width: 100%;
    padding: 10px 2rem 2rem 2rem;
    text-align: center;
  }

  .logo-ted {
    background: white;
    border-radius: 38px;
    box-shadow: 2px 2px #052a5f87;
    height: 90px;
    margin-left: 60px;
    margin-top: 0;
    border: 1px solid #0e3064;
    float: none;
  }

  .logo-edf {
    margin-left: 10px !important;
    width: 60px;
    position: relative;
    margin: 0;
    left: 0;
    top: 0;
  }

  .choose {
    font-size: 40px;
    margin-top: 15px;
    font-weight: normal;
    margin-bottom: 30px;
    color: #e26818;
    letter-spacing: 5px;
    margin-left: 0;
  }
}
