:root {
    --blue: #3157ee;
    --blue-dark: #2343c8;
    --blue-soft: #eef3ff;
    --ink: #111b34;
    --muted: #68738a;
    --border: #e4e8f0;
    --page: #fbfcff;
}

* { box-sizing: border-box; }

html { font-size:19px; }

body {
    margin: 0;
    background: var(--page);
    color: var(--ink);
    font-family: Pretendard Variable, Pretendard, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    -webkit-font-smoothing: antialiased;
}

button, input { font: inherit; }
button, a { -webkit-tap-highlight-color: transparent; }
button { color: inherit; cursor: pointer; }

svg {
    fill: none;
    stroke: currentColor;
    stroke-linecap: round;
    stroke-linejoin: round;
    stroke-width: 1.8;
}

.dg-header {
    position: sticky;
    z-index: 20;
    top: 0;
    height: 66px;
    border-bottom: 1px solid #e9ecf2;
    background: rgba(255,255,255,.97);
    backdrop-filter: blur(14px);
}

.dg-header-inner {
    width: min(1500px, calc(100% - 64px));
    height: 100%;
    margin: 0 auto;
    display: flex;
    align-items: center;
}

.dg-logo {
    display: flex;
    align-items: center;
    gap: 10px;
    color: #14203d;
    font-size:24px;
    font-weight: 850;
    letter-spacing: -.04em;
    text-decoration: none;
}

