/* ===== CUSTOM PROPERTIES ===== */
:root {
  /* Calm UI palette */
  --bg-warm: #F2EFE9;
  --bg-soft: #F7F7F8;
  --text-primary: #2D2D2D;
  --text-secondary: #6B6B6B;
  --accent-sage: #7A9E7E;
  --accent-sage-hover: #6B8E6F;
  --accent-terracotta: #E27D60;
  --accent-terracotta-hover: #D06A4D;

  /* Glass */
  --glass-bg: rgba(255, 255, 255, 0.45);
  --glass-border: rgba(255, 255, 255, 0.6);
  --glass-blur: 16px;

  /* Typography */
  --font-serif: 'Playfair Display', Georgia, 'Times New Roman', serif;
  --font-sans: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;

  /* Spacing */
  --section-padding: clamp(4rem, 8vw, 8rem);
  --container-max: 1120px;
}

/* ===== RESET & BASE ===== */
*,
*::before,
*::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body {
  font-family: var(--font-sans);
  font-size: 1rem;
  line-height: 1.7;
  color: var(--text-primary);
  background-color: var(--bg-warm);
}

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

a {
  color: inherit;
  text-decoration: none;
}

/* ===== LAYOUT ===== */
.container {
  max-width: var(--container-max);
  margin: 0 auto;
  padding: 0 1.5rem;
}

/* ===== TYPOGRAPHY ===== */
h1, h2, h3 {
  font-family: var(--font-serif);
  font-weight: 500;
  line-height: 1.25;
}

.section-title {
  font-size: clamp(1.75rem, 4vw, 2.75rem);
  text-align: center;
  margin-bottom: 2rem;
  color: var(--text-primary);
}

/* ===== BUTTON ===== */
.btn {
  display: inline-block;
  padding: 1rem 2.25rem;
  border-radius: 50px;
  font-family: var(--font-sans);
  font-size: 1.05rem;
  font-weight: 600;
  cursor: pointer;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background-color 0.2s ease;
  border: none;
}

.btn-primary {
  background-color: var(--accent-sage);
  color: #fff;
  box-shadow: 0 4px 20px rgba(122, 158, 126, 0.3);
}

.btn-primary:hover {
  background-color: var(--accent-sage-hover);
  transform: translateY(-2px);
  box-shadow: 0 6px 28px rgba(122, 158, 126, 0.4);
}

.btn-primary:active {
  transform: translateY(0);
}

/* ===== HERO ===== */
.hero {
  padding: var(--section-padding) 0;
  padding-top: clamp(1.5rem, 3vw, 3rem);
  padding-bottom: clamp(1rem, 2vw, 2rem);
  background-color: var(--bg-warm);
  text-align: center;
}

.hero-content {
  max-width: 860px;
}

.hero-bear {
  width: 80px;
  height: 80px;
  margin: 0 auto 1.25rem;
}

.hero-bears-trio {
  width: 240px;
  margin: 0 auto 1.25rem;
}

.hero-bandeau {
  width: 100%;
  display: block;
  max-height: 250px;
  object-fit: cover;
  object-position: center;
}

.hero-bandeau--contained {
  max-width: 860px;
  margin: 0 auto;
  border-radius: 0 0 16px 16px;
}

.hero--no-top {
  padding-top: clamp(1rem, 2vw, 2rem) !important;
}

.hero-title {
  font-size: clamp(2rem, 5vw, 3.5rem);
  margin-bottom: 1.5rem;
  color: var(--text-primary);
  letter-spacing: -0.02em;
}

.hero-title em {
  font-style: italic;
  color: var(--accent-sage);
}

.hero-subtitle {
  font-size: clamp(1.05rem, 2vw, 1.25rem);
  color: var(--text-secondary);
  margin-bottom: 1.5rem;
  max-width: 860px;
  margin-left: auto;
  margin-right: auto;
  line-height: 1.8;
}

.hero-micro {
  margin-top: 1rem;
  font-size: 0.875rem;
  color: var(--text-secondary);
}

/* ===== STEPS SECTION ===== */
.steps {
  padding: 2rem 0 var(--section-padding);
  background-color: var(--bg-soft);
}

