:root {
  --blue: #6ab8ff;
  --blue-light: #cfe8ff;
  --beige: #f7f4ef;
  --text: #2d2d2d;
  --round: 12px;
  --shadow: 0 3px 8px rgba(0,0,0,0.08);
  font-family: "Inter", sans-serif;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

body {
  background-color: #F0F7FF;
  margin: 0;
  color: var(--text);
}

/* Layout de base */
main {
  max-width: 960px;
  margin: 0 auto;
  padding: 16px;
}

.step {
  display: none;
  padding: 24px 8px 40px;
}

.step.active {
  display: block;
}

.hidden {
  display: none;
}

/* Header */
.header {
  background: #ffffff;
  box-shadow: var(--shadow);
  padding: 10px 0 4px;
  position: sticky;
  top: 0;
  z-index: 50;
}

.logo-area {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
}

.logo {
  height: 42px;
}

.brand {
  font-family: "Lora", serif;
  font-size: 24px;
}

/* Steps menu */
.steps-menu {
  display: flex;
  justify-content: center;
  gap: 6px;
  padding: 10px 12px 8px;
  flex-wrap: wrap;
}

.steps-menu button {
  background: #f2f2f2;
  border: none;
  padding: 8px 16px;
  border-radius: 999px;
  cursor: pointer;
  font-size: 14px;
}

.steps-menu button.active {
  background: var(--blue);
  color: #ffffff;
}

.progress-bar {
  width: 100%;
  height: 4px;
  background: #e0e0e0;
  margin-top: 6px;
}

.progress-fill {
  width: 0;
  height: 4px;
  background: var(--blue);
  transition: width 0.3s;
}

/* Titres et textes */
h2, h3 {
  font-family: "Lora", serif;
  margin-top: 0;
}

.note {
  font-size: 13px;
  opacity: 0.8;
}

/* Cards */
.cards {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  margin-bottom: 16px;
}

.card {
  padding: 16px 18px;
  background: #ffffff;
  border-radius: var(--round);
  cursor: pointer;
  box-shadow: var(--shadow);
  min-width: 220px;
  border: 2px solid transparent;
  text-align: left;
}

.card-title {
  font-weight: 600;
  margin-bottom: 4px;
}

.card.active {
  background: var(--blue);
  color: #ffffff;
  border-color: var(--blue);
}

/* Swatches / bulles de couleur */
.swatches {
  display: flex;
  gap: 14px;
  margin: 20px 0;
  align-items: center;
}

.color-bubble {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  cursor: pointer;
  border: 3px solid transparent;
  transition: transform 0.2s ease, border-color 0.2s ease;
  background-clip: padding-box;
  padding: 0;
}

/* Couleurs */
.color-bubble[data-color="beige"] {
  background: #F6F0E8;
}

.color-bubble[data-color="bleu"] {
  background: #B3E5FC;
}

.color-bubble[data-color="rose"] {
  background: #F8D0D8;
}

.color-bubble[data-color="vert"] {
  background: #D8EED3;
}

.color-bubble[data-color="gris"] {
  background: #E5E5E5;
}

/* État actif */
.color-bubble.active {
  border-color: #4285F4;
  transform: scale(1.15);
}

/* Boutons généraux */
.actions {
  margin-top: 16px;
}

.btn {
  padding: 10px 22px;
  border-radius: 999px;
  background: var(--blue);
  color: white;
  border: none;
  cursor: pointer;
  font-weight: 600;
  font-size: 14px;
}

.btn[disabled] {
  opacity: 0.4;
  cursor: not-allowed;
}

/* Pages disponibles */
.page-item {
  display: flex;
  background: #ffffff;
  border-radius: var(--round);
  padding: 12px;
  box-shadow: var(--shadow);
  margin-bottom: 12px;
  align-items: center;
  gap: 16px;
}

.page-thumb img {
  width: 90px;
  border-radius: 6px;
  cursor: zoom-in;
  transition: transform 0.15s ease;
}

.page-thumb img:hover {
  transform: scale(1.03);
}

.page-info {
  flex: 1;
}

.page-name {
  font-weight: 600;
  margin-bottom: 4px;
}

.page-desc {
  font-size: 13px;
  opacity: 0.85;
}

.page-actions-line {
  display: flex;
  gap: 8px;
  margin-top: 6px;
}

/* Boutons ronds */
.btn-round {
  width: 30px;
  height: 30px;
  border-radius: 50%;
  background: var(--blue-light);
  border: none;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 14px;
}

.btn-round.remove {
  background: #ffd3d3;
  color: #a00;
}

/* Mon agenda actuel */
#selected-manager {
  margin-bottom: 18px;
}

.selected-row {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 6px;
  font-size: 14px;
}

/* Anti robot */
.robot-check {
  margin: 24px 0 8px;
  background: #ffffff;
  padding: 14px 18px;
  border-radius: var(--round);
  box-shadow: var(--shadow);
  margin-top: 12px;
  margin-bottom: 20px;
}

.robot-label {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: 14px;
}

.robot-label input[type="checkbox"] {
  width: auto;
}

/* Aperçu visuel (live) */
.live-preview {
  display: flex;
  flex-direction: column;
  gap: 20px;
  margin-top: 20px;
}

.live-preview .page-block {
  text-align: center;
  font-size: 14px;
  color: #6b5b4b;
}

.live-preview img {
  width: 100%;
  border-radius: 12px;
  background: #f6f3ee;
  box-shadow: 0 3px 10px rgba(0,0,0,0.08);
  object-fit: contain;
}

/* Formulaire de commande */
.order-form {
  margin-top: 32px;
  background: #ffffff;
  padding: 20px 18px 24px;
  border-radius: var(--round);
  box-shadow: var(--shadow);
}

.order-form h3 {
  margin-top: 0;
  margin-bottom: 16px;
}

.order-form label {
  display: block;
  font-size: 14px;
  margin-bottom: 4px;
}

.order-form input,
.order-form textarea {
  width: 100%;
  font-family: "Inter", sans-serif;
  font-size: 14px;
  padding: 8px 10px;
  margin-bottom: 12px;
  border-radius: 8px;
  border: 1px solid #d0d0d0;
  outline: none;
}

.order-form input:focus,
.order-form textarea:focus {
  border-color: var(--blue);
}

.order-form textarea {
  min-height: 70px;
  resize: vertical;
}

.order-result {
  margin-top: 10px;
  font-size: 14px;
}

/* Zoom image overlay */
.img-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.7);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 9999;
}

.img-overlay img {
  max-width: 90%;
  max-height: 90%;
  border-radius: 12px;
  box-shadow: var(--shadow);
}

/* Footer */
footer {
  text-align: center;
  padding: 20px 0 30px;
  opacity: 0.6;
  font-size: 13px;
}

/* Responsive */
@media (max-width: 600px) {
  .cards {
    flex-direction: column;
  }

  .page-item {
    flex-direction: row;
  }

  main {
    padding: 12px;
  }
}
