@charset "utf-8";

/* ============================================
   텔레그램 보안 가이드 – 인터랙티브 SPA 스타일
   접두사: tg-safe- (기존 사이트 스타일 오염 방지)
   컬러 톤: 슬레이트(Slate) + 블루(Blue) 조합
============================================ */

:root {
    --tgs-blue: #3b82f6;
    --tgs-blue-dark: #2563eb;
    --tgs-blue-light: #eff6ff;
    --tgs-blue-border: #bfdbfe;
    --tgs-green: #22c55e;
    --tgs-green-light: #f0fdf4;
    --tgs-yellow: #eab308;
    --tgs-yellow-light: #fefce8;
    --tgs-yellow-border: #fde68a;
    --tgs-red: #ef4444;
    --tgs-slate-900: #0f172a;
    --tgs-slate-800: #1e293b;
    --tgs-slate-700: #334155;
    --tgs-slate-600: #475569;
    --tgs-slate-500: #64748b;
    --tgs-slate-400: #94a3b8;
    --tgs-slate-300: #cbd5e1;
    --tgs-slate-200: #e2e8f0;
    --tgs-slate-100: #f1f5f9;
    --tgs-slate-50: #f8fafc;
    --tgs-white: #ffffff;
    --tgs-radius: 12px;
}

/* ─── 래퍼 ─── */
.tg-safe-wrapper {
    max-width: 1100px;
    margin: 0 auto;
    font-family: 'Pretendard', -apple-system, BlinkMacSystemFont, system-ui, sans-serif;
    color: var(--tgs-slate-800);
    background-color: var(--tgs-slate-50);
    box-sizing: border-box;
    line-height: 1.6;
}

.tg-safe-wrapper *,
.tg-safe-wrapper *::before,
.tg-safe-wrapper *::after {
    box-sizing: inherit;
    margin: 0;
    padding: 0;
}

.tg-safe-wrapper strong {
    font-weight: 700;
}

/* ─── 상단 헤더 바 ─── */
.tg-safe-topbar {
    background-color: var(--tgs-white);
    border-bottom: 1px solid var(--tgs-slate-200);
    padding: 0 20px;
    height: 56px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    position: sticky;
    top: 0;
    z-index: 50;
}

.tg-safe-topbar__left {
    display: flex;
    align-items: center;
    gap: 8px;
}

.tg-safe-topbar__icon {
    font-size: 22px;
}

.tg-safe-topbar__title {
    font-size: 18px;
    font-weight: 700;
    color: var(--tgs-slate-800);
}

.tg-safe-topbar__subtitle {
    font-size: 13px;
    font-weight: 400;
    color: var(--tgs-slate-500);
}

.tg-safe-topbar__score {
    font-size: 14px;
    color: var(--tgs-slate-500);
    font-weight: 500;
}

/* ─── 인트로 섹션 ─── */
.tg-safe-intro {
    text-align: center;
    padding: 40px 20px 30px;
    max-width: 720px;
    margin: 0 auto;
}

.tg-safe-intro__title {
    font-size: 26px;
    font-weight: 800;
    color: var(--tgs-slate-900);
    margin-bottom: 14px;
}

.tg-safe-intro__desc {
    font-size: 16px;
    color: var(--tgs-slate-600);
    margin-bottom: 20px;
}

.tg-safe-intro__goals {
    display: inline-block;
    text-align: left;
    padding: 16px 20px;
    background-color: var(--tgs-blue-light);
    border: 1px solid var(--tgs-blue-border);
    border-radius: 10px;
}

.tg-safe-intro__goals-label {
    font-size: 14px;
    font-weight: 700;
    color: var(--tgs-blue-dark);
    margin-bottom: 8px;
}

.tg-safe-intro__goals-list {
    list-style: disc;
    padding-left: 20px;
    font-size: 14px;
    color: #1e40af;
    display: flex;
    flex-direction: column;
    gap: 4px;
}

