/* Moonlight Watercolor Theme — 静谧月色与莫奈水彩质感 */

html, body {
  background: #eef2f7 !important;
  color: #2c3e50 !important;
}

/* Watercolor Card — 半薄薄水彩质感 */
.glass-card {
  background: rgba(255, 255, 255, 0.52) !important;
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1px solid rgba(123, 167, 217, 0.28) !important;
  border-radius: 0.85rem;
  box-shadow:
    0 2px 12px rgba(123, 167, 217, 0.08),
    0 8px 32px rgba(123, 167, 217, 0.04),
    inset 0 1px 0 rgba(255, 255, 255, 0.6);
  transition: all 0.35s ease;
}
.glass-card:hover {
  border-color: rgba(168, 213, 186, 0.45) !important;
  box-shadow:
    0 4px 20px rgba(123, 167, 217, 0.12),
    0 12px 40px rgba(184, 169, 217, 0.06),
    inset 0 1px 0 rgba(255, 255, 255, 0.7);
  transform: translateY(-2px);
}

/* Legacy card override */
.card {
  background: rgba(255, 255, 255, 0.52) !important;
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1px solid rgba(123, 167, 217, 0.28) !important;
  border-radius: 0.85rem;
  box-shadow:
    0 2px 12px rgba(123, 167, 217, 0.08),
    0 8px 32px rgba(123, 167, 217, 0.04),
    inset 0 1px 0 rgba(255, 255, 255, 0.6);
  padding: 1.25rem;
}

/* Buttons — 莫奈水彩渐变 */
.moon-btn-primary {
  background: linear-gradient(135deg, rgba(123, 167, 217, 0.9), rgba(184, 169, 217, 0.9)) !important;
  color: #fff !important;
  border: none !important;
  box-shadow: 0 2px 10px rgba(123, 167, 217, 0.25);
  transition: all 0.3s ease;
}
.moon-btn-primary:hover {
  background: linear-gradient(135deg, rgba(123, 167, 217, 1), rgba(184, 169, 217, 1)) !important;
  box-shadow: 0 4px 18px rgba(123, 167, 217, 0.35), 0 0 12px rgba(184, 169, 217, 0.2);
  transform: translateY(-1px);
}
.moon-btn-secondary {
  background: rgba(255, 255, 255, 0.45) !important;
  color: #4a6582 !important;
  border: 1px solid rgba(123, 167, 217, 0.3) !important;
  transition: all 0.3s ease;
}
.moon-btn-secondary:hover {
  background: rgba(255, 255, 255, 0.65) !important;
  border-color: rgba(168, 213, 186, 0.5) !important;
  color: #3d5a73 !important;
}
.moon-btn-danger {
  background: rgba(232, 196, 196, 0.45) !important;
  color: #a65d5d !important;
  border: 1px solid rgba(232, 196, 196, 0.5) !important;
  transition: all 0.3s ease;
}
.moon-btn-danger:hover {
  background: rgba(232, 196, 196, 0.6) !important;
  box-shadow: 0 2px 10px rgba(232, 196, 196, 0.2);
}

/* Legacy button overrides */
.btn-primary {
  background: linear-gradient(135deg, rgba(123, 167, 217, 0.9), rgba(184, 169, 217, 0.9)) !important;
  color: #fff !important;
  border: none !important;
  box-shadow: 0 2px 10px rgba(123, 167, 217, 0.25);
}
.btn {
  display: inline-flex; align-items: center; padding: .4rem .8rem;
  border-radius: .5rem; font-size: .875rem; cursor: pointer;
  transition: all 0.3s ease;
}

/* Inputs — 月色下的宣纸质感 */
.moon-input {
  background: rgba(255, 255, 255, 0.55) !important;
  border: 1px solid rgba(123, 167, 217, 0.25) !important;
  color: #2c3e50 !important;
  border-radius: 0.6rem;
  transition: all 0.3s ease;
}
.moon-input::placeholder {
  color: #94a7b8 !important;
}
.moon-input:focus {
  outline: none !important;
  border-color: #a8d5ba !important;
  box-shadow: 0 0 0 3px rgba(168, 213, 186, 0.15), 0 0 16px rgba(168, 213, 186, 0.1);
  background: rgba(255, 255, 255, 0.75) !important;
}

/* Native input overrides */
select, input[type="text"], input[type="password"], input[type="number"], textarea {
  background: rgba(255, 255, 255, 0.55);
  border: 1px solid rgba(123, 167, 217, 0.25);
  color: #2c3e50;
  border-radius: 0.6rem;
}
select:focus, input:focus, textarea:focus {
  outline: none;
  border-color: #a8d5ba;
  box-shadow: 0 0 0 3px rgba(168, 213, 186, 0.15);
  background: rgba(255, 255, 255, 0.75);
}

