/* Enhanced styling for sections */

/* Sections backgrounds with better rhythm */
.tm-section-wrap:nth-child(1) {
  background: linear-gradient(135deg, rgba(0, 102, 204, 0.02) 0%, rgba(0, 82, 163, 0.02) 100%);
}

.tm-section-wrap:nth-child(2) {
  background: #ffffff;
  border-top: 1px solid #e8e8e8;
}

.tm-section-wrap:nth-child(3) {
  background: linear-gradient(135deg, rgba(0, 102, 204, 0.03) 0%, rgba(0, 82, 163, 0.03) 100%);
  border-top: 1px solid #e8e8e8;
}

.tm-section-wrap:nth-child(4) {
  background: #ffffff;
  border-top: 1px solid #e8e8e8;
}

.tm-section-wrap:nth-child(5) {
  background: linear-gradient(135deg, rgba(0, 102, 204, 0.02) 0%, rgba(0, 82, 163, 0.02) 100%);
  border-top: 1px solid #e8e8e8;
}

.bg-white {
  background: white !important;
  border-top: 1px solid #e8e8e8;
}

/* Improved intro section */
#intro {
  background: linear-gradient(135deg, rgba(0, 0, 0, 0.4) 0%, rgba(0, 0, 0, 0.3) 100%), 
              url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 1200 600"><defs><linearGradient id="grad" x1="0%" y1="0%" x2="100%" y2="100%"><stop offset="0%" style="stop-color:rgb(0,102,204);stop-opacity:0.1" /><stop offset="100%" style="stop-color:rgb(0,82,163);stop-opacity:0.1" /></linearGradient></defs><rect fill="url(%23grad)" width="1200" height="600"/></svg>') center/cover;
  background-attachment: fixed;
}

/* Enhanced link styling */
.tm-section-half a {
  color: #0066cc;
  font-weight: 500;
  border-bottom: 2px solid transparent;
  transition: all 0.3s ease;
  padding-bottom: 2px;
}

.tm-section-half a:hover {
  color: #0052a3;
  border-bottom-color: #0066cc;
}

/* Add subtle animations for headings */
@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.tm-section-title {
  animation: fadeInUp 0.6s ease-out;
}

.tm-section-half {
  animation: fadeInUp 0.6s ease-out;
  animation-fill-mode: both;
}

.tm-section-half:nth-child(1) { animation-delay: 0.1s; }
.tm-section-half:nth-child(2) { animation-delay: 0.2s; }
.tm-section-half:nth-child(3) { animation-delay: 0.3s; }

/* Add smooth transitions to images */
.tm-client-img {
  transition: transform 0.35s cubic-bezier(0.4, 0, 0.2, 1), filter 0.35s ease;
}

.tm-img-wrap:hover .tm-client-img {
  transform: scale(1.05);
}

/* Enhanced input and button styling */
input.form-control, textarea.form-control {
  font-size: 1rem;
  letter-spacing: 0.3px;
  padding: 15px 0 15px 0;
}

input.form-control::placeholder, textarea.form-control::placeholder {
  color: #c0c0c0;
  font-weight: 300;
}

/* Improved form group spacing */
.form-group {
  margin-bottom: 25px;
}

.form-group:last-child {
  margin-bottom: 0;
}

/* Better typography */
h2 {
  letter-spacing: -0.5px;
}

p {
  letter-spacing: 0.2px;
}

/* Smooth scroll behavior */
html {
  scroll-behavior: smooth;
}

/* Add subtle box-shadow to sections */
.tm-section:not(#intro) {
  transition: box-shadow 0.35s ease;
}

.tm-section:not(#intro):hover {
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
}

/* Improved focus states for accessibility */
.form-control:focus,
.nav-link:focus,
.tm-social-link:focus {
  outline: 2px solid #0066cc;
  outline-offset: 2px;
}

