@import url('https://fonts.googleapis.com/css2?family=Assistant:wght@300;400;600;700;800&display=swap');

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  font-family: 'Assistant', sans-serif;
}

body {
  background: radial-gradient(circle at 50% 10%, #1e293b 0%, #0f172a 100%);
  color: #f8fafc;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

.main-container {
  max-width: 520px;
  width: 100%;
  margin: 0 auto;
  padding: 24px 16px 12px;
  display: flex;
  flex-direction: column;
  gap: 16px;
  flex: 1;
}

.card {
  background: rgba(30, 41, 59, 0.7);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 24px;
  padding: 20px;
  box-shadow: 0 16px 32px rgba(0, 0, 0, 0.35);
}

.hero-card {
  text-align: center;
  overflow: hidden;
}

.prayer-tag {
  display: inline-block;
  background: rgba(59, 130, 246, 0.2);
  color: #93c5fd;
  border: 1px solid rgba(59, 130, 246, 0.3);
  padding: 4px 14px;
  border-radius: 999px;
  font-size: 0.8rem;
  font-weight: 700;
  margin-bottom: 12px;
}

.hero-card h1 {
  font-size: 1.35rem;
  font-weight: 700;
  color: #cbd5e1;
}

.hero-card h2 {
  font-size: 2.1rem;
  font-weight: 800;
  color: #60a5fa;
  margin: 2px 0 6px;
}

.subtitle {
  font-size: 0.85rem;
  color: #94a3b8;
}

.carousel-3d-stage {
  perspective: 1000px;
  width: 100%;
  height: 250px;
  margin-top: 16px;
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
}

.carousel-3d-track {
  position: relative;
  width: 100%;
  height: 100%;
  transform-style: preserve-3d;
  display: flex;
  align-items: center;
  justify-content: center;
}

.carousel-3d-card {
  position: absolute;
  width: 190px;
  height: 230px;
  border-radius: 16px;
  overflow: hidden;
  box-shadow: 0 15px 30px rgba(0, 0, 0, 0.5);
  border: 2px solid rgba(255, 255, 255, 0.15);
  cursor: pointer;
  transition: transform 0.6s cubic-bezier(0.25, 1, 0.5, 1), opacity 0.6s ease, filter 0.6s ease;
  user-select: none;
}

.carousel-3d-card img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  pointer-events: none;
}

.carousel-3d-card.pos-center {
  transform: translateX(0) scale(1) translateZ(0);
  opacity: 1;
  filter: brightness(1);
  z-index: 10;
  border-color: #60a5fa;
}

.carousel-3d-card.pos-left {
  transform: translateX(-120px) scale(0.8) rotateY(25deg);
  opacity: 0.6;
  filter: brightness(0.65);
  z-index: 5;
}

.carousel-3d-card.pos-right {
  transform: translateX(120px) scale(0.8) rotateY(-25deg);
  opacity: 0.6;
  filter: brightness(0.65);
  z-index: 5;
}

.carousel-3d-card.pos-hidden {
  transform: translateX(0) scale(0.5);
  opacity: 0;
  pointer-events: none;
  z-index: 1;
}

/* סידור שני הכפתורים באותה שורה */
.action-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 12px;
  width: 100%;
}

.action-btn {
  border-radius: 20px;
  padding: 16px 12px;
  color: #ffffff;
  text-decoration: none;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.25);
  transition: transform 0.2s;
  border: 1px solid rgba(255, 255, 255, 0.15);
  min-width: 0;
}

.action-btn:hover {
  transform: translateY(-2px);
}