.dg-logo-mark { position: relative; width: 27px; height: 22px; }
.dg-logo-mark i { position: absolute; width: 17px; height: 17px; border-radius: 7px 9px 9px 7px; transform: rotate(35deg); }
.dg-logo-mark i:first-child { left: 0; bottom: 0; background: #3b5cf3; }
.dg-logo-mark i:last-child { right: 0; top: 0; background: #a7b7ff; }

.dg-nav {
    height: 100%;
    margin-left: 74px;
    display: flex;
    align-items: stretch;
    gap: 46px;
}

.dg-nav a {
    position: relative;
    display: flex;
    align-items: center;
    color: #253047;
    font-size:18px;
    font-weight: 650;
    text-decoration: none;
    white-space: nowrap;
}

.dg-nav a.active { color: var(--blue); font-weight: 750; }
.dg-nav a.active::after { content: ""; position: absolute; right: 0; bottom: 0; left: 0; height: 3px; border-radius: 3px 3px 0 0; background: var(--blue); }
.dg-nav .tutor-pass-nav { align-self: center; height: 36px; gap: 5px; padding: 0 10px; border: 1px solid #cad5ff; border-radius: 10px; background: linear-gradient(135deg, #f1f5ff, #f5efff); box-shadow: 0 5px 13px rgba(49, 87, 238, .1); color: #2447cf; font-size: 15px; transition: border-color .2s, box-shadow .2s, transform .2s; }
.dg-nav .tutor-pass-nav:hover { border-color: #9eaff6; box-shadow: 0 8px 18px rgba(49, 87, 238, .17); transform: translateY(-1px); }
.dg-nav .tutor-pass-nav > i { color: #7b5be2; font-size: 13px; font-style: normal; transition: transform .2s; }
.dg-nav .tutor-pass-nav:hover > i { transform: rotate(18deg) scale(1.12); }
.dg-nav .tutor-pass-nav em { padding: 4px 6px; border-radius: 5px; background: linear-gradient(135deg, #3157ee, #7652d8); box-shadow: 0 3px 8px rgba(70, 76, 202, .2); color: #fff; font-size: 8px; line-height: 1; font-style: normal; font-weight: 850; letter-spacing: .04em; }
.dg-nav .tutor-pass-nav.active::after { display: none; }

.dg-header-actions { margin-left: auto; display: flex; align-items: center; gap: 25px; }
.icon-button { position: relative; display: inline-flex; align-items: center; justify-content: center; width: 28px; height: 36px; padding: 7px 3px; border: 0; background: transparent; color: inherit; text-decoration: none; }
.icon-button svg { width: 21px; height: 21px; }
.icon-button i { position: absolute; top: 7px; right: 1px; width: 5px; height: 5px; border: 1.5px solid white; border-radius: 50%; background: var(--blue); }
.login-link { color: #1e2940; font-size:18px; font-weight: 650; text-decoration: none; }
.join-button { padding: 11px 22px; border-radius: 8px; background: linear-gradient(135deg, #355ff4, #3e50df); box-shadow: 0 6px 15px rgba(49,87,238,.2); color: white; font-size:17px; font-weight: 750; text-decoration: none; }

.dg-page { width: min(1500px, calc(100% - 64px)); margin: 0 auto; padding: 14px 0 28px; }
.breadcrumb { display: flex; align-items: center; gap: 8px; height: 25px; color: #939cad; font-size:15px; }
.breadcrumb a { color: #758198; text-decoration: none; }
.breadcrumb strong { color: #7b869a; font-weight: 550; }
.breadcrumb::before { content: ""; width: 12px; height: 12px; background: linear-gradient(135deg, #5578f8, #3157ee); clip-path: polygon(50% 8%, 96% 43%, 85% 43%, 85% 92%, 59% 92%, 59% 64%, 41% 64%, 41% 92%, 15% 92%, 15% 43%, 4% 43%); }

.dg-layout { display: grid; grid-template-columns: 275px minmax(0, 1fr); gap: 32px; margin-top: 6px; align-items: start; }

.filter-card {
    padding: 20px 18px 18px;
    border: 1px solid var(--border);
    border-radius: 12px;
    background: #fff;
    box-shadow: 0 5px 18px rgba(27, 43, 74, .035);
}

.filter-title-row { display: flex; align-items: center; justify-content: space-between; margin-bottom: 18px; }
.filter-title-row h2 { margin: 0; font-size:20px; font-weight: 800; letter-spacing: -.03em; }
.reset-button, .clear-all { display: inline-flex; align-items: center; gap: 5px; border: 0; background: transparent; color: #727d91; font-size:15px; }
.reset-button { padding: 5px 7px; border: 1px solid #e5e8ef; border-radius: 7px; }
.reset-button svg, .clear-all svg { width: 14px; height: 14px; }

.filter-section { margin: 0 0 17px; }
.filter-section h3 { margin: 0 0 9px; font-size:16px; font-weight: 750; }
.filter-section h3 small { color: #69748a; font-size:14px; font-weight: 550; }
.field { width: 100%; min-height: 34px; display: flex; align-items: center; border: 1px solid #dce1e9; border-radius: 6px; background: #fff; color: #253148; font-size:15px; text-align: left; }
.select-field { padding: 0 11px; }
.select-field + .select-field { margin-top: 6px; }
.select-field span { flex: 1; }
.select-field button { padding: 4px 6px; border: 0; background: transparent; color: #7d889c; }
.select-field svg { width: 14px; height: 14px; color: #718098; }

.option-flow { display: flex; flex-wrap: wrap; gap: 8px 14px; }
.check-stack { display: grid; grid-template-columns: 1fr 1fr; gap: 8px 10px; }
.check-stack label:first-child { grid-column: 1 / -1; }
.filter-card label { display: flex; align-items: center; gap: 6px; color: #3c4658; font-size:15px; white-space: nowrap; cursor: pointer; }
.filter-card input { width: 14px; height: 14px; margin: 0; border: 1px solid #bcc5d4; accent-color: var(--blue); }
.transit-check { margin-top: 9px; }
.transit-check svg { width: 13px; height: 13px; color: #8c96a7; }

.range-section { margin-top: 20px; }
.range-line { position: relative; height: 11px; margin-top: 2px; }
.range-line::before { content: ""; position: absolute; top: 5px; left: 1px; width: calc(100% - 2px); height: 2px; background: #b6c7fe; }
.range-line.active::before { background: var(--blue); }
.range-line b { position: absolute; top: 1px; width: 9px; height: 9px; border: 1.8px solid #7190f7; border-radius: 50%; background: white; }
.range-line .range-left { left: 0; }
.range-line .range-right { right: 0; }
.range-label { display: flex; justify-content: space-between; color: #7b8698; font-size:13px; }
.range-label strong { color: #6273ae; font-weight: 550; }

.extras-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px 8px; }
.search-button { width: 100%; min-height: 39px; margin-top: 1px; border: 0; border-radius: 6px; background: linear-gradient(135deg, #315df2, #4154e8); box-shadow: 0 6px 12px rgba(49,87,238,.18); color: white; font-size:16px; }
.search-button strong { font-weight: 800; }

.results { min-width: 0; }
.results-head { min-height: 86px; display: flex; align-items: center; justify-content: space-between; border-bottom: 1px solid var(--border); }
.results-head h1 { margin: 2px 0 6px; color: #111a34; font-size:28px; line-height: 1; font-weight: 850; letter-spacing: -.045em; }
.results-head p { margin: 0; color: #606d83; font-size:17px; }
.results-head p strong { color: #44516c; font-weight: 650; }
.sort-button { width: 170px; height: 40px; padding: 0 13px; display: flex; align-items: center; justify-content: space-between; border: 1px solid #dce2eb; border-radius: 7px; background: white; color: #334057; font-size:16px; }
.sort-button svg { width: 15px; height: 15px; color: #6d7890; }

.active-filters { min-height: 55px; display: flex; align-items: center; gap: 18px; }
.chips { flex: 1; display: flex; flex-wrap: wrap; gap: 8px; }
.chips button { padding: 7px 14px; border: 0; border-radius: 99px; background: #f0f4fc; color: #3e4b63; font-size:15px; white-space: nowrap; }
.chips button span { margin-left: 4px; color: #64728b; }
.clear-all { flex: 0 0 auto; color: #425068; font-size:16px; }

.teacher-list { display: grid; gap: 9px; }
.teacher-card {
    min-height: 202px;
    display: grid;
    grid-template-columns: 185px minmax(355px, 1.25fr) minmax(260px, .85fr) 155px;
    align-items: stretch;
    padding: 12px;
    border: 1px solid #e0e5ed;
    border-radius: 13px;
    background: white;
    box-shadow: 0 5px 17px rgba(29, 45, 78, .045);
    transition: border-color .2s, box-shadow .2s, transform .2s;
}
.teacher-card:hover { border-color: #cdd8f8; box-shadow: 0 10px 25px rgba(36, 58, 111, .085); transform: translateY(-1px); }

.profile-photo { position: relative; min-height: 176px; overflow: hidden; border-radius: 9px; background: #f2f1ee; }
.profile-photo img { width: 100%; height: 100%; display: block; object-fit: cover; object-position: 50% 29%; }
.availability { position: absolute; top: 9px; left: 9px; padding: 5px 7px; border: 1px solid; border-radius: 5px; font-size:13px; font-weight: 650; }
.availability.online { border-color: #7cc994; background: #effbf2; color: #198a40; }
.availability.offline { border-color: #f6af68; background: #fff7eb; color: #c56b16; }
.favorite-button { position: absolute; top: 7px; right: 8px; width: 29px; height: 29px; padding: 5px; border: 0; background: rgba(255,255,255,.18); color: #7c8da5; }
.favorite-button svg { width: 20px; height: 20px; stroke-width: 1.7; }
.favorite-button.selected svg { fill: #ff6580; stroke: #ff6580; }
.verified { position: absolute; bottom: 8px; left: 8px; display: inline-flex; align-items: center; gap: 4px; padding: 5px 7px; border-radius: 5px; background: rgba(255,255,255,.93); box-shadow: 0 2px 8px rgba(28, 43, 70, .08); color: #556279; font-size:13px; font-weight: 650; }
.verified svg { width: 13px; height: 13px; color: #5475f5; }

.teacher-main { min-width: 0; padding: 14px 22px 9px; }
.name-row { display: flex; align-items: center; gap: 12px; min-height: 25px; }
.name-row h2 { margin: 0; color: #111a30; font-size:23px; font-weight: 820; letter-spacing: -.035em; white-space: nowrap; }
.rating { color: #ffb52b; font-size:19px; white-space: nowrap; }
.rating strong { margin-left: 3px; color: #38455c; font-size:16px; }
.rating em { color: #758197; font-size:15px; font-style: normal; }
.recommend { padding: 5px 7px; border-radius: 5px; background: #ece9ff; color: #544de2; font-size:13px; font-weight: 700; white-space: nowrap; }
.career { margin: 9px 0 10px; color: #3f4b61; font-size:16px; line-height: 1.8; }
.stat-pills, .specialty-pills { display: flex; flex-wrap: wrap; gap: 7px; }
.stat-pills { margin-bottom: 10px; }
.stat-pills span, .specialty-pills span { padding: 6px 10px; border-radius: 99px; font-size:14px; white-space: nowrap; }
.stat-pills span { background: #f3f5f9; color: #334057; }
.specialty-pills span { background: var(--blue-soft); color: #3157d9; font-weight: 600; }

.lesson-info { margin: 14px 0; padding: 0 20px 0 25px; display: flex; flex-direction: column; justify-content: center; gap: 13px; border-left: 1px solid #e5e9f0; }
.lesson-info > div { display: flex; align-items: flex-start; gap: 11px; }
.lesson-info svg { flex: 0 0 auto; width: 15px; height: 15px; margin-top: 2px; color: #4164dc; }
.lesson-info p { margin: 0; }
.lesson-info span, .lesson-info strong { display: block; }
.lesson-info span { margin-bottom: 3px; color: #778397; font-size:14px; }
.lesson-info strong { color: #4a566c; font-size:15px; font-weight: 550; white-space: nowrap; }

.card-actions { padding: 0 4px 0 10px; display: flex; flex-direction: column; align-items: stretch; justify-content: center; gap: 8px; }
.card-actions a, .card-actions button { height: 38px; display: flex; align-items: center; justify-content: center; border: 1px solid #496bf1; border-radius: 6px; background: white; color: #3157e9; font-size:15px; font-weight: 700; text-decoration: none; }
.card-actions button { background: linear-gradient(135deg, #315df2, #4053e7); box-shadow: 0 5px 12px rgba(49,87,238,.17); color: white; }
.card-actions span { display: flex; align-items: center; justify-content: center; gap: 6px; color: #758196; font-size:13px; white-space: nowrap; }
.card-actions span i { width: 7px; height: 7px; border: 1px solid #4bc978; border-radius: 50%; background: #e9fff0; }

.pagination { margin: 18px 0; display: flex; justify-content: center; gap: 8px; }
.pagination[hidden] { display: none; }
.js-page-buttons { display: flex; gap: 8px; }
.pagination button { min-width: 30px; height: 30px; padding: 0 7px; border: 1px solid #e1e6ee; border-radius: 6px; background: white; color: #455169; font-size:15px; }
.pagination button.current { border-color: var(--blue); background: var(--blue); box-shadow: 0 4px 9px rgba(49,87,238,.18); color: white; }

.trust-bar { min-height: 78px; display: grid; grid-template-columns: repeat(3, 1fr); border-radius: 10px; background: linear-gradient(105deg, #eff4ff, #f5f7ff); }
.trust-bar > div { position: relative; display: flex; align-items: center; justify-content: center; gap: 15px; padding: 13px 25px; }
.trust-bar > div + div::before { content: ""; position: absolute; top: 19px; bottom: 19px; left: 0; width: 1px; background: #e1e7f5; }
.trust-icon { flex: 0 0 auto; width: 37px; height: 37px; display: flex; align-items: center; justify-content: center; border-radius: 50%; }
.trust-icon svg { width: 28px; height: 28px; stroke-width: 1.7; }
.trust-icon.shield { color: #6885f7; }
.trust-icon.chat { color: #7b88f5; }
.trust-icon.swap { color: #e2a332; }
.trust-bar p { margin: 0; }
.trust-bar p strong, .trust-bar p span { display: block; }
.trust-bar p strong { margin-bottom: 4px; color: #243049; font-size:15px; }
.trust-bar p span { color: #748095; font-size:13px; line-height: 1.55; }

@media (max-width: 1320px) {
    .dg-header-inner, .dg-page { width: min(1220px, calc(100% - 36px)); }
    .dg-nav { margin-left: 45px; gap: 26px; }
    .dg-layout { grid-template-columns: 245px minmax(0, 1fr); gap: 22px; }
    .teacher-card { grid-template-columns: 160px minmax(315px, 1.2fr) minmax(230px, .8fr) 140px; }
    .teacher-main { padding-inline: 17px; }
    .lesson-info { padding-inline: 17px; }
    .stat-pills span, .specialty-pills span { padding-inline: 8px; }
}

@media (max-width: 1050px) {
    .dg-nav a:nth-child(n+5) { display: none; }
    .dg-nav .tutor-pass-nav { display: flex; }
    .dg-layout { grid-template-columns: 220px minmax(0, 1fr); }
    .teacher-card { grid-template-columns: 150px 1fr 145px; }
    .lesson-info { grid-column: 2; margin: 0 16px 8px; padding: 8px 0 0; flex-direction: row; justify-content: flex-start; border-top: 1px solid #edf0f4; border-left: 0; }
    .lesson-info > div { flex: 1; }
    .card-actions { grid-column: 3; grid-row: 1 / 3; }
    .teacher-main { padding-bottom: 2px; }
}

@media (max-width: 780px) {
    .dg-header { height: 58px; }
    .dg-header-inner, .dg-page { width: calc(100% - 28px); }
    .dg-nav { display: none; }
    .dg-header-actions { gap: 14px; }
    .dg-layout { display: block; }
    .filter-card { display: none; }
    .teacher-card { grid-template-columns: 104px minmax(0, 1fr); padding: 10px; }
    .profile-photo { min-height: 145px; }
    .teacher-main { padding: 6px 10px; }
    .name-row { flex-wrap: wrap; gap: 5px 8px; }
    .name-row h2 { width: 100%; font-size:20px; }
    .career { font-size:15px; }
    .lesson-info { grid-column: 1 / -1; margin: 8px 0; flex-direction: column; }
    .card-actions { grid-column: 1 / -1; grid-row: auto; padding: 0; display: grid; grid-template-columns: 1fr 1fr; }
    .card-actions span { grid-column: 1 / -1; }
    .trust-bar { grid-template-columns: 1fr; }
    .trust-bar > div + div::before { top: 0; right: 30px; bottom: auto; left: 30px; width: auto; height: 1px; }
    .sort-button { width: 120px; }
    .clear-all { display: none; }
    .chips { flex-wrap: nowrap; overflow-x: auto; padding: 10px 0; }
    .pagination button:nth-child(n+7):nth-child(-n+9) { display: none; }
}

/* Interactive search controls and empty result feedback. */
.filter-card select.field{padding:0 11px;appearance:auto}.reset-button,.clear-all{text-decoration:none}.filter-placeholder{color:#7b8798;font-size:15px}.search-empty{min-height:210px;padding:40px;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:8px;border:1px dashed #ccd5e2;border-radius:12px;background:#fff;color:#6b778a;text-align:center}.search-empty[hidden]{display:none}.search-empty strong{color:#334057;font-size:20px}.search-empty span{font-size:16px}.teacher-card[hidden]{display:none}
.featured-paid-card{border:2px solid #7b8ff2!important;box-shadow:0 10px 28px rgba(49,87,238,.12)!important}.paid-profile-placeholder{width:100%;height:100%;display:grid;place-items:center;background:linear-gradient(145deg,#dfe7ff,#f5f7ff);color:#3157ee;font-size:55px;font-weight:800}
/* 학생과 강사가 함께 사용하는 공통 포인트 잔액 */
.global-point-badge{height:38px;padding:0 12px;display:inline-flex;align-items:center;gap:7px;border:1px solid #d9e1ff;border-radius:999px;background:#f4f6ff;color:#274bd2;font-size:13px;font-weight:800;text-decoration:none;white-space:nowrap}
.global-point-badge span{width:21px;height:21px;display:grid;place-items:center;border-radius:50%;background:#3157ee;color:#fff;font-size:11px}
