*,
*::before,
*::after {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: system-ui, -apple-system, BlinkMacSystemFont, 'SF Pro Text',
    'Helvetica Neue', sans-serif;
  background: radial-gradient(circle at top, #101827, #020617 55%);
  color: #e5e7eb;
}

a {
  color: inherit;
}

.top-bar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: 56px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 16px;
  background: rgba(15, 23, 42, 0.9);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid rgba(148, 163, 184, 0.2);
  z-index: 20;
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
}

.logo-circle {
  width: 32px;
  height: 32px;
  border-radius: 999px;
  background: conic-gradient(
    from 200deg,
    #22c55e,
    #22d3ee,
    #6366f1,
    #22c55e
  );
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #020617;
  font-weight: 800;
  font-size: 18px;
}

.brand-text {
  font-weight: 600;
  letter-spacing: 0.08em;
  font-size: 14px;
  text-transform: uppercase;
  color: #e5e7eb;
}

.menu-toggle {
  width: 40px;
  height: 32px;
  border-radius: 999px;
  border: 1px solid rgba(148, 163, 184, 0.5);
  background: radial-gradient(circle at top left, #1f2937, #020617);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
  padding: 0;
  cursor: pointer;
}

.menu-toggle span {
  display: block;
  width: 16px;
  height: 2px;
  border-radius: 999px;
  background: #e5e7eb;
}

.side-nav {
  position: fixed;
  top: 56px;
  left: 0;
  bottom: 0;
  width: 220px;
  background: rgba(15, 23, 42, 0.92);
  backdrop-filter: blur(14px);
  border-right: 1px solid rgba(148, 163, 184, 0.25);
  padding: 12px 8px;
  transform: translateX(-100%);
  transition: transform 0.2s ease-out;
  z-index: 15;
}

.side-nav.open {
  transform: translateX(0);
}

.side-nav ul {
  list-style: none;
  padding: 0;
  margin: 0;
}

.nav-item {
  padding: 10px 14px;
  border-radius: 999px;
  margin-bottom: 6px;
  font-size: 14px;
  cursor: pointer;
  color: #e5e7eb;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.nav-item:hover {
  background: rgba(55, 65, 81, 0.9);
}

.nav-item.active {
  background: linear-gradient(90deg, #22c55e, #22d3ee);
  color: #020617;
}

.nav-logout {
  margin-top: 12px;
  color: #f97373;
}

.content {
  max-width: 960px;
  margin: 80px auto 32px;
  padding: 0 16px;
}

.card {
  background: radial-gradient(circle at top left, #111827, #020617);
  border-radius: 24px;
  padding: 24px 20px 24px;
  border: 1px solid rgba(148, 163, 184, 0.3);
  box-shadow: 0 24px 80px rgba(15, 23, 42, 0.9);
}

.section.hidden {
  display: none;
}

.section.active {
  display: block;
}

h1,
h2,
h3 {
  margin-top: 0;
  color: #f9fafb;
}

.subtitle {
  margin-top: 4px;
  margin-bottom: 20px;
  color: #9ca3af;
  font-size: 14px;
}

.muted {
  color: #6b7280;
  font-size: 13px;
}

.form {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

label {
  font-size: 13px;
  color: #d1d5db;
}

input,
select,
textarea {
  border-radius: 12px;
  border: 1px solid rgba(148, 163, 184, 0.35);
  padding: 8px 10px;
  font-size: 14px;
  background: rgba(15, 23, 42, 0.9);
  color: #e5e7eb;
}

input:focus,
select:focus,
textarea:focus {
  outline: none;
  border-color: #22c55e;
  box-shadow: 0 0 0 1px rgba(34, 197, 94, 0.5);
}

.btn {
  border-radius: 999px;
  border: none;
  padding: 9px 16px;
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
}

.btn.primary {
  background: linear-gradient(90deg, #22c55e, #22d3ee);
  color: #020617;
}

.btn.secondary {
  background: rgba(55, 65, 81, 0.9);
  color: #e5e7eb;
}

.btn:disabled {
  opacity: 0.6;
  cursor: default;
}

.error-text {
  color: #f97373;
  font-size: 13px;
}

.status-text {
  font-size: 13px;
  color: #22c55e;
  margin-left: 8px;
}

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

.list {
  margin-top: 16px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.list-item {
  border-radius: 16px;
  padding: 10px 12px;
  background: rgba(15, 23, 42, 0.95);
  border: 1px solid rgba(148, 163, 184, 0.3);
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
}

.list-item-main {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.list-title {
  font-size: 14px;
  font-weight: 500;
}

.list-meta {
  font-size: 12px;
  color: #9ca3af;
}

.chip {
  display: inline-flex;
  padding: 2px 8px;
  border-radius: 999px;
  font-size: 11px;
  border: 1px solid rgba(148, 163, 184, 0.6);
  color: #e5e7eb;
}

.chip.goal {
  border-color: #22d3ee;
}

.chip.tournament {
  border-color: #22c55e;
}

.pill-btn {
  border-radius: 999px;
  border: 1px solid rgba(148, 163, 184, 0.5);
  background: transparent;
  color: #e5e7eb;
  font-size: 12px;
  padding: 4px 10px;
  cursor: pointer;
}

.pill-btn.danger {
  border-color: #f97373;
  color: #fecaca;
}

.plan-output {
  margin-top: 16px;
  max-height: 520px;
  overflow: auto;
  padding: 12px 12px 4px;
  border-radius: 16px;
  background: rgba(15, 23, 42, 0.95);
  border: 1px solid rgba(148, 163, 184, 0.4);
  font-size: 14px;
}

.plan-output h1,
.plan-output h2,
.plan-output h3,
.plan-output h4 {
  margin-top: 10px;
}

.plan-output ul {
  padding-left: 20px;
}

.calendar-layout {
  margin-bottom: 20px;
}

.calendar-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 8px;
}

.calendar-grid {
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  gap: 4px;
  font-size: 12px;
}

.calendar-day {
  min-height: 60px;
  border-radius: 12px;
  padding: 4px 4px 6px;
  background: rgba(15, 23, 42, 0.9);
  border: 1px solid rgba(55, 65, 81, 0.9);
}

.calendar-day-label {
  font-size: 11px;
  color: #6b7280;
  margin-bottom: 2px;
}

.calendar-date {
  font-size: 12px;
  font-weight: 500;
}

.calendar-event-dot {
  width: 6px;
  height: 6px;
  border-radius: 999px;
  display: inline-block;
  margin-right: 3px;
}

.calendar-event-dot.goal {
  background: #22d3ee;
}

.calendar-event-dot.tournament {
  background: #22c55e;
}

.calendar-events {
  margin-top: 2px;
}

.icon-btn {
  border-radius: 999px;
  border: 1px solid rgba(148, 163, 184, 0.5);
  background: rgba(15, 23, 42, 0.9);
  color: #e5e7eb;
  width: 28px;
  height: 24px;
  cursor: pointer;
}

@media (min-width: 768px) {
  .side-nav {
    transform: translateX(0);
  }

  .content {
    margin-left: 240px;
  }
}

.hidden {
  display: none !important;
}

