/* ==========================================================================
   Index Page - Redesign (Paper Collage Concept)
   Depends on: redesign-shared.css (loaded first)
   ========================================================================== */

/* =============================================
   HERO
   ============================================= */
.rd-hero {
  position: relative;
  min-height: 100vh;
  background: linear-gradient(180deg, #daedf9 0%, #c5e4f7 40%, #e0f0fa 100%);
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 6rem 2rem 4rem;
}

/* Cloud cutouts */
.rd-cloud-cutout {
  position: absolute;
  border-radius: 50%;
  background: #fff;
  opacity: 0.7;
}

.rd-cloud-cutout-1 {
  width: 300px; height: 120px;
  top: 8%; left: -40px;
  border-radius: 60px;
  box-shadow: 40px -20px 0 #fff, 80px 0 0 #fff;
}

.rd-cloud-cutout-2 {
  width: 200px; height: 80px;
  top: 15%; right: 5%;
  border-radius: 40px;
  box-shadow: 30px -15px 0 #fff, 60px 0 0 #fff;
  opacity: 0.5;
}

.rd-cloud-cutout-3 {
  width: 250px; height: 100px;
  bottom: 30%; left: 3%;
  border-radius: 50px;
  box-shadow: 35px -18px 0 #fff, 70px 0 0 #fff;
  opacity: 0.4;
}

/* Torn paper edge (index uses taller version) */
.rd-hero .rd-torn-edge { height: 80px; }

.rd-hero-content {
  position: relative;
  z-index: 2;
  text-align: center;
  width: 100%;
  max-width: 900px;
}

.rd-hero-title {
  font-family: 'Playfair Display', serif;
  font-size: clamp(2.8rem, 7vw, 5rem);
  font-weight: 800;
  color: #1a3a5c;
  line-height: 1.1;
  margin-bottom: 1.5rem;
}

.rd-hero-subtitle {
  font-size: clamp(1.05rem, 2vw, 1.3rem);
  color: #5a7a9a;
  max-width: 520px;
  margin: 0 auto 2.5rem;
  font-weight: 400;
  line-height: 1.6;
}

.rd-hero-actions {
  display: flex;
  gap: 1rem;
  justify-content: center;
  flex-wrap: wrap;
}

/* Screenshot wrap */
.rd-screenshot-wrap {
  position: relative;
  z-index: 2;
  margin-top: 3rem;
  perspective: 800px;
}

.rd-screenshot {
  width: 100%;
  max-width: 750px;
  margin: 0 auto;
  border-radius: 12px;
  box-shadow:
    0 20px 60px rgba(0,80,160,0.15),
    0 1px 3px rgba(0,0,0,0.08);
  transform: rotateX(2deg);
  transition: transform 0.4s;
}

.rd-screenshot:hover { transform: rotateX(0deg); }

/* Collage notes */
.rd-collage-note {
  position: absolute;
  z-index: 3;
  padding: 1.2rem 1.5rem;
  border-radius: 2px;
  font-size: 0.85rem;
  line-height: 1.5;
  white-space: nowrap;
  box-shadow: 2px 3px 12px rgba(0,0,0,0.1);
  transform: rotate(var(--rotate, 3deg));
}

.rd-note-yellow {
  background: #fef3c7;
  color: #92400e;
  --rotate: -4deg;
  top: -20px; right: -30px;
}

.rd-note-blue {
  background: #dbeafe;
  color: #1e40af;
  --rotate: 5deg;
  bottom: 40px; left: -40px;
}

.rd-note-pink {
  background: #fce7f3;
  color: #9d174d;
  --rotate: -2deg;
  bottom: -10px; right: 60px;
}

/* =============================================
   FEATURES
   ============================================= */
.rd-features {
  padding: 5rem 2rem;
  background: #f4f8fc;
}

.rd-section-label {
  text-align: center;
  font-size: 0.8rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: #3bb9ff;
  margin-bottom: 0.75rem;
}

.rd-section-title {
  text-align: center;
  font-family: 'Playfair Display', serif;
  font-size: clamp(1.8rem, 4vw, 2.8rem);
  font-weight: 800;
  color: #1a3a5c;
  margin-bottom: 3rem;
}

.rd-feature-cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 2rem;
  max-width: 1000px;
  margin: 0 auto;
}

.rd-feature-card {
  background: #fff;
  border-radius: 16px;
  overflow: hidden;
  box-shadow: 0 4px 20px rgba(0,80,160,0.06);
  transition: transform 0.3s, box-shadow 0.3s;
  cursor: pointer;
}

.rd-feature-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 12px 36px rgba(0,80,160,0.12);
}

.rd-feature-card-img {
  width: 100%;
  height: 200px;
  object-fit: cover;
  object-position: top;
}

.rd-feature-card-body {
  padding: 1.5rem;
}

.rd-feature-card-tag {
  display: inline-block;
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  padding: 0.25rem 0.7rem;
  border-radius: 4px;
  margin-bottom: 0.6rem;
}