/* ─── 대시보드 그리드(3열) ─── */
.tg-safe-dashboard {
    display: flex;
    flex-direction: column;
    gap: 20px;
    padding: 0 20px 40px;
}

/* ─── 좌측 네비게이션 ─── */
.tg-safe-nav {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.tg-safe-nav__heading {
    font-size: 12px;
    font-weight: 700;
    color: var(--tgs-slate-400);
    text-transform: uppercase;
    letter-spacing: 1.5px;
    margin-bottom: 4px;
}

.tg-safe-nav__btn {
    width: 100%;
    text-align: left;
    padding: 14px 16px;
    border-radius: 10px;
    background-color: var(--tgs-white);
    border: 1px solid var(--tgs-slate-200);
    border-left: 4px solid transparent;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: space-between;
    transition: all 0.2s ease;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.04);
    font-family: inherit;
}

.tg-safe-nav__btn:hover {
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
}

.tg-safe-nav__btn--active {
    border-left-color: var(--tgs-blue);
    background-color: var(--tgs-blue-light);
}

.tg-safe-nav__btn-title {
    display: block;
    font-size: 15px;
    font-weight: 700;
    color: var(--tgs-slate-800);
}

.tg-safe-nav__btn-sub {
    display: block;
    font-size: 12px;
    color: var(--tgs-slate-500);
    margin-top: 2px;
}

.tg-safe-nav__btn-status {
    color: var(--tgs-slate-300);
    font-size: 14px;
}

/* ─── 중앙 시뮬레이터 ─── */
.tg-safe-sim {
    background-color: var(--tgs-white);
    border-radius: var(--tgs-radius);
    border: 1px solid var(--tgs-slate-200);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.06);
    overflow: hidden;
    display: flex;
    flex-direction: column;
    min-height: 500px;
}

.tg-safe-sim__header {
    background-color: var(--tgs-slate-800);
    color: var(--tgs-white);
    padding: 12px 16px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.tg-safe-sim__dots {
    display: flex;
    align-items: center;
    gap: 6px;
}

.tg-safe-sim__dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
}

.tg-safe-sim__dot--red {
    background-color: #ef4444;
}

.tg-safe-sim__dot--yellow {
    background-color: #eab308;
}

.tg-safe-sim__dot--green {
    background-color: #22c55e;
}

.tg-safe-sim__dot-label {
    font-size: 12px;
    font-family: monospace;
    color: var(--tgs-slate-400);
    margin-left: 6px;
}

.tg-safe-sim__step-indicator {
    font-size: 12px;
    color: var(--tgs-slate-400);
}

.tg-safe-sim__body {
    padding: 24px;
    flex: 1;
    background-color: var(--tgs-slate-50);
    position: relative;
}

/* ─── 뷰(Step) 공통 ─── */
.tg-safe-view {
    display: flex;
    flex-direction: column;
    height: 100%;
    animation: tgSafeFadeIn 0.4s ease;
}

.tg-safe-view--hidden {
    display: none;
}

@keyframes tgSafeFadeIn {
    from {
        opacity: 0;
    }

    to {
        opacity: 1;
    }
}

.tg-safe-view__title {
    font-size: 20px;
    font-weight: 800;
    color: var(--tgs-slate-800);
    margin-bottom: 8px;
}

.tg-safe-view__desc {
    font-size: 14px;
    color: var(--tgs-slate-600);
    margin-bottom: 20px;
}

.tg-safe-view__path {
    display: inline-block;
    font-size: 12px;
    font-weight: 700;
    color: var(--tgs-blue);
    background-color: var(--tgs-blue-light);
    padding: 2px 8px;
    border-radius: 4px;
    margin-top: 4px;
}

