/* ============================================
   REGISTER PAGE - PLN MODERN EDITION (v7)
   ============================================ */

@import url('https://fonts.googleapis.com/css2?family=Poppins:wght@300;400;500;600;700;800&display=swap');

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Poppins', sans-serif;
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(160deg, #EAF1FB 0%, #F8FBFF 100%);
    padding: 30px 16px;
}

/* ============================================
   CARD WRAPPER
   ============================================ */
.register-wrapper {
    display: flex;
    width: 100%;
    max-width: 880px;
    min-height: 560px;
    border-radius: 28px;
    overflow: hidden;
    box-shadow: 0 25px 60px rgba(15, 61, 115, 0.18);
    background: #FFFFFF;
}

/* ============================================
   LEFT SIDE - BRANDING
   ============================================ */
.register-left {
    flex: 0 0 42%;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 40px 30px 70px;
    overflow: hidden;
    background:
        linear-gradient(160deg, rgba(15,61,115,0.78) 0%, rgba(30,90,168,0.68) 55%, rgba(59,130,246,0.6) 100%),
        url('../img/background.png') center center / cover no-repeat;
    background-color: #0F3D73;
}

.register-left::before {
    content: '';
    position: absolute;
    top: -20%;
    right: -10%;
    width: 60%;
    height: 60%;
    background: radial-gradient(circle, rgba(244,180,0,0.10) 0%, transparent 70%);
    z-index: 0;
    border-radius: 50%;
}

/* WAVE DIVIDER */
.wave-divider {
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 100%;
    line-height: 0;
    z-index: 3;
    pointer-events: none;
}

.wave-divider svg {
    display: block;
    width: 100%;
    height: 90px;
}

/* BRAND CONTENT - dinaikkan */
.brand-content {
    position: relative;
    z-index: 2;
    text-align: center;
    color: white;
    animation: fadeInUp 0.8s ease;
    margin-bottom: 50px; /* naik dari posisi default */
}

