/* CSS Design System for FLEXX CLICK Login */
:root {
    --primary-yellow: #FFC20E;
    --primary-yellow-hover: #E0AB0B;
    --text-dark: #333333;
    --text-grey: #555555;
    --help-gold: #C48000;
    --bg-light-grey: #EFEFEF;
    --border-grey: #B0B0B0;
    --input-bg-grey: #CCCCCC;
    --sidebar-grey: #C8C8C8;
    --font-english: 'Open Sans', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    --font-arabic: 'Tajawal', 'Open Sans', sans-serif;
}

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

body {
    font-family: var(--font-english);
    color: var(--text-dark);
    background-color: #FFFFFF;
    font-size: 14px;
    line-height: 1.5;
    overflow-x: hidden;
}

/* RTL Override Font */
body.rtl {
    font-family: var(--font-arabic);
}

a {
    color: inherit;
    text-decoration: none;
}

/* Common Container */
.container {
    max-width: 1050px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Header Area */
.header {
    background-color: #FFFFFF;
    padding: 15px 0;
    border-bottom: 1px solid #E5E5E5;
}

.header-container {
    max-width: 1050px;
    margin: 0 auto;
    padding: 0 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

/* Left Side: Logos */
.logo-area {
    display: flex;
    align-items: center;
    gap: 15px;
}

.logo-saib {
    height: 55px;
    width: auto;
    object-fit: contain;
}

.logo-divider {
    width: 1px;
    height: 45px;
    background-color: #CCCCCC;
}

.logo-flexx {
    height: 50px;
    width: auto;
    object-fit: contain;
}

/* Right Side: Help & Lang Switcher */
.header-support {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 10px;
}

.help-section {
    text-align: right;
    font-size: 12px;
}

.need-help-text {
    color: var(--help-gold);
    font-weight: 700;
    display: block;
    margin-bottom: 2px;
    font-size: 13px;
}

.support-text {
    color: var(--text-grey);
}

.support-link {
    text-decoration: underline;
    color: var(--text-grey);
}

.support-link:hover {
    color: var(--text-dark);
}

/* Language Button switcher */
.lang-switcher {
    display: flex;
    gap: 15px;
    margin-top: 5px;
}

.lang-btn {
    background: none;
    border: none;
    cursor: pointer;
    font-size: 12px;
    color: var(--text-grey);
    font-weight: 600;
    padding: 2px 5px;
}

.lang-btn.active {
    color: var(--help-gold);
    font-weight: 700;
}

.lang-btn:hover {
    color: var(--text-dark);
}

/* Sub-header Grey Bar */
.subheader-bar {
    background-color: var(--bg-light-grey);
    padding: 10px 0;
    border-bottom: 1px solid #D8D8D8;
}

.page-title {
    font-size: 18px;
    font-weight: 600;
    color: var(--text-grey);
}

/* Main Content Grid */
.main-content {
    padding: 30px 0 60px 0;
}

.content-container {
    max-width: 1050px;
    margin: 0 auto;
    padding: 0 20px;
    display: grid;
    grid-template-columns: 1.8fr 1fr;
    gap: 40px;
}

/* Form Area */
.login-section {
    display: flex;
    flex-direction: column;
}

.welcome-heading {
    font-size: 16px;
    color: #1F385C; /* Dark corporate blue */
    font-weight: 700;
    margin-bottom: 15px;
}

.welcome-description {
    font-size: 12px;
    color: var(--text-grey);
    margin-bottom: 25px;
    line-height: 1.6;
}

.welcome-description p {
    margin-bottom: 5px;
}

/* Error Notification Box */
.error-box {
    background-color: #FFF0F0;
    border: 1px solid #FFCACA;
    color: #C00000;
    padding: 10px 15px;
    margin-bottom: 20px;
    font-size: 12px;
    font-weight: 600;
    max-width: 580px;
}

/* Input Rows */
.input-row {
    display: flex;
    align-items: stretch;
    background-color: var(--input-bg-grey);
    border: 1px solid var(--border-grey);
    margin-bottom: 15px;
    height: 45px;
    max-width: 580px;
    width: 100%;
}

.input-label {
    display: flex;
    align-items: center;
    padding: 0 15px;
    font-size: 12px;
    font-weight: 600;
    color: #444444;
    width: 220px;
    flex-shrink: 0;
}

.input-wrapper {
    flex-grow: 1;
    background-color: #FFFFFF;
    display: flex;
    align-items: center;
    padding: 0 10px;
    border-left: 1px solid var(--border-grey);
    border-right: 1px solid var(--border-grey);
}

.login-input {
    width: 100%;
    height: 100%;
    border: none;
    outline: none;
    font-size: 15px;
    font-family: inherit;
    color: var(--text-dark);
}

/* Virtual Keyboard Toggle */
.keyboard-toggle {
    width: 70px;
    background-color: var(--input-bg-grey);
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #FFFFFF;
    transition: background-color 0.2s;
    outline: none;
}

.keyboard-toggle:hover {
    background-color: #BCBCBC;
}

.keyboard-icon-svg {
    display: block;
}

/* Buttons Styling */
.yellow-btn {
    background-color: var(--primary-yellow);
    color: #000000;
    border: none;
    cursor: pointer;
    font-size: 13px;
    font-weight: 700;
    letter-spacing: 0.5px;
    text-transform: uppercase;
    transition: background-color 0.2s;
    border-radius: 0; /* Sharp corporate look */
}

.yellow-btn:hover {
    background-color: var(--primary-yellow-hover);
}

.form-actions {
    display: flex;
    justify-content: flex-end;
    max-width: 580px;
    margin-top: 15px;
}

.btn-login-action {
    padding: 8px 25px;
}

/* Right Column Sidebar */
.sidebar-info-box {
    background-color: var(--sidebar-grey);
    padding: 25px 20px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    height: 300px;
    border: 1px solid #B5B5B5;
}

.info-list {
    list-style-type: disc;
    padding-left: 20px;
    color: #333333;
}

.info-list li {
    font-size: 12px;
    margin-bottom: 20px;
    line-height: 1.5;
}

.info-list li:last-child {
    margin-bottom: 0;
}

.inline-link {
    text-decoration: underline;
    color: #333333;
    font-weight: 600;
}

.inline-link:hover {
    color: #000000;
}

.sidebar-actions {
    display: flex;
    justify-content: flex-end;
    margin-top: 10px;
}

.btn-registration-action {
    padding: 8px 18px;
    font-size: 12px;
}

/* Footer Section */
.footer {
    width: 100%;
}

.footer-banner {
    background-color: var(--primary-yellow);
    padding: 30px 40px;
}

.footer-banner span {
    font-size: 28px;
    font-weight: 700;
    color: #1F385C; /* Dark corporate blue to contrast with yellow */
    letter-spacing: -0.5px;
}

.footer-bottom-bar {
    background-color: #000000;
    height: 8px;
    width: 100%;
}

/* Virtual Keyboard Modal/Drawer UI */
.virtual-keyboard-drawer {
    background-color: #F0F0F0;
    border: 1px solid var(--border-grey);
    max-width: 580px;
    width: 100%;
    margin-top: 10px;
    padding: 12px;
    box-shadow: 0 4px 10px rgba(0,0,0,0.1);
    z-index: 100;
    transition: all 0.3s ease;
}

.virtual-keyboard-drawer.hidden {
    display: none;
}

.vk-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 10px;
    border-bottom: 1px solid #DDD;
    padding-bottom: 5px;
}

#vk-title {
    font-size: 12px;
    font-weight: bold;
    color: var(--text-grey);
}

