/* יום הולדת 39 לדנה - עיצוב */

:root {
  --bg: #fdf2f8;
  --bg-gradient: linear-gradient(180deg, #fdf2f8 0%, #fce7f3 50%, #fbcfe8 100%);
  --card: #ffffff;
  --text: #1f2937;
  --text-muted: #6b7280;
  --primary: #ec4899;
  --primary-dark: #be185d;
  --primary-light: #fce7f3;
  --accent: #f59e0b;
  --success: #10b981;
  --error: #ef4444;
  --border: #e5e7eb;
  --shadow: 0 10px 30px rgba(236, 72, 153, 0.12);
  --shadow-lg: 0 20px 50px rgba(236, 72, 153, 0.2);
  --radius: 16px;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  -webkit-text-size-adjust: 100%;
}

body {
  font-family: 'Heebo', -apple-system, BlinkMacSystemFont, sans-serif;
  background: var(--bg-gradient);
  background-attachment: fixed;
  color: var(--text);
  min-height: 100vh;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

.container {
  max-width: 600px;
  margin: 0 auto;
  padding: 24px 16px 48px;
}

/* Hero */
.hero {
  text-align: center;
  padding: 32px 16px 24px;
}

.confetti {
  font-size: 32px;
  letter-spacing: 8px;
  margin-bottom: 16px;
  animation: bounce 2s ease-in-out infinite;
}

@keyframes bounce {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-8px); }
}

.hero h1 {
  font-size: clamp(28px, 7vw, 42px);
  font-weight: 900;
  color: var(--primary-dark);
  margin-bottom: 16px;
  line-height: 1.2;
}

.hero .heart {
  display: inline-block;
  animation: pulse 1.5s ease-in-out infinite;
}

@keyframes pulse {
  0%, 100% { transform: scale(1); }
  50% { transform: scale(1.15); }
}

.subtitle {
  font-size: 17px;
  color: var(--text);
  max-width: 480px;
  margin: 0 auto 16px;
}

.secret {
  display: inline-block;
  background: var(--accent);
  color: #fff;
  padding: 6px 16px;
  border-radius: 999px;
  font-weight: 700;
  font-size: 14px;
  box-shadow: var(--shadow);
}

/* Cards */
.card {
  background: var(--card);
  border-radius: var(--radius);
  padding: 24px;
  margin-bottom: 20px;
  box-shadow: var(--shadow);
}

.card h2 {
  font-size: 22px;
  font-weight: 800;
  color: var(--primary-dark);
  margin-bottom: 16px;
}

/* Steps */
.steps {
  list-style: none;
  counter-reset: step;
}

.steps li {
  position: relative;
  padding-right: 48px;
  padding-bottom: 12px;
  counter-increment: step;
}

.steps li::before {
  content: counter(step);
  position: absolute;
  right: 0;
  top: 0;
  width: 32px;
  height: 32px;
  background: var(--primary);
  color: #fff;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 16px;
}

.tips {
  margin-top: 16px;
  padding: 14px;
  background: var(--primary-light);
  border-radius: 12px;
}

.tips summary {
  font-weight: 700;
  color: var(--primary-dark);
  cursor: pointer;
  user-select: none;
}

.tips ul {
  margin: 12px 0 0;
  padding-right: 20px;
}

.tips li {
  margin-bottom: 6px;
}

/* Search */
.hint {
  color: var(--text-muted);
  font-size: 14px;
  margin-bottom: 8px;
}

#search {
  width: 100%;
  padding: 14px 16px;
  border: 2px solid var(--border);
  border-radius: 12px;
  font-size: 16px;
  font-family: inherit;
  background: #fff;
  transition: border-color 0.2s, box-shadow 0.2s;
}

#search:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(236, 72, 153, 0.15);
}

/* Names list */
.status {
  text-align: center;
  padding: 16px;
  color: var(--text-muted);
  font-size: 14px;
}

