/* ===== VARIABLES ===== */
:root {
  --bg: #F9F7F4;
  --bg-alt: #FFFFFF;
  --text-primary: #1A1A1A;
  --text-secondary: #7A7068;
  --accent: #B8966E;
  --accent-light: #EDE0D0;
  --border: #E5E0D8;
  --font-heading: 'Cormorant Garamond', Georgia, serif;
  --font-body: 'Inter', system-ui, sans-serif;
  --transition: 0.3s ease;
}

/* Cursor: JS tarafından dinamik uygulanır (js/main.js → applyCursor) */

/* ===== CLICK HEARTS ===== */
.click-heart {
  position: fixed;
  pointer-events: none;
  z-index: 9999;
  line-height: 1;
  user-select: none;
  animation: clickHeartBurst var(--dur, 0.8s) ease-out forwards;
}

@keyframes clickHeartBurst {
  0% {
    opacity: 1;
    transform: translate(-50%, -50%) scale(0.2);
  }
  25% {
    opacity: 0.9;
    transform: translate(calc(-50% + var(--dx) * 0.25), calc(-50% + var(--dy) * 0.25)) scale(1.1);
  }
  100% {
    opacity: 0;
    transform: translate(calc(-50% + var(--dx)), calc(-50% + var(--dy))) scale(0.75);
  }
}

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

html {
  scroll-behavior: smooth;
  font-size: 16px;
}

body {
  font-family: var(--font-body);
  background: var(--bg);
  color: var(--text-primary);
  line-height: 1.6;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

img {
  display: block;
  max-width: 100%;
}

button {
  cursor: pointer;
  font-family: var(--font-body);
}

.hidden {
  display: none !important;
}

/* ===== COUNTDOWN SECTION ===== */
.countdown-section {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  background: var(--bg);
  position: relative;
  padding: 2rem;
}

.countdown-inner {
  text-align: center;
  max-width: 800px;
  width: 100%;
}

.countdown-label {
  font-family: var(--font-body);
  font-size: 0.75rem;
  font-weight: 500;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 1.25rem;
  opacity: 0;
  animation: fadeDown 1s ease 0.3s forwards;
}

.countdown-title {
  font-family: var(--font-heading);
  font-size: clamp(2.8rem, 7vw, 5.5rem);
  font-weight: 300;
  letter-spacing: 0.03em;
  color: var(--text-primary);
  margin-bottom: 3.5rem;
  font-style: italic;
  line-height: 1.1;
  opacity: 0;
  animation: fadeDown 1s ease 0.6s forwards;
}

.countdown-grid {
  display: flex;
  align-items: flex-end;
  justify-content: center;
  gap: 0;
  opacity: 0;
  animation: fadeUp 1s ease 0.9s forwards;
}

.countdown-block {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.75rem;
  padding: 0 2rem;
  position: relative;
}

.countdown-block::after {
  content: '';
  position: absolute;
  right: 0;
  bottom: 1.4rem;
  width: 1px;
  height: 3rem;
  background: var(--border);
}

.countdown-block:last-child::after {
  display: none;
}

.countdown-number {
  font-family: var(--font-heading);
  font-size: clamp(4rem, 10vw, 7rem);
  font-weight: 300;
  line-height: 1;
  color: var(--text-primary);
  letter-spacing: -0.03em;
  min-width: 2ch;
  display: inline-block;
  text-align: center;
}

.countdown-unit {
  font-family: var(--font-body);
  font-size: 0.65rem;
  font-weight: 500;
  letter-spacing: 0.25em;
  text-transform: uppercase;
  color: var(--text-secondary);
}

/* Countdown section — arka plan resmi */
.countdown-section.has-bg::before {
  content: '';
  position: absolute;
  inset: 0;
  background: rgba(249, 247, 244, 0.72);
  z-index: 0;
}

.countdown-section.has-bg .countdown-inner,
.countdown-section.has-bg .scroll-indicator {
  position: relative;
  z-index: 1;
}

/* Scroll Indicator */
.scroll-indicator {
  position: absolute;
  bottom: 2rem;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.6rem;
  color: var(--text-secondary);
  font-size: 0.65rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  opacity: 0;
  animation: fadeIn 1s ease 1.5s forwards;
}

.scroll-line {
  width: 1px;
  height: 36px;
  background: linear-gradient(to bottom, var(--accent), transparent);
  animation: scrollPulse 2s ease-in-out infinite;
}

@keyframes scrollPulse {
  0%   { transform: scaleY(0); transform-origin: top; opacity: 0; }
  50%  { transform: scaleY(1); transform-origin: top; opacity: 1; }
  51%  { transform: scaleY(1); transform-origin: bottom; opacity: 1; }
  100% { transform: scaleY(0); transform-origin: bottom; opacity: 0; }
}

/* Birthday Today */
.birthday-section {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  background: var(--bg);
  padding: 2rem;
}

.birthday-inner h1 {
  font-family: var(--font-heading);
  font-size: clamp(3rem, 8vw, 6rem);
  font-weight: 300;
  font-style: italic;
  color: var(--text-primary);
  margin-bottom: 1rem;
}

.birthday-inner p {
  font-size: 1rem;
  color: var(--text-secondary);
  letter-spacing: 0.1em;
}

/* ===== GALLERY SECTION ===== */
.gallery-section {
  background: var(--bg-alt);
  padding: 4rem 0 6rem;
}

.gallery-section-header {
  text-align: center;
  padding: 0 2rem 4rem;
}

.gallery-section-line {
  width: 40px;
  height: 1px;
  background: var(--accent);
  margin: 0 auto 1.5rem;
}

.gallery-section-title {
  font-family: var(--font-heading);
  font-size: clamp(1.8rem, 4vw, 2.8rem);
  font-weight: 300;
  font-style: italic;
  color: var(--text-primary);
}

.gallery-container {
  max-width: 1080px;
  margin: 0 auto;
  padding: 0 2rem;
}

.gallery-item {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 5rem;
  align-items: center;
  padding: 5rem 0;
  border-bottom: 1px solid var(--border);
  opacity: 0;
  transform: translateY(40px);
  transition: opacity 0.8s ease, transform 0.8s ease;
}

.gallery-item:first-child {
  padding-top: 0;
}

.gallery-item:last-child {
  border-bottom: none;
}

.gallery-item.visible {
  opacity: 1;
  transform: translateY(0);
}

.gallery-item.reverse .gallery-image-col {
  order: 2;
}

.gallery-item.reverse .gallery-text-col {
  order: 1;
}

/* Image Column */
.gallery-image-col {
  overflow: hidden;
  border-radius: 2px;
}

.gallery-image-wrap {
  aspect-ratio: 4 / 3;
  overflow: hidden;
  background: var(--accent-light);
  position: relative;
}

.gallery-image-wrap img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.7s ease;
}

