/* Member entry page — split login / sign-up with LinkedIn + email tabs.
   Tokens come from base.css (hsl(var(--token))). No hardcoded brand hex except
   the LinkedIn brand color, which is intentional. */

* { box-sizing: border-box; }

.member-body {
    margin: 0;
    min-height: 100vh;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    color: hsl(var(--foreground));
    background:
        radial-gradient(1200px 600px at 15% -10%, hsl(var(--violet-100)) 0%, transparent 55%),
        radial-gradient(1000px 600px at 110% 10%, hsl(var(--blue-50)) 0%, transparent 50%),
        hsl(var(--secondary));
    display: flex;
    flex-direction: column;
    align-items: center;
    /* 세로 센터 금지 — 항상 위에서부터 쌓아 "Log in" 제목이 상단 104px 에 고정되게 한다
       (탭마다 카드 높이가 달라도 위로 튀지 않음, 2026-07-09 사용자 요청). */
    justify-content: flex-start;
    padding: 32px 20px 56px;
}

.member-home {
    align-self: flex-start;
    margin-bottom: 8px;
}

.member-shell {
    width: 100%;
    max-width: 1040px;
    /* 상단 고정(세로 센터 금지): margin:auto 로 세로 센터를 잡으면 탭마다 카드 높이가 달라질 때
       카드 전체가 위아래로 튀는 현상이 생긴다. 상단을 고정하면 탭-내용이 늘어도 아래로만
       확장되어 상단(탭 위치)이 움직이지 않는다(2026-07-09 사용자 요청).
       "Log in" 제목까지의 상단 여백 = 항상 104px 로 고정(탭 무관, 제목이 탭 위에 있으므로):
       body padding-top 32 + .member-single margin-top 2rem(32) + .member-pane padding-top 40 = 104.
       이 세 값 중 하나라도 바꾸면 104px 가 깨지니 주의(모바일 ≤560px 는 96px). */
    margin: 0 auto;
}

/* ---- Signed-in banner ---- */
.signed-in-banner {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 16px;
    padding: 13px 18px;
    font-size: 14px;
    color: hsl(var(--emerald-800));
    background: hsl(var(--emerald-100));
    border: 1px solid hsl(var(--emerald-500) / 0.45);
    border-radius: 12px;
}
.signed-in-banner svg { flex: 0 0 auto; color: hsl(var(--emerald-700)); }
.signed-in-banner strong { font-weight: 700; }
.signed-in-banner .banner-actions {
    margin-left: auto;
    display: flex;
    gap: 14px;
    white-space: nowrap;
}
.signed-in-banner .banner-link {
    font-size: 13px;
    font-weight: 600;
    text-decoration: none;
    color: hsl(var(--emerald-800));
}
.signed-in-banner .banner-link:hover { text-decoration: underline; }
.signed-in-banner .banner-logout { color: hsl(var(--rose-700)); }

@media (max-width: 560px) {
    .signed-in-banner { flex-wrap: wrap; }
    .signed-in-banner .banner-actions { margin-left: 0; width: 100%; }
}

/* ---- Split grid: login | divider | signup ---- */
.member-grid {
    display: grid;
    grid-template-columns: 1fr 1px 1fr;
    gap: 0;
    background: hsl(var(--card));
    border: 1px solid hsl(var(--border));
    border-radius: 16px;
    box-shadow: 0 10px 40px -12px rgba(16, 24, 40, 0.18);
    overflow: hidden;
}

.member-pane {
    padding: 40px 36px;
    display: flex;
    flex-direction: column;
}

.member-divider {
    background: hsl(var(--border));
}

.pane-head { margin-bottom: 22px; }
.pane-head h1 {
    margin: 0 0 6px;
    font-size: 26px;
    font-weight: 700;
    letter-spacing: -0.01em;
}
.pane-head p {
    margin: 0;
    color: hsl(var(--muted-foreground));
    font-size: 14px;
}

/* ---- Tabs ---- */
.tabs {
    display: flex;
    gap: 4px;
    padding: 4px;
    background: hsl(var(--muted));
    border-radius: 10px;
    margin-bottom: 22px;
}
.tab {
    flex: 1;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 7px;
    padding: 9px 10px;
    border: none;
    background: transparent;
    border-radius: 7px;
    font-size: 14px;
    font-weight: 600;
    color: hsl(var(--muted-foreground));
    cursor: pointer;
    transition: background .15s, color .15s, box-shadow .15s;
}
.tab .tab-ico { opacity: .85; }
.tab:hover { color: hsl(var(--foreground)); }
.tab.active {
    background: hsl(var(--card));
    color: hsl(var(--foreground));
    box-shadow: 0 1px 2px rgba(16, 24, 40, 0.12);
}