/* ─── 토글 스위치 카드 ─── */
.tg-safe-toggle-card {
    background-color: var(--tgs-white);
    padding: 20px;
    border-radius: 10px;
    border: 1px solid var(--tgs-slate-200);
    box-shadow: 0 1px 4px rgba(0, 0, 0, 0.04);
    margin-bottom: 20px;
}

.tg-safe-toggle-card__row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 10px;
}

.tg-safe-toggle-card__label {
    font-size: 15px;
    font-weight: 600;
    color: var(--tgs-slate-700);
}

.tg-safe-toggle-card__feedback {
    font-size: 13px;
    color: var(--tgs-slate-400);
}

/* 커스텀 토글 스위치 */
.tg-safe-switch {
    position: relative;
    display: inline-block;
    width: 44px;
    height: 24px;
}

.tg-safe-switch__input {
    opacity: 0;
    width: 0;
    height: 0;
    position: absolute;
}

.tg-safe-switch__slider {
    position: absolute;
    cursor: pointer;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: var(--tgs-slate-300);
    border-radius: 24px;
    transition: background-color 0.3s ease;
}

.tg-safe-switch__slider::before {
    content: "";
    position: absolute;
    height: 18px;
    width: 18px;
    left: 3px;
    bottom: 3px;
    background-color: var(--tgs-white);
    border-radius: 50%;
    transition: transform 0.3s ease;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.15);
}

.tg-safe-switch__input:checked+.tg-safe-switch__slider {
    background-color: var(--tgs-blue);
}

.tg-safe-switch__input:checked+.tg-safe-switch__slider::before {
    transform: translateX(20px);
}

/* ─── 단축키 박스 ─── */
.tg-safe-shortcut-box {
    background-color: var(--tgs-slate-800);
    color: var(--tgs-white);
    padding: 20px;
    border-radius: 10px;
    margin-top: auto;
}

.tg-safe-shortcut-box__label {
    font-size: 14px;
    font-weight: 700;
    color: #facc15;
    margin-bottom: 10px;
}

.tg-safe-shortcut-box__keys {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 10px;
    border: 1px solid var(--tgs-slate-600);
    border-radius: 8px;
    background-color: var(--tgs-slate-700);
    margin-bottom: 10px;
}

.tg-safe-kbd {
    display: inline-block;
    padding: 6px 14px;
    font-size: 18px;
    font-weight: 800;
    font-family: monospace;
    color: var(--tgs-slate-900);
    background-color: var(--tgs-white);
    border: 1px solid #d1d5db;
    border-bottom: 3px solid #b0b5be;
    border-radius: 6px;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.08);
}

.tg-safe-kbd-plus {
    font-weight: 800;
    color: var(--tgs-slate-400);
    font-size: 16px;
}

.tg-safe-shortcut-box__note {
    font-size: 12px;
    text-align: center;
    color: var(--tgs-slate-400);
    margin-bottom: 12px;
}

.tg-safe-shortcut-box__test-btn {
    display: block;
    width: 100%;
    padding: 10px;
    background-color: var(--tgs-blue);
    color: var(--tgs-white);
    border: none;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: background-color 0.2s ease;
    font-family: inherit;
}

.tg-safe-shortcut-box__test-btn:hover {
    background-color: var(--tgs-blue-dark);
}

/* ─── 셀렉트 카드 (자동 잠금) ─── */
.tg-safe-select-card {
    background-color: var(--tgs-white);
    padding: 24px;
    border-radius: 10px;
    border: 1px solid var(--tgs-slate-200);
    box-shadow: 0 1px 4px rgba(0, 0, 0, 0.04);
    text-align: center;
    margin-bottom: 20px;
}

.tg-safe-select-card__label {
    display: block;
    font-size: 14px;
    font-weight: 600;
    color: var(--tgs-slate-700);
    margin-bottom: 10px;
}

.tg-safe-select-card__select {
    display: block;
    width: 100%;
    max-width: 280px;
    margin: 0 auto;
    padding: 10px 12px;
    border: 1px solid var(--tgs-slate-300);
    border-radius: 8px;
    font-size: 14px;
    font-family: inherit;
    color: var(--tgs-slate-800);
    background-color: var(--tgs-white);
    cursor: pointer;
}

