/*
Theme Name: ESPAS-Sup
Theme URI: https://www.espas-sup.fr
Author: Amen Design
Description: Thème custom ESPAS-Sup — cabinet de psychologie TSA / TND (sans page builder).
Version: 1.7.0
Requires at least: 6.0
Tested up to: 6.7
Requires PHP: 8.0
Text Domain: espas-sup
*/

/* ——— Inner pages ——— */
.entry-page {
  padding: 40px 0 100px;
}

/* Legacy page-hero styles superseded by .page-hero-band in pages.css */

.entry-layout {
  display: grid;
  gap: 40px;
}

.prose,
.entry-content {
  max-width: 72ch;
  font-family: Inter, sans-serif;
  font-size: 1.05rem;
  line-height: 1.75;
  color: var(--ink, #1a1225);
}

.prose h2,
.entry-content h2,
.prose h3,
.entry-content h3 {
  font-family: Sora, sans-serif;
  margin-top: 1.75em;
  margin-bottom: 0.55em;
  line-height: 1.2;
}

.prose p,
.entry-content p {
  margin: 0 0 1em;
}

.prose ul,
.entry-content ul {
  padding-left: 1.2em;
  margin: 0 0 1.2em;
}

.prose img,
.entry-content img,
.page-hero-img img {
  display: block;
  width: 100%;
  max-width: 100%;
  height: auto;
  margin: 1.25rem 0 1.75rem;
  border-radius: 2px;
}

.page-hero-img {
  margin: 0 0 1.5rem;
}

.page-gallery {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 12px;
  margin: 0 0 2rem;
  max-width: 52rem;
}

.page-gallery img {
  margin: 0;
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
}

/* ——— Psychologue (profil à onglets) ——— */
.psy-single {
  font-family: Inter, system-ui, sans-serif;
}

.psy-single .psy-name.display {
  font-family: Sora, sans-serif;
  font-weight: 700;
  letter-spacing: -0.03em;
  max-width: 14ch;
  margin: 8px 0 12px;
  line-height: 1.05;
}

.psy-statut {
  font-family: Inter, sans-serif;
  font-size: 1.05rem;
  color: var(--ink-mute, #4a4560);
  max-width: 36ch;
}

.psy-hero {
  display: grid;
  grid-template-columns: minmax(200px, 260px) 1fr;
  gap: 36px;
  align-items: end;
  margin-bottom: 28px;
  padding: 8px 0 28px;
  border-bottom: 1px solid var(--line, rgba(10, 10, 10, 0.12));
}

.psy-photo {
  position: relative;
  background: var(--paper-warm, #f7f5fc);
  padding: 20px 16px 22px;
  overflow: visible;
}

.psy-photo::after {
  content: "";
  position: absolute;
  inset: auto -8px -8px auto;
  width: 42%;
  height: 42%;
  border-right: 2px solid var(--coral, #b31ddc);
  border-bottom: 2px solid var(--coral, #b31ddc);
  pointer-events: none;
}

.psy-photo img {
  width: 100%;
  height: auto;
  aspect-ratio: auto;
  object-fit: contain;
  object-position: center center;
  border-radius: 2px;
  background: var(--paper-warm, #f7f5fc);
  display: block;
}

.psy-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 14px 18px;
  align-items: center;
  margin-top: 22px;
}

.psy-mail,
.psy-tel {
  font-family: "JetBrains Mono", ui-monospace, monospace;
  font-size: 0.82rem;
  color: var(--ink-mute, #4a4560);
  text-decoration: none;
}

.psy-mail:hover,
.psy-tel:hover {
  color: var(--coral, #b31ddc);
}

.psy-addr {
  flex: 1 1 100%;
  margin: 0;
  font-size: 0.88rem;
  line-height: 1.45;
  color: var(--ink-mute, #4a4560);
}

/* Tabs */
.psy-tabs__nav {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin: 0 0 28px;
  padding: 6px;
  background: var(--paper-warm, #f7f5fc);
  border: 1px solid var(--line-soft, rgba(10, 10, 10, 0.07));
  border-radius: 4px;
  position: sticky;
  top: 12px;
  z-index: 5;
}

.psy-tabs__btn {
  appearance: none;
  border: 0;
  background: transparent;
  font-family: Sora, sans-serif;
  font-size: 0.92rem;
  font-weight: 600;
  letter-spacing: -0.01em;
  color: var(--ink-mute, #4a4560);
  padding: 12px 16px;
  border-radius: 3px;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  transition: background 0.2s ease, color 0.2s ease;
}

.psy-tabs__btn:hover {
  color: var(--ink, #0a0a0a);
  background: rgba(255, 255, 255, 0.7);
}

.psy-tabs__btn.is-active {
  background: #fff;
  color: var(--ink, #0a0a0a);
  box-shadow: 0 8px 20px -14px rgba(74, 87, 223, 0.55);
}

.psy-tabs__idx {
  font-family: "JetBrains Mono", ui-monospace, monospace;
  font-size: 0.72rem;
  font-weight: 500;
  color: var(--coral, #b31ddc);
}

.psy-tabs__panel {
  display: none;
  animation: psyTabIn 0.28s ease;
  max-width: 72ch;
}

.psy-tabs__panel.is-active {
  display: block;
}

.psy-tabs--inner {
  margin-top: 4px;
}

.psy-tabs--inner .psy-tabs__nav {
  position: static;
  margin-bottom: 20px;
}

.psy-tabs--inner .psy-tabs__btn {
  font-size: 0.84rem;
  padding: 10px 12px;
}

.psy-tabs--inner .psy-tabs__panel {
  max-width: 72ch;
}

.psy-empty {
  margin: 0;
  color: var(--ink-mute, #4a4560);
  font-style: italic;
}

@keyframes psyTabIn {
  from {
    opacity: 0;
    transform: translateY(6px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.psy-block {
  margin: 0 0 28px;
}

.psy-block h3 {
  font-family: Sora, sans-serif;
  font-size: 1.15rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  margin: 0 0 14px;
  padding-bottom: 8px;
  border-bottom: 1px solid var(--line-soft, rgba(10, 10, 10, 0.07));
}

.psy-timeline {
  list-style: none;
  margin: 0;
  padding: 0;
}

.psy-timeline li {
  display: grid;
  grid-template-columns: 7.5rem 1fr;
  gap: 16px;
  padding: 14px 0;
  border-bottom: 1px solid var(--line-faint, rgba(10, 10, 10, 0.04));
}

.psy-timeline__date {
  font-family: "JetBrains Mono", ui-monospace, monospace;
  font-size: 0.78rem;
  color: var(--coral, #b31ddc);
  padding-top: 3px;
}

.psy-timeline__body strong {
  display: block;
  font-family: Sora, sans-serif;
  font-size: 0.98rem;
  font-weight: 600;
  letter-spacing: -0.015em;
  margin-bottom: 4px;
}

.psy-timeline__body p {
  margin: 0;
  font-size: 0.92rem;
  line-height: 1.55;
  color: var(--ink-mute, #4a4560);
}

.psy-chips {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.psy-chips li {
  font-family: Inter, sans-serif;
  font-size: 0.9rem;
  padding: 10px 14px;
  background: #fff;
  border: 1px solid var(--line, rgba(10, 10, 10, 0.12));
  border-radius: 3px;
}

.psy-chips a {
  color: inherit;
  text-decoration: none;
}

.psy-chips a:hover {
  color: var(--coral, #b31ddc);
}

.psy-single .prose {
  font-family: Inter, sans-serif;
  font-size: 1rem;
  line-height: 1.7;
  color: var(--ink-soft, #1a1a1a);
}

.psy-single .prose h2,
.psy-single .prose h3 {
  font-family: Sora, sans-serif;
}

/* Accordion (onglet Pratique) */
.psy-acc {
  display: grid;
  gap: 8px;
  max-width: 72ch;
}

.psy-acc__item {
  border: 1px solid var(--line, rgba(10, 10, 10, 0.12));
  background: #fff;
  border-radius: 3px;
  overflow: hidden;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.psy-acc__item.is-open {
  border-color: rgba(179, 29, 220, 0.35);
  box-shadow: 0 14px 30px -24px rgba(74, 87, 223, 0.55);
}

.psy-acc__trigger {
  width: 100%;
  appearance: none;
  border: 0;
  background: var(--paper-warm, #f7f5fc);
  display: grid;
  grid-template-columns: auto 1fr auto;
  gap: 14px;
  align-items: center;
  text-align: left;
  padding: 16px 18px;
  cursor: pointer;
  font-family: Sora, sans-serif;
  color: var(--ink, #0a0a0a);
}

.psy-acc__item.is-open .psy-acc__trigger {
  background: #fff;
  border-bottom: 1px solid var(--line-soft, rgba(10, 10, 10, 0.07));
}

.psy-acc__num {
  font-family: "JetBrains Mono", ui-monospace, monospace;
  font-size: 0.72rem;
  color: var(--coral, #b31ddc);
}

.psy-acc__title {
  font-size: 0.98rem;
  font-weight: 650;
  letter-spacing: -0.015em;
  line-height: 1.3;
}

.psy-acc__icon {
  width: 18px;
  height: 18px;
  position: relative;
}

.psy-acc__icon::before,
.psy-acc__icon::after {
  content: "";
  position: absolute;
  background: var(--ink, #0a0a0a);
  transition: transform 0.2s ease, opacity 0.2s ease;
}

.psy-acc__icon::before {
  left: 3px;
  right: 3px;
  top: 8px;
  height: 2px;
}

.psy-acc__icon::after {
  top: 3px;
  bottom: 3px;
  left: 8px;
  width: 2px;
}

.psy-acc__item.is-open .psy-acc__icon::after {
  opacity: 0;
  transform: scaleY(0);
}

.psy-acc__panel {
  padding: 18px 20px 22px;
}

.psy-acc__panel[hidden] {
  display: none;
}

.psy-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 28px;
  margin-top: 24px;
  max-width: none;
}

.psy-card {
  transition: transform 0.25s ease;
}

.psy-card:hover {
  transform: translateY(-3px);
}

.psy-card a {
  color: inherit;
  text-decoration: none;
  display: block;
}

.psy-card-img {
  overflow: hidden;
  border-radius: 2px;
  background: #f0eef5;
  margin-bottom: 12px;
}

.psy-card-img img {
  width: 100%;
  aspect-ratio: 1;
  object-fit: cover;
  display: block;
}

.psy-card h3 {
  font-family: Sora, sans-serif;
  font-size: 1.05rem;
  margin: 0 0 6px;
}

.psy-card p {
  margin: 0;
  font-size: 0.9rem;
  opacity: 0.75;
  line-height: 1.4;
}

/* ——— Région ——— */
.region-mode {
  margin: 0 0 20px;
}

.region-layout {
  display: grid;
  grid-template-columns: minmax(220px, 0.85fr) minmax(0, 1.15fr);
  gap: 24px;
  align-items: start;
  margin-bottom: 8px;
}

.region-map {
  margin: 0;
  position: sticky;
  top: 96px;
  border: 1px solid rgba(10, 10, 10, 0.08);
  border-radius: 3px;
  overflow: hidden;
  background: #f3f1f8;
}

.region-map img {
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  display: block;
}

/* ——— Tarifs ——— */
.tarif-blocks {
  margin-top: 24px;
  max-width: none;
  display: grid;
  gap: 16px;
}

.tarif-section h2 {
  font-family: Sora, sans-serif;
  font-size: 1.25rem;
  margin: 0;
}

.tarif-section .page-block__head {
  margin-bottom: 8px;
}

.tarif-table {
  width: 100%;
  border-collapse: collapse;
  margin: 0 0 36px;
  font-family: Inter, sans-serif;
}

.tarif-table td {
  padding: 14px 8px;
  border-bottom: 1px solid rgba(26, 18, 37, 0.1);
  vertical-align: top;
}

.tarif-table td:last-child {
  text-align: right;
  font-weight: 600;
  white-space: nowrap;
  font-family: "JetBrains Mono", monospace;
  color: var(--accent, #b31ddc);
}

.tarif-note {
  max-width: 60ch;
  opacity: 0.8;
  font-size: 0.95rem;
}

@media (max-width: 820px) {
  .psy-hero,
  .region-layout {
    grid-template-columns: 1fr;
  }

  .psy-hero {
    align-items: start;
  }

  .psy-photo {
    max-width: 240px;
  }

  .psy-timeline li {
    grid-template-columns: 1fr;
    gap: 6px;
  }

  .psy-tabs__nav {
    top: 0;
    overflow-x: auto;
    flex-wrap: nowrap;
  }

  .psy-tabs__btn {
    white-space: nowrap;
    padding: 10px 12px;
  }

  .region-map {
    position: static;
    max-width: 420px;
  }

  .page-hero .display {
    max-width: none;
  }
}
