/* ===== Reset and Hide Old OJS Elements ===== */
/* ===== Reset and Hide Old OJS Elements ===== */
body, html {
    margin: 0;
    padding: 0;
    min-height: 100vh;
    height: auto;
    font-family: 'Inter', sans-serif !important;
    background: #f8fafc;
}
.site-header, .pkp_structure_head, .pkp_head_wrapper, 
.pkp_navigation_primary_row, .pkp_structure_footer_wrapper, 
.pkp_brand_footer, .modern-footer, .cmp_breadcrumbs, .site-footer, .pkp_structure_sidebar {
    display: none !important;
}
.pkp_structure_page {
    margin: 0 !important;
    padding: 0 !important;
    border: none !important;
}
.pkp_structure_content, .pkp_structure_main, .site-content {
    max-width: 100% !important;
    padding: 0 !important;
    margin: 0 !important;
    width: 100% !important;
}

/* ===== Auth Wrapper (Split Screen) ===== */
.auth-wrapper {
    display: flex;
    min-height: 100vh;
    width: 100%;
    overflow: hidden;
}

/* ===== Left Panel ===== */
.auth-left {
    flex: 1.1;
    background: linear-gradient(135deg, #f8fafc 0%, #eef2ff 100%);
    padding: 60px;
    display: flex;
    flex-direction: column;
    position: relative;
    overflow: hidden;
    border-right: 1px solid #e2e8f0;
}
.auth-left::before {
    content: '';
    position: absolute;
    top: -50px;
    right: -50px;
    width: 300px;
    height: 300px;
    background: radial-gradient(circle, rgba(79,70,229,0.1) 0%, rgba(255,255,255,0) 70%);
}
.auth-left::after {
    content: '';
    position: absolute;
    bottom: 10%;
    left: -50px;
    width: 400px;
    height: 400px;
    background: radial-gradient(circle, rgba(59,130,246,0.1) 0%, rgba(255,255,255,0) 70%);
}

.auth-brand {
    display: flex;
    align-items: center;
    gap: 12px;
    text-decoration: none;
    margin-bottom: 60px;
    z-index: 10;
}
.auth-brand img { height: 40px; }
.auth-brand-text h1 { margin: 0; font-size: 1.2rem; font-weight: 800; color: #0f172a; line-height: 1.2; letter-spacing: -0.02em; }
.auth-brand-text p { margin: 0; font-size: 0.75rem; color: #64748b; font-weight: 500; }

.auth-left-content {
    max-width: 480px;
    z-index: 10;
}
.auth-welcome-badge {
    font-size: 1rem;
    font-weight: 700;
    color: #1e293b;
    margin-bottom: 10px;
    display: block;
}
.auth-title {
    font-size: 3rem;
    font-weight: 800;
    color: #4f46e5;
    margin: 0 0 20px;
    line-height: 1.1;
    letter-spacing: -0.03em;
}
.auth-title span { color: #0f172a; }
.auth-desc {
    font-size: 1rem;
    color: #475569;
    line-height: 1.6;
    margin-bottom: 40px;
}

.auth-features {
    display: flex;
    flex-direction: column;
    gap: 24px;
    background: rgba(255, 255, 255, 0.6);
    padding: 30px;
    border-radius: 20px;
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255,255,255,0.8);
    box-shadow: 0 10px 30px rgba(0,0,0,0.02);
}
.auth-feature {
    display: flex;
    align-items: flex-start;
    gap: 16px;
}
.auth-feature-icon {
    width: 40px;
    height: 40px;
    background: #e0e7ff;
    color: #4f46e5;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}
.auth-feature-text h4 { margin: 0 0 4px; font-size: 0.95rem; font-weight: 700; color: #0f172a; }
.auth-feature-text p { margin: 0; font-size: 0.8rem; color: #64748b; line-height: 1.5; }

.auth-illustration {
    position: absolute;
    bottom: -20px;
    right: 20px;
    width: 60%;
    max-width: 500px;
    z-index: 5;
    opacity: 0.9;
    pointer-events: none;
}
.auth-illustration img { width: 100%; height: auto; filter: drop-shadow(0 20px 30px rgba(0,0,0,0.1)); }

/* ===== Right Panel ===== */
.auth-right {
    flex: 0.9;
    background: #ffffff;
    display: flex;
    flex-direction: column;
    padding: 40px 60px;
    position: relative;
}

.auth-nav {
    display: flex;
    justify-content: flex-end;
    align-items: center;
    gap: 20px;
    margin-bottom: auto;
}
.auth-nav a {
    color: #475569;
    text-decoration: none;
    font-weight: 600;
    font-size: 0.9rem;
    display: flex;
    align-items: center;
    gap: 6px;
    transition: color 0.2s;
}
.auth-nav a:hover { color: #4f46e5; }
.auth-nav .lang-select {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 6px 12px;
    border-left: 2px solid #e2e8f0;
    color: #334155;
    font-weight: 600;
    font-size: 0.9rem;
    cursor: pointer;
}

/* ===== Form Container ===== */
.auth-form-container {
    width: 100%;
    max-width: 420px;
    margin: auto;
}
.auth-form-header {
    text-align: center;
    margin-bottom: 30px;
}
.auth-form-icon {
    width: 56px;
    height: 56px;
    background: #eff6ff;
    color: #3b82f6;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 16px;
}
.auth-form-header h2 { margin: 0 0 8px; font-size: 1.8rem; font-weight: 800; color: #0f172a; }
.auth-form-header p { margin: 0; color: #64748b; font-size: 0.95rem; }

.auth-form .form-group {
    margin-bottom: 20px;
}
.auth-form label {
    display: block;
    margin-bottom: 8px;
    font-size: 0.85rem;
    font-weight: 700;
    color: #1e293b;
}
.auth-form .input-wrapper {
    position: relative;
    display: flex;
    align-items: center;
}
.auth-form .input-wrapper svg {
    position: absolute;
    left: 14px;
    color: #94a3b8;
}
.auth-form .input-wrapper .toggle-password {
    position: absolute;
    right: 14px;
    left: auto;
    cursor: pointer;
    color: #64748b;
}
.auth-form input[type="text"],
.auth-form input[type="password"],
.auth-form input[type="email"],
.auth-form select {
    width: 100%;
    padding: 12px 14px 12px 42px;
    border: 1px solid #e2e8f0;
    border-radius: 10px;
    font-size: 0.95rem;
    font-family: 'Inter', sans-serif;
    color: #334155;
    background: #fff;
    transition: all 0.2s;
    box-sizing: border-box;
}
.auth-form input:focus, .auth-form select:focus {
    border-color: #4f46e5;
    box-shadow: 0 0 0 3px rgba(79, 70, 229, 0.1);
    outline: none;
}
.auth-form .forgot-password {
    display: block;
    margin-top: 8px;
    font-size: 0.85rem;
    color: #3b82f6;
    text-decoration: none;
    font-weight: 600;
}
.auth-form .forgot-password:hover { text-decoration: underline; }

.auth-form .form-check {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 24px;
}
.auth-form .form-check input[type="checkbox"] {
    width: 18px;
    height: 18px;
    border-radius: 4px;
    border: 1px solid #cbd5e1;
    cursor: pointer;
}
.auth-form .form-check label {
    margin: 0;
    font-size: 0.85rem;
    font-weight: 600;
    color: #475569;
    cursor: pointer;
}

.btn-primary {
    width: 100%;
    padding: 14px;
    background: linear-gradient(135deg, #3b82f6, #4f46e5);
    color: #fff;
    border: none;
    border-radius: 10px;
    font-weight: 700;
    font-size: 1rem;
    cursor: pointer;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 8px;
    transition: all 0.2s;
    box-shadow: 0 4px 14px rgba(79, 70, 229, 0.25);
}
.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(79, 70, 229, 0.35);
}

.auth-divider {
    display: flex;
    align-items: center;
    text-align: center;
    margin: 24px 0;
    color: #94a3b8;
    font-size: 0.85rem;
}
.auth-divider::before, .auth-divider::after {
    content: '';
    flex: 1;
    border-bottom: 1px solid #e2e8f0;
}
.auth-divider::before { margin-right: 10px; }
.auth-divider::after { margin-left: 10px; }

.btn-outline {
    width: 100%;
    padding: 12px;
    background: #fff;
    color: #3b82f6;
    border: 1px solid #cbd5e1;
    border-radius: 10px;
    font-weight: 700;
    font-size: 0.95rem;
    cursor: pointer;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 8px;
    transition: all 0.2s;
    text-decoration: none;
    box-sizing: border-box;
}
.btn-outline:hover {
    background: #f8fafc;
    border-color: #94a3b8;
    color: #2563eb;
}

/* Fix for OJS form errors */
.pkp_form_error {
    color: #ef4444;
    font-size: 0.8rem;
    margin-top: 4px;
    display: block;
}
.pkp_form_error_block {
    background: #fee2e2;
    border-left: 4px solid #ef4444;
    padding: 12px 16px;
    border-radius: 6px;
    margin-bottom: 20px;
}

/* For register page multi-column form - Restoring standard Bootstrap grid */
.page_register .form-row {
    display: flex !important;
    flex-wrap: wrap !important;
    margin-right: -8px !important;
    margin-left: -8px !important;
}
.page_register .form-row .form-group {
    padding-left: 8px !important;
    padding-right: 8px !important;
    flex: none !important;
    margin-bottom: 20px !important;
}
.page_register .form-control {
    display: block !important;
    width: 100% !important;
    height: auto !important;
    padding: 10px 14px !important;
    font-size: 0.9rem !important;
    font-weight: 500 !important;
    line-height: 1.5 !important;
    color: #334155 !important;
    background-color: #ffffff !important;
    border: 1px solid #cbd5e1 !important;
    border-radius: 8px !important;
    box-sizing: border-box !important;
    transition: border-color 0.15s ease-in-out, box-shadow 0.15s ease-in-out !important;
}
.page_register .form-control:focus {
    border-color: #3b82f6 !important;
    box-shadow: 0 0 0 4px rgba(59, 130, 246, 0.12) !important;
    outline: none !important;
}
.page_register .registration-info-title.alert {
    background: transparent !important;
    border: none !important;
    color: #0f172a !important;
    font-size: 1.1rem !important;
    font-weight: 700 !important;
    padding: 0 !important;
    margin-top: 28px !important;
    margin-bottom: 16px !important;
    border-bottom: 2px solid #e2e8f0 !important;
    padding-bottom: 8px !important;
    border-radius: 0 !important;
}
.page_register small.form-text.text-muted {
    font-size: 0.75rem !important;
    color: #ef4444 !important;
    margin-top: 4px !important;
    display: block !important;
}

.auth-footer {
    position: absolute;
    bottom: 20px;
    left: 0;
    width: 100%;
    text-align: center;
    font-size: 0.75rem;
    color: #94a3b8;
}

/* OJS Form Wrapper Styling */
.ojs-form-wrapper fieldset {
    border: none;
    padding: 0;
    margin: 0 0 24px 0;
}
.ojs-form-wrapper legend {
    font-size: 1.1rem;
    font-weight: 800;
    color: #0f172a;
    margin-bottom: 16px;
    padding-bottom: 8px;
    border-bottom: 1px solid #e2e8f0;
    width: 100%;
}
.ojs-form-wrapper .fields > div {
    margin-bottom: 16px;
    float: none !important;
    width: 100% !important;
    display: block !important;
}
.ojs-form-wrapper label .label {
    display: block;
    margin-bottom: 8px;
    font-size: 0.85rem;
    font-weight: 700;
    color: #1e293b;
}
.ojs-form-wrapper input[type="text"],
.ojs-form-wrapper input[type="password"],
.ojs-form-wrapper input[type="email"],
.ojs-form-wrapper select {
    width: 100%;
    padding: 12px 14px;
    border: 1px solid #e2e8f0;
    border-radius: 10px;
    font-size: 0.95rem;
    font-family: 'Inter', sans-serif;
    color: #334155;
    background: #fff;
    transition: all 0.2s;
    box-sizing: border-box;
}
.ojs-form-wrapper input:focus, .ojs-form-wrapper select:focus {
    border-color: #4f46e5;
    box-shadow: 0 0 0 3px rgba(79, 70, 229, 0.1);
    outline: none;
}
.ojs-form-wrapper .required {
    color: #ef4444;
}
.ojs-form-wrapper .pkp_screen_reader {
    display: none;
}
.ojs-form-wrapper .form-check label {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.85rem;
    color: #475569;
    cursor: pointer;
    font-weight: normal;
}
.ojs-form-wrapper .form-check input[type="checkbox"] {
    width: 16px;
    height: 16px;
}
.auth-form.register .optin label {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 10px;
    font-weight: normal;
    font-size: 0.85rem;
    color: #475569;
}

/* ===== Responsive ===== */
@media (max-width: 992px) {
    .auth-wrapper { flex-direction: column; overflow: auto; }
    .auth-left { flex: none; border-right: none; border-bottom: 1px solid #e2e8f0; padding: 40px 20px; }
    .auth-illustration { display: none; }
    .auth-right { padding: 40px 20px; }
    .auth-footer { position: static; margin-top: 40px; }
}
