/* Page de connexion etudiant v2 : sans barre de navigation, theme en haut a droite, carte centree. */
body.lp2 {
  --lp2-surface: #ffffff;
  --lp2-page: #faf9f5;
  --lp2-ink: #1f1e1d;
  --lp2-muted: #6b6a66;
  --lp2-line: #e6e3da;
  --lp2-hover: #f5f3ee;
  --lp2-accent: #c15f3c;
  margin: 0;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  background: var(--lp2-page);
  color: var(--lp2-ink);
  font-family: Figtree, system-ui, -apple-system, Segoe UI, sans-serif;
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) body.lp2 {
    --lp2-surface: #1e1d1b;
    --lp2-page: #161514;
    --lp2-ink: #f5f3ee;
    --lp2-muted: #a3a09a;
    --lp2-line: #34322e;
    --lp2-hover: #2a2927;
    --lp2-accent: #e08a6b;
  }
}
:root[data-theme="dark"] body.lp2 {
  --lp2-surface: #1e1d1b;
  --lp2-page: #161514;
  --lp2-ink: #f5f3ee;
  --lp2-muted: #a3a09a;
  --lp2-line: #34322e;
  --lp2-hover: #2a2927;
  --lp2-accent: #e08a6b;
}

.lp2-theme {
  position: fixed;
  top: 16px;
  right: 16px;
  z-index: 50;
}

.lp2-main {
  flex: 1;
  width: 100%;
  max-width: 1180px;
  margin: 0 auto;
  padding: 88px 24px 48px;
  box-sizing: border-box;
  display: grid;
  grid-template-columns: minmax(320px, 440px) minmax(0, 1fr);
  gap: 56px;
  align-items: center;
}

.lp2-card {
  background: var(--lp2-surface);
  border: 1px solid var(--lp2-line);
  border-radius: 20px;
  padding: 40px 36px 32px;
  box-shadow: 0 12px 40px rgba(31, 30, 29, .08);
}

.lp2-brand {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 700;
  font-size: 15px;
  letter-spacing: .01em;
}
.lp2-brand img {
  width: 36px;
  height: 36px;
  object-fit: contain;
}

.lp2-card h1 {
  margin: 28px 0 6px;
  font-family: "Source Serif 4", Georgia, serif;
  font-weight: 500;
  font-size: 32px;
  line-height: 1.15;
  letter-spacing: -.01em;
}

.lp2-sub {
  margin: 0 0 24px;
  color: var(--lp2-muted);
  font-size: 15px;
  line-height: 1.5;
}

.lp2-methods {
  display: grid;
  gap: 10px;
}

.lp2-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  width: 100%;
  height: 50px;
  box-sizing: border-box;
  padding: 0 16px;
  border: 1px solid var(--lp2-line);
  border-radius: 12px;
  background: var(--lp2-surface);
  color: var(--lp2-ink);
  font: 600 15px/1 Figtree, system-ui, sans-serif;
  text-decoration: none;
  cursor: pointer;
  transition: background .15s ease, box-shadow .15s ease, transform .15s ease;
}
.lp2-btn:hover {
  background: var(--lp2-hover);
  box-shadow: 0 2px 10px rgba(31, 30, 29, .06);
}
.lp2-btn:active {
  transform: translateY(1px);
}
.lp2-btn svg {
  flex: 0 0 auto;
}

.lp2-divider {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 20px 0;
  color: var(--lp2-muted);
  font-size: 13px;
}
.lp2-divider::before,
.lp2-divider::after {
  content: "";
  flex: 1;
  height: 1px;
  background: var(--lp2-line);
}

.lp2-ghost {
  font-weight: 500;
  color: var(--lp2-muted);
}

.lp2-form {
  margin-top: 18px;
  text-align: left;
}

.lp2-back {
  display: block;
  margin-top: 24px;
  text-align: center;
  color: var(--lp2-accent);
  font-weight: 600;
  font-size: 14px;
  text-decoration: none;
}
.lp2-back:hover {
  text-decoration: underline;
}

.lp2-visual {
  min-width: 0;
}
.lp2-visual img {
  display: block;
  width: 100%;
  height: auto;
  max-height: 640px;
  object-fit: cover;
  border-radius: 24px;
}

@media (max-width: 860px) {
  .lp2-main {
    grid-template-columns: 1fr;
    padding: 72px 16px 32px;
    gap: 24px;
  }
  .lp2-visual {
    display: none;
  }
  .lp2-card {
    padding: 28px 22px 24px;
  }
  .lp2-card h1 {
    font-size: 28px;
  }
}

/* v3 : logo centre, photo agrandie et animee, citation */
.lp2-card > .lp2-brand-center,
.lp2-card > h1,
.lp2-card > .lp2-sub {
  text-align: center;
}
.lp2-brand-center {
  justify-content: center;
}
.lp2-brand-center img {
  width: 64px;
  height: 64px;
}
.lp2-card h1 {
  margin-top: 22px;
}
.lp2-card .lp2-sub {
  margin-left: auto;
  margin-right: auto;
  max-width: 340px;
}

.lp2-main {
  max-width: 1280px;
  grid-template-columns: minmax(320px, 420px) minmax(0, 1fr);
}
.lp2-photo {
  position: relative;
  margin: 0;
  height: 100%;
  min-height: 640px;
  border-radius: 24px;
  overflow: hidden;
  background: var(--lp2-hover);
}
.lp2-photo img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  max-height: none;
  object-fit: cover;
  object-position: center 30%;
  border-radius: 0;
  transform: scale(1.04);
  animation: lp2-drift 20s ease-in-out infinite alternate;
  will-change: transform;
}
@keyframes lp2-drift {
  from { transform: scale(1.04) translate3d(0, 0, 0); }
  to   { transform: scale(1.12) translate3d(-1.5%, -1%, 0); }
}
.lp2-quote {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  margin: 0;
  padding: 80px 36px 36px;
  background: linear-gradient(to top, rgba(15, 14, 13, .82), rgba(15, 14, 13, 0));
  color: #fff;
}
.lp2-quote p {
  margin: 0;
  max-width: 480px;
  font-family: "Source Serif 4", Georgia, serif;
  font-size: 28px;
  line-height: 1.25;
  text-wrap: balance;
}

@media (prefers-reduced-motion: reduce) {
  .lp2-photo img {
    animation: none;
  }
}
@media (max-width: 860px) {
  .lp2-brand-center img {
    width: 52px;
    height: 52px;
  }
  .lp2-photo {
    min-height: 0;
  }
}