.gallery-image-wrap:hover img {
  transform: scale(1.04);
}

.gallery-placeholder {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--accent-light);
  color: var(--text-secondary);
  font-size: 0.75rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
}

/* Text Column */
.gallery-text-col {
  padding: 0.5rem 0;
}

.gallery-accent-line {
  width: 36px;
  height: 1px;
  background: var(--accent);
  margin-bottom: 1.5rem;
}

.gallery-title {
  font-family: var(--font-heading);
  font-size: clamp(1.4rem, 2.5vw, 2rem);
  font-weight: 300;
  font-style: italic;
  color: var(--text-primary);
  line-height: 1.3;
  margin-bottom: 1.25rem;
}

.gallery-text {
  font-size: 0.9rem;
  color: var(--text-secondary);
  line-height: 1.9;
  font-weight: 300;
}

/* ===== MUSIC MINI CONTROLS ===== */
.music-mini {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 1.5rem;
  margin-top: 3rem;
  opacity: 0;
  animation: fadeIn 1s ease 1.3s forwards;
}

.music-mini-btn {
  background: none;
  border: 1px solid rgba(26, 26, 26, 0.18);
  border-radius: 50%;
  width: 38px;
  height: 38px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-secondary);
  transition: border-color 0.25s ease, color 0.25s ease, background 0.25s ease;
}

.music-mini-btn:hover {
  border-color: var(--accent);
  color: var(--accent);
}

.music-mini-play {
  width: 48px;
  height: 48px;
  border-color: rgba(26, 26, 26, 0.28);
  color: var(--text-primary);
}

.music-mini-play:hover {
  border-color: var(--accent);
  color: var(--accent);
  background: rgba(232, 120, 120, 0.06);
}

/* ===== ANIMATIONS ===== */
@keyframes fadeDown {
  from { opacity: 0; transform: translateY(-16px); }
  to   { opacity: 1; transform: translateY(0); }
}

@keyframes fadeUp {
  from { opacity: 0; transform: translateY(16px); }
  to   { opacity: 1; transform: translateY(0); }
}

@keyframes fadeIn {
  from { opacity: 0; }
  to   { opacity: 1; }
}

/* ===== RESPONSIVE ===== */
@media (max-width: 900px) {
  .countdown-block {
    padding: 0 1.25rem;
  }

  .gallery-item {
    gap: 3rem;
  }
}

@media (max-width: 700px) {
  .countdown-block {
    padding: 0 0.75rem;
  }

  .countdown-block::after {
    height: 2rem;
    bottom: 1rem;
  }

  .gallery-item {
    grid-template-columns: 1fr;
    gap: 1.75rem;
    padding: 3.5rem 0;
  }

  .gallery-item.reverse .gallery-image-col,
  .gallery-item.reverse .gallery-text-col {
    order: unset;
  }

  .gallery-image-wrap {
    aspect-ratio: 16 / 9;
  }

  .music-player-inner {
    padding: 0.75rem 1rem;
  }
}

@media (max-width: 480px) {
  .countdown-number {
    font-size: clamp(3rem, 18vw, 4rem);
  }

  .countdown-block {
    padding: 0 0.5rem;
  }

  .countdown-block::after {
    height: 1.5rem;
    bottom: 0.9rem;
  }
}
