:root {
  --kt-red: #ef3542;
  --kt-red-dark: #b4232e;
  --kt-blue: #1367ad;
  --kt-blue-soft: #eaf4ff;
  --kt-ink: #15181d;
  --kt-surface: #ffffff;
  --kt-canvas: #f4f6f8;
  --kt-muted: #65707c;
  --kt-line: #dce2e8;
  --kt-line-dark: #b9c2cb;
  --kt-shadow: 0 12px 32px rgba(0, 0, 0, 0.12);
  font-family: Inter, ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI", Arial, sans-serif;
}

* {
  box-sizing: border-box;
}

html,
body {
  min-height: 100%;
  margin: 0;
}

body {
  overflow-x: hidden;
  background: #111315;
  color: var(--kt-ink);
}

button,
input,
select,
textarea {
  font: inherit;
}

button {
  cursor: pointer;
}

button:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible,
summary:focus-visible {
  outline: 3px solid rgba(19, 103, 173, 0.45);
  outline-offset: 3px;
}

.app-root {
  min-height: 100vh;
}

.login-shell,
.center-shell {
  display: grid;
  min-height: 100vh;
  place-items: center;
  padding: 20px;
}

.login-card,
.card {
  width: min(100%, 620px);
  background: var(--kt-surface);
  border: 1px solid rgba(255, 255, 255, 0.38);
  border-radius: 16px;
  box-shadow: var(--kt-shadow);
  padding: 24px;
}

.login-card {
  border-top: 5px solid var(--kt-red);
}

.login-logo {
  display: block;
  width: min(250px, 82%);
  margin: 0 auto 22px;
}

.app-kicker,
.section-label {
  margin: 0 0 8px;
  color: var(--kt-red);
  font-size: 13px;
  font-weight: 800;
  letter-spacing: 0.09em;
  text-transform: uppercase;
}

.app-kicker span {
  color: var(--kt-muted);
  font-weight: 700;
}

h1,
h2,
h3,
p {
  margin-top: 0;
}

h1,
h2,
h3 {
  color: var(--kt-ink);
  letter-spacing: 0;
  line-height: 1.1;
}

h1 {
  font-size: 36px;
}

h2 {
  font-size: 28px;
  margin-bottom: 12px;
}

.login-card h1 {
  margin-bottom: 24px;
  font-size: 42px;
}

.form-stack {
  display: grid;
  gap: 18px;
}

label {
  display: grid;
  gap: 8px;
  color: #2b333d;
  font-size: 15px;
  font-weight: 750;
}

input,
select,
textarea {
  width: 100%;
  min-height: 50px;
  border: 1px solid var(--kt-line-dark);
  border-radius: 10px;
  background: #fff;
  padding: 12px 13px;
  color: var(--kt-ink);
  font-size: 17px;
}

select {
  appearance: auto;
}

textarea {
  min-height: 98px;
  resize: vertical;
}

input::placeholder,
textarea::placeholder {
  color: #8b95a1;
}

input:focus,
select:focus,
textarea:focus {
  border-color: var(--kt-blue);
  box-shadow: 0 0 0 3px rgba(19, 103, 173, 0.12);
  outline: none;
}

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

.check-row input {
  width: 22px;
  height: 22px;
  min-height: 0;
}

.primary-button,
.secondary-button,
.logout-button,
.text-button,
.mini-button {
  min-height: 48px;
  border-radius: 10px;
  border: 1px solid transparent;
  padding: 11px 16px;
  font-weight: 800;
}

.primary-button {
  background: var(--kt-red);
  color: #fff;
}

.primary-button:hover {
  background: var(--kt-red-dark);
}

.secondary-button {
  background: #252a30;
  color: #fff;
}

.secondary-button:hover {
  background: #121417;
}

.text-button {
  min-height: auto;
  background: transparent;
  color: var(--kt-blue);
  padding: 8px 0;
}

.text-button:hover {
  color: #0e4f86;
  text-decoration: underline;
}

.mini-button {
  background: #f2f4f6;
  border-color: var(--kt-line);
  color: #20262d;
}

.mini-button:hover {
  background: #e7ebef;
}

.mini-button:disabled,
.action-card:disabled {
  cursor: progress;
  opacity: 0.58;
}

