/* ============================================
   LANDING PAGE - Lunaple EN
   ============================================ */

/* No tab bar on landing */
body.page-landing {
  padding-bottom: 0;
}

/* Landing uses common bg_main background */

/* --- Hero Section --- */
.hero {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  text-align: center;
  padding: calc(var(--header-height) + var(--space-2xl)) var(--space-md) var(--space-2xl);
  position: relative;
  overflow: hidden;
}


.hero-content {
  position: relative;
  z-index: 2;
  max-width: 420px;
  width: 100%;
  animation: fadeIn 800ms var(--ease-out);
}

/* Luna avatar in hero */
.hero-luna {
  width: 80px;
  height: 80px;
  border-radius: 50%;
  margin: 0 auto var(--space-lg);
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
}

.hero-luna::before {
  content: '';
  position: absolute;
  inset: -3px;
  border-radius: 50%;
  background: var(--gradient-luna);
  z-index: -1;
  animation: float 4s ease-in-out infinite;
}

.hero-luna-img {
  width: 100%;
  height: 100%;
  border-radius: 50%;
  object-fit: cover;
  border: 2px solid var(--bg-primary);
}

/* Luna placeholder when no image */
.hero-luna-placeholder {
  width: 100%;
  height: 100%;
  border-radius: 50%;
  background: var(--gradient-cta);
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-display);
  font-size: 2rem;
  color: #fff;
  border: 2px solid var(--bg-primary);
}

.hero-badge {
  margin-bottom: var(--space-md);
}

.hero h1 {
  margin-bottom: var(--space-md);
  animation: fadeInUp 600ms var(--ease-out) 200ms both;
}

.hero-subtitle {
  font-size: clamp(0.9375rem, 2.5vw, 1.0625rem);
  color: var(--text-secondary);
  line-height: 1.7;
  margin-bottom: var(--space-xl);
  animation: fadeInUp 600ms var(--ease-out) 400ms both;
}

/* --- Luna Chat Widget --- */
.luna-chat {
  width: 100%;
  max-width: 420px;
  margin: 0 auto;
  border-radius: var(--radius-xl);
  overflow: hidden;
  animation: fadeInUp 600ms var(--ease-out) 600ms both;
}

.luna-chat-header {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
  padding: var(--space-md) var(--space-lg);
  border-bottom: 1px solid var(--border-subtle);
}

.luna-chat-avatar {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: var(--gradient-cta);
  display: flex;
  align-items: center;
  justify-content: center;
  animation: lunaIdleBreathe 4.5s ease-in-out infinite;
}

/* Luna breathing animation */
@keyframes lunaIdleBreathe {
  0%, 100% { transform: scale(1); }
  50% { transform: scale(1.06); }
}

/* Luna thinking animation (when waiting for AI response) */
.luna-thinking .luna-chat-avatar {
  animation: lunaIdleBreathe 4.5s ease-in-out infinite, lunaThinking 1.2s ease-in-out infinite;
}

@keyframes lunaThinking {
  0%, 100% { box-shadow: 0 0 0 0 rgba(91, 168, 168, 0.3); }
  50% { box-shadow: 0 0 12px 4px rgba(91, 168, 168, 0.15); }
}

/* Message arrive spring animation */
.msg-luna .msg-bubble {
  animation: lunaMsgArrive 0.4s var(--ease-spring) both;
}

@keyframes lunaMsgArrive {
  from { opacity: 0; transform: translateY(8px) scale(0.95); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}

@media (prefers-reduced-motion: reduce) {
  .luna-chat-avatar { animation: none; }
  .msg-luna .msg-bubble { animation: none; }
  font-family: var(--font-display);
  font-size: 1.1rem;
  color: #fff;
  flex-shrink: 0;
}

.luna-chat-name {
  font-weight: 600;
  font-size: 0.9375rem;
}

.luna-chat-status {
  font-size: 0.75rem;
  color: #5DD47D;
  display: flex;
  align-items: center;
  gap: 4px;
}

.luna-chat-status::before {
  content: '';
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #5DD47D;
  display: inline-block;
}

.luna-chat-messages {
  padding: var(--space-lg);
  min-height: 200px;
  max-height: 320px;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: var(--space-md);
}

/* Message bubbles */
.msg {
  display: flex;
  gap: var(--space-sm);
  max-width: 85%;
  animation: fadeInUp 300ms var(--ease-out);
}

.msg-luna {
  align-self: flex-start;
}

.msg-user {
  align-self: flex-end;
  flex-direction: row-reverse;
}

.msg-avatar {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: var(--gradient-cta);
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-display);
  font-size: 0.8rem;
  color: #fff;
  flex-shrink: 0;
  margin-top: 2px;
}

.msg-bubble {
  padding: 10px 14px;
  border-radius: 16px;
  font-size: 0.9375rem;
  line-height: 1.5;
}

.msg-luna .msg-bubble {
  background: var(--bg-surface-2);
  border-bottom-left-radius: 4px;
  color: var(--text-primary);
}

.msg-user .msg-bubble {
  background: var(--gradient-cta);
  border-bottom-right-radius: 4px;
  color: #fff;
}

/* Typing indicator */
.msg-typing .msg-bubble {
  display: flex;
  gap: 4px;
  padding: 12px 18px;
}

.typing-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--text-muted);
  animation: typingBounce 1.4s ease-in-out infinite;
}

.typing-dot:nth-child(2) { animation-delay: 0.2s; }
.typing-dot:nth-child(3) { animation-delay: 0.4s; }

