#screen-habits{

  z-index: 10000;
}

.habits-grid {
  display: flex;
  flex-direction: column;
  gap: 20px;
  width: 100%;
  margin-top: 20px;
}

.habit-card {
  width: 100%;
  height: 60px;
  border-radius: 30px; 
  display: flex;
  align-items: center;
  gap: 15px;
  cursor: pointer;
  box-sizing: border-box;
}


.habit-card:active {
  transform: scale(0.98);
}

.habit-icon {
  font-size: 34px;
  margin-left: 20px; 
}

.habit-name {
  font-size:20px;
  font-weight: 600;
}

.form-group {
  margin-bottom: 20px;
}

.form-group label {
  display: block;
  margin-bottom: 8px;
  font-weight: 600;
}

.form-group input[type="text"],
.form-group input[type="color"] {
  width: 100%;
  padding: 12px;
  border-radius: 12px;
}

#calendar-wrapper {
   padding-top: 70px;
    padding-bottom: 100px;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
}

.calendar-container {
  width: 100%;
  display: flex;
  flex-direction: column;
  gap: 40px;
  padding: 16px 0;
}

.month-block {
  width: 100%;
  padding: 0 4px;
}

.month-header {
  display: flex;
  align-items: baseline;
  margin-bottom: 20px;
  padding-left: 1px;
}

.month-name {
  font-size: 22px;
  font-weight: 700;
  margin-right: 12px;
}

.month-year {
  font-size: 18px;
  font-weight: 500;
}

.weekdays {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 4px;
  margin-bottom: 8px;
  padding: 0 4px;
}

.weekday {
  text-align: center;
  font-size: 12px;
  font-weight: 600;
  padding: 4px 0;
}

.days-grid {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 4px;
  padding: 0 4px;
}

.day {
  aspect-ratio: 1;
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 8px;
  background: transparent;
  cursor: pointer;
  font-size: 16px;
  font-weight: 500;
  transition: all 0.15s ease;
  position: relative;
}

.day:active {
  transform: scale(0.92);
}

.day.completed {
  background: #34C759;
  font-weight: 600;
  border-radius: 50px;
  box-shadow: 0 2px 8px rgba(52, 199, 89, 0.3);
}

.day.today {
  background: #7f0000;
  font-weight: 700;
  border-radius: 50px;
}


.day.past {
  opacity: 0.3;
}


.action-buttons {
  position: fixed;
  bottom: 20px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  gap: 30px;
  z-index: 9999;
}

.action-buttons button {
 width: 55px;
  height: 55px;
  border-radius: 50%;
  font-weight: 700;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
}

.action-buttons button:active {
  transform: scale(0.92);
}

#todayBtn .material-symbols-outlined {
  font-size: 32px;
}
#statsBtn {
 position: fixed;
  top: calc(env(safe-area-inset-top, 0px) + 8px);
  right: 80px;
  width: 50px;
  height: 50px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  pointer-events: auto;
  touch-action: manipulation;
  z-index: 2147483647;
}

#recapCount {
  position: absolute;
  top: -4px;
  right: -4px;
  padding: 4px 8px;
  border-radius: 12px;
  font-size: 11px;
  font-weight: 700;
  min-width: 20px;
  text-align: center;
}
@media (min-width: 768px) {
  .calendar-container {
    max-width: 600px;
    margin: 0 auto;
  }
  
  .month-name {
    font-size: 24px;
  }
  
  .day {
    font-size: 18px;
    border-radius: 10px;
  }
}
.years-header {
  position: fixed;
  top: 70px;
  left: 0;
  right: 0;
  z-index: 1000;
  display: flex;
  gap: 12px;
  border-radius: 50px;
  padding: 12px 10px;
  width: 80%;
  left: 50%;
  transform: translate(-50%);
  overflow-x: auto;
  scrollbar-width: none; 
  background: transparent;
}
.year-tab {
  padding: 10px 18px;
  border-radius: 999px;
  font-weight: 600;
  font-size: 14px;
  white-space: nowrap;
  cursor: pointer;
}
.year-tab.active {
  background: linear-gradient(135deg, #ff3b3b, #ff0000);
  color: white;
  border-color: #ff0000;
  box-shadow: 0 6px 18px rgba(255, 0, 0, 0.35);
}
#monthsList {
  width: 100%;
  margin-top: 50px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  box-sizing: border-box;
}
.month-item {
  width: 100%;
  height: 70px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 18px;
  border-radius: 50px;
  cursor: pointer;
  box-sizing: border-box; 
  transition: transform 0.2s ease;
}
.month-item:active {
  transform: scale(0.98);
}
.month-count {
  padding: 4px 12px;
  border-radius: 20px;
  font-size: 13px;
}
#deleteHabitBtn {
  position: fixed;
  top: calc(env(safe-area-inset-top, 0px) + 8px);
  right: 20px;
  width: 50px;
  height: 50px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  pointer-events: auto;
  touch-action: manipulation;
  z-index: 2147483647;
}

#deleteHabitBtn .material-symbols-outlined {
  font-size: 30px;
}

#addHabitMiniBtn{
  position: fixed;
  top: calc(env(safe-area-inset-top, 0px) + 8px);
  right: 20px;
  width: 50px;
  height: 50px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  cursor: pointer;
  pointer-events: auto;
  touch-action: manipulation;
  z-index: 1000;
  transition: transform 0.12s ease, background 0.2s ease, box-shadow 0.2s ease;
}

#addhabitcontent { 
  height: auto;
  display: flex; 
  flex-direction: column; 
  gap: 30px;
  margin-top: 20px;
  align-items: flex-start;
  width: 100%;
} 
 
.form-group { 
  display: flex; 
  flex-direction: column; 
  gap: 12px;
  width: 100%;
  align-items: flex-start;
} 
 
.creattitle { 
  font-size: 18px; 
  font-weight: 700; 
  text-align: left; 
  margin-bottom: 4px;
} 
 
#habitName { 
  width: 95%; 
  height: 25px; 
  border-radius: 50px; 
  font-size: 18px; 
   
  outline: none; 
} 

#habitColor { 
  width: 95%; 
  height: 50px; 
  padding-inline: 8px;
  padding-block: 8px;
  border-radius: 50px; 
  cursor: pointer; 
} 
 
.icon-select { 
  display: grid; 
  grid-template-columns: repeat(4, 1fr); 
  gap: 14px;
  width: 100%;
} 

.icon-option.selected {
  border-color: #f00101;
  background: #ff0000;
}
.icon-option { 
  aspect-ratio: 1 / 1; 
  border-radius: 50%; 
  display: flex; 
  width: 65px;
  height:65px;
  align-items: center; 
  justify-content: center; 
  cursor: pointer; 
} 
 

#createHabitBtn { 
  position: fixed;
  top: calc(env(safe-area-inset-top, 0px) + 8px);
  right: 14px;
  width: 50px;
  height: 50px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  pointer-events: auto;
  touch-action: manipulation;
  z-index: 2147483647;
  transition: transform 0.12s ease, background 0.2s ease, box-shadow 0.2s ease;
}