.alert,
.notice {
  margin-bottom: 4px;
  border-radius: 10px;
  padding: 14px 15px;
  font-size: 15px;
  font-weight: 750;
}

.alert {
  border: 1px solid #ffbac1;
  background: #fff1f2;
  color: #94242d;
}

.notice {
  border: 1px solid #c7e2fa;
  background: #eff8ff;
  color: #155989;
}

.test-logins {
  margin-top: 18px;
  color: var(--kt-muted);
  font-size: 14px;
}

.test-logins summary {
  cursor: pointer;
  color: #323a45;
  font-weight: 800;
}

.test-logins p {
  margin: 7px 0 0;
}

.app-shell {
  width: min(100%, 1360px);
  margin: 0 auto;
  padding: 12px;
}

.topbar {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 18px;
  border-top: 4px solid var(--kt-red);
  box-shadow: inset 0 -4px 0 var(--kt-blue), var(--kt-shadow);
  padding: 18px;
  border-radius: 16px;
  background: var(--kt-surface);
}

.brand-block {
  display: flex;
  min-width: 0;
  gap: 14px;
  align-items: center;
}

.brand-block img {
  width: 110px;
  max-width: 36%;
  object-fit: contain;
}

.brand-copy {
  min-width: 0;
}

.brand-block h1 {
  margin: 0;
  overflow-wrap: anywhere;
}

.brand-subtitle {
  margin: 7px 0 0;
  color: var(--kt-muted);
  font-size: 14px;
  font-weight: 650;
}

.brand-korean {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin: 8px 0 0;
  color: #272d34;
  font-size: 12px;
  font-weight: 900;
  letter-spacing: 0.12em;
}

.brand-korean span {
  display: block;
  width: 28px;
  height: 3px;
  background: var(--kt-red);
  box-shadow: 11px 0 0 var(--kt-blue);
}

.header-controls {
  display: grid;
  gap: 12px;
}

.studio-selector {
  display: grid;
  gap: 6px;
  min-width: 0;
}

.studio-selector select,
.language-selector select {
  min-height: 48px;
  font-size: 16px;
}

.language-selector {
  display: grid;
  gap: 6px;
  min-width: 0;
}

.single-studio-label {
  display: grid;
  gap: 3px;
  padding: 9px 0;
  color: var(--kt-muted);
  font-size: 13px;
}

.single-studio-label strong {
  color: var(--kt-ink);
  font-size: 16px;
}

.logout-button {
  min-height: 48px;
  border-color: #ebc8cb;
  background: #fff;
  color: var(--kt-red-dark);
}

.logout-button:hover {
  border-color: var(--kt-red);
  background: #fff6f6;
}

.module-nav {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
  padding: 14px 0 18px;
}

.module-nav button {
  min-height: 48px;
  border: 1px solid #30343a;
  border-radius: 10px;
  background: #1e2125;
  color: #f7f8f9;
  font-size: 14px;
  font-weight: 750;
}

.module-nav button:hover {
  background: #30353a;
}

.module-nav button.active {
  border-color: var(--kt-red);
  background: var(--kt-red);
  color: #fff;
}

.content-shell {
  display: grid;
  gap: 16px;
  min-width: 0;
  padding-bottom: 52px;
}

.screen-heading {
  color: #fff;
}

.screen-heading h2 {
  margin-bottom: 7px;
  color: #fff;
  font-size: 30px;
}

.screen-heading > div > p:last-child {
  max-width: 620px;
  margin: 0;
  color: #c5cbd1;
  font-size: 16px;
  line-height: 1.45;
}

.workspace-status {
  display: grid;
  gap: 4px;
  margin-top: 16px;
  border-left: 3px solid var(--kt-red);
  padding: 7px 0 7px 12px;
  color: #d6dce2;
}

.workspace-status span {
  color: #ff8a92;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.07em;
  text-transform: uppercase;
}

.workspace-status strong {
  font-size: 14px;
  line-height: 1.35;
}

.action-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.action-card {
  display: grid;
  min-width: 0;
  min-height: 124px;
  gap: 7px;
  align-content: start;
  border: 1px solid var(--kt-line);
  border-radius: 14px;
  background: #fff;
  color: var(--kt-ink);
  padding: 16px;
  text-align: left;
  box-shadow: 0 7px 18px rgba(0, 0, 0, 0.09);
}

