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

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  background-color: #fafafa;
  color: #262626;
  font-size: 14px;
  min-height: 100vh;
}

/* ===== LAYOUT ===== */
.page {
  display: flex;
  justify-content: center;
  align-items: center;
  min-height: calc(100vh - 110px);
  gap: 28px;
  padding: 32px 20px 16px;
}

/* ===== MOCKUP TÉLÉPHONE ===== */
.phone-mockup {
  width: 370px;
  display: flex;
  justify-content: center;
  align-items: center;
  flex-shrink: 0;
}

.phone-frame {
  position: relative;
  width: 240px;
  height: 508px;
  background: #fff;
  border: 1.5px solid #dbdbdb;
  border-radius: 38px;
  overflow: hidden;
  box-shadow:
    0 0 0 8px #fff,
    0 0 0 9.5px #dbdbdb,
    0 12px 40px rgba(0,0,0,0.10);
  display: flex;
  flex-direction: column;
}

.phone-notch {
  position: absolute;
  top: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 72px;
  height: 24px;
  background: #fff;
  border-radius: 0 0 18px 18px;
  border: 1.5px solid #dbdbdb;
  border-top: none;
  z-index: 20;
}

.phone-screen {
  flex: 1;
  overflow: hidden;
  margin-top: 0;
}

.phone-navbar {
  height: 44px;
  border-top: 1px solid #dbdbdb;
  display: flex;
  align-items: center;
  justify-content: space-around;
  padding: 0 12px;
  background: #fff;
  color: #262626;
  font-size: 20px;
  flex-shrink: 0;
}

.mock-profile-dot {
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: linear-gradient(45deg, #f09433, #e6683c, #dc2743, #cc2366, #bc1888);
  border: 1.5px solid #fff;
  outline: 1.5px solid #262626;
}

/* ===== SLIDESHOW ===== */
.slideshow {
  width: 100%;
  height: 100%;
  position: relative;
}

.slide {
  position: absolute;
  inset: 0;
  opacity: 0;
  transition: opacity 0.7s ease-in-out;
  overflow: hidden;
}

.slide.active { opacity: 1; }

/* ===== MOCK FEED ===== */
.mock-feed {
  width: 100%;
  height: 100%;
  background: #fff;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  padding-top: 24px;
}

.mock-topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 8px 12px 6px;
}

.mock-topbar svg text {
  font-family: 'Dancing Script', Georgia, cursive;
}

.mock-topbar-icons {
  display: flex;
  gap: 14px;
  font-size: 20px;
  color: #262626;
}

/* Stories */
.mock-story-bar {
  display: flex;
  gap: 12px;
  padding: 8px 12px;
  border-bottom: 1px solid #efefef;
  overflow: hidden;
}

.mock-story-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
}