/* Navigation — 月光纱帘 */
.moon-nav {
  background: rgba(238, 242, 247, 0.82) !important;
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid rgba(123, 167, 217, 0.18) !important;
}

/* Tables — 水彩淡染 */
.moon-table thead {
  background: rgba(232, 238, 245, 0.7) !important;
  color: #5a6e7e !important;
}
.moon-table tbody tr {
  border-color: rgba(123, 167, 217, 0.12) !important;
}
.moon-table tbody tr:hover {
  background: rgba(168, 213, 186, 0.08) !important;
}

/* Modal / Overlay — 雾色 */
.moon-overlay {
  background: rgba(180, 190, 205, 0.35) !important;
  backdrop-filter: blur(6px);
}
.overlay {
  position: fixed; inset: 0;
  background: rgba(180, 190, 205, 0.35) !important;
  backdrop-filter: blur(6px);
  display: flex; align-items: center; justify-content: center; z-index: 50;
}
.moon-modal {
  background: rgba(250, 252, 254, 0.92) !important;
  backdrop-filter: blur(20px);
  border: 1px solid rgba(123, 167, 217, 0.3) !important;
  box-shadow:
    0 12px 48px rgba(123, 167, 217, 0.12),
    0 4px 16px rgba(184, 169, 217, 0.08);
  border-radius: 0.85rem;
}
.modal {
  background: rgba(250, 252, 254, 0.92) !important;
  backdrop-filter: blur(20px);
  border: 1px solid rgba(123, 167, 217, 0.3) !important;
  border-radius: 0.85rem;
  box-shadow:
    0 12px 48px rgba(123, 167, 217, 0.12),
    0 4px 16px rgba(184, 169, 217, 0.08);
  width: 90%; max-width: 640px; max-height: 90vh; overflow: auto; padding: 1.5rem;
}

/* Text utilities */
.moon-text-secondary { color: #6b7c8e !important; }
.moon-text-accent { color: #5a8bc2 !important; }
.moon-text-cyan { color: #6ab0a0 !important; }
.moon-text-purple { color: #8b7cb8 !important; }

/* Status badges — 水彩晕染 */
.moon-badge-green {
  background: rgba(168, 213, 186, 0.25) !important;
  color: #4a8a6a !important;
  border: 1px solid rgba(168, 213, 186, 0.35) !important;
}
.moon-badge-red {
  background: rgba(232, 196, 196, 0.3) !important;
  color: #a65d5d !important;
  border: 1px solid rgba(232, 196, 196, 0.4) !important;
}
.moon-badge-blue {
  background: rgba(184, 210, 236, 0.3) !important;
  color: #4a7aad !important;
  border: 1px solid rgba(184, 210, 236, 0.4) !important;
}
.moon-badge-purple {
  background: rgba(208, 196, 228, 0.3) !important;
  color: #7a6aad !important;
  border: 1px solid rgba(208, 196, 228, 0.4) !important;
}

/* Scrollbar — 淡雅 */
::-webkit-scrollbar { width: 8px; height: 8px; }
::-webkit-scrollbar-track { background: rgba(238, 242, 247, 0.8); }
::-webkit-scrollbar-thumb { background: rgba(123, 167, 217, 0.3); border-radius: 4px; }
::-webkit-scrollbar-thumb:hover { background: rgba(123, 167, 217, 0.45); }

/* Tooltip — 水色 */
.tooltip-box {
  background: rgba(250, 252, 254, 0.95) !important;
  border: 1px solid rgba(123, 167, 217, 0.25) !important;
  color: #3d4f5f !important;
  box-shadow: 0 6px 24px rgba(123, 167, 217, 0.1);
  border-radius: 0.5rem;
}

/* Link */
a.moon-link { color: #5a8bc2 !important; }
a.moon-link:hover { color: #7ba7d9 !important; }

/* Code / ID tags */
code, .moon-code {
  background: rgba(232, 238, 245, 0.8) !important;
  color: #5a8bc2 !important;
  border: 1px solid rgba(123, 167, 217, 0.2) !important;
}

/* Progress / loading bar */
.moon-progress-bg { background: rgba(232, 238, 245, 0.8) !important; }
.moon-progress-fill { background: linear-gradient(90deg, #7ba7d9, #a8d5ba) !important; }