.action-card:hover {
  transform: translateY(-1px);
  border-color: #aeb8c2;
  box-shadow: 0 11px 24px rgba(0, 0, 0, 0.13);
}

.action-card strong {
  font-size: 18px;
  line-height: 1.15;
}

.action-card small {
  color: var(--kt-muted);
  font-size: 13px;
  font-weight: 650;
  line-height: 1.32;
}

.action-kicker {
  color: var(--kt-red);
  font-size: 11px;
  font-weight: 850;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.action-primary,
.action-publish {
  grid-column: 1 / -1;
}

.action-primary {
  border-color: var(--kt-red);
  background: var(--kt-red);
  color: #fff;
  box-shadow: inset 5px 0 0 var(--kt-blue), 0 7px 18px rgba(0, 0, 0, 0.13);
}

.action-primary:hover {
  border-color: var(--kt-red-dark);
  background: var(--kt-red-dark);
}

.action-primary .action-kicker,
.action-primary small {
  color: #fff;
}

.action-publish {
  border-color: #0d5b9f;
  background: #1268ad;
  color: #fff;
}

.action-publish:hover {
  border-color: #0a4e86;
  background: #0d5b9f;
}

.action-publish .action-kicker,
.action-publish small {
  color: #fff;
}

.content-card,
.form-card,
.preview-card {
  width: 100%;
}

.card-heading {
  display: flex;
  min-width: 0;
  gap: 12px;
  align-items: start;
  justify-content: space-between;
  margin-bottom: 12px;
}

.card-heading h2 {
  margin-bottom: 0;
  font-size: 25px;
}

.card-count {
  display: grid;
  width: 34px;
  height: 34px;
  flex: 0 0 auto;
  place-items: center;
  border-radius: 50%;
  background: #eef1f4;
  color: #333b45;
  font-size: 14px;
  font-weight: 850;
}

.form-studio,
.staging-badge {
  flex: 0 0 auto;
  border-radius: 999px;
  background: var(--kt-blue-soft);
  color: #0c528d;
  padding: 7px 10px;
  font-size: 12px;
  font-weight: 800;
  text-align: center;
}

.event-list,
.daily-list,
.staff-list {
  display: grid;
  gap: 10px;
}

.event-row,
.daily-row,
.staff-card {
  display: grid;
  min-width: 0;
  grid-template-columns: 54px minmax(0, 1fr);
  gap: 12px;
  align-items: center;
  border: 1px solid var(--kt-line);
  border-radius: 12px;
  background: #fff;
  padding: 12px;
}

.event-row.has-actions {
  grid-template-columns: 54px minmax(0, 1fr);
}

.event-row > div:nth-child(2) {
  display: grid;
  gap: 3px;
  min-width: 0;
}

.event-row strong,
.daily-row strong {
  font-size: 17px;
}

.event-row span,
.daily-row span,
.staff-card span,
.staff-card small,
.soft-text,
.empty-text {
  color: var(--kt-muted);
  font-weight: 600;
  line-height: 1.4;
}

.event-row span,
.daily-row span {
  overflow-wrap: anywhere;
}

.event-row.has-actions .mini-button {
  grid-column: 1 / -1;
}

.date-pill {
  display: grid;
  min-height: 48px;
  place-items: center;
  border-radius: 10px;
  background: #20252b;
  color: #fff;
  font-size: 13px;
  font-weight: 850;
  text-align: center;
}

.daily-row {
  grid-template-columns: 92px minmax(0, 1fr);
  background: #f8fafb;
}

.daily-row strong {
  color: var(--kt-red);
}

.group-box {
  min-width: 0;
  margin: 0;
  border: 1px solid var(--kt-line);
  border-radius: 12px;
  background: #f8fafb;
  padding: 16px;
}

.group-box legend {
  padding: 0 6px;
  color: var(--kt-ink);
  font-size: 15px;
  font-weight: 850;
}

.two-column,
.session-row {
  display: grid;
  gap: 12px;
}

.session-row + .session-row {
  margin-top: 14px;
  border-top: 1px solid var(--kt-line);
  padding-top: 14px;
}

.full-width {
  width: 100%;
  margin-top: 14px;
}

.form-actions {
  display: grid;
  gap: 10px;
}

.preview-box {
  border: 1px solid #cfe1f1;
  border-radius: 12px;
  background: #f5faff;
  padding: 15px;
}

.preview-box p {
  margin: 6px 0;
  font-weight: 700;
}

.preview-heading {
  display: flex;
  gap: 12px;
  align-items: start;
  justify-content: space-between;
}

.preview-heading h2 {
  margin-bottom: 0;
  font-size: 29px;
}

.preview-help {
  margin: 17px 0;
  border-left: 3px solid var(--kt-blue);
  background: #f2f8fd;
  color: #194f78;
  padding: 12px 13px;
  font-size: 15px;
  font-weight: 650;
  line-height: 1.45;
}

.preview-toolbar {
  display: grid;
  gap: 10px;
  margin-bottom: 20px;
}

.preview-toolbar label {
  min-width: 0;
}

.preview-agenda {
  display: grid;
  gap: 9px;
  margin-bottom: 20px;
}

.preview-agenda h3 {
  margin: 0 0 2px;
  color: var(--kt-ink);
  font-size: 18px;
}

.agenda-event {
  display: grid;
  min-width: 0;
  grid-template-columns: 58px minmax(0, 1fr);
  gap: 12px;
  border: 1px solid var(--kt-line);
  border-radius: 12px;
  background: #fff;
  padding: 12px;
}

.agenda-event.is-closure {
  border-color: #f4c4c9;
  background: #fff7f7;
}

.agenda-date {
  display: grid;
  align-self: start;
  min-height: 48px;
  place-items: center;
  border-radius: 10px;
  background: #20252b;
  color: #fff;
  font-size: 13px;
  font-weight: 850;
  text-align: center;
}

.agenda-event.is-closure .agenda-date {
  background: var(--kt-red);
}

.agenda-event > div:last-child {
  display: grid;
  min-width: 0;
  gap: 4px;
}

.agenda-event strong {
  font-size: 17px;
}

.agenda-event span {
  color: var(--kt-muted);
  font-size: 14px;
  font-weight: 650;
  overflow-wrap: anywhere;
}

.agenda-sessions {
  display: grid;
  gap: 6px;
  margin-top: 7px;
  padding-top: 8px;
  border-top: 1px solid var(--kt-line);
}

.agenda-sessions div {
  display: grid;
  grid-template-columns: 84px minmax(0, 1fr);
  gap: 10px;
  align-items: baseline;
}

.agenda-sessions strong,
.agenda-sessions span {
  font-size: 14px;
}

.calendar-grid-details {
  border-top: 1px solid var(--kt-line);
  padding-top: 15px;
}

.calendar-grid-details summary {
  cursor: pointer;
  color: #20262d;
  font-size: 15px;
  font-weight: 800;
}

.calendar-preview-shell {
  overflow: hidden;
  margin-top: 14px;
  border: 1px solid #69727c;
  border-radius: 10px;
  background: #fff;
}

.calendar-weekdays,
.calendar-preview-grid {
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
}

.calendar-weekdays {
  background: #20252b;
  color: #fff;
  font-weight: 800;
  text-align: center;
}

.calendar-weekdays div {
  padding: 10px 3px;
  font-size: 14px;
}

.calendar-day {
  display: grid;
  min-width: 0;
  min-height: 122px;
  gap: 6px;
  align-content: start;
  border-top: 1px solid #cfd5db;
  border-right: 1px solid #cfd5db;
  padding: 7px;
}

.calendar-day:nth-child(7n) {
  border-right: 0;
}

.calendar-day.outside-month {
  background: #fafbfc;
  color: #a1a8b0;
}

.calendar-day-number {
  justify-self: end;
  color: #313841;
  font-size: 16px;
  font-weight: 850;
}

.outside-month .calendar-day-number {
  color: #a1a8b0;
}

.calendar-day-events {
  display: grid;
  min-width: 0;
  gap: 5px;
}

.calendar-event-pill {
  display: grid;
  min-width: 0;
  gap: 2px;
  border-radius: 7px;
  border-left: 3px solid var(--kt-blue);
  background: var(--kt-blue-soft);
  padding: 5px;
}

.calendar-event-pill.is-closure {
  border-left-color: var(--kt-red);
  background: #fff0f1;
}

.calendar-event-pill strong,
.calendar-event-pill span,
.calendar-day-events small {
  overflow-wrap: anywhere;
  line-height: 1.17;
}

.calendar-event-pill strong {
  color: #1a222a;
  font-size: 12px;
}

.calendar-event-pill span,
.calendar-day-events small {
  color: var(--kt-muted);
  font-size: 11px;
  font-weight: 700;
}

.staff-card {
  grid-template-columns: 1fr;
  align-items: start;
}

.coming-soon {
  min-height: 220px;
}

@media (min-width: 700px) {
  .app-shell {
    display: grid;
    grid-template-columns: 210px minmax(0, 1fr);
    gap: 22px;
    padding: 22px;
  }

  .topbar {
    grid-column: 1 / -1;
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
    padding: 20px 22px;
  }

  .brand-block img {
    width: 150px;
    max-width: none;
  }

  .brand-block h1 {
    font-size: 42px;
  }

  .header-controls {
    grid-template-columns: minmax(190px, 260px) minmax(126px, 145px) auto;
    align-items: end;
  }

  .logout-button {
    min-width: 96px;
  }

  .module-nav {
    position: sticky;
    top: 16px;
    display: grid;
    grid-template-columns: 1fr;
    align-self: start;
    gap: 6px;
    padding: 0;
  }

  .module-nav button {
    min-height: 48px;
    padding: 10px 12px;
    text-align: left;
  }

  .content-shell {
    gap: 18px;
  }

  .screen-heading {
    display: flex;
    gap: 24px;
    align-items: end;
    justify-content: space-between;
    padding: 4px 0 2px;
  }

  .screen-heading h2 {
    font-size: 38px;
  }

  .workspace-status {
    width: min(315px, 35%);
    margin: 0 0 4px;
  }

  .action-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }

  .action-card {
    min-height: 136px;
  }

  .action-primary {
    grid-column: span 2;
  }

  .action-publish {
    grid-column: span 2;
  }

  .two-column {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .session-row {
    grid-template-columns: minmax(120px, 0.75fr) minmax(150px, 1fr) minmax(150px, 1fr) auto;
    align-items: end;
  }

  .nunchuck-row {
    grid-template-columns: minmax(120px, 0.75fr) minmax(200px, 1fr) auto;
  }

  .form-actions {
    grid-template-columns: auto auto auto;
    justify-content: start;
  }

  .event-row.has-actions {
    grid-template-columns: 58px minmax(0, 1fr) auto;
  }

  .event-row.has-actions .mini-button {
    grid-column: auto;
  }

  .staff-list {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .preview-heading {
    align-items: center;
  }

  .preview-toolbar {
    grid-template-columns: auto minmax(200px, 280px) auto auto;
    align-items: end;
  }

  .calendar-grid-details summary {
    cursor: default;
    list-style: none;
  }

  .calendar-grid-details summary::-webkit-details-marker {
    display: none;
  }

  .calendar-day {
    min-height: 132px;
  }
}

@media (min-width: 1050px) {
  .app-shell {
    grid-template-columns: 230px minmax(0, 1fr);
  }

  .action-card strong {
    font-size: 19px;
  }

  .card,
  .login-card {
    padding: 28px;
  }
}

@media (max-width: 420px) {
  .app-shell {
    padding: 8px;
  }

  .topbar,
  .login-card,
  .card {
    padding: 16px;
  }

  .brand-block img {
    width: 94px;
  }

  .brand-block h1 {
    font-size: 30px;
  }

  .module-nav {
    gap: 6px;
    padding: 10px 0 16px;
  }

  .module-nav button {
    min-height: 44px;
    font-size: 13px;
  }

  .screen-heading h2 {
    font-size: 28px;
  }

  .action-card {
    min-height: 118px;
    padding: 14px;
  }

  .action-card strong {
    font-size: 17px;
  }

  .form-studio {
    max-width: 110px;
    overflow-wrap: anywhere;
  }

  .agenda-event {
    grid-template-columns: 1fr;
  }

  .agenda-date {
    width: max-content;
  }

  .calendar-weekdays div {
    padding: 8px 2px;
    font-size: 10px;
  }

  .calendar-day {
    min-height: 86px;
    gap: 4px;
    padding: 4px;
  }

  .calendar-day-number {
    font-size: 12px;
  }

  .calendar-event-pill {
    padding: 4px;
  }

  .calendar-event-pill strong {
    font-size: 9px;
  }

  .calendar-event-pill span,
  .calendar-day-events small {
    font-size: 8px;
  }
}
