@import url('https://cdn.jsdelivr.net/gh/orioncactus/pretendard@v1.3.9/dist/web/static/pretendard.min.css');

:root {
  /* DCU 네이비(로고) → 블루 → 바이올렛 */
  --navy: #053a7c;
  --blue: #2f5bea;
  --indigo: #4f46e5;
  --violet: #7c3aed;
  --brand: #5b4ee8;
  --brand-dark: #3b2fa8;
  --grad: linear-gradient(135deg, #053a7c 0%, #2f5bea 48%, #7c3aed 100%);
  --grad-soft: linear-gradient(135deg, #eef3ff 0%, #f4f0ff 100%);
  --grad-btn: linear-gradient(100deg, #2f5bea 0%, #5b4ee8 55%, #7c3aed 100%);
  --ink: #1a1b3a;
  --sub: #6b6f8a;
  --line: #e7e5f2;
  --field: #f7f7fc;
  --bg: #f4f3fb;
  --red: #e0245e;
  --amber-bg: #fff8eb;
  --amber-line: #fbd38d;
  --amber-ink: #8a4b08;
  --green: #059669;
  --radius: 14px;
}
* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
body {
  font-family: 'Pretendard', 'Apple SD Gothic Neo', 'Malgun Gothic', sans-serif;
  color: var(--ink); background: var(--bg); font-size: 15px; line-height: 1.55;
  -webkit-font-smoothing: antialiased; letter-spacing: -0.01em;
}
button, input, select, textarea { font: inherit; color: inherit; letter-spacing: inherit; }
a { color: var(--blue); }
.hidden { display: none !important; }

/* ---------- 학생 신청서 ---------- */
body.apply-body {
  background:
    radial-gradient(900px 500px at 0% 0%, #e6ecff 0%, transparent 60%),
    radial-gradient(800px 500px at 100% 100%, #efe7ff 0%, transparent 60%),
    #f6f5fc;
  min-height: 100vh;
}
.wrap { max-width: 560px; margin: 0 auto; min-height: 100vh; }
@media (min-width: 600px) { .wrap { margin: 28px auto 40px; min-height: auto; } }

.hero {
  position: relative; overflow: hidden; color: #fff;
  background: var(--grad);
  padding: 22px 24px 58px;
}
@media (min-width: 600px) { .hero { border-radius: 26px 26px 0 0; } }
.hero::before, .hero::after {
  content: ''; position: absolute; border-radius: 50%; pointer-events: none;
}
.hero::before { width: 260px; height: 260px; right: -80px; top: -90px; background: radial-gradient(circle, rgba(255,255,255,.28), rgba(255,255,255,0) 70%); }
.hero::after { width: 220px; height: 220px; left: -70px; bottom: -110px; background: radial-gradient(circle, rgba(167,139,250,.55), rgba(167,139,250,0) 70%); }
.hero > * { position: relative; z-index: 1; }
.hero .logo { height: 26px; width: auto; display: block; }
.hero .tag {
  display: inline-flex; align-items: center; gap: 6px; margin-top: 22px;
  background: rgba(255,255,255,.16); border: 1px solid rgba(255,255,255,.28);
  padding: 5px 12px; border-radius: 999px; font-size: 12.5px; font-weight: 700;
  backdrop-filter: blur(6px);
}
.hero .tag i { width: 6px; height: 6px; border-radius: 50%; background: #c4f1ff; box-shadow: 0 0 0 3px rgba(196,241,255,.25); }
.hero h1 { margin: 12px 0 6px; font-size: 27px; line-height: 1.25; font-weight: 800; letter-spacing: -0.03em; }
.hero h1 small { display: block; font-size: 15px; font-weight: 600; opacity: .85; letter-spacing: -0.01em; margin-bottom: 2px; }
.hero p { margin: 0; font-size: 14px; opacity: .88; }

.body {
  position: relative; margin-top: -30px; background: #fff;
  border-radius: 26px 26px 0 0; padding: 10px 22px 30px;
  box-shadow: 0 -6px 24px rgba(40,30,120,.06);
}
@media (min-width: 600px) { .body { border-radius: 26px; box-shadow: 0 18px 50px rgba(40,30,120,.10); } }

.sec { margin-top: 30px; }
.sec-title { display: flex; align-items: center; gap: 10px; font-size: 17px; font-weight: 800; margin: 0 0 16px; letter-spacing: -0.02em; }
.sec-title .num {
  display: inline-flex; align-items: center; justify-content: center; width: 28px; height: 28px; border-radius: 9px;
  background: var(--grad); color: #fff; font-size: 12.5px; font-weight: 800; box-shadow: 0 4px 10px rgba(91,78,232,.28);
}
.field { margin-bottom: 18px; }
.label { display: block; font-size: 14px; font-weight: 700; margin-bottom: 7px; color: #2a2c4f; }
.req { color: var(--red); font-size: 11.5px; font-weight: 700; margin-left: 5px; }
.opt { color: #8a8fb0; font-size: 11.5px; font-weight: 600; margin-left: 5px; }
.input, .select, textarea.input {
  width: 100%; border: 1.5px solid var(--line); background: var(--field); border-radius: 12px;
  padding: 12px 14px; outline: none; transition: border-color .15s, background .15s, box-shadow .15s;
  -webkit-appearance: none; appearance: none;
}
.select {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1l5 5 5-5' fill='none' stroke='%236b6f8a' stroke-width='1.8' stroke-linecap='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-position: right 14px center; padding-right: 36px;
}
.input::placeholder { color: #a6a9c2; }
.input:focus, .select:focus { border-color: #8b7cf6; background-color: #fff; box-shadow: 0 0 0 4px rgba(124,58,237,.12); }
.input[readonly] { color: #3a3d5c; }
.row { display: flex; gap: 8px; align-items: center; }
.row > * { min-width: 0; }
.grow { flex: 1; }
.dash { color: var(--sub); }
.rrn-back { display: flex; align-items: center; gap: 6px; flex: 1; }
.rrn-back .input { width: 56px; text-align: center; flex: none; }
.dots { letter-spacing: 3px; color: #b3b5cc; font-size: 13px; white-space: nowrap; }
.btn {
  border: 0; border-radius: 12px; padding: 12px 16px; font-weight: 700; cursor: pointer;
  background: #2a2c4f; color: #fff; white-space: nowrap; transition: transform .1s, box-shadow .15s, opacity .15s;
}
.btn:active { transform: translateY(1px); }
.btn:disabled { opacity: .55; cursor: not-allowed; }
.btn-primary { background: var(--grad-btn); box-shadow: 0 6px 16px rgba(91,78,232,.28); }
.btn-ghost { background: #fff; color: var(--ink); border: 1.5px solid var(--line); box-shadow: none; }
.btn-danger { background: #fff; color: var(--red); border: 1.5px solid #fbc7d6; }
.btn-soft { background: #efeaff; color: #4c1d95; }
.btn-sm { padding: 7px 11px; font-size: 13px; border-radius: 9px; }
.btn-block { width: 100%; padding: 16px; font-size: 16.5px; border-radius: 16px; }
.help { font-size: 13px; color: var(--sub); margin-top: 7px; }
.error { font-size: 13px; color: var(--red); margin-top: 7px; font-weight: 500; }
.fixed { background: var(--grad-soft); border: 1.5px solid #e3e0fb; border-radius: 12px; padding: 12px 14px; font-weight: 800; color: #3b2fa8; }

.radios { display: flex; flex-wrap: wrap; gap: 10px 18px; }
.radios.grid2 { display: grid; grid-template-columns: 1fr 1fr; gap: 9px; }
.radio { display: inline-flex; align-items: center; gap: 8px; cursor: pointer; font-size: 15px; }
.radio input { width: 19px; height: 19px; accent-color: var(--violet); margin: 0; flex: none; }
.radios.stack { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.radios.stack .radio {
  border: 1.5px solid var(--line); border-radius: 12px; padding: 11px 12px; background: #fff; font-size: 14.5px; line-height: 1.35;
  transition: border-color .15s, background .15s;
}
.radios.stack .radio.wide { grid-column: 1 / -1; }
.radios.stack .radio:has(input:checked) { border-color: #8b7cf6; background: #f6f3ff; color: #3b2fa8; font-weight: 700; }
.chip {
  display: flex; align-items: center; gap: 8px; border: 1.5px solid var(--line); border-radius: 12px;
  padding: 12px 12px; cursor: pointer; font-weight: 600; background: #fff; transition: border-color .15s, background .15s;
}
.chip:has(input:checked) { border-color: #8b7cf6; background: #f6f3ff; color: #3b2fa8; font-weight: 800; }
.chip input { accent-color: var(--violet); margin: 0; width: 18px; height: 18px; }

.notice-box {
  background: linear-gradient(135deg, #f3f6ff, #f7f3ff); border: 1px solid #e4e2fa; border-radius: 14px; padding: 13px 15px;
  font-size: 13px; color: #4a4e72; margin-bottom: 18px;
}
.notice-box p { margin: 0 0 6px; padding-left: 14px; position: relative; }
.notice-box p::before { content: ''; position: absolute; left: 2px; top: 8px; width: 5px; height: 5px; border-radius: 50%; background: var(--violet); }
.notice-box p.plain { padding-left: 0; color: var(--sub); }
.notice-box p.plain::before { display: none; }
.notice-box p:last-child { margin: 0; }
.warn { background: var(--amber-bg); border: 1px solid var(--amber-line); color: var(--amber-ink); border-radius: 12px; padding: 11px 13px; font-size: 13px; margin-top: 9px; }
.ok-note { background: #ecfbf5; border: 1px solid #a8e6cd; color: #075e45; border-radius: 12px; padding: 11px 13px; font-size: 13px; margin-top: 9px; }
.banner { background: var(--grad-soft); border: 1px solid #dcd8fb; color: #3b2fa8; border-radius: 14px; padding: 13px 15px; font-size: 14px; margin-top: 18px; white-space: pre-line; }

.agree { border: 1.5px solid var(--line); border-radius: 14px; margin-bottom: 10px; background: #fff; }
.agree-head { display: flex; align-items: center; justify-content: space-between; padding: 13px 15px; gap: 10px; }
.agree-head label { display: flex; align-items: center; gap: 10px; font-weight: 700; cursor: pointer; font-size: 14px; }
.agree-head input { width: 20px; height: 20px; accent-color: var(--violet); flex: none; }
.agree-more { font-size: 12px; color: var(--sub); background: none; border: 0; cursor: pointer; text-decoration: underline; white-space: nowrap; }
.agree-body { border-top: 1px solid var(--line); padding: 12px 15px; font-size: 13px; color: #4a4e72; background: #fafaff; border-radius: 0 0 14px 14px; }
.agree-body p { margin: 0 0 4px; }
.agree-all { background: var(--grad-soft); border-color: #dcd8fb; }
.agree-all .agree-head label { font-size: 15px; color: #3b2fa8; }

.recommender {
  margin-top: 30px; border-radius: 18px; padding: 18px;
  border: 2px solid transparent;
  background: linear-gradient(#fbfaff, #fbfaff) padding-box, var(--grad) border-box;
}
.recommender .k { font-size: 12.5px; color: #6d5fd6; font-weight: 800; letter-spacing: .02em; }
.recommender .v {
  font-size: 23px; font-weight: 800; margin-top: 3px; letter-spacing: -0.03em;
  background: var(--grad); -webkit-background-clip: text; background-clip: text; color: transparent;
}
.recommender .d { font-size: 13px; color: var(--sub); }
.suggest { border: 1.5px solid var(--line); border-radius: 12px; margin-top: 7px; overflow: hidden; background: #fff; box-shadow: 0 8px 20px rgba(40,30,120,.08); }
.suggest button { display: block; width: 100%; text-align: left; padding: 11px 13px; background: #fff; border: 0; border-bottom: 1px solid var(--line); cursor: pointer; }
.suggest button:last-child { border-bottom: 0; }
.suggest button:hover { background: #f6f3ff; }
.foot { text-align: center; font-size: 12px; color: var(--sub); padding: 22px 24px 30px; }
.foot img { height: 20px; display: block; margin: 0 auto 8px; opacity: .9; }

/* 모달 */
.modal-bg { position: fixed; inset: 0; background: rgba(20,16,60,.5); backdrop-filter: blur(3px); display: flex; align-items: center; justify-content: center; padding: 16px; z-index: 50; }
.modal { background: #fff; border-radius: 22px; width: 100%; max-width: 420px; padding: 28px 22px 22px; text-align: center; max-height: 90vh; overflow: auto; box-shadow: 0 24px 60px rgba(20,16,60,.25); }
.modal .icon { width: 62px; height: 62px; border-radius: 50%; background: var(--grad); color: #fff; display: flex; align-items: center; justify-content: center; font-size: 30px; font-weight: 800; margin: 0 auto 14px; box-shadow: 0 10px 24px rgba(91,78,232,.35); }
.modal .icon.bad { background: #fee2e2; color: var(--red); box-shadow: none; }
.modal h2 { margin: 0 0 8px; font-size: 20px; letter-spacing: -0.03em; }
.modal p { margin: 0 0 6px; color: #4a4e72; font-size: 14px; }
.modal .prof-name { font-weight: 800; color: #3b2fa8; }

/* ---------- 관리자 / 교수 ---------- */
.admin-body { background: var(--bg); }
.topbar { background: var(--grad); color: #fff; padding: 12px 20px; display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; }
.topbar b { font-size: 16px; }
.topbar .btn { background: rgba(255,255,255,.15); }
.tabs { display: flex; gap: 4px; padding: 0 20px; background: #fff; border-bottom: 1px solid var(--line); overflow-x: auto; }
.tab { padding: 12px 14px; border: 0; background: none; cursor: pointer; font-weight: 700; color: var(--sub); border-bottom: 3px solid transparent; white-space: nowrap; }
.tab.on { color: var(--brand); border-bottom-color: var(--brand); }
.page { max-width: 1280px; margin: 0 auto; padding: 20px; }
.panel { background: #fff; border-radius: var(--radius); border: 1px solid var(--line); padding: 18px; margin-bottom: 16px; }
.panel h3 { margin: 0 0 12px; font-size: 16px; }
.filters { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.filters .select, .filters .input { width: auto; padding: 8px 10px; font-size: 14px; }
.tbl-wrap { overflow-x: auto; }
table.tbl { width: 100%; border-collapse: collapse; font-size: 14px; }
.tbl th { text-align: left; font-size: 13px; color: var(--sub); font-weight: 700; padding: 9px 10px; border-bottom: 1px solid var(--line); white-space: nowrap; background: #fafafa; }
.tbl td { padding: 10px; border-bottom: 1px solid #f1f5f9; white-space: nowrap; }
.tbl tr.click { cursor: pointer; }
.tbl tr.click:hover td { background: #f8faff; }
.badge { display: inline-block; font-size: 12px; font-weight: 700; padding: 2px 8px; border-radius: 999px; background: #f1f5f9; color: #334155; }
.badge.ok { background: #dcfce7; color: #166534; }
.badge.no { background: #fef3c7; color: #92400e; }
.badge.dup { background: #fee2e2; color: #991b1b; }
.badge.off { background: #e5e7eb; color: #6b7280; }
.badge.s-NEW { background: #dbeafe; color: #1e40af; }
.badge.s-CONTACTED { background: #e0e7ff; color: #3730a3; }
.badge.s-COUNSELING { background: #fef9c3; color: #854d0e; }
.badge.s-WILLING { background: #dcfce7; color: #166534; }
.badge.s-HOLD { background: #f1f5f9; color: #475569; }
.muted { color: var(--sub); font-size: 13px; }
.kpis { display: grid; grid-template-columns: repeat(auto-fit, minmax(160px, 1fr)); gap: 12px; margin-bottom: 16px; }
.kpi { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 14px 16px; }
.kpi .k { font-size: 13px; color: var(--sub); font-weight: 700; }
.kpi .v { font-size: 26px; font-weight: 800; margin-top: 2px; }
.bars .bar-row { display: grid; grid-template-columns: 140px 1fr 44px; gap: 10px; align-items: center; margin-bottom: 8px; font-size: 14px; }
.bars .bar { height: 12px; background: #e5e7eb; border-radius: 6px; overflow: hidden; }
.bars .bar i { display: block; height: 100%; background: var(--brand); border-radius: 6px; }
.form-inline { display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: 10px; align-items: end; }
.kv { display: grid; grid-template-columns: 130px 1fr; gap: 6px 12px; font-size: 14px; }
.kv dt { color: var(--sub); font-weight: 700; }
.kv dd { margin: 0; word-break: break-all; }
.drawer-bg { position: fixed; inset: 0; background: rgba(15,23,42,.45); z-index: 40; display: flex; justify-content: flex-end; }
.drawer { background: #fff; width: 100%; max-width: 560px; height: 100%; overflow: auto; padding: 20px; }
.drawer h2 { margin: 0 0 4px; font-size: 20px; }
.note-item { border-top: 1px solid var(--line); padding: 10px 0; font-size: 14px; }
.note-item .meta { font-size: 12px; color: var(--sub); }
.qr-card { display: flex; gap: 16px; flex-wrap: wrap; align-items: flex-start; }
.qr-card canvas { border: 1px solid var(--line); border-radius: 10px; width: 180px; height: auto; }
.link-box { display: flex; gap: 6px; margin-top: 6px; }
.link-box .input { font-size: 13px; padding: 8px 10px; }
.login-card { max-width: 380px; margin: 60px auto; background: #fff; border-radius: 16px; border: 1px solid var(--line); padding: 26px; }
.login-card h1 { font-size: 20px; margin: 0 0 4px; }
.toast { position: fixed; bottom: 20px; left: 50%; transform: translateX(-50%); background: #111827; color: #fff; padding: 10px 16px; border-radius: 10px; font-size: 14px; z-index: 60; }
.cards { display: grid; gap: 10px; }
@media (max-width: 640px) {
  .page { padding: 12px; }
  .kv { grid-template-columns: 100px 1fr; }
  .bars .bar-row { grid-template-columns: 90px 1fr 36px; }
}
.m-only { display: none; }
.m-card { border: 1px solid var(--line); border-radius: 12px; padding: 12px 14px; cursor: pointer; display: grid; gap: 3px; font-size: 14px; }
.m-card:active { background: #f8faff; }
@media (max-width: 640px) { .m-only { display: grid; } .d-only { display: none; } }
.topbar .logo { height: 20px; width: auto; margin-right: 10px; vertical-align: middle; }
.topbar .ttl { display: flex; align-items: center; }
.tab.on { color: var(--violet); border-bottom-color: var(--violet); }
.kpi .v { background: var(--grad); -webkit-background-clip: text; background-clip: text; color: transparent; }
.bars .bar i { background: var(--grad-btn); }
.login-card .logo { height: 26px; width: auto; display: block; margin-bottom: 18px; }
.filters .select { padding-right: 34px; background-position: right 12px center; }