/* ---- Tab panels ---- */
.tab-panel { display: none; animation: fade .18s ease; }
.tab-panel.active { display: block; }
@keyframes fade { from { opacity: 0; transform: translateY(4px); } to { opacity: 1; transform: none; } }

/* ---- Form fields ---- */
.form-group { margin-bottom: 16px; }
.form-group label {
    display: block;
    font-size: 13px;
    font-weight: 600;
    margin-bottom: 6px;
    color: hsl(var(--foreground));
}
.form-group label .optional { color: hsl(var(--muted-foreground)); font-weight: 400; }
.form-group input[type="email"],
.form-group input[type="password"],
.form-group input[type="text"] {
    width: 100%;
    padding: 11px 13px;
    font-size: 14px;
    border: 1px solid hsl(var(--input));
    border-radius: 9px;
    background: hsl(var(--card));
    color: hsl(var(--foreground));
    transition: border-color .15s, box-shadow .15s;
}
.form-group input:focus {
    outline: none;
    border-color: hsl(var(--violet-700));
    box-shadow: 0 0 0 3px hsl(var(--violet-100));
}
.input-with-btn { display: flex; gap: 8px; }
.input-with-btn input { flex: 1; }
.input-with-btn .btn { white-space: nowrap; }

/* ---- Buttons ---- */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 11px 16px;
    font-size: 14px;
    font-weight: 600;
    border-radius: 9px;
    border: 1px solid transparent;
    cursor: pointer;
    transition: filter .15s, background .15s, opacity .15s;
}
.btn-full { width: 100%; }
.btn-primary {
    background: hsl(var(--violet-700));
    color: #fff;
}
.btn-primary:hover { filter: brightness(1.07); }
.btn-primary:disabled { opacity: .65; cursor: default; }
.btn-outline {
    background: hsl(var(--card));
    border-color: hsl(var(--input));
    color: hsl(var(--foreground));
}
.btn-outline:hover { background: hsl(var(--muted)); }
.btn-outline:disabled { opacity: .55; cursor: default; }

/* ---- LinkedIn button (brand color intentional) ---- */
.btn-linkedin {
    width: 100%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 13px 16px;
    font-size: 15px;
    font-weight: 600;
    color: #fff;
    background: #0A66C2;
    border: none;
    border-radius: 9px;
    cursor: pointer;
    text-decoration: none;
    transition: background .15s, transform .05s;
}
.btn-linkedin:hover { background: #004182; }
.btn-linkedin:active { transform: translateY(1px); }

.hint {
    margin: 12px 2px 0;
    font-size: 12.5px;
    color: hsl(var(--muted-foreground));
    text-align: center;
}

/* 회원가입 LinkedIn/Email 사이 "or" 구분선(2026-07-09). */
.or-divider {
    display: flex;
    align-items: center;
    gap: 12px;
    margin: 20px 0;
    color: hsl(var(--muted-foreground));
    font-size: 12px;
    text-transform: uppercase;
    letter-spacing: 0.06em;
}
.or-divider::before,
.or-divider::after {
    content: "";
    flex: 1;
    height: 1px;
    background: hsl(var(--border));
}
/* 인증메일 발송 완료 안내는 초록 톤(.security-note 기본 amber 아이콘 색을 emerald 로). */
#su-sent-msg svg { color: hsl(var(--emerald-700)); }

/* LinkedIn 탭 혜택 안내: Email 탭의 두 입력칸이 차지하던 공간을 대신 채운다(2026-07-09).
   빈 스페이서 대신 실제로 도움이 되는 문구(검증 신원·원클릭·최소 권한)로 공간을 메운다.
   체크 아이콘은 제거하고 텍스트만 둔다(2026-07-09 사용자 요청). */
.ln-benefits {
    list-style: none;
    margin: 4px 0 20px;
    padding: 14px 16px;
    display: flex;
    flex-direction: column;
    gap: 12px;
    background: hsl(var(--secondary));
    border: 1px solid hsl(var(--border));
    border-radius: 10px;
}
.ln-benefits li {
    font-size: 13px;
    line-height: 1.45;
    color: hsl(var(--muted-foreground));
}
.ln-benefits li strong { color: hsl(var(--foreground)); font-weight: 600; }
/* 환영 메시지 첫 줄(제목)은 나머지 본문보다 키워 인사말이 눈에 들어오게 한다(2026-07-10). */
.ln-benefits li.ln-welcome-title {
    margin-bottom: 2px;
}
.ln-benefits li.ln-welcome-title strong {
    font-size: 18px;
    font-weight: 700;
    letter-spacing: -0.01em;
}

.aux-links {
    margin-top: 16px;
    text-align: center;
    font-size: 13px;
}
.aux-links a { color: hsl(var(--violet-700)); text-decoration: none; }
.aux-links a:hover { text-decoration: underline; }
.aux-links .sep { color: hsl(var(--border)); margin: 0 8px; }

/* ---- Verification helpers ---- */
.timer { color: hsl(var(--rose-700)); font-weight: 500; font-size: 12px; margin-left: 6px; }
.verified-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    margin-top: 4px;
    padding: 5px 11px;
    font-size: 12.5px;
    font-weight: 600;
    color: hsl(var(--emerald-700));
    background: hsl(var(--emerald-100));
    border-radius: 999px;
}