.rd-tag-green { background: #d1fae5; color: #065f46; }
.rd-tag-purple { background: #ede9fe; color: #5b21b6; }
.rd-tag-orange { background: #ffedd5; color: #9a3412; }

.rd-feature-card-body h3 {
  font-family: 'Playfair Display', serif;
  font-size: 1.3rem;
  font-weight: 700;
  color: #1a3a5c;
  margin-bottom: 0.5rem;
}

.rd-feature-card-body p {
  font-size: 0.9rem;
  color: #5a7a9a;
  line-height: 1.6;
}

/* =============================================
   CLOUD BREAK - Login section
   ============================================= */
.rd-cloud-break {
  position: relative;
  padding: 4rem 2rem;
  background: linear-gradient(180deg, #f4f8fc 0%, #daedf9 50%, #f4f8fc 100%);
  text-align: center;
  overflow: hidden;
}

.rd-cloud-break-bg {
  position: absolute;
  inset: 0;
  background: url('../images/clouds.png') no-repeat center center;
  background-size: cover;
  opacity: 0.25;
}

.rd-cloud-break-content {
  position: relative;
  z-index: 1;
}

.rd-cloud-break h2 {
  font-family: 'Playfair Display', serif;
  font-size: clamp(1.5rem, 3.5vw, 2.2rem);
  color: #1a3a5c;
  margin-bottom: 0.5rem;
}

.rd-cloud-break p {
  font-size: 1.05rem;
  color: #5a7a9a;
  margin-bottom: 2rem;
}

.rd-inline-login {
  display: inline-flex;
  gap: 0.5rem;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  background: rgba(255,255,255,0.8);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  padding: 0.5rem;
  border-radius: 14px;
  box-shadow: 0 4px 20px rgba(0,80,160,0.08);
}

.rd-inline-login input {
  padding: 0.7rem 1rem;
  border: 1.5px solid #c5e4f7;
  border-radius: 10px;
  font-size: 0.9rem;
  font-family: inherit;
  width: 180px;
  outline: none;
  background: #fff;
  color: #1a3a5c;
}

.rd-inline-login input:focus { border-color: #3bb9ff; }
.rd-inline-login input::placeholder { color: #8bb8d8; }

.rd-inline-login .rd-btn {
  padding: 0.7rem 1.5rem;
  border-radius: 10px;
}

.rd-login-links {
  margin-top: 1rem;
  font-size: 0.85rem;
  color: #5a7a9a;
}

.rd-login-links a {
  color: #2a6cb8;
  font-weight: 500;
}

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

/* =============================================
   CTA
   ============================================= */
.rd-cta {
  padding: 5rem 2rem;
  text-align: center;
  background: #1a3a5c;
  position: relative;
  overflow: hidden;
}

.rd-cta::before {
  content: '';
  position: absolute;
  top: -60px;
  left: 50%;
  width: 600px;
  height: 200px;
  transform: translateX(-50%);
  border-radius: 50%;
  background: rgba(59,185,255,0.15);
}

.rd-cta h2 {
  font-family: 'Playfair Display', serif;
  font-size: clamp(2rem, 5vw, 3rem);
  color: #fff;
  margin-bottom: 1rem;
  position: relative;
}

.rd-cta p {
  color: rgba(255,255,255,0.6);
  font-size: 1.1rem;
  max-width: 480px;
  margin: 0 auto 2rem;
  position: relative;
}

/* =============================================
   LIGHTBOX
   ============================================= */
.rd-lightbox {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 200;
  background: rgba(10, 20, 35, 0.92);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  align-items: center;
  justify-content: center;
  flex-direction: column;
}

.rd-lightbox.active { display: flex; }

.rd-lightbox-img {
  max-width: min(90vw, 900px);
  max-height: 75vh;
  border-radius: 12px;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.4);
  object-fit: contain;
  transition: opacity 0.2s;
}

.rd-lightbox-close {
  position: absolute;
  top: 1.5rem;
  right: 1.5rem;
  background: none;
  border: none;
  color: rgba(255, 255, 255, 0.7);
  font-size: 2.5rem;
  cursor: pointer;
  line-height: 1;
  padding: 0.5rem;
  transition: color 0.2s;
}

.rd-lightbox-close:hover { color: #fff; }

.rd-lightbox-prev,
.rd-lightbox-next {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background: rgba(255, 255, 255, 0.1);
  border: none;
  color: rgba(255, 255, 255, 0.8);
  font-size: 2.5rem;
  cursor: pointer;
  width: 52px;
  height: 52px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.2s, color 0.2s;
}

.rd-lightbox-prev { left: 1.5rem; }
.rd-lightbox-next { right: 1.5rem; }

.rd-lightbox-prev:hover,
.rd-lightbox-next:hover {
  background: rgba(255, 255, 255, 0.2);
  color: #fff;
}

.rd-lightbox-caption {
  margin-top: 1.5rem;
  text-align: center;
  display: flex;
  gap: 1rem;
  align-items: center;
}

.rd-lightbox-title {
  font-family: 'Playfair Display', serif;
  font-size: 1.2rem;
  font-weight: 700;
  color: #fff;
}

.rd-lightbox-counter {
  font-size: 0.85rem;
  color: rgba(255, 255, 255, 0.5);
}

/* =============================================
   RESPONSIVE (index-specific)
   ============================================= */
@media (max-width: 768px) {
  .rd-collage-note { display: none; }
  .rd-feature-cards { grid-template-columns: 1fr; }
  .rd-inline-login { flex-direction: column; }
  .rd-inline-login input { width: 100%; }
  .rd-hero { padding: 5rem 1rem 3rem; }
  .rd-cloud-cutout { display: none; }
  .rd-lightbox-prev { left: 0.5rem; }
  .rd-lightbox-next { right: 0.5rem; }
  .rd-lightbox-prev,
  .rd-lightbox-next { width: 40px; height: 40px; font-size: 2rem; }
}
