:root {
  --primary-color: #ff6b6b;
  --secondary-color: #ff8e8e;
  --accent-color: #ee5253;
  --text-dark: #2d3436;
  --text-light: #636e72;
  --glass-bg: rgba(255, 255, 255, 0.45);
  --glass-border: rgba(255, 255, 255, 0.6);
  --shadow: 0 8px 32px 0 rgba(31, 38, 135, 0.15);
  --font-heading: "Great Vibes", cursive;
  --font-body: "Outfit", "Zen Kaku Gothic New", sans-serif;
  --font-number: "Outfit", sans-serif;
  --nav-height: 70px;
}
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}
body {
  font-family: var(--font-body);
  background: linear-gradient(135deg, #fdfbfb 0%, #ebedee 100%);
  min-height: 100vh;
  display: flex;
  justify-content: center;
  align-items: flex-start;
  color: var(--text-dark);
  overflow-x: hidden;
  position: relative;
  padding-bottom: var(--nav-height);
}
.background-animation {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: -1;
  overflow: hidden;
}
.blob {
  position: absolute;
  filter: blur(80px);
  opacity: 0.6;
  animation: float 20s infinite alternate;
}
.blob-1 {
  top: -10%;
  left: -10%;
  width: 50vw;
  height: 50vw;
  background: #ff9a9e;
  border-radius: 40% 60% 70% 30% / 40% 50% 60% 50%;
}
.blob-2 {
  bottom: -10%;
  right: -10%;
  width: 60vw;
  height: 60vw;
  background: #a18cd1;
  border-radius: 60% 40% 30% 70% / 60% 30% 70% 40%;
  animation-delay: -5s;
}
.blob-3 {
  top: 40%;
  left: 40%;
  width: 40vw;
  height: 40vw;
  background: #fbc2eb;
  border-radius: 30% 70% 70% 30% / 30% 30% 70% 70%;
  animation-delay: -10s;
}
@keyframes float {
  0% {
    transform: translate(0, 0) rotate(0deg);
  }
  100% {
    transform: translate(30px, 50px) rotate(20deg);
  }
}
.app-container {
  width: 100%;
  max-width: 500px;
  padding: 20px;
  min-height: 100vh;
  position: relative;
}
.hidden {
  display: none !important;
}
.modal {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(255, 255, 255, 0.8);
  z-index: 2000;
  display: grid;
  place-items: center;
  padding: 40px 20px;
  opacity: 1;
  transition: opacity 0.3s ease;
  overflow-y: auto;
}
.modal.hidden {
  pointer-events: none;
  opacity: 0;
}
.modal-content {
  width: 100%;
  max-width: 400px;
  padding: 5px;
  position: relative;
}
.glass-card {
  background: var(--glass-bg);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-radius: 24px;
  border: 1px solid var(--glass-border);
  box-shadow: var(--shadow);
  padding: 20px;
  margin-bottom: 15px;
  position: relative;
  transition: z-index 0.3s;
}
.glass-card.z-top {
  z-index: 1500;
}
.app-header {
  text-align: center;
  margin-bottom: 20px;
  padding-top: 10px;
}
.app-header h2 {
  font-size: 2rem;
  font-weight: 700;
  color: var(--text-dark);
}
.header-content {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 5px;
  position: relative;
}
.account-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-bottom: 20px;
}
.account-item {
  padding: 15px;
  background: rgba(255, 255, 255, 0.4);
  border: 1px solid var(--glass-border);
  border-radius: 16px;
  display: flex;
  align-items: center;
  gap: 12px;
  cursor: pointer;
  transition: all 0.2s;
}
.account-item:hover {
  background: rgba(255, 255, 255, 0.8);
}
.account-item.active {
  border-color: var(--primary-color);
  background: rgba(255, 107, 107, 0.1);
}
.account-item i.active-icon {
  color: var(--primary-color);
  margin-left: auto;
}
.account-item .account-info {
  flex: 1;
}
.account-item .account-title {
  font-weight: 600;
  font-size: 0.9rem;
}
.account-item .account-date {
  font-size: 0.75rem;
  color: var(--text-light);
}
.sub-label {
  font-size: 0.8rem;
  letter-spacing: 1px;
  color: var(--text-light);
  font-weight: 500;
}
.date-badge {
  background: rgba(255, 255, 255, 0.6);
  padding: 6px 16px;
  border-radius: 20px;
  font-size: 0.9rem;
  display: flex;
  gap: 8px;
  align-items: center;
  margin-top: 5px;
  color: var(--primary-color);
  font-weight: 600;
}
.timer-card {
  padding: 30px 20px;
  text-align: center;
}
.timer-row {
  display: flex;
  justify-content: center;
  gap: 15px;
  margin-bottom: 30px;
}
.time-block {
  display: flex;
  flex-direction: column;
  align-items: center;
  min-width: 80px;
}
.time-block .number {
  font-family: var(--font-number);
  font-size: 3rem;
  font-weight: 700;
  line-height: 1;
  color: #333;
}
.time-block .label {
  font-size: 0.8rem;
  color: var(--text-light);
  margin-top: 5px;
  font-weight: 500;
}
.detail-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 15px;
}
.detail-box {
  background: rgba(255, 255, 255, 0.4);
  border-radius: 16px;
  padding: 15px;
  display: flex;
  flex-direction: column;
  align-items: center;
}
.detail-icon {
  font-size: 1.2rem;
  color: var(--primary-color);
  margin-bottom: 5px;
}
.detail-val {
  font-family: var(--font-number);
  font-size: 1.2rem;
  font-weight: 600;
}
.detail-key {
  font-size: 0.75rem;
  color: var(--text-light);
}
.widget-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 15px;
}
.small-widget {
  padding: 15px 20px;
  background: linear-gradient(
    135deg,
    rgba(255, 255, 255, 0.7),
    rgba(255, 255, 255, 0.4)
  );
}
.widget-content {
  display: flex;
  flex-direction: column;
}
.widget-label {
  font-size: 0.75rem;
  color: var(--text-light);
  letter-spacing: 1px;
  margin-bottom: 4px;
}
.widget-main {
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.widget-title {
  font-weight: 700;
  font-size: 1.1rem;
}
.widget-badge {
  background: var(--primary-color);
  color: white;
  padding: 4px 10px;
  border-radius: 8px;
  font-weight: 600;
  font-size: 0.85rem;
}
.milestone-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding-bottom: 20px;
}
.milestone-item {
  display: flex;
  align-items: center;
  padding: 16px 20px;
  background: rgba(255, 255, 255, 0.5);
  border-radius: 16px;
  border: 1px solid rgba(255, 255, 255, 0.4);
}
.milestone-item.reached {
  opacity: 0.6;
  background: rgba(230, 230, 230, 0.3);
}
.milestone-date {
  font-family: var(--font-number);
  font-size: 0.9rem;
  color: var(--text-light);
  width: 90px;
}
.milestone-info {
  flex-grow: 1;
}
.milestone-name {
  font-weight: 600;
  font-size: 1rem;
  color: var(--text-dark);
}
.milestone-diff {
  font-size: 0.8rem;
  color: var(--primary-color);
  font-weight: 500;
}
.input-group {
  margin-bottom: 15px;
  position: relative;
}
.input-group label {
  display: block;
  margin-bottom: 8px;
  font-weight: 500;
  font-size: 0.9rem;
  color: #555;
}
.input-group input,
.input-group select,
.custom-select-trigger,
.custom-date-trigger {
  width: 100%;
  padding: 12px 16px;
  border-radius: 12px;
  border: 2px solid rgba(255, 255, 255, 0.8);
  background: rgba(255, 255, 255, 0.5);
  font-family: var(--font-body);
  font-size: 1rem;
  outline: none;
  transition: all 0.3s ease;
  text-align: left;
  cursor: pointer;
}
.input-group input:focus {
  border-color: var(--primary-color);
  background: rgba(255, 255, 255, 0.9);
}
.custom-select-wrapper,
.custom-date-wrapper {
  position: relative;
}
.custom-select-trigger,
.custom-date-trigger {
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.custom-options {
  position: absolute;
  top: calc(100% + 8px);
  left: 0;
  width: 100%;
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-radius: 16px;
  border: 1px solid var(--glass-border);
  box-shadow: var(--shadow);
  z-index: 10000;
  opacity: 0;
  pointer-events: none;
  transform: translateY(-10px);
  transition: all 0.3s cubic-bezier(0.18, 0.89, 0.32, 1.28);
  overflow: hidden;
}
.custom-options.show {
  opacity: 1;
  pointer-events: auto;
  transform: translateY(0);
}
.custom-option {
  padding: 14px 18px;
  cursor: pointer;
  transition: all 0.2s cubic-bezier(0.175, 0.885, 0.32, 1.275);
  font-size: 0.95rem;
  display: flex;
  flex-direction: column;
  gap: 4px;
  border-bottom: 1px solid rgba(0, 0, 0, 0.02);
  position: relative;
  overflow: hidden;
}
.custom-option:last-child {
  border-bottom: none;
}
.custom-option:hover {
  background: rgba(255, 107, 107, 0.08);
  padding-left: 22px;
}
.custom-option.selected {
  background: rgba(255, 107, 107, 0.12);
  color: var(--primary-color);
  font-weight: 600;
}
.custom-option.selected::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0;
  width: 4px;
  height: 100%;
  background: var(--primary-color);
}
.custom-option.selected::after {
  content: "♥";
  position: absolute;
  right: 15px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--primary-color);
  font-size: 1.2rem;
  opacity: 0.8;
}
.custom-option .opt-names {
  font-weight: 600;
  display: block;
  font-size: 1rem;
}
.custom-option .opt-date {
  font-size: 0.78rem;
  opacity: 0.7;
  font-family: var(--font-number);
  display: flex;
  align-items: center;
  gap: 5px;
}
.custom-option:hover .opt-names {
  color: var(--primary-color);
}
.settings-card {
  margin-bottom: 20px;
  border: 1px solid rgba(255, 107, 107, 0.05);
}
.custom-label-input {
  margin-top: 10px;
  animation: slideDown 0.3s ease forwards;
}
@keyframes slideDown {
  from {
    opacity: 0;
    transform: translateY(-10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}
.date-picker-modal {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(255, 255, 255, 0.6);
  backdrop-filter: blur(8px);
  z-index: 3000;
  display: flex;
  justify-content: center;
  align-items: center;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s ease;
}
.date-picker-modal.show {
  opacity: 1;
  pointer-events: auto;
}
.date-picker-card {
  width: 95%;
  max-width: 420px;
  padding: 24px;
  background: #fff;
  border-radius: 28px;
  box-shadow: var(--shadow);
}
.date-picker-header {
  text-align: center;
  margin-bottom: 20px;
  font-weight: 700;
  font-size: 1.1rem;
}
.date-manual-inputs {
  display: flex;
  gap: 8px;
  margin-bottom: 15px;
  width: 100%;
}
.date-manual-inputs input {
  flex: 1;
  min-width: 0;
  padding: 10px 5px;
  border-radius: 10px;
  border: 1px solid #eee;
  background: #f9f9f9;
  text-align: center;
  font-family: var(--font-number);
  font-size: 1rem;
  outline: none;
}
.date-manual-inputs input::-webkit-outer-spin-button,
.date-manual-inputs input::-webkit-inner-spin-button {
  -webkit-appearance: none;
  appearance: none;
  margin: 0;
}
.date-manual-inputs input[type="number"] {
  -moz-appearance: textfield;
  appearance: textfield;
}
.date-picker-grid {
  display: flex;
  gap: 5px;
  margin-bottom: 20px;
  width: 100%;
}
.date-slot {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
}
.date-slot label {
  font-size: 0.75rem;
  color: var(--text-light);
  text-align: center;
  font-weight: 600;
}
.wheel-container {
  height: 150px;
  overflow: hidden;
  background: #f9f9f9;
  border-radius: 12px;
  position: relative;
  user-select: none;
  touch-action: none;
  cursor: grab;
}
.wheel-container:active {
  cursor: grabbing;
}
.wheel-content {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  transition: transform 0.1s ease-out;
}
.wheel-item {
  height: 50px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-number);
  font-size: 1.1rem;
  color: #aaa;
  transition: all 0.2s;
}
.wheel-item.selected {
  color: var(--primary-color);
  font-weight: 700;
  font-size: 1.3rem;
}
.wheel-center-bar {
  position: absolute;
  top: 50px;
  left: 0;
  width: 100%;
  height: 50px;
  border-top: 1px solid rgba(0, 0, 0, 0.05);
  border-bottom: 1px solid rgba(0, 0, 0, 0.05);
  pointer-events: none;
  background: rgba(255, 107, 107, 0.05);
  z-index: 5;
}
.btn-primary {
  background: linear-gradient(45deg, var(--primary-color), var(--accent-color));
  color: white;
  border: none;
  padding: 14px 28px;
  border-radius: 50px;
  font-size: 1.1rem;
  font-weight: 600;
  cursor: pointer;
  width: 100%;
  font-family: var(--font-body);
  box-shadow: 0 4px 15px rgba(255, 107, 107, 0.4);
  transition: all 0.3s;
}
.btn-primary:active {
  transform: scale(0.98);
}
.btn-secondary {
  background: #fff;
  color: var(--text-dark);
  border: 2px solid #eee;
  padding: 12px;
  border-radius: 50px;
  font-weight: 600;
  cursor: pointer;
  width: 100%;
  transition: background 0.2s;
}
.btn-secondary:hover {
  background: #f9f9f9;
}
.btn-danger {
  background: #ff7675;
  color: white;
  border: none;
  padding: 12px;
  border-radius: 50px;
  font-weight: 600;
  cursor: pointer;
  width: 100%;
  transition: background 0.2s;
}
.btn-danger:hover {
  background: #d63031;
}
.bottom-nav {
  position: fixed;
  bottom: 20px;
  left: 50%;
  transform: translateX(-50%);
  width: 90%;
  max-width: 400px;
  background: rgba(255, 255, 255, 0.9);
  backdrop-filter: blur(20px);
  border-radius: 30px;
  display: flex;
  justify-content: space-around;
  padding: 12px;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.1);
  z-index: 100;
}
.nav-item {
  background: none;
  border: none;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  color: #aaa;
  cursor: pointer;
  font-family: var(--font-body);
  font-size: 0.75rem;
  width: 60px;
  transition: all 0.3s;
}
.nav-item i {
  font-size: 1.2rem;
  transition: transform 0.2s;
}
.nav-item.active {
  color: var(--primary-color);
}
.nav-item.active i {
  transform: translateY(-2px);
}
#toast-container {
  position: fixed;
  bottom: 100px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 4000;
  display: flex;
  flex-direction: column;
  gap: 10px;
  pointer-events: none;
  width: 90%;
  max-width: 400px;
}
.toast {
  background: rgba(45, 52, 54, 0.95);
  color: white;
  padding: 12px 20px;
  border-radius: 12px;
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  animation: toastIn 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275) forwards;
  pointer-events: auto;
  font-size: 0.9rem;
}
.toast.success {
  background: rgba(0, 184, 148, 0.95);
}
.toast.error {
  background: rgba(214, 48, 49, 0.95);
}
@keyframes toastIn {
  from {
    opacity: 0;
    transform: translateY(20px) scale(0.9);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}
@keyframes toastOut {
  to {
    opacity: 0;
    transform: translateY(-10px);
  }
}
.toast.hiding {
  animation: toastOut 0.3s ease forwards;
}
@media (max-width: 400px) {
  .time-block {
    min-width: 60px;
  }
  .time-block .number {
    font-size: 2.2rem;
  }
  .detail-val {
    font-size: 1.1rem;
  }
  .date-picker-card {
    padding: 20px 15px;
  }
  .wheel-item {
    font-size: 1rem;
  }
  .wheel-item.selected {
    font-size: 1.2rem;
  }
}
.fade-in {
  animation: fadeIn 0.6s ease forwards;
}
@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}
.tab-view {
  display: none;
  animation: fadeIn 0.4s ease;
}
.tab-view.active {
  display: block;
}
.celebration-modal {
  z-index: 5000;
  background: rgba(255, 255, 255, 0.4);
  backdrop-filter: blur(10px);
}
.celebration-content {
  text-align: center;
  padding: 40px 20px;
}
.celebration-icon {
  font-size: 4rem;
  margin-bottom: 20px;
  display: block;
}
.celebration-title {
  font-family: var(--font-heading);
  font-weight: 400;
  font-size: 4.5rem;
  letter-spacing: normal;
  background: linear-gradient(
    135deg,
    var(--primary-color),
    var(--accent-color)
  );
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  margin-bottom: 10px;
  text-transform: none;
  filter: drop-shadow(0 4px 10px rgba(0, 0, 0, 0.1));
}
.celebration-message {
  font-weight: 500;
  font-size: 1.15rem;
  color: var(--text-dark);
  margin-bottom: 25px;
  line-height: 1.5;
  letter-spacing: 0.5px;
}
.confetti {
  position: fixed;
  width: 10px;
  height: 10px;
  top: -10px;
  z-index: 6000;
  pointer-events: none;
}
@keyframes confetti-fall {
  0% {
    transform: translateY(0) rotate(0deg);
    opacity: 1;
  }
  100% {
    transform: translateY(100vh) rotate(720deg);
    opacity: 0;
  }
}
