/* ═══════════════════════════════════════════════════
   etudes.css — Rubrique Études & Projets
   Julien RIFFARD · Géomaticien
═══════════════════════════════════════════════════ */

/* ── Page hero (standard portfolio) ─────────────── */
.page-hero {
  padding: 9rem 3rem 4rem;
  max-width: 1160px;
  margin: 0 auto;
}
@media (max-width: 900px) { .page-hero { padding: 7rem 1.5rem 3rem; } }
@media (max-width: 600px) { .page-hero { padding: 6rem 1.25rem 2.5rem; } }

/* ── Accent local (teal eau) ─────────────────────── */
:root {
  --eau:     #06b6d4;
  --eau-bg:  rgba(6,182,212,0.08);
  --eau-bd:  rgba(6,182,212,0.22);
}

/* ══════════════════════════════════════════════════
   PAGE LISTE (etudes.html)
══════════════════════════════════════════════════ */

/* ── Hero ──────────────────────────────────────── */
.et-hero {
  padding: 120px 3rem 3rem;
  max-width: 900px;
  margin: 0 auto;
}
.et-hero h1 {
  margin: 1rem 0 0.75rem;
  background: linear-gradient(135deg, var(--text) 0%, var(--eau) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}
.et-hero p {
  color: var(--dim);
  font-size: 1rem;
  max-width: 620px;
  line-height: 1.75;
}

/* ── Grille d'études ────────────────────────────── */
.et-grid {
  max-width: 1100px;
  margin: 3rem auto 5rem;
  padding: 0 3rem;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 1.5rem;
}

.et-card {
  background: var(--surf);
  border: 1px solid var(--border);
  border-radius: var(--r-lg);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: border-color var(--t), transform var(--t), box-shadow var(--t);
  cursor: pointer;
  text-decoration: none;
  color: inherit;
}
.et-card:hover {
  border-color: var(--eau-bd);
  transform: translateY(-3px);
  box-shadow: 0 12px 32px rgba(6,182,212,0.12);
}

.et-card-thumb {
  width: 100%;
  aspect-ratio: 16/9;
  object-fit: cover;
  display: block;
  transition: transform 0.4s ease;
}
.et-card:hover .et-card-thumb { transform: scale(1.03); }

.et-card-thumb-wrap {
  overflow: hidden;
  background: var(--surf2);
}

.et-card-body {
  padding: 1.25rem 1.4rem 1.4rem;
  display: flex;
  flex-direction: column;
  gap: 0.55rem;
  flex: 1;
}

.et-card-meta {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--eau);
}
.et-card-meta span {
  color: var(--muted);
  font-weight: 400;
  text-transform: none;
  letter-spacing: 0;
}

.et-card h3 {
  font-size: 1rem;
  font-weight: 600;
  color: var(--text);
  line-height: 1.4;
}

.et-card p {
  font-size: 0.84rem;
  color: var(--dim);
  line-height: 1.65;
  flex: 1;
}

.et-card-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: 0.5rem;
}

.et-card-arrow {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--eau);
  transition: gap var(--t);
}
.et-card:hover .et-card-arrow { gap: 0.7rem; }

/* ══════════════════════════════════════════════════
   PAGE DÉTAIL (etudes/nom-projet.html)
══════════════════════════════════════════════════ */

/* ── Hero détail ────────────────────────────────── */
.ed-hero {
  padding: 110px 3rem 3.5rem;
  max-width: 900px;
  margin: 0 auto;
}

.ed-hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--eau);
  background: var(--eau-bg);
  border: 1px solid var(--eau-bd);
  padding: 5px 14px;
  border-radius: 20px;
  margin-bottom: 1.2rem;
}
.ed-hero-badge span {
  width: 6px; height: 6px;
  border-radius: 50%;
  background: var(--eau);
}

