/* ========================================
   TWO-PANEL LOGIN PAGE WITH ILLUSTRATION
   배경 블롭 + 폰 일러스트레이션 디자인
   ======================================== */

/* ========================================
   FORCE LIGHT MODE - 라이트 모드 강제
   ======================================== */

/* 1. 기본 color-scheme 선언 */
:root,
html,
body {
    color-scheme: light only !important;
}

/* 2. 강제 색상 조정 비활성화 */
*,
*::before,
*::after {
    forced-color-adjust: none !important;
    -webkit-forced-color-adjust: none !important;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --primary: #667eea;
    --primary-dark: #5a67d8;
    --primary-gradient: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    --bg-gradient: linear-gradient(135deg, #e0e7ff 0%, #f0e6ff 50%, #fce7f3 100%);
    --text-primary: #1e293b;
    --text-secondary: #64748b;
    --text-muted: #94a3b8;
    --border: #e2e8f0;
    --success: #667eea;
    --error: #ef4444;
}

body {
    font-family: 'Pretendard', -apple-system, BlinkMacSystemFont, sans-serif;
    background: var(--bg-gradient);
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    position: relative;
    overflow-x: hidden;
}

/* ========================================
   FLOATING BLOBS
   ======================================== */

.blob {
    position: fixed;
    border-radius: 50%;
    filter: blur(60px);
    opacity: 0.5;
    animation: blobFloat 8s ease-in-out infinite;
    z-index: 0;
}

.blob-1 {
    width: 300px;
    height: 300px;
    background: linear-gradient(135deg, #667eea, #764ba2);
    top: -100px;
    left: -50px;
    animation-delay: 0s;
}

.blob-2 {
    width: 250px;
    height: 250px;
    background: linear-gradient(135deg, #a5b4fc, #818cf8);
    bottom: -80px;
    right: -50px;
    animation-delay: 2s;
}

.blob-3 {
    width: 200px;
    height: 200px;
    background: linear-gradient(135deg, #a78bfa, #8b5cf6);
    top: 50%;
    right: 10%;
    animation-delay: 4s;
}

@keyframes blobFloat {
    0%, 100% { transform: translate(0, 0) scale(1); }
    33% { transform: translate(20px, -20px) scale(1.05); }
    66% { transform: translate(-10px, 10px) scale(0.95); }
}

/* ========================================
   LOGIN WRAPPER
   ======================================== */

.login-wrapper {
    display: flex;
    width: 100%;
    max-width: 640px;
    min-height: 450px;
    background: rgba(255, 255, 255, 0.9);
    backdrop-filter: blur(20px);
    border-radius: 24px;
    box-shadow: 0 25px 80px rgba(0, 0, 0, 0.1);
    overflow: hidden;
    position: relative;
    z-index: 1;
}

/* ========================================
   ILLUSTRATION PANEL
   ======================================== */

.illustration-panel {
    width: 38%;
    background: linear-gradient(160deg, #667eea 0%, #764ba2 100%);
    position: relative;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 24px 20px;
}

.deco-circle {
    position: absolute;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.06);
}

.deco-circle-1 {
    width: 220px;
    height: 220px;
    top: -100px;
    left: -60px;
}

.deco-circle-2 {
    width: 160px;
    height: 160px;
    bottom: -60px;
    right: -50px;
}

/* ========================================
   PHONE MOCKUP
   ======================================== */

.phone-container {
    position: relative;
    z-index: 10;
    margin-bottom: 20px;
}

.phone {
    width: 130px;
    height: 260px;
    background: white;
    border-radius: 26px;
    padding: 10px;
    box-shadow: 0 25px 50px rgba(0, 0, 0, 0.25);
    transition: box-shadow 0.4s ease;
}

.phone-container.typing .phone {
    box-shadow: 0 30px 60px rgba(0, 0, 0, 0.3);
}

.phone-screen {
    width: 100%;
    height: 100%;
    background: #f8fafc;
    border-radius: 18px;
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

.phone-header {
    background: var(--primary-gradient);
    padding: 14px 12px 10px;
}

.phone-header-text {
    color: white;
    font-size: 10px;
    font-weight: 700;
}

.phone-content {
    padding: 12px;
    flex: 1;
    display: flex;
    flex-direction: column;
}

.phone-doc-preview {
    background: white;
    border-radius: 8px;
    padding: 10px;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.05);
    margin-bottom: 10px;
}

.phone-line {
    height: 5px;
    background: #e2e8f0;
    border-radius: 3px;
    margin-bottom: 6px;
}

.phone-line:nth-child(1) { width: 55%; }
.phone-line:nth-child(2) { width: 100%; }
.phone-line:nth-child(3) { width: 75%; margin-bottom: 0; }

/* ========================================
   SIGNATURE PAD IN PHONE
   ======================================== */

.signature-pad {
    background: white;
    border-radius: 8px;
    padding: 8px;
    border: 1.5px solid #e2e8f0;
    flex: 1;
    display: flex;
    flex-direction: column;
}

.signature-pad-label {
    font-size: 7px;
    color: var(--text-muted);
    margin-bottom: 4px;
}

.signature-pad-area {
    flex: 1;
    background: #fafafa;
    border-radius: 6px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.signature-path {
    stroke: var(--primary);
    stroke-width: 2;
    fill: none;
    stroke-dasharray: 100;
    animation: drawSign 2.5s ease-in-out infinite;
    transition: stroke 0.3s ease;
}

.phone-container.typing .signature-path {
    animation: drawSign 1.2s ease-in-out infinite;
    stroke: #764ba2;
}

@keyframes drawSign {
    0% { stroke-dashoffset: 100; }
    50% { stroke-dashoffset: 0; }
    100% { stroke-dashoffset: 100; }
}

/* ========================================
   BRAND AREA
   ======================================== */

.brand-area {
    text-align: center;
    z-index: 10;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.brand-header {
    display: flex;
    align-items: center;
    gap: 6px;
    margin-bottom: 6px;
}

.brand-icon {
    width: 28px;
    height: 28px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.brand-icon svg {
    width: 100%;
    height: 100%;
    stroke: white;
}

.brand-title {
    color: white;
    font-size: 22px;
    font-weight: 800;
}

.brand-subtitle {
    color: rgba(255, 255, 255, 0.85);
    font-size: 12px;
}

/* ========================================
   FORM PANEL
   ======================================== */

.form-panel {
    width: 62%;
    padding: 28px 36px;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

/* ========================================
   FORM HEADER
   ======================================== */

.form-header {
    margin-bottom: 26px;
}

.form-header h1 {
    font-size: 28px;
    font-weight: 800;
    color: var(--text-primary);
    margin-bottom: 12px;
}

.form-header p {
    font-size: 14px;
    color: var(--text-secondary);
}

/* ========================================
   ALERTS
   ======================================== */

.alert {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 14px 18px;
    border-radius: 12px;
    margin-bottom: 20px;
    font-size: 14px;
}

.alert-icon {
    width: 20px;
    height: 20px;
    flex-shrink: 0;
}

.alert-success {
    background: rgba(102, 126, 234, 0.15);
    color: #4c51bf;
    border: 1px solid rgba(102, 126, 234, 0.3);
}

.alert-error {
    background: rgba(239, 68, 68, 0.15);
    color: #b91c1c;
    border: 1px solid rgba(239, 68, 68, 0.3);
}

/* ========================================
   FORM
   ======================================== */

.login-form {
    display: flex;
    flex-direction: column;
    gap: 0;
}

.form-group {
    margin-bottom: 12px;
}

.form-group label {
    display: block;
    font-size: 13px;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 6px;
    transition: color 0.2s ease;
}

.form-group:focus-within label {
    color: var(--primary);
}

.form-control {
    width: 100%;
    padding: 13px 15px;
    border: 2px solid #e2e8f0;
    border-radius: 12px;
    font-size: 14px;
    color: var(--text-primary);
    background: #f8fafc;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.form-control:focus {
    outline: none;
    border-color: var(--primary);
    background: white;
    box-shadow: 0 0 0 4px rgba(102, 126, 234, 0.15), 0 4px 12px rgba(102, 126, 234, 0.1);
    transform: translateY(-1px);
}

.form-control:focus::placeholder {
    opacity: 0.5;
}

.form-control::placeholder {
    color: var(--text-muted);
}

.required {
    color: var(--error);
    margin-left: 2px;
    font-weight: 600;
}

.form-control.is-invalid {
    border-color: var(--error);
    background: #fef2f2;
}

.form-control.is-invalid:focus {
    box-shadow: 0 0 0 4px rgba(239, 68, 68, 0.15), 0 4px 12px rgba(239, 68, 68, 0.1);
}

.form-control.verified {
    border-color: var(--success);
    background: #eef2ff;
    color: var(--text-primary);
}

.form-control.verified:focus {
    border-color: var(--success);
    box-shadow: 0 0 0 4px rgba(102, 126, 234, 0.15), 0 4px 12px rgba(102, 126, 234, 0.1);
}

/* 브라우저 자동완성 스타일 오버라이드 */
.form-control:-webkit-autofill,
.form-control:-webkit-autofill:hover,
.form-control:-webkit-autofill:focus,
.form-control:-webkit-autofill:active {
    -webkit-box-shadow: 0 0 0 1000px #f8fafc inset !important;
    -webkit-text-fill-color: var(--text-primary) !important;
    transition: background-color 5000s ease-in-out 0s;
    caret-color: var(--text-primary);
}

/* ========================================
   BUTTONS
   ======================================== */

.submit-btn {
    width: 100%;
    padding: 12px 20px;
    border: none;
    border-radius: 14px;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    background: var(--primary-gradient);
    color: white;
    box-shadow: 0 8px 24px rgba(102, 126, 234, 0.35);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    margin-top: 8px;
    position: relative;
    overflow: hidden;
}

.submit-btn::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    background: rgba(255, 255, 255, 0.3);
    border-radius: 50%;
    transform: translate(-50%, -50%);
    transition: width 0.6s ease, height 0.6s ease;
}

.submit-btn:active::before {
    width: 300px;
    height: 300px;
}

.submit-btn:hover {
    transform: translateY(-2px) scale(1.01);
    box-shadow: 0 12px 32px rgba(102, 126, 234, 0.45);
}

.submit-btn:active {
    transform: translateY(0) scale(0.98);
}

.submit-btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none;
}

.secondary-btn {
    width: 100%;
    padding: 12px;
    border: 2px solid #e2e8f0;
    border-radius: 12px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    background: white;
    color: var(--text-secondary);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    margin-top: 10px;
}

.secondary-btn:hover {
    border-color: var(--primary);
    color: var(--primary);
    background: rgba(102, 126, 234, 0.05);
    transform: translateY(-1px);
}

.secondary-btn:active {
    transform: translateY(0) scale(0.98);
}

/* ========================================
   HIDE SCROLL TO TOP BUTTON
   ======================================== */

.scroll-to-top {
    display: none !important;
}

/* ========================================
   TERMS AGREEMENT
   ======================================== */

.terms-agreement {
    margin-bottom: 16px;
}

.terms-item {
    display: flex;
    align-items: center;
    padding: 14px 16px;
    border: 1.5px solid var(--border);
    border-radius: 12px;
    cursor: pointer;
    transition: all 0.2s ease;
    gap: 12px;
}

.terms-item:hover {
    border-color: #cbd5e1;
    background: #fafbfc;
}

.terms-item.checked {
    border-color: var(--primary);
    background: rgba(102, 126, 234, 0.04);
}

.terms-item-all {
    margin-bottom: 12px;
    padding: 16px;
    background: #f8fafc;
}

.terms-item-all.checked {
    background: rgba(102, 126, 234, 0.06);
    border-color: var(--primary);
}

.terms-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.terms-check {
    width: 24px;
    height: 24px;
    border-radius: 50%;
    border: 2px solid #d1d5db;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    transition: all 0.2s ease;
}

.terms-check svg {
    opacity: 0;
    color: white;
    transition: opacity 0.2s ease;
    width: 14px;
    height: 14px;
}

.terms-item.checked .terms-check {
    background: var(--primary-gradient);
    border-color: transparent;
}

.terms-item.checked .terms-check svg {
    opacity: 1;
}

.terms-label-all {
    font-size: 15px;
    font-weight: 700;
    color: var(--text-primary);
}

.terms-label {
    font-size: 14px;
    font-weight: 500;
    color: var(--text-primary);
    flex: 1;
}

.terms-badge-required {
    font-size: 11px;
    font-weight: 600;
    color: #7c3aed;
    background: #ede9fe;
    padding: 2px 8px;
    border-radius: 4px;
    flex-shrink: 0;
}

.terms-view-link {
    font-size: 13px;
    color: var(--text-muted);
    text-decoration: none;
    flex-shrink: 0;
    transition: color 0.2s;
}

.terms-view-link:hover {
    color: var(--primary);
}

@media (max-width: 480px) {
    .terms-item {
        padding: 12px 14px;
        gap: 10px;
    }

    .terms-item-all {
        padding: 14px;
    }

    .terms-label {
        font-size: 13px;
    }

    .terms-badge-required {
        font-size: 10px;
        padding: 2px 6px;
    }
}

/* ========================================
   TERMS MODAL
   ======================================== */

.terms-modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(4px);
    z-index: 10000;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.terms-modal.active {
    display: flex;
}

.terms-modal-content {
    background: white;
    border-radius: 20px;
    width: 100%;
    max-width: 560px;
    max-height: 80vh;
    display: flex;
    flex-direction: column;
    box-shadow: 0 25px 80px rgba(0, 0, 0, 0.2);
    animation: authFadeIn 0.25s ease;
}

.terms-modal-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 20px 24px;
    border-bottom: 1px solid var(--border);
    flex-shrink: 0;
}

.terms-modal-header h3 {
    font-size: 18px;
    font-weight: 700;
    color: var(--text-primary);
    margin: 0;
}

.terms-modal-close {
    width: 36px;
    height: 36px;
    border: none;
    background: #f1f5f9;
    border-radius: 10px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-secondary);
    transition: all 0.2s;
}

.terms-modal-close:hover {
    background: #e2e8f0;
    color: var(--text-primary);
}

.terms-modal-body {
    padding: 24px;
    overflow-y: auto;
    flex: 1;
    font-size: 14px;
    line-height: 1.7;
    color: var(--text-primary);
}

.terms-modal-body h4 {
    font-size: 15px;
    font-weight: 700;
    color: var(--text-primary);
    margin: 20px 0 8px;
}

.terms-modal-body h4:first-child {
    margin-top: 0;
}

.terms-modal-body p {
    margin: 0 0 12px;
    color: var(--text-secondary);
}

.terms-modal-body ul {
    margin: 0 0 12px;
    padding-left: 20px;
    color: var(--text-secondary);
}

.terms-modal-body li {
    margin-bottom: 4px;
}

.terms-table {
    width: 100%;
    border-collapse: collapse;
    margin: 8px 0 16px;
    font-size: 13px;
}

.terms-table th,
.terms-table td {
    padding: 10px 12px;
    border: 1px solid var(--border);
    text-align: left;
    vertical-align: top;
}

.terms-table th {
    background: #f8fafc;
    font-weight: 600;
    color: var(--text-primary);
    white-space: nowrap;
}

.terms-table td {
    color: var(--text-secondary);
}

.terms-date {
    font-size: 13px;
    color: var(--text-muted) !important;
    margin-top: 20px !important;
    text-align: right;
}

.terms-modal-footer {
    padding: 16px 24px;
    border-top: 1px solid var(--border);
    flex-shrink: 0;
}

.terms-modal-footer .submit-btn {
    margin-top: 0;
}

@media (max-width: 480px) {
    .terms-modal {
        padding: 12px;
    }

    .terms-modal-content {
        max-height: 85vh;
        border-radius: 16px;
    }

    .terms-modal-header {
        padding: 16px 20px;
    }

    .terms-modal-body {
        padding: 20px;
    }

    .terms-table {
        font-size: 12px;
    }

    .terms-table th,
    .terms-table td {
        padding: 8px;
    }

    .terms-modal-footer {
        padding: 12px 20px;
    }
}

/* ========================================
   SIGNUP ROLE CARDS
   ======================================== */

.signup-role-cards {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.signup-role-card {
    border: 2px solid #e2e8f0;
    border-radius: 16px;
    padding: 20px;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    text-align: center;
    position: relative;
}

.signup-role-card:hover {
    border-color: var(--primary);
    box-shadow: 0 0 0 4px rgba(102, 126, 234, 0.12);
    transform: translateY(-1px);
}

.signup-role-card:active {
    transform: translateY(0) scale(0.98);
}

.signup-role-icon {
    width: 56px;
    height: 56px;
    border-radius: 14px;
    background: linear-gradient(135deg, rgba(102, 126, 234, 0.1), rgba(118, 75, 162, 0.1));
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 12px;
    color: var(--primary);
}

.signup-role-name {
    font-size: 17px;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 4px;
}

.signup-role-desc {
    font-size: 13px;
    color: var(--text-secondary);
    line-height: 1.5;
}

.signup-role-card--disabled {
    cursor: default;
    opacity: 0.55;
}

.signup-role-card--disabled:hover {
    border-color: #e2e8f0;
    box-shadow: none;
    transform: none;
}

.signup-role-card--disabled:active {
    transform: none;
}

.signup-role-badge {
    display: inline-block;
    margin-top: 10px;
    padding: 4px 12px;
    font-size: 12px;
    font-weight: 600;
    color: #4c51bf;
    background: #e0e7ff;
    border-radius: 20px;
}

/* ========================================
   RESPONSIVE
   ======================================== */

@media (max-width: 768px) {
    .login-wrapper {
        max-width: 440px;
        flex-direction: column;
        min-height: auto;
    }

    .illustration-panel {
        width: 100%;
        padding: 30px 20px;
    }

    .phone-container {
        margin-bottom: 16px;
    }

    .phone {
        width: 100px;
        height: 200px;
        border-radius: 20px;
        padding: 8px;
    }

    .phone-screen {
        border-radius: 14px;
    }

    .phone-header {
        padding: 10px 10px 8px;
    }

    .phone-header-text {
        font-size: 8px;
    }

    .phone-content {
        padding: 8px;
    }

    .phone-doc-preview {
        padding: 8px;
        margin-bottom: 8px;
    }

    .phone-line {
        height: 4px;
        margin-bottom: 4px;
    }

    .signature-pad {
        padding: 6px;
    }

    .signature-pad-label {
        font-size: 6px;
    }

    .brand-icon {
        width: 24px;
        height: 24px;
    }

    .brand-title {
        font-size: 18px;
    }

    .brand-subtitle {
        font-size: 11px;
    }

    .form-panel {
        width: 100%;
        padding: 28px 28px;
    }

    .form-header {
        margin-bottom: 22px;
    }

    .form-header h1 {
        font-size: 26px;
    }

    .form-control {
        padding: 14px;
    }

    .submit-btn {
        padding: 14px;
    }

    .secondary-btn {
        padding: 12px;
    }

    /* Reduce blob sizes on mobile */
    .blob-1 {
        width: 200px;
        height: 200px;
    }

    .blob-2 {
        width: 180px;
        height: 180px;
    }

    .blob-3 {
        width: 150px;
        height: 150px;
    }
}

@media (max-width: 480px) {
    body {
        padding: 12px;
    }

    .login-wrapper {
        border-radius: 20px;
    }

    .illustration-panel {
        padding: 24px 16px;
    }

    .form-panel {
        padding: 24px 24px;
    }

    .form-header h1 {
        font-size: 24px;
    }

    .form-header p {
        font-size: 13px;
    }

    .form-group {
        margin-bottom: 12px;
    }

    .form-group label {
        font-size: 12px;
    }

    .form-control {
        padding: 13px;
        font-size: 14px;
    }

    .signup-role-card {
        padding: 16px;
    }

    .invitation-info {
        padding: 6px 0 2px;
    }
}

/* ========================================
   SOCIAL LOGIN BUTTONS (공통)
   ======================================== */

.social-btn-container {
    display: flex;
    flex-direction: column;
    gap: 14px;
    margin-top: 12px;
}

.social-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    padding: 12px 20px;
    border-radius: 14px;
    font-size: 15px;
    font-weight: 600;
    text-decoration: none;
    border: none;
    cursor: pointer;
    line-height: 1.4;
    transition: all 0.2s ease;
    position: relative;
}

.social-btn:hover:not(:disabled) {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.08);
}

.social-btn:active:not(:disabled) {
    transform: translateY(0);
}

.social-btn:disabled {
    cursor: not-allowed;
    opacity: 0.45;
}

.social-btn-kakao {
    background: #FEE500;
    color: #3C1E1E;
}

.social-btn-naver {
    background: #03C75A;
    color: #ffffff;
}

.social-btn-email {
    background: var(--primary-gradient);
    color: white;
    box-shadow: 0 4px 16px rgba(102, 126, 234, 0.25);
}

.social-btn-email:hover:not(:disabled) {
    box-shadow: 0 8px 24px rgba(102, 126, 234, 0.35);
}

.social-btn-badge {
    position: absolute;
    top: 50%;
    right: 16px;
    transform: translateY(-50%);
    background: rgba(0, 0, 0, 0.06);
    color: rgba(0, 0, 0, 0.4);
    padding: 3px 10px;
    border-radius: 10px;
    font-size: 11px;
    font-weight: 500;
}

/* ========================================
   INVITATION INFO (설계사 가입)
   ======================================== */

.invitation-info {
    text-align: center;
    padding: 8px 0 4px;
    margin-bottom: 12px;
}

.invitation-info p {
    font-size: 14px;
    color: var(--text-secondary);
    line-height: 1.6;
}

.invitation-agency {
    font-weight: 700;
    color: #667eea;
    position: relative;
}

.invitation-agency::after {
    content: '';
    position: absolute;
    bottom: -1px;
    left: 0;
    right: 0;
    height: 2px;
    background: rgba(102, 126, 234, 0.3);
    border-radius: 1px;
}

/* ========================================
   DIVIDER & INFO TEXT (공통)
   ======================================== */

.divider {
    display: flex;
    align-items: center;
    gap: 12px;
    margin: 24px 0;
}

.divider::before,
.divider::after {
    content: '';
    flex: 1;
    height: 1px;
    background: #e2e8f0;
}

.divider span {
    font-size: 12px;
    color: #94a3b8;
    font-weight: 500;
    white-space: nowrap;
}

.info-text {
    text-align: center;
    color: #cbd5e1;
    font-size: 12px;
    margin-top: 26px;
    line-height: 1.7;
}

.login-link {
    text-align: center;
    margin-top: 18px;
    color: #64748b;
    font-size: 14px;
}

.login-link a {
    color: #667eea;
    font-weight: 600;
    text-decoration: none;
    margin-left: 4px;
}

.login-link a:hover {
    text-decoration: underline;
}

/* ========================================
   AUTH VIEW TRANSITION
   ======================================== */

@keyframes authFadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.auth-view-enter {
    animation: authFadeIn 0.3s ease forwards;
}

.auth-back-link {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    font-size: 14px;
    color: var(--text-secondary);
    text-decoration: none;
    margin-bottom: 20px;
    cursor: pointer;
    transition: color 0.2s;
}

.auth-back-link:hover {
    color: var(--primary);
}

.auth-footer-links {
    text-align: center;
    margin-top: 18px;
    font-size: 14px;
    color: var(--text-secondary);
}

.auth-footer-links a {
    color: var(--primary);
    font-weight: 600;
    text-decoration: none;
}

.auth-footer-links a:hover {
    opacity: 0.75;
}

.auth-footer-divider {
    margin: 0 12px;
    color: #e2e8f0;
}

/* ========================================
   INLINE INPUT GROUP (이메일 인증 인라인 배치)
   ======================================== */

.inline-input-group {
    display: flex;
    gap: 8px;
    align-items: stretch;
}

.inline-input-group .form-control {
    flex: 1;
    min-width: 0;
}

.inline-btn {
    padding: 0 20px;
    border: none;
    border-radius: 12px;
    font-size: 14px;
    font-weight: 600;
    background: var(--primary-gradient);
    color: white;
    cursor: pointer;
    white-space: nowrap;
    font-family: inherit;
    transition: all 0.2s ease;
    min-width: 70px;
}

.inline-btn:hover:not(:disabled) {
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.3);
}

.inline-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.code-input {
    text-align: center;
    letter-spacing: 8px;
    font-weight: 700;
}

.code-timer {
    font-size: 13px;
    font-weight: 600;
    color: var(--primary);
    margin-left: 4px;
}

.code-timer.expired {
    color: var(--error);
}

.verification-help-text {
    margin-top: 8px;
    font-size: 13px;
    color: var(--text-muted);
}

.verification-help-text a {
    color: var(--primary);
    font-weight: 600;
    text-decoration: none;
    margin-left: 2px;
}

.verification-help-text a:hover {
    text-decoration: underline;
}

.cooldown-text {
    text-align: center;
    margin-top: 10px;
    font-size: 13px;
    color: var(--text-muted);
}

.cooldown-text a {
    color: var(--primary);
    font-weight: 600;
    text-decoration: none;
}

.cooldown-text a:hover {
    text-decoration: underline;
}

.signup-divider {
    display: flex;
    align-items: center;
    gap: 12px;
    margin: 16px 0 12px;
}

.signup-divider::before,
.signup-divider::after {
    content: '';
    flex: 1;
    height: 1px;
    background: #e2e8f0;
}

.signup-divider span {
    font-size: 12px;
    color: #94a3b8;
    font-weight: 500;
    white-space: nowrap;
}

/* ========================================
   INVITE ACCEPT PAGE (초대 수락)
   ======================================== */

.invite-accept-wrapper {
    width: 100%;
    max-width: 440px;
    border-radius: 24px;
    overflow: hidden;
    box-shadow: 0 25px 80px rgba(0, 0, 0, 0.1);
    position: relative;
    z-index: 1;
    display: flex;
    flex-direction: column;
}

.invite-accept-top {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    text-align: center;
    padding: 40px 24px 28px;
    position: relative;
    overflow: hidden;
}

.invite-accept-top::before {
    content: '';
    position: absolute;
    width: 200px;
    height: 200px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.06);
    top: -80px;
    left: -40px;
}

.invite-accept-top::after {
    content: '';
    position: absolute;
    width: 150px;
    height: 150px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.06);
    bottom: -50px;
    right: -30px;
}

