@import url("https://fonts.googleapis.com/css2?family=Orbitron:wght@400;700&family=Roboto:wght@300;500&display=swap");

/* Genel ayarlar */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  display: flex;
  justify-content: center;
  align-items: center;
  flex-direction: column;
  min-height: 100vh;
  background: linear-gradient(135deg, #000428, #004e92);
  color: white;
  font-family: "Orbitron", sans-serif;
  overflow: hidden;
  animation: backgroundAnimation 15s infinite alternate;
}

@keyframes backgroundAnimation {
  0% {
    background-position: 0% 50%;
  }
  50% {
    background-position: 100% 50%;
  }
  100% {
    background-position: 0% 50%;
  }
}

.container {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 2rem;
  background: rgba(0, 0, 0, 0.5);
  border-radius: 20px;
  box-shadow: 0 0 30px rgba(0, 128, 255, 0.6);
  backdrop-filter: blur(10px);
}

.container:hover {
  transform: scale(1.02);
  box-shadow: 0 0 40px rgba(0, 200, 255, 0.8);
}

.clock-wrapper:hover .analog {
  transform: rotateX(10deg) rotateY(10deg);
}

.digital:hover {
  box-shadow: 0 0 25px rgba(0, 200, 255, 0.8);
  transform: scale(1.05);
}

.title {
  font-size: 2.5rem;
  margin-bottom: 1.5rem;
  background: linear-gradient(90deg, #00c6ff, #0072ff);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  text-shadow: 0 0 15px rgba(0, 200, 255, 0.3);
  letter-spacing: 2px;
  font-weight: 700;
}

/* Analog saat */
.analog {
  position: relative;
  width: 400px;
  height: 400px;
  border: 6px solid rgba(0, 150, 255, 0.5);
  border-radius: 50%;
  display: flex;
  justify-content: center;
  align-items: center;
  box-shadow: 0 0 25px rgba(255, 255, 255, 0.3);
  background: rgba(0, 20, 40, 0.7);
}

/* Saat işaretleri */
.markers {
  position: absolute;
  width: 100%;
  height: 100%;
  top: 0;
  left: 0;
}

.hour-mark {
  position: absolute;
  width: 4px;
  height: 15px;
  background: rgba(255, 255, 255, 0.7);
  border-radius: 50%;
  top: 50%;
  left: 50%;
  transform-origin: bottom;
}

/* Dijilog eller */
.hand {
  position: absolute;
  width: 6px;
  left: 50%;
  top: 50%;
  transform-origin: bottom center;
  transform: translate(-50%, -100%);
  border-radius: 10px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-start;
}

.hour {
  height: 100px;
  background: cyan;
  box-shadow: 0 0 15px cyan;
}

.minute {
  height: 140px;
  background: lime;
  box-shadow: 0 0 15px lime;
}

.second {
  height: 170px;
  width: 4px;
  background: red;
  box-shadow: 0 0 15px red;
}

/* Dijital rakamlar içeren span'ler */
.hand span {
  position: absolute;
  width: 30px;
  height: 30px;
  background: rgba(0, 0, 0, 0.7);
  display: flex;
  justify-content: center;
  align-items: center;
  border-radius: 5px;
  transform: translateX(-50%) rotate(90deg);
  box-shadow: 0 0 8px rgba(255, 255, 255, 0.5);
  font-weight: bold;
}

.hour span {
  color: cyan;
  border: 1px solid cyan;
}

.minute span {
  color: lime;
  border: 1px solid lime;
}

.second span {
  color: red;
  border: 1px solid red;
  width: 25px;
  height: 25px;
  font-size: 0.9rem;
}

/* Merkez noktası */
.center {
  position: absolute;
  width: 20px;
  height: 20px;
  background: white;
  border-radius: 50%;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  box-shadow: 0 0 10px rgba(255, 255, 255, 0.8);
  z-index: 100;
}

/* Dijital saat */
.digital {
  margin-top: 2rem;
  padding: 1rem 2rem;
  font-size: 2.2rem;
  background: rgba(0, 20, 40, 0.7);
  border-radius: 15px;
  box-shadow: 0 0 15px rgba(0, 150, 255, 0.6);
  transition: all 0.3s;
  border: 2px solid rgba(0, 150, 255, 0.5);
  letter-spacing: 2px;
  color: #fff;
  text-shadow: 0 0 10px rgba(0, 200, 255, 0.8);
}

/* Arka plan yıldızları */
.stars {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: -1;
}

.star {
  position: absolute;
  background: white;
  border-radius: 50%;
  animation: twinkle var(--duration) infinite ease-in-out;
  opacity: var(--opacity);
}

/* Tarih görüntüleme */
.date-display {
  margin-top: 1rem;
  font-family: "Roboto", sans-serif;
  font-size: 1.1rem;
  color: rgba(255, 255, 255, 0.8);
  display: flex;
  align-items: center;
  gap: 8px;
}

.date-display i {
  color: rgba(0, 200, 255, 0.8);
}

@keyframes twinkle {
  0%,
  100% {
    opacity: var(--opacity);
  }
  50% {
    opacity: 0.2;
  }
}

/* Mobil cihazlar için düzenleme */
@media (max-width: 480px) {
  .container {
    padding: 1rem;
  }

  .title {
    font-size: 1.8rem;
  }

  .analog {
    width: 300px;
    height: 300px;
  }

  .digital {
    font-size: 1.6rem;
    padding: 0.8rem 1.5rem;
  }
}