.tehilim-btn {
  background: linear-gradient(135deg, #2563eb, #1e40af);
}

.zoom-btn {
  background: linear-gradient(135deg, #0284c7, #0369a1);
}

.action-icon {
  font-size: 1.8rem;
  margin-bottom: 4px;
}

.action-title {
  font-size: 1rem;
  font-weight: 700;
  white-space: nowrap;
}

.action-sub {
  font-size: 0.75rem;
  opacity: 0.85;
  margin-top: 4px;
}

.zoom-badge {
  background: rgba(255, 255, 255, 0.2);
  padding: 2px 8px;
  border-radius: 999px;
  display: inline-block;
  font-weight: 600;
}

.form-card h3 {
  font-size: 1.15rem;
  font-weight: 700;
  margin-bottom: 12px;
}

.app-input {
  width: 100%;
  padding: 12px 14px;
  border-radius: 12px;
  border: 1px solid rgba(255, 255, 255, 0.15);
  background: rgba(15, 23, 42, 0.7);
  color: #f8fafc;
  font-size: 0.9rem;
  outline: none;
  margin-bottom: 10px;
}

.app-input:focus {
  border-color: #3b82f6;
}

.submit-action-btn {
  width: 100%;
  padding: 12px;
  border-radius: 12px;
  border: none;
  background: #3b82f6;
  color: #ffffff;
  font-weight: 700;
  font-size: 0.95rem;
  cursor: pointer;
  transition: background 0.2s;
}

.submit-action-btn:hover {
  background: #2563eb;
}

.feed-header {
  font-size: 0.8rem;
  font-weight: 700;
  color: #64748b;
  margin: 16px 0 8px;
  text-transform: uppercase;
}

.feed-box {
  display: flex;
  flex-direction: column;
  gap: 8px;
  max-height: 180px;
  overflow-y: auto;
}

.feed-row {
  background: rgba(15, 23, 42, 0.5);
  border: 1px solid rgba(255, 255, 255, 0.05);
  border-radius: 10px;
  padding: 10px 12px;
  font-size: 0.85rem;
  display: flex;
  justify-content: space-between;
  align-items: baseline;
}

.feed-date {
  font-size: 0.7rem;
  color: #64748b;
  white-space: nowrap;
  margin-right: 8px;
}

.app-footer {
  margin-top: auto;
  padding: 24px 16px;
  text-align: center;
}

.credit-line {
  font-size: 0.8rem;
  font-style: italic;
  color: #94a3b8;
  letter-spacing: 0.2px;
}

.author-tag {
  color: #60a5fa;
  font-weight: 700;
  text-decoration: underline;
}

.chat-launcher {
  position: fixed;
  bottom: 20px;
  left: 20px;
  z-index: 90;
}

.chat-bubble-btn {
  width: 54px;
  height: 54px;
  border-radius: 50%;
  background: linear-gradient(135deg, #2563eb, #6366f1);
  color: #ffffff;
  border: none;
  font-size: 1.5rem;
  box-shadow: 0 8px 24px rgba(37, 99, 235, 0.4);
  cursor: pointer;
  transition: transform 0.2s;
}

.chat-bubble-btn:hover {
  transform: scale(1.08);
}

.chat-popup {
  position: fixed;
  bottom: 84px;
  left: 20px;
  width: 320px;
  height: 380px;
  background: #1e293b;
  border-radius: 20px;
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.5);
  display: none;
  flex-direction: column;
  z-index: 100;
  border: 1px solid rgba(255, 255, 255, 0.1);
  overflow: hidden;
}

.chat-popup.active {
  display: flex;
}

.chat-topbar {
  background: #0f172a;
  padding: 12px 16px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  font-size: 0.9rem;
  font-weight: 700;
}

.chat-close-btn {
  background: transparent;
  border: none;
  font-size: 1.2rem;
  cursor: pointer;
  color: #94a3b8;
}

.chat-feed-area {
  flex: 1;
  padding: 12px;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 8px;
  font-size: 0.85rem;
}

.bubble-ai {
  background: #334155;
  color: #f8fafc;
  padding: 8px 12px;
  border-radius: 12px 12px 0 12px;
  align-self: flex-start;
  max-width: 85%;
}

.bubble-me {
  background: #2563eb;
  color: #ffffff;
  padding: 8px 12px;
  border-radius: 12px 12px 12px 0;
  align-self: flex-end;
  max-width: 85%;
}

.chat-input-bar {
  padding: 8px;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  display: flex;
  gap: 6px;
  background: #0f172a;
}

.chat-input-bar input {
  flex: 1;
  border: 1px solid rgba(255, 255, 255, 0.15);
  background: #1e293b;
  color: #f8fafc;
  padding: 8px 12px;
  border-radius: 10px;
  font-size: 0.85rem;
  outline: none;
}

.chat-input-bar button {
  background: #3b82f6;
  color: #ffffff;
  border: none;
  padding: 8px 14px;
  border-radius: 10px;
  font-size: 0.85rem;
  font-weight: 700;
  cursor: pointer;
}

/* התאמות למסכים קטנים: שומר על שורה אחת עם מרווחים מותאמים */
@media (max-width: 440px) {
  .action-grid {
    gap: 8px;
  }

  .action-btn {
    padding: 12px 8px;
  }

  .action-title {
    font-size: 0.9rem;
  }

  .action-sub {
    font-size: 0.7rem;
  }

  .action-icon {
    font-size: 1.5rem;
  }
}