/* ============================================================
   Método Manniello – boutique de livres PDF
   Thème repris du site principal :
   vert #1CA14D · accent #61CE70 · rouge #FF0000 · texte #7A7A7A
   Titres Montserrat · texte Roboto
   ============================================================ */

:root {
  --green: #1ca14d;
  --green-dark: #15803c;
  --green-light: #61ce70;
  --red: #ff0000;
  --text: #4a4a4a;
  --text-soft: #7a7a7a;
  --heading: #1f2a24;
  --bg: #ffffff;
  --bg-soft: #f6f8f6;
  --border: #e6ebe7;
  --shadow: 0 10px 30px rgba(31, 42, 36, 0.08);
  --radius: 18px;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: 'Roboto', system-ui, -apple-system, sans-serif;
  font-size: 16px;
  line-height: 1.65;
  color: var(--text);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3 {
  font-family: 'Montserrat', 'Roboto', sans-serif;
  color: var(--heading);
  line-height: 1.2;
  margin: 0 0 0.5em;
}

a { color: var(--green); text-decoration: none; }
a:hover { color: var(--green-dark); }

img { max-width: 100%; display: block; }

.container {
  width: min(1140px, 100% - 2.5rem);
  margin-inline: auto;
}

/* ---------- Header ---------- */

.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--border);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.7rem 0;
}

.brand img { width: 120px; height: auto; }

/* Sélecteur de langues : dropdown avec drapeaux (comme le site principal) */

.lang-dd {
  position: relative;
  font-family: 'Montserrat', sans-serif;
  font-size: 0.85rem;
  font-weight: 600;
}

.lang-dd svg:not(.caret) {
  width: 22px;
  height: 16px;
  border-radius: 3px;
  box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.08);
  flex: none;
}

.lang-dd summary {
  list-style: none;
  display: flex;
  align-items: center;
  gap: 0.55rem;
  cursor: pointer;
  color: var(--heading);
  padding: 0.5rem 0.85rem;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: #fff;
  transition: border-color 0.15s ease;
  user-select: none;
}

.lang-dd summary::-webkit-details-marker { display: none; }

.lang-dd summary:hover { border-color: var(--green); }

.lang-dd .caret { color: var(--text-soft); transition: transform 0.15s ease; }

.lang-dd[open] .caret { transform: rotate(180deg); }

.lang-menu {
  position: absolute;
  right: 0;
  top: calc(100% + 8px);
  z-index: 50;
  margin: 0;
  padding: 0.4rem;
  list-style: none;
  min-width: 185px;
  background: #fff;
  border: 1px solid var(--border);
  border-radius: 14px;
  box-shadow: 0 14px 34px rgba(31, 42, 36, 0.14);
}

.lang-menu a {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  padding: 0.55rem 0.75rem;
  border-radius: 9px;
  color: var(--heading);
}

.lang-menu a:hover { background: var(--bg-soft); color: var(--green-dark); }

/* ---------- Hero ---------- */

.hero {
  position: relative;
  overflow: hidden;
  text-align: center;
  padding: 4.5rem 0 3.5rem;
  background:
    radial-gradient(ellipse at 50% -20%, rgba(28, 161, 77, 0.10), transparent 60%),
    linear-gradient(180deg, #fbfdfb 0%, #ffffff 100%);
}

.hero-kicker {
  font-family: 'Montserrat', sans-serif;
  font-size: 0.85rem;
  font-weight: 700;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--green);
  margin: 0 0 0.75rem;
}

.hero h1 {
  font-size: clamp(2.1rem, 5vw, 3.2rem);
  font-weight: 800;
  margin-bottom: 0.6rem;
}

.hero-subtitle {
  max-width: 620px;
  margin: 0 auto;
  color: var(--text-soft);
  font-size: 1.08rem;
}

/* ---------- Books ---------- */

.books {
  position: relative;
  overflow: hidden;
  padding: 1rem 0 5rem;
}

/* Logo « M » rouge en filigrane, en bas à gauche de la section livres */
.books::before {
  content: '';
  position: absolute;
  left: -160px;
  bottom: -140px;
  width: 520px;
  height: 480px;
  background: url('/img/logo_Manniello_rouge.png') no-repeat center / contain;
  opacity: 0.05;
  pointer-events: none;
}

.books-grid {
  position: relative;
  display: grid;
  gap: 2rem;
}

.book-card {
  display: grid;
  grid-template-columns: 340px 1fr;
  background: #fff;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  overflow: hidden;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.book-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 16px 40px rgba(31, 42, 36, 0.12);
}

