:root {
  --bg: #0f1220;
  --page-grad-1: #eef1ff;
  --page-grad-2: #f7f5ff;
  --card-bg: #ffffff;
  --border: #ecebf3;
  --text: #1a1b2e;
  --muted: #8d8ea3;
  --accent: #6d5ef8;
  --accent-soft: #f0edff;
  --weekend: #ff5a7a;
  --weekend-soft: #ffe9ee;
  --holiday-national: #6d5ef8;
  --holiday-religious: #0fb787;
  --holiday-cultural: #ff9f43;
  --today-ring: #1a1b2e;
  --radius: 18px;
}

body {
  margin: 0;
  padding: 110px 20px 70px;
  background: linear-gradient(160deg, var(--page-grad-1), var(--page-grad-2));
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  color: var(--text);
}

nav {
  background: rgba(10, 24, 64, 0.96) !important;
  backdrop-filter: blur(20px) !important;
  -webkit-backdrop-filter: blur(20px) !important;
  box-shadow: 0 1px 0 rgba(37,99,235,0.25), 0 12px 30px rgba(14,36,120,0.18) !important;
  border-bottom: 1px solid rgba(96, 165, 250, 0.2) !important;
}

.nav-links > li > a,
.logo-name,
.logo-sub,
.nav-login-btn,
.nav-apply,
.arr,
.mob-nav-title {
  color: #fff !important;
}

.header {
  max-width: 960px;
  margin: 0 auto 32px;
  text-align: center;
}

.eyebrow {
  display: inline-block;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--accent);
  background: var(--accent-soft);
  padding: 6px 14px;
  border-radius: 999px;
  margin-bottom: 14px;
}

h1 {
  font-size: 32px;
  font-weight: 600;
  margin: 0 0 8px;
  letter-spacing: -0.02em;
}

.subtitle {
  color: var(--muted);
  font-size: 14px;
  margin: 0;
}

.total-academic-days {
  margin: 12px auto 0;
  font-size: 15px;
  color: #2b2f46;
  font-weight: 500;
}

.total-academic-days strong {
  color: #0f172a;
  font-weight: 700;
}

.legend {
  max-width: 960px;
  margin: 22px auto 0;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 10px 20px;
  font-size: 12.5px;
  color: var(--muted);
}

.legend-item {
  display: flex;
  align-items: center;
  gap: 6px;
}

.dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  display: inline-block;
  flex-shrink: 0;
}

.dot.national { background: var(--holiday-national); }
.dot.religious { background: var(--holiday-religious); }
.dot.cultural { background: var(--holiday-cultural); }
.dot.weekend { background: var(--weekend); }

.calendar-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 22px;
  max-width: 1400px;
  margin: 32px auto 0;
}

.month-card {
  background: var(--card-bg);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 20px 22px 22px;
  box-shadow: 0 1px 2px rgba(20,20,50,0.03), 0 12px 28px -18px rgba(20,20,50,0.18);
}

.month-header {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  margin-bottom: 16px;
}

.month-title {
  font-size: 17px;
  font-weight: 600;
  margin: 0;
  letter-spacing: -0.01em;
}

.month-num {
  font-size: 11px;
  color: var(--muted);
  font-weight: 500;
}

table {
  width: 100%;
  border-collapse: collapse;
  table-layout: fixed;
}

th {
  font-size: 10.5px;
  font-weight: 600;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.03em;
  padding-bottom: 10px;
  text-align: center;
}

th.weekend { color: var(--weekend); }

td {
  text-align: center;
  padding: 3px 0;
  height: 34px;
}

.day-cell {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  font-size: 13px;
  font-weight: 400;
  color: var(--text);
  border: 1px solid transparent;
  transition: all 0.2s ease;
}

td.weekend .day-cell { color: var(--weekend); font-weight: 500; }
td.weekend { background: transparent; }

td.holiday .day-cell,
td.custom-holiday .day-cell {
  background: var(--accent-soft);
  color: var(--accent);
  font-weight: 600;
  border-color: rgba(109, 94, 248, 0.25);
}

td.comment-day .day-cell,
td.custom-comment .day-cell,
td.comment .day-cell {
  background: linear-gradient(135deg, #fff1f2 0%, #fee2e2 100%);
  color: #b91c1c;
  font-weight: 700;
  border-color: rgba(239, 68, 68, 0.6);
  box-shadow: 0 0 0 2px rgba(239, 68, 68, 0.13), 0 8px 18px -12px rgba(185, 28, 28, 0.65);
  transform: scale(1.04);
}

td.holiday-day .day-cell,
td.holiday.weekend .day-cell,
td.custom-holiday.weekend .day-cell {
  background: linear-gradient(135deg, #fff1f2 0%, #fee2e2 100%);
  color: #b91c1c;
  font-weight: 700;
  border-color: rgba(239, 68, 68, 0.6);
  box-shadow: 0 0 0 2px rgba(239, 68, 68, 0.13), 0 8px 18px -12px rgba(185, 28, 28, 0.65);
  transform: scale(1.04);
}

.hmark.holiday,
.hmark.national {
  background: #dc2626;
}

td.holiday.weekend .day-cell,
td.custom-holiday.weekend .day-cell {
  background: var(--weekend-soft);
  color: var(--weekend);
}

td.today .day-cell {
  background: var(--today-ring);
  color: #fff;
  font-weight: 600;
}

.hmark {
  position: absolute;
  bottom: 2px;
  left: 50%;
  transform: translateX(-50%);
  width: 7px;
  height: 7px;
  border-radius: 50%;
  box-shadow: 0 0 0 2px rgba(255,255,255,0.8);
}

.hmark.national { background: #dc2626; }
.hmark.religious { background: var(--holiday-religious); }
.hmark.cultural { background: var(--holiday-cultural); }

td.today .hmark { background: #fff; }

.holiday-list {
  margin-top: 14px;
  padding-top: 12px;
  border-top: 1px solid var(--border);
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.holiday-row {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  font-size: 11.5px;
  color: var(--muted);
  background: #f8f8ff;
  border: 1px solid #eeeaff;
  border-radius: 10px;
  padding: 8px 9px;
}

.holiday-row .hd {
  font-weight: 700;
  color: var(--text);
  min-width: 22px;
  flex-shrink: 0;
}

.holiday-row .hn {
  flex: 1;
  line-height: 1.5;
}

.holiday-row .hn strong {
  display: block;
  color: var(--text);
  font-size: 11.8px;
  margin-bottom: 2px;
}

.holiday-row .comment {
  display: block;
  color: #4b5563;
  font-size: 10.7px;
  line-height: 1.45;
}

.footnote {
  max-width: 960px;
  margin: 28px auto 0;
  font-size: 12px;
  color: var(--muted);
  text-align: center;
  line-height: 1.6;
}

.calendar-page-bottom-space {
  height: 50px;
}

@media (min-width: 1100px) {
  .calendar-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

@media (max-width: 640px) {
  .calendar-grid { grid-template-columns: 1fr; }
  body { padding: 100px 14px 50px; }
  h1 { font-size: 24px; }
}
