/*
Theme Name: Mes Ephémères
Theme URI: https://mesephemeressite.vercel.app/
Author: Vivien Faivre
Description: Thème WordPress sur-mesure pour Mes Ephémères.
Version: 1.0
Text Domain: mes-ephemeres
*/

@import url('https://fonts.googleapis.com/css2?family=Cormorant+Garamond:ital,wght@0,300;0,400;0,600;1,400&family=Outfit:wght@300;400;500&display=swap');

:root {
  --color-sand: #F5F2EB;
  --color-sage: #AAB7A2;
  --color-espresso: #2B2A27;
  --color-blush: #E6D5CE;
  --color-white: #FFFFFF;
  
  --font-serif: 'Cormorant Garamond', serif;
  --font-sans: 'Outfit', sans-serif;
  
  --spacing-sm: 1rem;
  --spacing-md: 2rem;
  --spacing-lg: 4rem;
  --spacing-xl: 8rem;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  background-color: var(--color-sand);
  color: var(--color-espresso);
  font-family: var(--font-sans);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4, .serif {
  font-family: var(--font-serif);
  font-weight: 400;
}

h1 { font-size: clamp(3rem, 8vw, 6rem); line-height: 1; }
h2 { font-size: clamp(2rem, 5vw, 4rem); margin-bottom: var(--spacing-md); }
h3 { font-size: clamp(1.5rem, 3vw, 2.5rem); }

a {
  color: inherit;
  text-decoration: none;
  transition: opacity 0.3s ease;
}

a:hover {
  opacity: 0.7;
}

/* Animations */
.fade-in {
  opacity: 0;
  transform: translateY(20px);
  animation: fadeIn 1s ease forwards;
}

@keyframes fadeIn {
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Specific Section Styles */
.hero {
  height: 100vh;
  width: 100%;
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  color: var(--color-white);
  overflow: hidden;
}

.hero-bg {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: -2;
  filter: brightness(0.6); /* Sombre pour lire le texte blanc */
}

.hero-content {
  z-index: 1;
  padding: var(--spacing-md);
}

.hero-subtitle {
  font-size: 1.2rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  margin-top: 1rem;
}

.section {
  padding: var(--spacing-xl) 5%;
  max-width: 1400px;
  margin: 0 auto;
}

/* About */
.about-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--spacing-lg);
  align-items: center;
}

.about-img {
  width: 100%;
  height: 600px;
  object-fit: cover;
  border-radius: 4px;
}

/* Portfolio Masonry */
.portfolio-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 20px;
}

.portfolio-item {
  width: 100%;
  height: 400px;
  border-radius: 4px;
  overflow: hidden;
  transition: transform 0.5s ease;
}

.portfolio-item:hover {
  transform: scale(1.02);
}

.portfolio-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

/* Navigation */
.navbar {
  position: fixed;
  top: 0;
  width: 100%;
  padding: 1.5rem 5%;
  display: flex;
  justify-content: space-between;
  align-items: center;
  z-index: 100;
  transition: background 0.3s ease, padding 0.3s ease;
  color: var(--color-white);
}

.navbar.scrolled {
  background: var(--color-sand);
  color: var(--color-espresso);
  padding: 1rem 5%;
  box-shadow: 0 2px 20px rgba(0,0,0,0.05);
}

.nav-links {
  display: flex;
  gap: 2rem;
  font-size: 0.9rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

/* Footer */
footer {
  background: var(--color-espresso);
  color: var(--color-sand);
  padding: var(--spacing-lg) 5%;
  text-align: center;
}

@media (max-width: 768px) {
  .about-grid { grid-template-columns: 1fr; }
  .nav-links { display: none; }
  h1 { font-size: 3.5rem; }
  .section { padding: var(--spacing-lg) 5%; }
}

/* Fix pour la barre d'administration WordPress (admin bar) */
body.admin-bar .navbar {
  top: 32px;
}
@media screen and (max-width: 782px) {
  body.admin-bar .navbar {
    top: 46px;
  }
}
