/* ===================================================
   🎨 REGISTER.CSS - PREMIUM MODERN DESIGN
   =================================================== */

@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700;800&display=swap');

:root {
    --primary: #3b82f6;
    --primary-hover: #2563eb;
    --bg: #f8fafc;
    --card-bg: #ffffff;
    --text-main: #1e293b;
    --text-muted: #64748b;
    --border: #e2e8f0;
    --error: #ef4444;
    --success: #10b981;
    --radius: 12px;
    --shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
}

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

body {
    font-family: 'Inter', system-ui, -apple-system, sans-serif;
    background-color: var(--bg);
    color: var(--text-main);
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    line-height: 1.5;
}

/* Card Container */
.reg-card {
    display: flex;
    max-width: 950px;
    width: 100%;
    background: var(--card-bg);
    border-radius: 20px;
    box-shadow: var(--shadow);
    overflow: hidden;
    min-height: 650px;
    animation: slideUp 0.5s ease-out;
}

/* Cột trái: Illustration & Welcome */
.reg-illustration {
    flex: 1;
    background: linear-gradient(135deg, #3b82f6 0%, #1e40af 100%);
    color: #ffffff;
    padding: 60px 40px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
    position: relative;
    overflow: hidden;
}

/* Hiệu ứng vòng tròn trang trí cho cột trái */
.reg-illustration::before {
    content: "";
    position: absolute;
    width: 300px;
    height: 300px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    top: -100px;
    left: -100px;
}

.reg-illustration h2 {
    font-size: 2.25rem;
    font-weight: 800;
    margin-bottom: 20px;
    z-index: 1;
}

.reg-illustration p {
    font-size: 1.1rem;
    line-height: 1.6;
    opacity: 0.9;
    max-width: 300px;
    z-index: 1;
}

/* Cột phải: Form Content */
.reg-content {
    flex: 1.2;
    padding: 50px 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #ffffff;
}

.reg-inner {
    width: 100%;
    max-width: 380px;
}

.reg-header {
    margin-bottom: 30px;
    text-align: left; /* Căn trái cho chuyên nghiệp */
}

.reg-header h1 {
    font-size: 1.85rem;
    font-weight: 800;
    color: var(--text-main);
    margin-bottom: 10px;
}

.reg-header .subtitle {
    color: var(--text-muted);
    font-size: 15px;
}

/* Form Styles */
.reg-form {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

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

.field label {
    font-size: 14px;
    font-weight: 600;
    color: var(--text-main);
}

.field input {
    width: 100%;
    padding: 12px 16px;
    border: 1.5px solid var(--border);
    border-radius: var(--radius);
    font-size: 15px;
    font-family: inherit;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    background-color: #fcfcfd;
}

.field input:focus {
    outline: none;
    border-color: var(--primary);
    background-color: #ffffff;
    box-shadow: 0 0 0 4px rgba(59, 130, 246, 0.1);
}

/* reCAPTCHA - Căn giữa nhẹ */
.g-recaptcha {
    margin: 5px 0;
    transform: scale(0.95);
    transform-origin: 0 0;
}

/* Button */
.btn {
    width: 100%;
    padding: 14px;
    background-color: var(--primary);
    color: #ffffff;
    border: none;
    border-radius: var(--radius);
    font-size: 16px;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.2s ease;
    margin-top: 10px;
}

.btn:hover {
    background-color: var(--primary-hover);
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(59, 130, 246, 0.25);
}

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

/* Legal/Description */
.reg-description {
    font-size: 12px;
    color: var(--text-muted);
    text-align: center;
    line-height: 1.6;
    margin-top: 10px;
    padding: 0 10px;
}

/* Messages */
.msg {
    min-height: 24px;
    text-align: center;
    font-size: 14px;
    font-weight: 500;
    margin-top: 15px;
    padding: 12px;
    border-radius: 8px;
    display: none;
}

.msg:not(:empty) {
    display: block;
}

.msg.error {
    background-color: #fef2f2;
    color: var(--error);
    border: 1px solid #fee2e2;
}

.msg.success {
    background-color: #f0fdf4;
    color: var(--success);
    border: 1px solid #dcfce7;
}

/* Footer Link */
.reg-footer {
    margin-top: 30px;
    padding-top: 20px;
    border-top: 1px solid var(--border);
    text-align: center;
    font-size: 14px;
    color: var(--text-muted);
}

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

.reg-footer a:hover {
    text-decoration: underline;
}

/* Animations */
@keyframes slideUp {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

/* ===================================================
   📱 RESPONSIVE (MOBILE OPTIMIZED)
   =================================================== */

@media (max-width: 850px) {
    .reg-card {
        flex-direction: column;
        max-width: 480px;
        min-height: auto;
    }

    .reg-illustration {
        padding: 40px 20px;
    }

    .reg-illustration h2 {
        font-size: 1.75rem;
    }

    .reg-illustration p {
        font-size: 1rem;
    }

    .reg-content {
        padding: 40px 25px;
    }

    .reg-header {
        text-align: center;
    }

    .g-recaptcha {
        transform: scale(0.85);
        transform-origin: center;
        display: flex;
        justify-content: center;
    }
}