.book-cover {
  background: linear-gradient(160deg, #f4f6f4, #e9eeea);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1.25rem;
}

.book-cover img {
  width: 100%;
  max-width: 300px;
  border-radius: 10px;
}

.book-body {
  padding: 2rem 2.25rem;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
}

.book-title {
  font-size: 1.45rem;
  font-weight: 700;
  margin-bottom: 0.15rem;
}

.book-author {
  font-size: 0.9rem;
  color: var(--text-soft);
  margin: 0 0 0.6rem;
}

.book-subtitle {
  font-weight: 500;
  color: var(--heading);
  margin: 0 0 0.6rem;
}

.book-desc {
  color: var(--text-soft);
  margin: 0 0 1.4rem;
}

.book-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-top: auto;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.55rem;
  font-family: 'Montserrat', sans-serif;
  font-size: 0.95rem;
  font-weight: 700;
  line-height: 1.25;
  padding: 0.8rem 1.5rem;
  border-radius: 999px;
  /* bordure transparente : tous les boutons ont exactement la même hauteur,
     y compris ceux avec bordure visible (Amazon) */
  border: 2px solid transparent;
  cursor: pointer;
  transition: all 0.15s ease;
}

.btn-primary {
  background: var(--green);
  color: #fff;
  box-shadow: 0 6px 18px rgba(28, 161, 77, 0.35);
}

.btn-primary:hover {
  background: var(--green-dark);
  color: #fff;
  transform: translateY(-1px);
}

.btn-amazon {
  background: #fff;
  color: #131921;
  border: 2px solid #f3a847;
}

.btn-amazon:hover {
  background: #fff7ec;
  color: #131921;
}

.btn-ghost {
  background: transparent;
  color: var(--green);
  border: 2px solid var(--border);
}

.btn-ghost:hover { border-color: var(--green); }

.secure-note {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.82rem;
  color: var(--text-soft);
  margin: 1rem 0 0;
}

/* ---------- Success / Cancel ---------- */

.status-page {
  position: relative;
  overflow: hidden;
  padding: 4.5rem 0 5.5rem;
  background:
    radial-gradient(ellipse at 50% -20%, rgba(28, 161, 77, 0.08), transparent 60%),
    #fff;
}

.status-page::before {
  content: '';
  position: absolute;
  right: -160px;
  bottom: -160px;
  width: 520px;
  height: 480px;
  background: url('/img/logo_Manniello_rouge.png') no-repeat center / contain;
  opacity: 0.045;
  pointer-events: none;
}

.status-card {
  max-width: 640px;
  background: #fff;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 3rem 2.5rem;
  text-align: center;
}

.status-icon {
  width: 72px;
  height: 72px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 1.25rem;
}

.status-icon.success {
  color: #fff;
  background: var(--green);
  box-shadow: 0 8px 24px rgba(28, 161, 77, 0.4);
}

.status-icon.cancel {
  color: #fff;
  background: #c8532f;
  box-shadow: 0 8px 24px rgba(200, 83, 47, 0.35);
}

.status-card h1 { font-size: 1.8rem; }

.status-book {
  display: flex;
  align-items: center;
  gap: 1rem;
  text-align: left;
  background: var(--bg-soft);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 0.9rem 1.1rem;
  margin: 1.25rem auto;
  max-width: 420px;
}

.status-book img { width: 64px; border-radius: 6px; }

.status-book-title {
  font-family: 'Montserrat', sans-serif;
  font-weight: 700;
  color: var(--heading);
  margin: 0;
}

.status-book-author {
  font-size: 0.85rem;
  color: var(--text-soft);
  margin: 0;
}

.muted { color: var(--text-soft); font-size: 0.9rem; }

.status-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.75rem;
  margin-top: 1.75rem;
}

/* ---------- Footer ---------- */

.site-footer {
  background: #14211a;
  color: #b9c6be;
  padding: 3rem 0 2rem;
  text-align: center;
}

.footer-inner p { margin: 0.3rem 0; }

.footer-logo {
  width: 110px;
  margin: 0 auto 1rem;
  filter: brightness(0) invert(1);
  opacity: 0.9;
}

.site-footer a { color: var(--green-light); font-weight: 500; }

.site-footer .copyright {
  margin-top: 1.25rem;
  font-size: 0.82rem;
  opacity: 0.6;
}

/* ---------- Responsive ---------- */

@media (max-width: 860px) {
  .book-card { grid-template-columns: 1fr; }

  .book-cover { padding: 1.5rem 1.5rem 0.5rem; background: linear-gradient(180deg, #f4f6f4, #ffffff); }

  .book-cover img { max-width: 260px; }

  .book-body { padding: 1.5rem 1.5rem 2rem; }

  .hero { padding: 3rem 0 2.5rem; }

  .status-card { padding: 2.25rem 1.5rem; }
}

@media (max-width: 480px) {
  .book-actions { width: 100%; }
  .book-actions form, .book-actions .btn { width: 100%; justify-content: center; }
}