.ed-hero h1 {
  font-size: clamp(1.9rem, 4vw, 3rem);
  margin: 0.8rem 0 1rem;
  background: linear-gradient(135deg, var(--text) 0%, var(--eau) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.ed-hero p {
  font-size: 1rem;
  color: var(--dim);
  max-width: 640px;
  line-height: 1.75;
}

/* ── Chiffres clés ──────────────────────────────── */
.ed-kpi-row {
  max-width: 900px;
  margin: 0 auto 0;
  padding: 0 3rem 3rem;
  display: flex;
  gap: 1.2rem;
  flex-wrap: wrap;
}

.ed-kpi {
  flex: 1;
  min-width: 130px;
  background: var(--surf);
  border: 1px solid var(--border);
  border-radius: var(--r);
  padding: 1.1rem 1.3rem;
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.ed-kpi-value {
  font-family: var(--font-h);
  font-size: 1.6rem;
  font-weight: 700;
  color: var(--eau);
}

.ed-kpi-label {
  font-size: 0.75rem;
  color: var(--dim);
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

/* ── Sections ────────────────────────────────────── */
.ed-section {
  max-width: 900px;
  margin: 0 auto;
  padding: 3rem 3rem;
  border-top: 1px solid var(--border);
}

.ed-section h2 {
  font-size: 1.4rem;
  font-weight: 600;
  margin-bottom: 1.4rem;
  color: var(--text);
}

.ed-section p {
  font-size: 0.93rem;
  color: var(--dim);
  line-height: 1.75;
  max-width: 680px;
}

/* ── Étapes méthodo ─────────────────────────────── */
.ed-steps {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  margin-top: 1.4rem;
}

.ed-step {
  display: flex;
  gap: 1.2rem;
  align-items: flex-start;
  background: var(--surf);
  border: 1px solid var(--border);
  border-radius: var(--r);
  padding: 1.1rem 1.4rem;
}

.ed-step-num {
  flex-shrink: 0;
  width: 32px; height: 32px;
  border-radius: 50%;
  background: var(--eau-bg);
  border: 1px solid var(--eau-bd);
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-h);
  font-size: 0.72rem;
  font-weight: 700;
  color: var(--eau);
}

.ed-step-body h4 {
  font-size: 0.93rem;
  font-weight: 600;
  color: var(--text);
  margin-bottom: 0.3rem;
}

.ed-step-body p {
  font-size: 0.83rem;
  color: var(--dim);
  line-height: 1.6;
}

/* ── Tableau résultats ──────────────────────────── */
.ed-table-wrap {
  overflow-x: auto;
  margin-top: 1.4rem;
  border-radius: var(--r);
  border: 1px solid var(--border);
}

.ed-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.83rem;
}

.ed-table th {
  background: var(--surf2);
  color: var(--dim);
  font-weight: 600;
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  padding: 0.65rem 1rem;
  text-align: left;
  border-bottom: 1px solid var(--border);
  white-space: nowrap;
}

.ed-table td {
  padding: 0.6rem 1rem;
  border-bottom: 1px solid var(--border);
  color: var(--dim);
}
.ed-table tr:last-child td { border-bottom: none; }
.ed-table tr:hover td { background: var(--surf2); }

.ed-table td.val {
  font-family: var(--font-h);
  font-weight: 600;
  color: var(--text);
  text-align: right;
}
.ed-table th.r, .ed-table td.r { text-align: right; }

.ed-table .tr-period td:first-child {
  font-weight: 700;
  color: var(--eau);
}

/* ── Galerie cartes ─────────────────────────────── */
.ed-gallery {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 1rem;
  margin-top: 1.4rem;
}

.ed-map-card {
  background: var(--surf);
  border: 1px solid var(--border);
  border-radius: var(--r);
  overflow: hidden;
  cursor: zoom-in;
  transition: border-color var(--t), transform var(--t);
}
.ed-map-card:hover {
  border-color: var(--eau-bd);
  transform: translateY(-2px);
}

.ed-map-card img {
  width: 100%;
  aspect-ratio: 4/3;
  object-fit: cover;
  display: block;
  transition: transform 0.3s ease;
}
.ed-map-card:hover img { transform: scale(1.03); }

.ed-map-label {
  padding: 0.55rem 0.85rem;
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--dim);
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

/* ── CTA / PDF ───────────────────────────────────── */
.ed-cta {
  max-width: 900px;
  margin: 0 auto 5rem;
  padding: 2.5rem 3rem;
  background: var(--surf);
  border: 1px solid var(--border);
  border-radius: var(--r-lg);
  border-top: 3px solid var(--eau);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 2rem;
  flex-wrap: wrap;
}

.ed-cta-text h3 { font-size: 1.1rem; margin-bottom: 0.35rem; }
.ed-cta-text p { font-size: 0.87rem; color: var(--dim); }

.btn-eau {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  background: var(--eau);
  color: #020c18;
  font-weight: 700;
  font-size: 0.85rem;
  padding: 0.65rem 1.4rem;
  border-radius: 8px;
  transition: opacity var(--t), transform var(--t);
  white-space: nowrap;
}
.btn-eau:hover { opacity: 0.88; transform: translateY(-1px); }

/* ── Lightbox (réutilise realisations mais repaint) ─ */
.ed-lb-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(2,12,24,0.94);
  z-index: 900;
  align-items: center;
  justify-content: center;
}
.ed-lb-overlay.open { display: flex; }

.ed-lb-wrap {
  position: relative;
  max-width: 92vw;
  max-height: 88vh;
  overflow: hidden;
  cursor: zoom-in;
  user-select: none;
}
.ed-lb-wrap.panned { cursor: grab; }
.ed-lb-wrap.dragging { cursor: grabbing !important; }

.ed-lb-wrap img {
  max-width: 90vw;
  max-height: 84vh;
  display: block;
  transform-origin: center center;
  pointer-events: none;
}

.ed-lb-close {
  position: fixed;
  top: 1rem; right: 1.2rem;
  background: rgba(255,255,255,0.08);
  border: none;
  color: var(--text);
  font-size: 1.4rem;
  width: 36px; height: 36px;
  border-radius: 50%;
  cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  transition: background var(--t);
}
.ed-lb-close:hover { background: rgba(255,255,255,0.15); }

/* toolbar bas */
.ed-lb-toolbar {
  position: absolute;
  bottom: 0; left: 0; right: 0;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0.55rem 1rem;
  background: rgba(2,12,24,0.55);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
}

.ed-lb-nav { display: flex; align-items: center; gap: 0.4rem; }
.ed-lb-zoom { display: flex; align-items: center; gap: 0.4rem; }

.ed-lb-btn {
  background: rgba(255,255,255,0.08);
  border: 1px solid rgba(255,255,255,0.10);
  color: var(--text);
  font-size: 0.8rem;
  padding: 0.28rem 0.6rem;
  border-radius: 5px;
  cursor: pointer;
  transition: background var(--t);
  display: flex; align-items: center; gap: 0.25rem;
}
.ed-lb-btn:hover { background: rgba(255,255,255,0.15); }

.ed-lb-counter {
  font-size: 0.75rem;
  color: var(--dim);
  min-width: 40px;
  text-align: center;
}

/* ── Tag eau ─────────────────────────────────────── */
.pf-tag.eau { background: var(--eau-bg); border-color: var(--eau-bd); color: var(--eau); }

/* ── Responsive ─────────────────────────────────── */
@media (max-width: 680px) {
  .et-hero, .ed-hero, .ed-kpi-row, .ed-section { padding-left: 1.25rem; padding-right: 1.25rem; }
  .et-grid { padding: 0 1.25rem; }
  .ed-kpi-row { gap: 0.75rem; }
  .ed-gallery { grid-template-columns: repeat(2, 1fr); gap: 0.6rem; }
  .ed-cta { flex-direction: column; align-items: flex-start; padding: 1.5rem 1.25rem; }
  .ed-lb-toolbar { display: none; }
  .ed-lb-close { top: 0.5rem; right: 0.75rem; }
}