/* 3-column grid (Calm style) */
.steps-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2rem;
}

.step-card {
  display: flex;
  flex-direction: column;
}

.step-card-visual {
  padding: 1rem;
}

/* Browser window mockup */
.browser-frame {
  border-radius: 10px;
  overflow: hidden;
  background: #fff;
  box-shadow: 0 8px 30px rgba(0, 0, 0, 0.15), 0 2px 8px rgba(0, 0, 0, 0.08);
  transform: rotate(-2.5deg);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.browser-frame:hover {
  transform: rotate(0deg) translateY(-4px);
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.18), 0 4px 12px rgba(0, 0, 0, 0.1);
}

.step-card:nth-child(2) .browser-frame {
  transform: rotate(2deg);
}

.step-card:nth-child(2) .browser-frame:hover {
  transform: rotate(0deg) translateY(-4px);
}

.browser-bar {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 10px 14px;
  background: #F0F0F0;
  border-bottom: 1px solid #E0E0E0;
}

.browser-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
}

.browser-dot--red { background: #EC6A5E; }
.browser-dot--yellow { background: #F4BF4F; }
.browser-dot--green { background: #61C554; }

.step-img {
  width: 100%;
  border-radius: 12px;
  box-shadow: 0 2px 12px rgba(0, 0, 0, 0.06);
}

.step-card-body {
  padding: 1.5rem;
}

.step-number {
  display: inline-block;
  font-family: var(--font-serif);
  font-size: 0.875rem;
  font-weight: 700;
  color: var(--accent-terracotta);
  letter-spacing: 0.1em;
  text-transform: uppercase;
  margin-bottom: 0.75rem;
}

.step-title {
  font-size: clamp(1.4rem, 3vw, 2rem);
  margin-bottom: 1rem;
  color: var(--text-primary);
}

.step-description {
  font-size: 1.05rem;
  color: var(--text-secondary);
  line-height: 1.8;
}

/* ===== GLASS CARD / PLACEHOLDER ===== */
.glass-card {
  background: var(--glass-bg);
  backdrop-filter: blur(var(--glass-blur));
  -webkit-backdrop-filter: blur(var(--glass-blur));
  border: 1px solid var(--glass-border);
  border-radius: 20px;
  overflow: hidden;
}

.placeholder-img {
  aspect-ratio: 4 / 3;
  display: flex;
  align-items: center;
  justify-content: center;
}

.placeholder-content {
  text-align: center;
  padding: 2rem;
}

.placeholder-icon {
  margin-bottom: 1rem;
  opacity: 0.7;
}

.placeholder-label {
  font-size: 0.875rem;
  color: var(--text-secondary);
  font-style: italic;
}

/* ===== INSTALL SECTION ===== */
.install {
  padding: var(--section-padding) 0;
  background-color: var(--bg-warm);
}

.install-grid {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 1.25rem;
}

.install-card {
  padding: 1.5rem 1.25rem;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.install-card-icon {
  margin-bottom: 1rem;
}

.install-number {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background-color: var(--accent-sage);
  color: #fff;
  font-family: var(--font-serif);
  font-weight: 700;
  font-size: 0.875rem;
  margin-bottom: 0.75rem;
}

.install-title {
  font-size: 1.05rem;
  margin-bottom: 0.75rem;
  color: var(--text-primary);
}

.install-text {
  font-size: 0.875rem;
  color: var(--text-secondary);
  line-height: 1.7;
  margin-bottom: 1rem;
  flex-grow: 1;
}

.install-warning {
  font-size: 0.8rem;
  color: var(--accent-terracotta);
  font-weight: 500;
  padding: 0.5rem 0.75rem;
  background: rgba(226, 125, 96, 0.08);
  border-radius: 8px;
}

/* Copy button */
.copy-btn {
  display: inline-block;
  padding: 0.6rem 1rem;
  background: rgba(45, 45, 45, 0.06);
  border: 1px dashed rgba(45, 45, 45, 0.2);
  border-radius: 8px;
  font-family: monospace;
  font-size: 0.8rem;
  color: var(--text-primary);
  cursor: pointer;
  transition: background 0.2s ease;
  position: relative;
}

.copy-btn:hover {
  background: rgba(45, 45, 45, 0.1);
}

.copy-btn-feedback {
  display: none;
  color: var(--accent-sage);
  font-family: var(--font-sans);
  font-weight: 600;
}

.copy-btn.copied .copy-btn-text {
  display: none;
}

.copy-btn.copied .copy-btn-feedback {
  display: inline;
}

/* Dev mode toggle (Chrome-style) */
.dev-toggle {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.4rem 0.75rem;
  background: rgba(45, 45, 45, 0.06);
  border-radius: 8px;
  margin-top: auto;
  white-space: nowrap;
}

.dev-toggle-label {
  font-size: 0.7rem;
  color: var(--text-primary);
  font-weight: 500;
}

.dev-toggle-switch {
  display: inline-block;
  width: 36px;
  height: 20px;
  background-color: var(--accent-sage);
  border-radius: 10px;
  position: relative;
}

.dev-toggle-knob {
  position: absolute;
  top: 2px;
  right: 2px;
  width: 16px;
  height: 16px;
  background: #fff;
  border-radius: 50%;
}

/* Small button variant */
.btn-small {
  padding: 0.65rem 1.5rem;
  font-size: 0.9rem;
}

/* ===== MODAL EMAIL ===== */
.modal-overlay {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(45, 45, 45, 0.4);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
  z-index: 1000;
  align-items: center;
  justify-content: center;
  padding: 1.5rem;
}

.modal-overlay.active {
  display: flex;
}

.modal {
  max-width: 420px;
  width: 100%;
  padding: 2rem;
  text-align: center;
  position: relative;
  background: var(--bg-warm);
  border: 1px solid rgba(45, 45, 45, 0.08);
  box-shadow: 0 8px 30px rgba(0, 0, 0, 0.15);
}

.modal-close {
  position: absolute;
  top: 0.75rem;
  right: 1rem;
  background: none;
  border: none;
  font-size: 1.5rem;
  color: var(--text-secondary);
  cursor: pointer;
}

.modal-title {
  font-size: 1.25rem;
  margin-bottom: 0.75rem;
}

.modal-text {
  font-size: 0.9rem;
  color: var(--text-secondary);
  line-height: 1.7;
  margin-bottom: 1.25rem;
}

.modal-form {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.modal-input {
  padding: 0.75rem 1rem;
  border: 1px solid rgba(45, 45, 45, 0.15);
  border-radius: 10px;
  font-family: var(--font-sans);
  font-size: 1rem;
  background: rgba(255, 255, 255, 0.6);
  outline: none;
  transition: border-color 0.2s ease;
}

.modal-input:focus {
  border-color: var(--accent-sage);
}

.modal-feedback {
  margin-top: 0.75rem;
  font-size: 0.875rem;
  color: var(--accent-sage);
  font-weight: 500;
}

/* ===== FOOTER ===== */
.footer {
  padding: 3rem 0;
  text-align: center;
  background-color: var(--bg-warm);
  border-top: 1px solid rgba(45, 45, 45, 0.08);
}

.footer-text {
  font-family: var(--font-serif);
  font-size: 1rem;
  color: var(--text-primary);
  margin-bottom: 0.25rem;
}

.footer-sub {
  font-size: 0.8rem;
  color: var(--text-secondary);
}

/* ===== ANIMATIONS ===== */
.fade-in {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.7s ease, transform 0.7s ease;
}

.fade-in.visible {
  opacity: 1;
  transform: translateY(0);
}

/* ===== RESPONSIVE ===== */
@media (max-width: 1024px) {
  .install-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

@media (max-width: 768px) {
  .steps-grid {
    grid-template-columns: 1fr;
    gap: 1.5rem;
  }

  .install-grid {
    grid-template-columns: 1fr;
  }

  .hero-content {
    padding: 0 0.5rem;
  }
}

/* ===== REDUCED MOTION ===== */
@media (prefers-reduced-motion: reduce) {
  .fade-in {
    opacity: 1;
    transform: none;
    transition: none;
  }

  html {
    scroll-behavior: auto;
  }
}