.names-list {
  list-style: none;
  margin-top: 16px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

@media (min-width: 480px) {
  .names-list {
    grid-template-columns: 1fr 1fr 1fr;
  }
}

.name-item {
  padding: 14px 12px;
  text-align: center;
  background: #fff;
  border: 2px solid var(--border);
  border-radius: 12px;
  cursor: pointer;
  font-weight: 500;
  font-size: 15px;
  transition: all 0.15s ease;
  user-select: none;
}

.name-item:hover, .name-item:focus {
  border-color: var(--primary);
  background: var(--primary-light);
  transform: translateY(-2px);
  outline: none;
}

.name-item.taken {
  background: #f3f4f6;
  color: #9ca3af;
  cursor: not-allowed;
  text-decoration: line-through;
  transform: none;
  border-color: var(--border);
}

.name-item.taken:hover {
  border-color: var(--border);
  background: #f3f4f6;
}

.name-item.taken::after {
  content: ' ✓';
  color: var(--success);
  text-decoration: none;
  font-weight: 700;
}

/* Upload area */
.upload-area {
  text-align: center;
}

.selected {
  font-size: 17px;
  margin-bottom: 20px;
  line-height: 1.7;
}

.upload-buttons {
  display: flex;
  flex-direction: column;
  gap: 10px;
  max-width: 360px;
  margin: 0 auto;
}

.file-label {
  display: block;
  padding: 18px 24px;
  background: var(--primary-light);
  color: var(--primary-dark);
  border: 2px dashed var(--primary);
  border-radius: 12px;
  font-weight: 700;
  font-size: 16px;
  cursor: pointer;
  transition: all 0.15s;
  width: 100%;
  text-align: center;
}

.file-label-camera {
  background: var(--primary);
  color: #fff;
  border-style: solid;
}

.file-label-camera:hover {
  background: var(--primary-dark);
}

.file-label-gallery:hover {
  background: var(--primary);
  color: #fff;
}

.file-info {
  margin-top: 14px;
  padding: 12px;
  background: var(--primary-light);
  border-radius: 10px;
  font-size: 14px;
  color: var(--text);
}

.upload-btn {
  display: block;
  width: 100%;
  max-width: 360px;
  margin: 18px auto 12px;
  padding: 16px;
  background: var(--primary);
  color: #fff;
  border: none;
  border-radius: 12px;
  font-size: 17px;
  font-weight: 700;
  font-family: inherit;
  cursor: pointer;
  transition: background 0.15s, transform 0.05s;
}

.upload-btn:hover:not(:disabled) {
  background: var(--primary-dark);
}

.upload-btn:active:not(:disabled) {
  transform: scale(0.98);
}

.upload-btn:disabled {
  background: #d1d5db;
  cursor: not-allowed;
}

.cancel-btn {
  background: transparent;
  border: none;
  color: var(--text-muted);
  font-size: 14px;
  cursor: pointer;
  font-family: inherit;
  padding: 8px;
  text-decoration: underline;
}

.cancel-btn:hover {
  color: var(--primary-dark);
}

/* Progress */
.progress-wrap {
  margin-top: 20px;
}

.progress-bar {
  width: 100%;
  height: 12px;
  background: var(--primary-light);
  border-radius: 999px;
  overflow: hidden;
}

.progress-fill {
  height: 100%;
  width: 0%;
  background: linear-gradient(90deg, var(--primary), var(--accent));
  border-radius: 999px;
  transition: width 0.2s ease;
}

.progress-text {
  margin-top: 8px;
  font-size: 14px;
  color: var(--text-muted);
}

/* Success */
.success {
  text-align: center;
  padding: 24px 0;
}

.success-icon {
  font-size: 64px;
  margin-bottom: 12px;
  animation: pop 0.5s ease;
}

@keyframes pop {
  0% { transform: scale(0); }
  60% { transform: scale(1.2); }
  100% { transform: scale(1); }
}

.success h2 {
  color: var(--success);
  margin-bottom: 12px;
}

.success p {
  font-size: 17px;
  margin-bottom: 14px;
}

.success .reminder {
  display: inline-block;
  background: var(--accent);
  color: #fff;
  padding: 8px 18px;
  border-radius: 999px;
  font-weight: 700;
  font-size: 14px;
  margin-top: 8px;
}

/* Error */
.error {
  background: #fee2e2;
  color: var(--error);
  padding: 14px;
  border-radius: 12px;
  font-weight: 500;
  margin-top: 16px;
  text-align: center;
}

/* Footer */
footer {
  text-align: center;
  padding: 24px 16px;
  color: var(--text-muted);
  font-size: 13px;
}

/* Mobile-specific */
@media (max-width: 380px) {
  .container {
    padding: 16px 12px 32px;
  }
  .card {
    padding: 18px;
  }
}