.invite-accept-logo {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-size: 18px;
    font-weight: 700;
    color: #fff;
    position: relative;
    z-index: 1;
}

.invite-accept-logo-icon {
    width: 36px;
    height: 36px;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.invite-accept-tagline {
    color: rgba(255, 255, 255, 0.8);
    font-size: 13px;
    margin-top: 4px;
    position: relative;
    z-index: 1;
}

.invite-accept-card {
    background: #fff;
    padding: 36px 28px 40px;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
}

.invite-accept-icon {
    width: 64px;
    height: 64px;
    border-radius: 50%;
    background: linear-gradient(135deg, #667eea, #764ba2);
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 20px;
}

.invite-accept-title {
    font-size: 24px;
    font-weight: 700;
    color: var(--text-primary);
    margin: 0 0 12px;
}

.invite-accept-chip {
    display: inline-block;
    background: #f0ebff;
    color: #6d28d9;
    font-size: 14px;
    font-weight: 600;
    padding: 6px 16px;
    border-radius: 20px;
    margin-bottom: 12px;
}

.invite-accept-desc {
    color: var(--text-secondary);
    font-size: 15px;
    line-height: 1.6;
    margin: 0 0 28px;
}

.invite-accept-btn {
    display: block;
    width: 100%;
    max-width: 320px;
    padding: 16px;
    background: var(--primary-gradient);
    color: #fff;
    border: none;
    border-radius: 14px;
    font-size: 17px;
    font-weight: 600;
    cursor: pointer;
    box-shadow: 0 4px 15px rgba(102, 126, 234, 0.4);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    font-family: inherit;
}

.invite-accept-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(102, 126, 234, 0.5);
}

.invite-accept-btn:active {
    transform: translateY(0);
}

@media (max-width: 480px) {
    .invite-accept-wrapper {
        border-radius: 20px;
    }

    .invite-accept-card {
        padding: 28px 24px 32px;
    }
}

/* ========================================
   COMPACT TOP BAR (모바일 일러스트 대체)
   ======================================== */

.compact-top-bar {
    display: none;
}

.compact-top-bar-logo {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 17px;
    font-weight: 700;
    color: #fff;
    position: relative;
    z-index: 1;
}

.compact-top-bar-icon {
    width: 32px;
    height: 32px;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 9px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.compact-top-bar-chip {
    margin-top: 8px;
    background: rgba(255, 255, 255, 0.2);
    color: #fff;
    font-size: 13px;
    padding: 5px 14px;
    border-radius: 16px;
    font-weight: 500;
    position: relative;
    z-index: 1;
}

@media (max-width: 768px) {
    .login-wrapper:has(.compact-top-bar) .compact-top-bar {
        display: flex;
        flex-direction: column;
        align-items: center;
        background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
        padding: 20px 24px;
        position: relative;
        overflow: hidden;
    }

    .login-wrapper:has(.compact-top-bar) .compact-top-bar::before {
        content: '';
        position: absolute;
        width: 180px;
        height: 180px;
        border-radius: 50%;
        background: rgba(255, 255, 255, 0.06);
        top: -80px;
        left: -40px;
    }

    .login-wrapper:has(.compact-top-bar) .illustration-panel {
        display: none;
    }

    .login-wrapper:has(.compact-top-bar) .invitation-info {
        display: none;
    }

    .login-wrapper:has(.compact-top-bar) .form-panel {
        width: 100%;
    }
}

/* ========================================
   MOBILE PC-ONLY BLOCK
   모바일 로그인 차단 화면
   ======================================== */

.mobile-pc-block {
    display: none;
}

@media (max-width: 768px) {
    .mobile-pc-block {
        display: flex;
        flex-direction: column;
        width: 100%;
        max-width: 440px;
        min-height: 480px;
        position: relative;
        z-index: 1;
    }

    .mobile-pc-block ~ .login-wrapper {
        display: none;
    }

    .mobile-pc-block-top {
        background: linear-gradient(135deg, #667eea, #764ba2);
        padding: 40px 24px 28px;
        text-align: center;
        border-radius: 24px 24px 0 0;
        position: relative;
        overflow: hidden;
    }

    .mobile-pc-block-top::before {
        content: '';
        position: absolute;
        width: 180px;
        height: 180px;
        border-radius: 50%;
        background: rgba(255, 255, 255, 0.06);
        top: -70px;
        right: -50px;
    }

    .mobile-pc-block-logo {
        display: flex;
        align-items: center;
        justify-content: center;
        gap: 8px;
        color: white;
        font-size: 18px;
        font-weight: 700;
        position: relative;
        z-index: 1;
    }

    .mobile-pc-block-logo-icon {
        width: 28px;
        height: 28px;
        background: rgba(255, 255, 255, 0.2);
        border-radius: 8px;
        display: flex;
        align-items: center;
        justify-content: center;
    }

    .mobile-pc-block-tagline {
        color: rgba(255, 255, 255, 0.7);
        font-size: 12px;
        margin-top: 6px;
        position: relative;
        z-index: 1;
    }

    .mobile-pc-block-content {
        flex: 1;
        display: flex;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        padding: 36px 24px;
        text-align: center;
        background: rgba(255, 255, 255, 0.9);
        backdrop-filter: blur(20px);
        border-radius: 0 0 24px 24px;
    }

    .mobile-pc-block-icon {
        width: 56px;
        height: 56px;
        background: #ede9fe;
        border-radius: 50%;
        display: flex;
        align-items: center;
        justify-content: center;
        margin-bottom: 20px;
    }

    .mobile-pc-block-title {
        font-size: 18px;
        font-weight: 700;
        color: #1e293b;
        margin-bottom: 8px;
    }

    .mobile-pc-block-desc {
        font-size: 14px;
        color: #64748b;
        line-height: 1.6;
        margin-bottom: 24px;
    }

    .mobile-pc-block-url {
        background: white;
        border: 1px solid #e2e8f0;
        border-radius: 12px;
        padding: 14px 20px;
        display: flex;
        align-items: center;
        gap: 8px;
    }

    .mobile-pc-block-url span {
        font-size: 14px;
        color: #475569;
        font-weight: 500;
    }
}