@keyframes fadeInUp {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

.brand-logo {
    width: 64px;
    height: 64px;
    object-fit: contain;
    margin-bottom: 14px;
    filter: drop-shadow(0 4px 18px rgba(0,0,0,0.25));
}

.brand-content h1 {
    font-size: 20px;
    font-weight: 700;
    color: white;
    margin-bottom: 4px;
    letter-spacing: -0.3px;
    line-height: 1.2;
}

.brand-content .subtitle {
    font-size: 11px;
    color: rgba(255,255,255,0.85);
    margin-bottom: 16px;
    font-weight: 300;
    letter-spacing: 0.4px;
}

.brand-divider {
    width: 44px;
    height: 3px;
    background: #F4B400;
    margin: 0 auto 18px;
    border-radius: 2px;
}

/* BRAND FEATURES - hidden */
.brand-features {
    display: none;
}

.brand-tagline {
    margin-top: 16px;
    font-size: 8.5px;
    letter-spacing: 1.5px;
    text-transform: uppercase;
    color: rgba(255,255,255,0.7);
    position: relative;
    z-index: 4;
}

/* ============================================
   RIGHT SIDE - FORM
   ============================================ */
.register-right {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 36px 40px;
    background: #FFFFFF;
    position: relative;
}

.register-card {
    width: 100%;
    position: relative;
    z-index: 2;
    animation: slideIn 0.8s ease;
}

@keyframes slideIn {
    from { opacity: 0; transform: translateX(20px); }
    to { opacity: 1; transform: translateX(0); }
}

/* ============================================
   CARD HEADER
   ============================================ */
.card-header {
    text-align: center;
    margin-bottom: 20px;
}

.card-header h2 {
    font-size: 22px;
    font-weight: 700;
    color: #0F3D73;
    margin-bottom: 3px;
    letter-spacing: -0.4px;
}

.card-header p {
    font-size: 12px;
    color: #6B7280;
    font-weight: 400;
}

/* ============================================
   FORM GROUP
   ============================================ */
.form-group {
    margin-bottom: 11px;
}

.form-group label {
    font-size: 10.5px;
    font-weight: 600;
    color: #374151;
    display: block;
    margin-bottom: 4px;
    letter-spacing: 0.2px;
}

.form-group label i {
    margin-right: 5px;
    color: #1E5AA8;
    font-size: 10.5px;
}

.form-group input,
.form-group select {
    width: 100%;
    padding: 9px 13px;
    border: 2px solid #E5E7EB;
    border-radius: 10px;
    font-size: 12.5px;
    font-family: 'Poppins', sans-serif;
    background: #FAFBFF;
    transition: all 0.3s ease;
    color: #1A2634;
    font-weight: 400;
}

.form-group input:focus,
.form-group select:focus {
    border-color: #1E5AA8;
    outline: none;
    box-shadow: 0 0 0 3px rgba(30, 90, 168, 0.08);
    background: #FFFFFF;
}

.form-group input:hover,
.form-group select:hover {
    border-color: #1E5AA8;
}

.form-group input::placeholder {
    color: #B0B8C4;
    font-size: 11.5px;
    font-weight: 300;
}

/* ============================================
   PASSWORD WRAPPER
   ============================================ */
.password-wrapper {
    position: relative;
}

.password-wrapper input {
    padding-right: 42px;
}

.toggle-pass {
    position: absolute;
    right: 11px;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    color: #B0B8C4;
    cursor: pointer;
    font-size: 14px;
    padding: 5px 7px;
    border-radius: 6px;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

.toggle-pass:hover {
    color: #1E5AA8;
    background: rgba(30, 90, 168, 0.08);
}

.toggle-pass:active {
    transform: translateY(-50%) scale(0.9);
}

/* ============================================
   ROLE FIXED
   ============================================ */
.role-fixed .role-display {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 9px 13px;
    border: 2px solid #E5E7EB;
    border-radius: 10px;
    background: #FAFBFF;
    color: #1A2634;
    font-size: 12.5px;
    font-weight: 500;
}

.role-fixed .role-display i {
    color: #B0B8C4;
    font-size: 12.5px;
}

.role-fixed small {
    display: block;
    margin-top: 4px;
    font-size: 9.5px;
    color: #B0B8C4;
    font-weight: 400;
}

.role-fixed small i {
    margin-right: 3px;
    color: #F4B400;
}

/* ============================================
   BUTTON
   ============================================ */
.btn-register {
    width: 100%;
    padding: 11px;
    background: linear-gradient(135deg, #0F3D73, #1E5AA8);
    border: none;
    border-radius: 10px;
    color: white;
    font-size: 12.5px;
    font-weight: 600;
    font-family: 'Poppins', sans-serif;
    cursor: pointer;
    transition: all 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
    margin-top: 6px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    letter-spacing: 0.4px;
    box-shadow: 0 4px 16px rgba(15, 61, 115, 0.25);
}

.btn-register:hover {
    transform: translateY(-2px);
    box-shadow: 0 12px 28px rgba(15, 61, 115, 0.35);
    background: linear-gradient(135deg, #1E5AA8, #3B82F6);
}

.btn-register:active {
    transform: scale(0.97);
}

/* ============================================
   ALERT
   ============================================ */
.alert-custom {
    padding: 9px 13px;
    border-radius: 10px;
    font-size: 11.5px;
    display: flex;
    align-items: center;
    gap: 9px;
    margin-bottom: 14px;
    font-weight: 500;
    border: 1px solid transparent;
}

.alert-custom i {
    font-size: 15px;
}

.alert-danger {
    background: #FEE2E2;
    border-color: #FECACA;
    color: #DC2626;
}

.alert-success {
    background: #DCFCE7;
    border-color: #BBF7D0;
    color: #16A34A;
}

.success-extra {
    background: #F0F9FF;
    padding: 11px 13px;
    border-radius: 10px;
    border-left: 3px solid #1E5AA8;
    display: flex;
    gap: 9px;
    align-items: flex-start;
    margin-bottom: 14px;
}

.success-extra i {
    color: #1E5AA8;
    font-size: 16px;
    margin-top: 1px;
}

.success-extra div {
    font-size: 11.5px;
    color: #1A2634;
    line-height: 1.6;
    font-weight: 400;
}

.success-extra small {
    color: #6B7280;
    font-size: 9.5px;
    font-weight: 400;
}

/* ============================================
   LINK
   ============================================ */
.login-link {
    text-align: center;
    margin-top: 14px;
    font-size: 11.5px;
    color: #374151;
    font-weight: 400;
}

.login-link a {
    color: #1E5AA8;
    text-decoration: none;
    font-weight: 600;
    transition: color 0.3s ease;
}

.login-link a:hover {
    color: #0F3D73;
    text-decoration: underline;
}

.card-footer {
    text-align: center;
    margin-top: 16px;
    padding-top: 12px;
    border-top: 1px solid #E5E7EB;
    font-size: 8.5px;
    color: #B0B8C4;
    font-weight: 400;
    letter-spacing: 0.3px;
}

.card-footer i {
    color: #F4B400;
    margin-right: 3px;
}

/* ============================================
   RESPONSIVE
   ============================================ */
@media (max-width: 860px) {
    .register-wrapper { max-width: 600px; border-radius: 22px; }
    .register-left { padding: 30px 22px 60px; }
    .brand-content h1 { font-size: 17px; }
    .brand-logo { width: 52px; height: 52px; }
    .register-right { padding: 28px 26px; }
}

@media (max-width: 720px) {
    body { padding: 16px 10px; }
    .register-wrapper { flex-direction: column; max-width: 420px; min-height: auto; }
    .register-left {
        flex: none;
        padding: 26px 18px 56px;
        min-height: 220px;
    }
    .wave-divider svg { height: 60px; }
    .register-right { padding: 24px 20px; }
    .brand-logo { width: 46px; height: 46px; margin-bottom: 10px; }
    .brand-content h1 { font-size: 15px; }
    .brand-content .subtitle { font-size: 9.5px; margin-bottom: 12px; }
    .card-header h2 { font-size: 19px; }
}

@media (max-width: 420px) {
    .register-wrapper { border-radius: 18px; max-width: 100%; }
    .register-left { padding: 20px 14px 44px; min-height: 190px; }
    .wave-divider svg { height: 46px; }
    .register-right { padding: 18px 14px; }
    .brand-logo { width: 38px; height: 38px; margin-bottom: 8px; }
    .brand-content h1 { font-size: 13px; }
    .brand-content .subtitle { font-size: 8.5px; margin-bottom: 9px; }
    .brand-divider { width: 30px; margin-bottom: 9px; }
    .brand-tagline { font-size: 7px; }
    .card-header h2 { font-size: 17px; }
    .card-header p { font-size: 10px; }
    .form-group input { font-size: 11.5px; padding: 8px 11px; border-radius: 8px; }
    .form-group label { font-size: 9.5px; }
    .btn-register { font-size: 11.5px; padding: 10px; border-radius: 8px; }
    .role-fixed .role-display { font-size: 11.5px; padding: 8px 11px; border-radius: 8px; }
    .alert-custom { font-size: 10.5px; padding: 8px 11px; border-radius: 8px; }
    .success-extra { font-size: 10.5px; padding: 8px 11px; }
    .login-link { font-size: 10.5px; margin-top: 11px; }
    .card-footer { font-size: 7.5px; margin-top: 13px; padding-top: 9px; }
}

/* Dark Mode */
@media (prefers-color-scheme: dark) {
    body { background: #0E0E1A; }
    .register-wrapper { background: #1A1A2E; }
    .register-right { background: #1A1A2E; }
    .card-header h2 { color: #FFFFFF; }
    .card-header p { color: #9CA3AF; }
    .form-group label { color: #D1D5DB; }
    .form-group input,
    .form-group select {
        background: #2A2A4A;
        border-color: #3A3A5A;
        color: #FFFFFF;
    }
    .form-group input:focus,
    .form-group select:focus {
        border-color: #1E5AA8;
        background: #2A2A4A;
    }
    .form-group input::placeholder { color: #6B7280; }
    .role-fixed .role-display {
        background: #2A2A4A;
        border-color: #3A3A5A;
        color: #FFFFFF;
    }
    .login-link { color: #9CA3AF; }
    .login-link a { color: #3B82F6; }
    .card-footer { border-top-color: #3A3A5A; color: #6B7280; }
    .success-extra {
        background: #1A2A3E;
        border-left-color: #1E5AA8;
    }
    .success-extra div { color: #FFFFFF; }
    .alert-success {
        background: #0A2A1E;
        border-color: #0A4A2E;
        color: #4ADE80;
    }
    .alert-danger {
        background: #2A0A0A;
        border-color: #4A1A1A;
        color: #F87171;
    }
}

/* Reduced Motion */
@media (prefers-reduced-motion: reduce) {
    * {
        animation-duration: 0.01ms !important;
        transition-duration: 0.01ms !important;
    }
}