.tg-safe-select-card__select:focus {
    outline: none;
    border-color: var(--tgs-blue);
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.15);
}

.tg-safe-select-card__feedback {
    margin-top: 14px;
    font-size: 14px;
    font-weight: 600;
    color: var(--tgs-slate-500);
}

/* ─── 정보 노트 ─── */
.tg-safe-info-note {
    padding: 16px;
    background-color: var(--tgs-slate-100);
    border: 1px solid var(--tgs-slate-200);
    border-radius: 10px;
    font-size: 14px;
    color: var(--tgs-slate-600);
    margin-top: auto;
}

.tg-safe-info-note--warn {
    background-color: var(--tgs-yellow-light);
    border-color: var(--tgs-yellow-border);
    color: #92400e;
}

/* ─── 알림 설정 그리드 ─── */
.tg-safe-noti-grid {
    display: flex;
    flex-direction: column;
    gap: 14px;
    margin-bottom: 20px;
}

.tg-safe-noti-controls {
    background-color: var(--tgs-white);
    padding: 16px;
    border-radius: 10px;
    border: 1px solid var(--tgs-slate-200);
    box-shadow: 0 1px 4px rgba(0, 0, 0, 0.04);
}

.tg-safe-noti-controls__item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 8px 6px;
    border-radius: 6px;
    cursor: pointer;
    font-size: 14px;
    font-weight: 500;
    color: var(--tgs-slate-700);
    transition: background-color 0.15s ease;
    margin-bottom: 8px;
}

.tg-safe-noti-controls__item:last-of-type {
    margin-bottom: 0;
}

.tg-safe-noti-controls__item:hover {
    background-color: var(--tgs-slate-50);
}

.tg-safe-noti-controls__item input[type="checkbox"] {
    width: 16px;
    height: 16px;
    cursor: pointer;
    accent-color: var(--tgs-blue);
}

.tg-safe-noti-controls__hint {
    margin-top: 12px;
    text-align: center;
    font-size: 13px;
    font-weight: 700;
    color: var(--tgs-red);
}

/* 알림 미리보기 영역 */
.tg-safe-noti-preview {
    background-color: #dbeafe;
    padding: 16px;
    border-radius: 10px;
    position: relative;
    min-height: 120px;
    overflow: hidden;
}

.tg-safe-noti-preview__label {
    font-size: 12px;
    color: var(--tgs-slate-500);
}

.tg-safe-noti-toast {
    position: absolute;
    bottom: 10px;
    right: 10px;
    width: 200px;
    background-color: var(--tgs-slate-800);
    color: var(--tgs-white);
    padding: 12px;
    border-radius: 10px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
    display: flex;
    gap: 10px;
    transition: all 0.3s ease;
}

.tg-safe-noti-toast__avatar {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background-color: var(--tgs-blue);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 11px;
    font-weight: 700;
    flex-shrink: 0;
}

.tg-safe-noti-toast__title {
    font-size: 12px;
    font-weight: 700;
}

.tg-safe-noti-toast__text {
    font-size: 12px;
    color: var(--tgs-slate-300);
    margin-top: 2px;
}

.tg-safe-noti-toast__text--italic {
    font-style: italic;
}

/* ─── 우측 대시보드 ─── */
.tg-safe-dashboard-side {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

/* 보안 점수 차트 카드 */
.tg-safe-score-card {
    background-color: var(--tgs-white);
    padding: 24px;
    border-radius: var(--tgs-radius);
    border: 1px solid var(--tgs-slate-200);
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.05);
    text-align: center;
}

.tg-safe-score-card__title {
    font-size: 17px;
    font-weight: 700;
    color: var(--tgs-slate-800);
    margin-bottom: 16px;
}

