* {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: "Segoe UI", Tahoma, Geneva, Verdana, sans-serif;
  background: radial-gradient(circle at top, #fce7f3 0%, #fdf2f8 45%, #fff1f2 100%);
  color: #1f2937;
}

.page {
  max-width: 960px;
  margin: 0 auto;
  padding: 36px 20px 80px;
}

.hero {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  background: linear-gradient(140deg, #f472b6 0%, #ec4899 45%, #db2777 100%);
  color: #f8fafc;
  padding: 30px 34px;
  border-radius: 26px;
  position: relative;
  overflow: hidden;
  box-shadow: 0 20px 45px rgba(219, 39, 119, 0.35);
  border: 1px solid rgba(255, 255, 255, 0.35);
}

.hero::after {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at 15% 20%, rgba(255, 255, 255, 0.35), transparent 55%),
    radial-gradient(circle at 85% 0%, rgba(251, 191, 36, 0.25), transparent 50%);
  opacity: 0.9;
  pointer-events: none;
}

.hero > * {
  position: relative;
  z-index: 1;
}

.hero h1 {
  margin: 0 0 8px;
  font-size: 32px;
}

.hero p {
  margin: 0;
  opacity: 0.85;
}

.badge {
  background: rgba(255, 255, 255, 0.25);
  padding: 8px 14px;
  border-radius: 999px;
  font-size: 12px;
  letter-spacing: 0.6px;
  text-transform: uppercase;
  border: 1px solid rgba(255, 255, 255, 0.5);
}

.badge.is-error {
  background: rgba(248, 113, 113, 0.2);
  border-color: rgba(248, 113, 113, 0.45);
  color: #ffe4e6;
}

.filters {
  display: flex;
  gap: 10px;
  margin: 26px 0 14px;
  flex-wrap: wrap;
}

.chip {
  border: 1px solid rgba(244, 114, 182, 0.35);
  background: rgba(255, 255, 255, 0.85);
  padding: 8px 16px;
  border-radius: 999px;
  cursor: pointer;
  font-weight: 600;
  color: #9f1239;
  transition: all 0.2s ease;
}

.chip.is-active {
  background: linear-gradient(120deg, #ec4899, #db2777);
  border-color: #f472b6;
  color: #ffffff;
  box-shadow: 0 10px 20px rgba(236, 72, 153, 0.35);
}

.chip:hover {
  transform: translateY(-1px);
  box-shadow: 0 8px 18px rgba(236, 72, 153, 0.2);
}

.stats {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  gap: 16px;
  background: rgba(255, 255, 255, 0.95);
  padding: 22px;
  border-radius: 20px;
  margin-bottom: 26px;
  box-shadow: 0 18px 40px rgba(244, 114, 182, 0.18);
  border: 1px solid rgba(244, 114, 182, 0.25);
  color: #1f2937;
}

.stats .label {
  margin: 0;
  font-size: 12px;
  color: #9f1239;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.stats .value {
  margin: 6px 0 0;
  font-size: 20px;
  font-weight: 700;
  color: #1f2937;
}

.card {
  background: rgba(255, 255, 255, 0.98);
  padding: 26px;
  border-radius: 22px;
  box-shadow: 0 18px 38px rgba(244, 114, 182, 0.2);
  margin-bottom: 34px;
  border: 1px solid rgba(244, 114, 182, 0.2);
  color: #1f2937;
}

.card h2 {
  margin: 0 0 16px;
}

form {
  display: grid;
  gap: 16px;
}

label {
  display: grid;
  gap: 6px;
  font-size: 14px;
  color: #6b7280;
}

.toggle {
  display: flex;
  align-items: center;
  gap: 10px;
  padding-top: 26px;
  color: #9f1239;
}

.toggle input {
  width: 18px;
  height: 18px;
}

input,
select,
textarea {
  padding: 11px 12px;
  border-radius: 12px;
  border: 1px solid rgba(244, 114, 182, 0.35);
  font-size: 14px;
  font-family: inherit;
  color: #111827;
  background: #ffffff;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

input:focus,
select:focus,
textarea:focus {
  outline: none;
  border-color: #f472b6;
  box-shadow: 0 0 0 3px rgba(244, 114, 182, 0.25);
}

textarea {
  resize: vertical;
}

.grid.two {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 16px;
}

.grid.three {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 16px;
}

.actions {
  display: flex;
  gap: 12px;
}

.select-with-add {
  display: grid;
  gap: 10px;
}

.add-row {
  display: flex;
  gap: 10px;
}

.add-row input {
  flex: 1;
}

.small {
  padding: 10px 14px;
  font-size: 12px;
}

button {
  border: none;
  cursor: pointer;
  font-weight: 600;
  font-family: inherit;
  padding: 12px 18px;
  border-radius: 12px;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

button:disabled {
  cursor: not-allowed;
  opacity: 0.6;
  transform: none;
  box-shadow: none;
}

.primary {
  background: linear-gradient(120deg, #ec4899, #db2777);
  color: #ffffff;
  box-shadow: 0 14px 26px rgba(236, 72, 153, 0.35);
}

.primary:hover {
  transform: translateY(-1px);
  box-shadow: 0 18px 32px rgba(236, 72, 153, 0.45);
}

.ghost {
  background: rgba(244, 114, 182, 0.12);
  color: #9f1239;
  border: 1px solid rgba(244, 114, 182, 0.35);
}

.entries h2 {
  margin: 0 0 16px;
  color: #1f2937;
}

.entry-list {
  display: grid;
  gap: 16px;
}

.entry-card {
  background: rgba(255, 255, 255, 0.98);
  padding: 18px;
  border-radius: 18px;
  box-shadow: 0 16px 28px rgba(244, 114, 182, 0.18);
  border: 1px solid rgba(244, 114, 182, 0.2);
  color: #1f2937;
}

.entry-card header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 12px;
}

.entry-title {
  margin: 0;
  font-weight: 700;
}

.entry-meta {
  margin: 4px 0 0;
  font-size: 12px;
  color: #9f1239;
}

.entry-details {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 12px;
  font-size: 13px;
  color: #6b7280;
}

.entry-notes {
  margin-top: 12px;
  font-size: 13px;
  color: #4b5563;
}

.delete {
  background: rgba(244, 114, 182, 0.2);
  color: #be123c;
  padding: 6px 10px;
  font-size: 12px;
  border-radius: 999px;
  border: 1px solid rgba(244, 114, 182, 0.45);
}

.empty {
  background: rgba(255, 255, 255, 0.9);
  border: 1px dashed rgba(244, 114, 182, 0.35);
  border-radius: 16px;
  padding: 24px;
  text-align: center;
  color: #9f1239;
}

@media (max-width: 720px) {
  .hero {
    flex-direction: column;
    align-items: flex-start;
  }
  .actions {
    flex-direction: column;
  }
}