.mock-story-item span {
  font-size: 9px;
  color: #262626;
  max-width: 44px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.mock-story-ring {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: linear-gradient(45deg, #f09433, #e6683c, #dc2743, #cc2366, #bc1888);
  padding: 2px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.mock-story-avatar {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  border: 2px solid #fff;
}

.s1 { background: #b2c9e3; }
.s2 { background: #e3c4b2; }
.s3 { background: #b2e3c7; }
.s4 { background: #e3ddb2; }

/* Post */
.mock-post {
  display: flex;
  flex-direction: column;
}

.mock-post-header {
  display: flex;
  align-items: center;
  gap: 9px;
  padding: 8px 10px;
}

.mock-post-avatar {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  flex-shrink: 0;
}

.pa1 { background: linear-gradient(135deg, #667eea 0%, #764ba2 100%); }
.pa3 { background: linear-gradient(135deg, #f7971e 0%, #ffd200 100%); }

.mock-post-name {
  width: 70px;
  height: 9px;
  background: #e0e0e0;
  border-radius: 4px;
  margin-bottom: 4px;
}

.mock-post-location {
  width: 50px;
  height: 7px;
  background: #efefef;
  border-radius: 4px;
}

.mock-more {
  margin-left: auto;
  color: #8e8e8e;
  font-size: 14px;
}

.mock-image {
  width: 100%;
  height: 210px;
}

.mi1 { background: linear-gradient(135deg, #667eea 0%, #764ba2 100%); }
.mi2 { background: linear-gradient(135deg, #f7971e 0%, #ffd200 100%); }

.mock-actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 8px 12px 4px;
  font-size: 20px;
  color: #262626;
}

.mock-left-actions {
  display: flex;
  gap: 14px;
}

.mock-likes-row {
  padding: 0 12px 4px;
}

.mock-likes-bar {
  width: 80px;
  height: 9px;
  background: #e0e0e0;
  border-radius: 4px;
}

.mock-caption-row {
  padding: 0 12px 8px;
}

.mock-caption {
  width: 140px;
  height: 8px;
  background: #efefef;
  border-radius: 4px;
}

/* ===== EXPLORE ===== */
.mock-search-bar {
  padding: 6px 10px;
  background: #fff;
}

.mock-search-input {
  display: flex;
  align-items: center;
  gap: 6px;
  background: #efefef;
  border-radius: 8px;
  padding: 7px 10px;
  color: #8e8e8e;
  font-size: 12px;
}

.mock-explore-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr;
  grid-auto-rows: 72px;
  gap: 2px;
  overflow: hidden;
}

.ex-cell { background: #e0e0e0; }
.ex-cell.big { grid-row: span 2; }
.ex-col { display: contents; }
.ec1 { background: linear-gradient(135deg, #a1c4fd, #c2e9fb); }
.ec2 { background: linear-gradient(135deg, #ffecd2, #fcb69f); }
.ec3 { background: linear-gradient(135deg, #a18cd1, #fbc2eb); }
.ec4 { background: linear-gradient(135deg, #84fab0, #8fd3f4); }
.ec5 { background: linear-gradient(135deg, #fddb92, #d1fdff); }
.ec6 { background: linear-gradient(135deg, #f6d365, #fda085); }
.ec7 { background: linear-gradient(135deg, #a1c4fd, #c2e9fb); }
.ec8 { background: linear-gradient(135deg, #fccb90, #d57eeb); }

/* ===== REEL ===== */
.mock-reel {
  position: relative;
  width: 100%;
  height: 100%;
}

.reel-bg {
  position: absolute;
  inset: 0;
  background: linear-gradient(160deg, #1a1a2e 0%, #16213e 40%, #0f3460 100%);
}

.reel-overlay {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: 32px 10px 14px;
}

.reel-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  color: #fff;
  font-weight: 700;
  font-size: 15px;
}

.reel-icon { font-size: 18px; }

.reel-side-actions {
  position: absolute;
  right: 10px;
  bottom: 80px;
  display: flex;
  flex-direction: column;
  gap: 18px;
  align-items: center;
  color: #fff;
}

.reel-action {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
  font-size: 20px;
}

.reel-action span {
  font-size: 10px;
  font-weight: 600;
}

.reel-bottom {
  display: flex;
  flex-direction: column;
  gap: 6px;
  padding-right: 44px;
}

.reel-user-info {
  display: flex;
  align-items: center;
  gap: 8px;
  color: #fff;
  font-size: 12px;
  font-weight: 600;
}

.reel-follow {
  background: none;
  border: 1px solid #fff;
  border-radius: 6px;
  color: #fff;
  font-size: 11px;
  font-weight: 600;
  padding: 2px 10px;
  cursor: pointer;
}

.reel-desc {
  width: 120px;
  height: 8px;
  background: rgba(255,255,255,0.3);
  border-radius: 4px;
}

.reel-music {
  display: flex;
  align-items: center;
  gap: 6px;
  color: rgba(255,255,255,0.8);
  font-size: 11px;
}

.reel-music-bar {
  width: 80px;
  height: 7px;
  background: rgba(255,255,255,0.3);
  border-radius: 4px;
}

/* ===== FORM SECTION ===== */
.form-section {
  display: flex;
  flex-direction: column;
  gap: 10px;
  width: 350px;
  flex-shrink: 0;
}

/* ===== CARD ===== */
.card {
  background: #fff;
  border: 1px solid #dbdbdb;
  border-radius: 2px;
  padding: 40px 40px 22px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
}

.signup-card {
  padding: 20px 40px;
}

/* ===== LOGO ===== */
.logo {
  margin-bottom: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
}

.logo-text {
  font-family: 'Billabong', cursive;
  font-size: 38px;
  font-weight: 400;
  color: #262626;
  line-height: 1;
  letter-spacing: 0.5px;
}

/* ===== INPUTS (floating label) ===== */
form {
  width: 100%;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.input-group {
  position: relative;
  width: 100%;
}

.input-group input {
  width: 100%;
  height: 44px;
  padding: 14px 12px 2px;
  background: #fafafa;
  border: 1px solid #dbdbdb;
  border-radius: 3px;
  font-size: 12px;
  font-family: inherit;
  color: #262626;
  outline: none;
  transition: border-color 0.15s;
}

.input-group input:focus {
  border-color: #a8a8a8;
}

/* Floating label */
.input-group label {
  position: absolute;
  left: 12px;
  top: 50%;
  transform: translateY(-50%);
  font-size: 12px;
  color: #8e8e8e;
  pointer-events: none;
  transition: top 0.1s, font-size 0.1s, color 0.1s;
}

.input-group input:focus ~ label,
.input-group input:not(:placeholder-shown) ~ label {
  top: 8px;
  font-size: 9px;
  color: #8e8e8e;
  transform: none;
}

/* Mot de passe */
.password-group input {
  padding-right: 64px;
}

.toggle-password {
  position: absolute;
  right: 10px;
  top: 50%;
  transform: translateY(-50%);
  background: none;
  border: none;
  cursor: pointer;
  font-size: 14px;
  font-weight: 700;
  font-family: inherit;
  color: #262626;
  transition: color 0.15s;
}

.toggle-password:hover {
  color: #8e8e8e;
}

/* ===== BOUTON CONNEXION ===== */
.btn-login {
  width: 100%;
  height: 34px;
  margin-top: 6px;
  background: #0095f6;
  color: #fff;
  border: none;
  border-radius: 8px;
  font-size: 14px;
  font-weight: 600;
  font-family: inherit;
  cursor: pointer;
  transition: background 0.15s;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
}

.btn-login:hover:not(:disabled) {
  background: #0086e0;
}

.btn-login:active:not(:disabled) {
  background: #0077c9;
}

.btn-login:disabled {
  opacity: 0.5;
  cursor: default;
}

/* ===== SÉPARATEUR ===== */
.divider {
  display: flex;
  align-items: center;
  width: 100%;
  gap: 18px;
  margin: 4px 0;
}

.line {
  flex: 1;
  height: 1px;
  background: #dbdbdb;
}

.or-text {
  font-size: 13px;
  font-weight: 600;
  color: #8e8e8e;
  letter-spacing: 1px;
}

/* ===== BOUTON FACEBOOK ===== */
.btn-facebook {
  background: none;
  border: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 8px;
  color: #385185;
  font-size: 14px;
  font-weight: 600;
  font-family: inherit;
  transition: color 0.15s;
}

.btn-facebook:hover {
  color: #1877f2;
}

/* ===== MOT DE PASSE OUBLIÉ ===== */
.forgot {
  font-size: 12px;
  color: #00376b;
  text-decoration: none;
  margin-top: 6px;
}

.forgot:hover {
  color: #262626;
}

/* ===== INSCRIPTION ===== */
.signup-card p {
  font-size: 14px;
  color: #262626;
}

.signup-card a {
  color: #0095f6;
  font-weight: 600;
  text-decoration: none;
}

.signup-card a:hover {
  text-decoration: underline;
}

/* ===== TÉLÉCHARGER L'APP ===== */
.get-app {
  text-align: center;
  padding: 12px 0 6px;
}

.get-app p {
  font-size: 14px;
  color: #262626;
  margin-bottom: 12px;
}

.app-badges {
  display: flex;
  justify-content: center;
  gap: 8px;
}

.badge-link img {
  height: 40px;
  display: block;
}

/* Le badge Google Play a des marges intégrées, on compense */
.badge-link img[alt="Disponible sur Google Play"] {
  height: 58px;
  margin: -9px 0;
}

/* ===== FOOTER ===== */
footer {
  width: 100%;
  padding: 20px 20px 40px;
  text-align: center;
}

.footer-links {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 4px 16px;
  margin-bottom: 16px;
}

.footer-links a {
  font-size: 12px;
  color: #8e8e8e;
  text-decoration: none;
}

.footer-links a:hover {
  text-decoration: underline;
}

.footer-bottom {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 16px;
  font-size: 12px;
  color: #8e8e8e;
}

.footer-bottom select {
  background: none;
  border: none;
  font-size: 12px;
  color: #8e8e8e;
  cursor: pointer;
  font-family: inherit;
}

/* ===== BANNIÈRE AVERTISSEMENT ===== */
.notice-banner {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  background: #fff8e1;
  border: 1px solid #ffe082;
  border-radius: 8px;
  padding: 12px 14px;
  font-size: 12px;
  color: #5d4037;
  line-height: 1.5;
  position: relative;
}

.notice-icon {
  color: #f9a825;
  font-size: 16px;
  flex-shrink: 0;
  margin-top: 1px;
}

.notice-text {
  flex: 1;
}

.notice-close {
  background: none;
  border: none;
  cursor: pointer;
  color: #aaa;
  font-size: 14px;
  padding: 0;
  flex-shrink: 0;
  line-height: 1;
}

.notice-close:hover { color: #555; }

/* ===== TOAST ===== */
.toast {
  position: fixed;
  bottom: 32px;
  left: 50%;
  transform: translateX(-50%) translateY(20px);
  background: #262626;
  color: #fff;
  padding: 12px 24px;
  border-radius: 8px;
  font-size: 14px;
  opacity: 0;
  transition: opacity 0.3s, transform 0.3s;
  z-index: 9999;
  white-space: nowrap;
  box-shadow: 0 4px 16px rgba(0,0,0,0.2);
}

.toast.toast-error { background: #e53935; }

.toast.toast-visible {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
}

/* ===== RESPONSIVE ===== */
@media (max-width: 800px) {
  .phone-mockup { display: none; }

  .form-section {
    width: 100%;
    max-width: 350px;
  }
}

@media (max-width: 420px) {
  .card {
    border: none;
    background: transparent;
    padding: 24px 16px;
  }

  .signup-card {
    border: none;
    background: transparent;
  }
}