.tg-safe-score-card__chart {
    position: relative;
    width: 100%;
    max-width: 240px;
    height: 200px;
    margin: 0 auto;
}

.tg-safe-score-card__message {
    margin-top: 16px;
    font-size: 14px;
    font-weight: 500;
    color: var(--tgs-slate-500);
}

/* 설정 요약 체크리스트 */
.tg-safe-checklist {
    background-color: var(--tgs-white);
    padding: 24px;
    border-radius: var(--tgs-radius);
    border: 1px solid var(--tgs-slate-200);
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.05);
}

.tg-safe-checklist__title {
    font-size: 17px;
    font-weight: 700;
    color: var(--tgs-slate-800);
    margin-bottom: 14px;
    padding-bottom: 10px;
    border-bottom: 1px solid var(--tgs-slate-200);
}

.tg-safe-checklist__list {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.tg-safe-checklist__item {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 14px;
    color: var(--tgs-slate-600);
}

.tg-safe-checklist__icon {
    font-size: 13px;
}

.tg-safe-checklist__icon--off {
    color: var(--tgs-slate-300);
}

.tg-safe-checklist__icon--on {
    color: var(--tgs-green);
}

.tg-safe-checklist__icon--warn {
    color: var(--tgs-yellow);
}

/* CTA 배너 */
.tg-safe-cta {
    background: linear-gradient(135deg, var(--tgs-blue) 0%, #6366f1 100%);
    color: var(--tgs-white);
    padding: 28px 24px;
    border-radius: var(--tgs-radius);
    text-align: center;
    box-shadow: 0 4px 16px rgba(59, 130, 246, 0.25);
}

.tg-safe-cta__title {
    font-size: 18px;
    font-weight: 800;
    margin-bottom: 8px;
}

.tg-safe-cta__desc {
    font-size: 13px;
    opacity: 0.9;
    margin-bottom: 16px;
}

.tg-safe-cta__btn {
    display: inline-block;
    background-color: var(--tgs-white);
    color: var(--tgs-blue);
    font-size: 13px;
    font-weight: 700;
    padding: 8px 20px;
    border-radius: 100px;
    text-decoration: none;
    transition: background-color 0.2s ease;
}

.tg-safe-cta__btn:hover {
    background-color: var(--tgs-slate-100);
    text-decoration: none;
}

/* ─── 하단 푸터 ─── */
.tg-safe-footer {
    background-color: var(--tgs-slate-800);
    color: var(--tgs-slate-400);
    padding: 28px 20px;
    text-align: center;
    margin-top: 40px;
}

.tg-safe-footer p {
    font-size: 13px;
}

/* ============================================
   반응형 미디어 쿼리 (모바일 퍼스트)
============================================ */
@media (min-width: 768px) {
    .tg-safe-intro__title {
        font-size: 30px;
    }

    .tg-safe-noti-grid {
        display: grid;
        grid-template-columns: 1fr 1fr;
    }

    /* 네비게이션 가로 배치 */
    .tg-safe-nav {
        flex-direction: row;
        flex-wrap: wrap;
    }

    .tg-safe-nav__heading {
        width: 100%;
    }

    .tg-safe-nav__btn {
        flex: 1;
    }
}

@media (min-width: 1024px) {
    .tg-safe-topbar {
        padding: 0 32px;
    }

    .tg-safe-intro {
        padding: 50px 20px 40px;
    }

    .tg-safe-intro__title {
        font-size: 32px;
    }

    /* 대시보드 3열 그리드: 좌3 중6 우3 비율 */
    .tg-safe-dashboard {
        display: grid;
        grid-template-columns: 240px 1fr 260px;
        gap: 24px;
        padding: 0 32px 50px;
    }

    /* 네비게이션 세로 복귀 */
    .tg-safe-nav {
        flex-direction: column;
    }

    .tg-safe-nav__btn {
        flex: none;
    }
}