/* Gradient text for headings */
#about .tm-section-title,
#work .tm-section-title,
#clients .tm-section-title,
#talk .tm-section-title {
  background: linear-gradient(135deg, #0066cc 0%, #0052a3 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* Better spacing for sections */
@media (min-width: 1201px) {
  .tm-section {
    padding: 100px 80px;
  }

  .tm-box-pad {
    padding: 80px 100px;
  }
}

/* Add decorative lines under titles */
.tm-section-title::after {
  content: '';
  display: block;
  width: 60px;
  height: 4px;
  background: linear-gradient(90deg, #0066cc, #0052a3);
  margin-top: 15px;
  border-radius: 2px;
  animation: slideInLeft 0.6s ease-out;
}

@keyframes slideInLeft {
  from {
    opacity: 0;
    width: 0;
  }
  to {
    opacity: 1;
    width: 60px;
  }
}

/* Enhance footer styling */
.tm-sidebar-sticky footer {
  padding-top: 30px;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.tm-sidebar-sticky footer p {
  letter-spacing: 0.3px;
}

/* Smooth transitions for all interactive elements */
button, a, input, textarea, select {
  transition: all 0.35s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Add hover effect to rows */
.row:hover .tm-section-half {
  transition: all 0.35s ease;
}

/* IA Projects Cards Styling */
.tm-project-card {
  background: linear-gradient(135deg, rgba(0, 102, 204, 0.05) 0%, rgba(0, 82, 163, 0.05) 100%);
  padding: 30px;
  border-radius: 8px;
  border: 2px solid rgba(0, 102, 204, 0.2);
  transition: all 0.35s cubic-bezier(0.4, 0, 0.2, 1);
  height: 100%;
  display: flex;
  flex-direction: column;
}

.tm-project-card:hover {
  transform: translateY(-10px);
  box-shadow: 0 15px 40px rgba(0, 102, 204, 0.2);
  border-color: rgba(0, 102, 204, 0.5);
  background: linear-gradient(135deg, rgba(0, 102, 204, 0.1) 0%, rgba(0, 82, 163, 0.1) 100%);
}

.tm-project-card h3 {
  font-size: 1.3rem;
  margin-bottom: 15px;
  font-weight: 700;
}

.tm-project-card p {
  color: #555;
  font-size: 0.95rem;
  line-height: 1.6;
}

.tm-project-card p strong {
  color: #0066cc;
  font-weight: 600;
}

.tm-project-link {
  display: inline-block;
  color: #0066cc;
  text-decoration: none;
  font-weight: 600;
  margin-top: auto;
  padding-top: 15px;
  border-top: 2px solid rgba(0, 102, 204, 0.2);
  transition: all 0.35s ease;
}

.tm-project-link:hover {
  color: #0052a3;
  border-top-color: #0066cc;
  padding-top: 20px;
}

/* Align "Travaux en Cours", "Projets 100% IA" and "talk" padding with other sections */
#work .tm-box-pad,
#ia-projects .tm-box-pad,
#talk .tm-box-pad {
  padding: 40px 30px;
}

/* Work Cards Styling */
.tm-work-card {
  background: white;
  border-radius: 8px;
  border: 1px solid #e0e0e0;
  overflow: hidden;
  transition: all 0.35s cubic-bezier(0.4, 0, 0.2, 1);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
  display: flex;
  flex-direction: column;
}

.tm-work-card:hover {
  transform: translateY(-12px);
  box-shadow: 0 20px 50px rgba(0, 102, 204, 0.25);
  border-color: rgba(0, 102, 204, 0.3);
}

.tm-work-image {
  height: 250px;
  overflow: hidden;
  background: #f5f5f5;
}

.tm-work-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.35s ease;
}

.tm-work-card:hover .tm-work-image img {
  transform: scale(1.05);
}

.tm-work-content {
  padding: 30px 25px;
  flex-grow: 1;
  display: flex;
  flex-direction: column;
}

.tm-work-content h3 {
  font-size: 1.25rem;
  font-weight: 700;
  margin-bottom: 15px;
}

.tm-work-content p {
  margin-bottom: 12px;
  color: #555;
  font-size: 0.9rem;
  line-height: 1.6;
}

.tm-work-content .tm-project-link {
  margin-top: auto;
  padding-top: 15px;
}