@keyframes typingBounce {
  0%, 60%, 100% { transform: translateY(0); opacity: 0.4; }
  30% { transform: translateY(-6px); opacity: 1; }
}

/* Quick action chips */
.luna-chat-chips {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-sm);
  padding: 0 var(--space-lg) var(--space-md);
}

.chip {
  font-family: var(--font-body);
  font-size: 0.8125rem;
  font-weight: 500;
  padding: 8px 14px;
  border-radius: var(--radius-full);
  background: var(--bg-surface-1);
  border: 1px solid var(--border-glass);
  color: var(--text-secondary);
  cursor: pointer;
  transition: all var(--duration-fast) var(--ease-out);
  white-space: nowrap;
}

.chip:hover {
  border-color: var(--color-primary);
  color: var(--color-primary);
  background: var(--color-primary-dim);
}

/* Input area */
.luna-chat-input {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
  padding: var(--space-md) var(--space-lg);
  border-top: 1px solid var(--border-subtle);
}

.luna-chat-input input {
  flex: 1;
  font-family: var(--font-body);
  font-size: 0.9375rem;
  color: var(--text-primary);
  background: var(--bg-surface-1);
  border: 1px solid var(--border-glass);
  border-radius: var(--radius-full);
  padding: 10px 16px;
  outline: none;
  transition: border-color var(--duration-fast) var(--ease-out);
}

.luna-chat-input input:focus {
  border-color: var(--color-primary);
}

.luna-chat-input input::placeholder {
  color: var(--text-muted);
}

.luna-send-btn {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: var(--gradient-cta);
  border: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all var(--duration-fast) var(--ease-out);
  flex-shrink: 0;
}

.luna-send-btn:hover {
  transform: scale(1.05);
  box-shadow: 0 0 16px rgba(184, 169, 212, 0.3);
}

.luna-send-btn svg {
  width: 18px;
  height: 18px;
  fill: #fff;
}

/* --- Services Section --- */
.services-section {
  padding: var(--space-3xl) var(--space-md);
  position: relative;
  z-index: 1;
}

.services-section h2 {
  text-align: center;
  margin-bottom: var(--space-sm);
}

.services-subtitle {
  text-align: center;
  color: var(--text-secondary);
  font-size: 0.9375rem;
  margin-bottom: var(--space-2xl);
}

.services-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--space-md);
  max-width: var(--content-max);
  margin: 0 auto;
}

.service-card {
  padding: var(--space-lg);
  text-align: center;
  cursor: pointer;
}

.service-card:hover {
  border-color: var(--border-hover);
}

.service-icon {
  width: 48px;
  height: 48px;
  border-radius: var(--radius-md);
  margin: 0 auto var(--space-md);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
}

.service-icon-tarot { background: var(--color-secondary-dim); }
.service-icon-dream { background: var(--color-teal-dim); }
.service-icon-astrology { background: var(--color-tertiary-dim); }

.service-card h3 {
  font-family: var(--font-body);
  font-size: 0.9375rem;
  font-weight: 600;
  margin-bottom: var(--space-xs);
}

.service-card p {
  font-size: 0.8125rem;
  color: var(--text-secondary);
  line-height: 1.5;
}

/* --- Features Section --- */
.features-section {
  padding: var(--space-3xl) var(--space-md);
  position: relative;
  z-index: 1;
}

.features-list {
  display: flex;
  flex-direction: column;
  gap: var(--space-lg);
  max-width: var(--content-max);
  margin: 0 auto;
}

.feature-item {
  display: flex;
  gap: var(--space-md);
  align-items: flex-start;
}

.feature-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--gradient-cta);
  margin-top: 8px;
  flex-shrink: 0;
}

.feature-text h3 {
  font-family: var(--font-body);
  font-size: 1rem;
  font-weight: 600;
  margin-bottom: 4px;
}

.feature-text p {
  font-size: 0.875rem;
  color: var(--text-secondary);
  line-height: 1.6;
}

/* --- CTA Section --- */
.cta-section {
  padding: var(--space-3xl) var(--space-md) var(--space-4xl);
  text-align: center;
  position: relative;
  z-index: 1;
}

.cta-card {
  max-width: 400px;
  margin: 0 auto;
  text-align: center;
}

.cta-card h2 {
  margin-bottom: var(--space-sm);
}

.cta-card p {
  color: var(--text-secondary);
  margin-bottom: var(--space-lg);
}

/* --- Footer --- */
.site-footer {
  padding: var(--space-2xl) var(--space-md);
  border-top: 1px solid var(--border-subtle);
  text-align: center;
  background: rgba(244, 249, 247, 0.95);
  position: relative;
  z-index: 1;
}

.footer-logo {
  font-family: var(--font-display);
  font-size: 1.25rem;
  background: var(--gradient-luna);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  margin-bottom: var(--space-sm);
}

.footer-tagline {
  font-size: 0.8125rem;
  color: var(--text-muted);
  margin-bottom: var(--space-lg);
}

.footer-links {
  display: flex;
  justify-content: center;
  gap: var(--space-lg);
  margin-bottom: var(--space-lg);
}

.footer-links a {
  font-size: 0.8125rem;
  color: var(--text-secondary);
}

.footer-copyright {
  font-size: 0.75rem;
  color: var(--text-muted);
}

/* --- Responsive --- */
@media (min-width: 640px) {
  .hero {
    padding-top: calc(var(--header-height) + var(--space-4xl));
  }

  .luna-chat {
    max-width: 460px;
  }

  .services-grid {
    max-width: 520px;
  }
}