.vk-close-btn {
    background: none;
    border: none;
    font-size: 20px;
    cursor: pointer;
    color: var(--text-grey);
}

.vk-keys-grid {
    display: grid;
    grid-template-columns: repeat(10, 1fr);
    gap: 5px;
}

.vk-key {
    background-color: #FFFFFF;
    border: 1px solid #CCC;
    padding: 8px 0;
    font-size: 12px;
    font-weight: 600;
    text-align: center;
    cursor: pointer;
    user-select: none;
    transition: background-color 0.1s;
    border-radius: 2px;
}

.vk-key:active {
    background-color: #DDD;
}

.vk-key.wide {
    grid-column: span 2;
    background-color: #E6E6E6;
}

.vk-key.special {
    background-color: #E6E6E6;
    font-size: 11px;
}

/* RTL (Right to Left) Styles */
body.rtl .header-container {
    flex-direction: row-reverse;
}

body.rtl .header-support {
    align-items: flex-start;
}

body.rtl .help-section {
    text-align: left;
}

body.rtl .lang-switcher {
    flex-direction: row-reverse;
}

body.rtl .content-container {
    grid-template-columns: 1fr 1.8fr;
}

body.rtl .login-section {
    grid-column: 2;
}

body.rtl .sidebar-info-box {
    grid-column: 1;
}

body.rtl .input-row {
    flex-direction: row-reverse;
}

body.rtl .input-label {
    text-align: right;
    border-left: none;
}

body.rtl .input-wrapper {
    border-left: 1px solid var(--border-grey);
    border-right: 1px solid var(--border-grey);
}

body.rtl .form-actions {
    justify-content: flex-start;
}

body.rtl .sidebar-actions {
    justify-content: flex-start;
}

body.rtl .info-list {
    padding-left: 0;
    padding-right: 20px;
}

body.rtl .footer-banner {
    text-align: right;
}

/* Responsive Adjustments */
@media (max-width: 768px) {
    .content-container {
        grid-template-columns: 1fr;
        gap: 30px;
    }

    body.rtl .content-container {
        grid-template-columns: 1fr;
    }

    body.rtl .login-section {
        grid-column: 1;
    }

    body.rtl .sidebar-info-box {
        grid-column: 1;
    }

    .header-container {
        flex-direction: column;
        gap: 15px;
        align-items: flex-start;
    }

    body.rtl .header-container {
        flex-direction: column;
        align-items: flex-start;
    }

    .header-support {
        align-items: flex-start;
        width: 100%;
    }

    body.rtl .header-support {
        align-items: flex-start;
    }
}