/* ---- Security note ---- */
.security-note {
    display: flex;
    gap: 11px;
    padding: 13px 14px;
    margin-bottom: 18px;
    font-size: 12.8px;
    line-height: 1.5;
    color: hsl(var(--amber-800));
    background: hsl(var(--amber-100));
    border: 1px solid hsl(var(--amber-500) / 0.4);
    border-radius: 10px;
}
.security-note svg { flex: 0 0 auto; margin-top: 1px; color: hsl(var(--amber-700)); }
.security-note strong { display: block; margin-bottom: 2px; }

/* ---- Password checklist ---- */
.pw-checklist {
    list-style: none;
    margin: -4px 0 16px;
    padding: 0;
    display: grid;
    gap: 7px;
}
.pw-checklist li {
    display: flex;
    align-items: center;
    gap: 9px;
    font-size: 12.8px;
    color: hsl(var(--muted-foreground));
    transition: color .15s;
}
.pw-checklist .dot {
    flex: 0 0 auto;
    width: 16px;
    height: 16px;
    border-radius: 999px;
    border: 1.5px solid hsl(var(--border));
    position: relative;
    transition: background .15s, border-color .15s;
}
.pw-checklist li.ok { color: hsl(var(--emerald-700)); }
.pw-checklist li.ok .dot {
    background: hsl(var(--emerald-500));
    border-color: hsl(var(--emerald-500));
}
.pw-checklist li.ok .dot::after {
    content: "";
    position: absolute;
    left: 5px; top: 2px;
    width: 4px; height: 8px;
    border: solid #fff;
    border-width: 0 2px 2px 0;
    transform: rotate(45deg);
}

.match-msg { display: block; margin-top: 6px; font-size: 12.5px; }
.match-msg.ok { color: hsl(var(--emerald-700)); }
.match-msg.bad { color: hsl(var(--rose-700)); }

/* ---- Footer note ---- */
.member-foot {
    text-align: center;
    margin: 20px 4px 0;
    font-size: 12.5px;
    color: hsl(var(--muted-foreground));
}

/* ---- Spinner ---- */
.spinner { animation: spin 0.8s linear infinite; }
.spinner circle { stroke-dasharray: 50; stroke-dashoffset: 18; }
@keyframes spin { to { transform: rotate(360deg); } }

/* ---- Toast ---- */
.member-toast {
    position: fixed;
    left: 50%;
    bottom: 28px;
    transform: translateX(-50%) translateY(20px);
    max-width: 90vw;
    padding: 12px 18px;
    background: hsl(var(--foreground));
    color: hsl(var(--background));
    border-radius: 10px;
    font-size: 13.5px;
    font-weight: 500;
    box-shadow: 0 10px 30px -8px rgba(16, 24, 40, 0.45);
    opacity: 0;
    pointer-events: none;
    transition: opacity .2s, transform .2s;
    z-index: 50;
}
.member-toast.show {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
}

/* ---- Responsive: stack on narrow screens ---- */
@media (max-width: 820px) {
    .member-grid { grid-template-columns: 1fr; }
    .member-divider { height: 1px; width: 100%; }
    .member-pane { padding: 32px 24px; }
}
