/**
 * HR Connect - Creative Frontend Styles
 */

/* Variables - VIFM Brand Colors */
:root {
    --hr-primary: #5190d5;
    --hr-primary-dark: #3a7bc8;
    --hr-primary-light: #e8f4fc;
    --hr-secondary: #4080c5;
    --hr-accent: #8fae1b;
    --hr-success: #8fae1b;
    --hr-warning: #fdcb6e;
    --hr-danger: #b81c23;
    --hr-dark: #515151;
    --hr-gray: #636e72;
    --hr-light: #f5f8fc;
    --hr-white: #ffffff;
    --hr-gradient-1: linear-gradient(135deg, #5190d5 0%, #4080c5 100%);
    --hr-gradient-2: linear-gradient(135deg, #8fae1b 0%, #a8c92e 100%);
    --hr-gradient-3: linear-gradient(135deg, #5190d5 0%, #7eb3e8 100%);
    --hr-shadow: 0 10px 40px rgba(81, 144, 213, 0.1);
    --hr-shadow-hover: 0 20px 60px rgba(81, 144, 213, 0.15);
    --hr-radius: .3rem 0 0 .3rem;
    --hr-radius-sm: 10px;
    --hr-transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Main content area background override */
#main,
#content,
#primary,
.site-main,
.content-area,
main.site-main,
.entry-content,
article.page {
    background: transparent !important;
}

/* Ensure page container has VIFM background */
body:has(.hr-connect-dashboard),
body:has(.hr-connect-container) {
    background-color: #f5f8fc !important;
}

/* Base Styles */
.hr-connect-container,
.hr-connect-dashboard {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    line-height: 1.6;
    color: #515151;
}

.hr-connect-container {
    max-width: 1000px;
    margin: 0 auto;
    padding: 40px 20px;
    min-height: 80vh;
}

.hr-connect-dashboard {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0px 0px 0px;
    min-height: 80vh;
}

.rtl {
    direction: rtl;
    text-align: right;
}

/* ========================================
   LOGIN/REGISTER PAGE STYLES
   ======================================== */

/* Creative Tabs */
.hr-connect-tabs {
    display: flex;
    justify-content: center;
    gap: 10px;
    margin-bottom: 40px;
}

.hr-connect-tab {
    padding: 16px 40px;
    background: var(--hr-white);
    border: 2px solid #e0e0e0;
    font-size: 16px;
    font-weight: 600;
    color: var(--hr-gray);
    cursor: pointer;
    transition: var(--hr-transition);
    position: relative;
    overflow: hidden;
}

.hr-connect-tab span {
    position: relative;
    z-index: 1;
}

.hr-connect-tab:hover {
    border-color: var(--hr-primary);
    transform: translateY(-2px);
}

.hr-connect-tab.active {
    border-color: #5190d5;
    color: var(--hr-white);
    background: #5190d5;
}


/* Form Container */
.hr-connect-form-container {
    background: var(--hr-white);
    box-shadow: var(--hr-shadow);
    padding: 50px;
    position: relative;
    overflow: hidden;
}

.hr-connect-form-container::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 5px;
    background: var(--hr-gradient-1);
}

.hr-connect-form-header {
    text-align: center;
    margin-bottom: 40px;
}

.hr-connect-form-header h2 {
    margin: 0 0 12px 0;
    font-size: 32px;
    font-weight: 700;
    background: var(--hr-gradient-1);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.hr-connect-form-header p {
    margin: 0;
    color: var(--hr-gray);
    font-size: 16px;
}

/* Form Fields */
.hr-connect-form {
    margin: 0;
}

.hr-connect-row {
    display: flex;
    gap: 24px;
}

.hr-connect-row .hr-connect-field {
    flex: 1;
}

.hr-connect-field {
    margin-bottom: 24px;
}

.hr-connect-field label {
    display: block;
    margin-bottom: 10px;
    font-weight: 600;
    color: var(--hr-dark);
    font-size: 14px;
}

.hr-connect-field .required {
    color: var(--hr-danger);
}

.hr-connect-field input[type="text"],
.hr-connect-field input[type="email"],
.hr-connect-field input[type="tel"],
.hr-connect-field input[type="password"],
.hr-connect-field select,
.hr-connect-field textarea {
    width: 100%;
    border: 2px solid #e8e8e8;
    font-size: 15px;
    transition: var(--hr-transition);
    box-sizing: border-box;
    background: var(--hr-light);
    color: var(--hr-dark);
}

.hr-connect-field select {
    -webkit-appearance: none;
    -moz-appearance: none;
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%23515151' d='M6 8L1 3h10z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 16px center;
    padding-right: 40px;
    cursor: pointer;
}

.rtl .hr-connect-field select {
    background-position: left 16px center;
    padding-right: 20px;
    padding-left: 40px;
}

.hr-connect-field input:focus,
.hr-connect-field select:focus,
.hr-connect-field textarea:focus {
    outline: none;
    border-color: var(--hr-primary);
    background: var(--hr-white);
    box-shadow: 0 0 0 4px rgba(81, 144, 213, 0.1);
}

.hr-connect-field input.error,
.hr-connect-field select.error,
.hr-connect-field textarea.error {
    border-color: var(--hr-danger);
    background: #fff5f5;
}

/* Buttons */
.hr-connect-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 16px 32px;
    border: none;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    text-decoration: none;
    transition: var(--hr-transition);
    position: relative;
    overflow: hidden;
}

.hr-connect-btn-primary {
    background: linear-gradient(135deg, #5190d5 0%, #4080c5 100%) !important;
    color: #ffffff !important;
    width: 100%;
    box-shadow: 0 4px 15px rgba(81, 144, 213, 0.4);
    border: none !important;
}

.hr-connect-btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(81, 144, 213, 0.5);
    background: linear-gradient(135deg, #3a7bc8 0%, #3570b5 100%) !important;
    color: #ffffff !important;
}

.hr-connect-btn-primary:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none;
}

.hr-connect-btn-secondary {
    background: var(--hr-light);
    color: var(--hr-dark);
    border: 2px solid #e0e0e0;
}

.hr-connect-btn-secondary:hover {
    background: var(--hr-primary-light);
    border-color: var(--hr-primary);
    color: var(--hr-primary);
}

.hr-connect-btn-outline {
    background: transparent;
    color: var(--hr-white);
    border: 2px solid rgba(255, 255, 255, 0.5);
}

.hr-connect-btn-outline:hover {
    background: var(--hr-white);
    color: var(--hr-primary);
    border-color: var(--hr-white);
}

/* Messages */
.hr-connect-message,
.hr-form-message {
    padding: 16px 20px;
    margin-top: 20px;
    text-align: center;
    font-weight: 500;
    animation: slideIn 0.3s ease;
}

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

.hr-connect-message.success,
.hr-form-message.success {
    background: linear-gradient(135deg, #d4edda 0%, #c3e6cb 100%);
    color: #155724;
}

.hr-connect-message.error,
.hr-form-message.error {
    background: linear-gradient(135deg, #f8d7da 0%, #f5c6cb 100%);
    color: #721c24;
}

/* Form Footer */
.hr-connect-form-footer {
    text-align: center;
    margin-top: 30px;
    padding-top: 25px;
    border-top: 1px solid #eee;
}

.hr-connect-form-footer a {
    color: var(--hr-primary);
    text-decoration: none;
    font-weight: 600;
    transition: var(--hr-transition);
}

.hr-connect-form-footer a:hover {
    color: var(--hr-secondary);
}

.hr-connect-form-footer p {
    margin: 0;
    color: var(--hr-gray);
    font-size: 13px;
}

/* ========================================
   DASHBOARD STYLES
   ======================================== */

/* Creative Welcome Banner - VIFM Purple */
.hr-connect-welcome {
    background: linear-gradient(135deg, #5190d5 0%, #4080c5 100%) !important;
    padding: 50px 60px;
    margin-bottom: 40px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    color: #ffffff !important;
    position: relative;
    overflow: hidden;
    box-shadow: 0 20px 60px rgba(81, 144, 213, 0.3);
}

.hr-connect-welcome::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -10%;
    width: 400px;
    height: 400px;
    background: rgba(255, 255, 255, 0.1);
}

.hr-connect-welcome::after {
    content: '';
    position: absolute;
    bottom: -30%;
    left: 20%;
    width: 200px;
    height: 200px;
    background: rgba(255, 255, 255, 0.05);
}

.hr-connect-welcome-content {
    position: relative;
    z-index: 1;
}

.hr-connect-welcome h1 {
    margin: 0 0 12px 0;
    font-size: 36px;
    font-weight: 700;
}

.hr-connect-welcome p {
    margin: 0;
    opacity: 0.9;
    font-size: 18px;
}

.hr-connect-welcome-actions {
    display: flex;
    gap: 15px;
    align-items: center;
    position: relative;
    z-index: 1;
}

.hr-connect-btn-white {
    background: rgba(255, 255, 255, 0.2);
    backdrop-filter: blur(10px);
    color: var(--hr-white);
    border: 2px solid rgba(255, 255, 255, 0.3);
    padding: 14px 28px;
}

.hr-connect-btn-white:hover {
    background: var(--hr-white);
    color: var(--hr-primary);
    border-color: var(--hr-white);
    transform: translateY(-2px);
}

.hr-connect-btn-white .dashicons {
    font-size: 18px;
    width: 18px;
    height: 18px;
}

/* ========================================
   HOME TAB STYLES
   ======================================== */

/* Home Header */
.hr-home-header {
    background: linear-gradient(135deg, #5190d5 0%, #4080c5 100%);
    padding: 30px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 24px;
    position: relative;
    overflow: hidden;
}

.hr-home-header::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -5%;
    width: 300px;
    height: 300px;
    background: rgba(255, 255, 255, 0.1);
}

.hr-home-header-content {
    display: flex;
    align-items: center;
    gap: 20px;
    position: relative;
    z-index: 1;
}

.hr-home-avatar img {
    width: 70px;
    height: 70px;
    border: 3px solid rgba(255, 255, 255, 0.3);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
}

.hr-home-info h1 {
    margin: 0 0 6px 0;
    font-size: 26px;
    font-weight: 700;
    color: #ffffff;
}

.hr-home-info p {
    margin: 0;
    font-size: 15px;
    color: rgba(255, 255, 255, 0.85);
}

.hr-home-header-actions {
    position: relative;
    z-index: 1;
}

.hr-logout-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 20px;
    background: rgba(255, 255, 255, 0.15);
    color: #ffffff;
    border: 1px solid rgba(255, 255, 255, 0.3);
    font-size: 14px;
    font-weight: 500;
    text-decoration: none;
    transition: var(--hr-transition);
}

.hr-logout-btn:hover {
    background: #ffffff;
    color: #5190d5;
    border-color: #ffffff;
}

.hr-logout-btn .dashicons {
    font-size: 18px;
    width: 18px;
    height: 18px;
}

/* Quick Actions Grid */
.hr-home-actions-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
    margin-bottom: 24px;
}

.hr-home-action-card {
    background: var(--hr-white);
    padding: 24px;
    display: flex;
    align-items: center;
    gap: 16px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.06);
    border: 1px solid #eee;
    cursor: pointer;
    transition: var(--hr-transition);
}

.hr-home-action-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 30px rgba(81, 144, 213, 0.15);
    border-color: #5190d5;
}

.hr-action-icon {
    width: 50px;
    height: 50px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.hr-action-icon .dashicons {
    font-size: 24px;
    width: 24px;
    height: 24px;
    color: #ffffff;
}

.hr-action-icon-blue {
    background: linear-gradient(135deg, #5190d5 0%, #4080c5 100%);
}

.hr-action-icon-green {
    background: linear-gradient(135deg, #8fae1b 0%, #a8c92e 100%);
}

.hr-action-icon-purple {
    background: linear-gradient(135deg, #9b59b6 0%, #8e44ad 100%);
}

.hr-action-icon-orange {
    background: linear-gradient(135deg, #f39c12 0%, #e67e22 100%);
}

.hr-action-content {
    flex: 1;
    min-width: 0;
}

.hr-action-content h3 {
    margin: 0 0 4px 0;
    font-size: 16px;
    font-weight: 700;
    color: var(--hr-dark);
}

.hr-action-content p {
    margin: 0;
    font-size: 13px;
    color: var(--hr-gray);
}

.hr-action-arrow {
    color: #ccc;
    font-size: 20px;
    width: 20px;
    height: 20px;
    transition: var(--hr-transition);
}

.hr-home-action-card:hover .hr-action-arrow {
    color: #5190d5;
    transform: translateX(4px);
}

/* Export Catalog Card */
.hr-home-export-card {
    background: var(--hr-white);
    padding: 24px 30px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.06);
    border: 1px solid #eee;
}

.hr-export-card-content {
    display: flex;
    align-items: center;
    gap: 20px;
}

.hr-export-icon {
    width: 56px;
    height: 56px;
    background: linear-gradient(135deg, #e8f4fc 0%, #d4e9f7 100%);
    display: flex;
    align-items: center;
    justify-content: center;
}

.hr-export-icon .dashicons {
    font-size: 28px;
    width: 28px;
    height: 28px;
    color: #5190d5;
}

.hr-export-info h3 {
    margin: 0 0 4px 0;
    font-size: 17px;
    font-weight: 700;
    color: var(--hr-dark);
}

.hr-export-info p {
    margin: 0;
    font-size: 14px;
    color: var(--hr-gray);
}

.hr-export-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 12px 24px;
    background: linear-gradient(135deg, #5190d5 0%, #4080c5 100%);
    color: #ffffff;
    border: none;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: var(--hr-transition);
    box-shadow: 0 4px 15px rgba(81, 144, 213, 0.3);
}

.hr-export-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(81, 144, 213, 0.4);
}

.hr-export-btn .dashicons {
    font-size: 18px;
    width: 18px;
    height: 18px;
}

.rtl .hr-action-arrow {
    transform: rotate(180deg);
}

.rtl .hr-home-action-card:hover .hr-action-arrow {
    transform: rotate(180deg) translateX(4px);
}

/* Mobile responsive for Home tab */
@media (max-width: 768px) {
    .hr-home-header {
        flex-direction: column;
        text-align: center;
        gap: 20px;
        padding: 25px 20px;
    }

    .hr-home-header-content {
        flex-direction: column;
    }

    .hr-home-info h1 {
        font-size: 22px;
    }

    .hr-home-actions-grid {
        grid-template-columns: 1fr;
    }

    .hr-home-export-card {
        flex-direction: column;
        gap: 20px;
        text-align: center;
    }

    .hr-export-card-content {
        flex-direction: column;
    }

    .hr-export-btn {
        width: 100%;
        justify-content: center;
    }

}

/* Dashboard Layout - Sidebar + Content */
.hr-dashboard-layout {
    display: flex;
    gap: 15px;
    align-items: flex-start;
}

.hr-dashboard-sidebar {
    flex: 0 0 250px;
    position: sticky;
    top: 30px;
    align-self: flex-start;
}

.hr-dashboard-sidebar .hr-dashboard-tabs {
    min-height: 500px;
    box-shadow: 0 0px 19px 0 rgba(0, 0, 0, 0.1), 0 3px 16px 0 rgba(0, 0, 0, 0.1);
}

.hr-dashboard-main {
    flex: 1;
    min-width: 0;
}


/* Creative Dashboard Tabs - Vertical Sidebar */
.hr-dashboard-tabs {
    display: flex;
    flex-direction: column;
    background: var(--hr-white);
    box-shadow: var(--hr-shadow);
    padding: 16px;
    gap: 8px;
    position: relative;
}

.hr-dashboard-tab {
    width: 100%;
    padding: 16px 20px;
    background: transparent;
    border: none;
    font-size: 15px;
    font-weight: 600;
    color: var(--hr-gray);
    cursor: pointer;
    transition: var(--hr-transition);
    display: flex;
    align-items: center;
    justify-content: flex-start;
    gap: 12px;
    position: relative;
    overflow: hidden;
    text-align: left;
}

.rtl .hr-dashboard-tab {
    text-align: right;
}

.hr-dashboard-tab .dashicons {
    font-size: 20px;
    width: 20px;
    height: 20px;
    position: relative;
    z-index: 1;
    transition: var(--hr-transition);
    flex-shrink: 0;
}

.hr-dashboard-tab .hr-tab-label {
    position: relative;
    z-index: 1;
    white-space: nowrap;
}

.hr-dashboard-tab:hover {
    color: #5190d5 !important;
    background: rgba(81, 144, 213, 0.08);
}

.hr-dashboard-tab:hover .dashicons {
    color: #5190d5 !important;
}

.hr-dashboard-tab.active {
    color: #ffffff !important;
    box-shadow: 0 4px 15px rgba(81, 144, 213, 0.4);
    background: #5190d5;
}

.hr-dashboard-tab.active::before {
    opacity: 1;
}

.hr-dashboard-tab.active .dashicons {
    color: var(--hr-white) !important;
}

/* Logout Tab */
.hr-dashboard-tab.hr-dashboard-logout {
    margin-top: auto;
    border-top: 1px solid #eee;
    padding-top: 15px;
    color: #e74c3c;
    text-decoration: none;
}

.hr-dashboard-tab.hr-dashboard-logout:hover {
    background: #fdf2f2;
    color: #c0392b;
}

.hr-dashboard-tab.hr-dashboard-logout .dashicons {
    color: #e74c3c;
}

.hr-dashboard-tab.hr-dashboard-logout:hover .dashicons {
    color: #c0392b;
}

/* Dashboard Content */
.hr-dashboard-content {
    display: none;
    animation: fadeIn 0.5s ease;
}

.hr-dashboard-content.active {
    display: block;
}

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

/* Section */
.hr-connect-section {
    background: var(--hr-white);
    box-shadow: var(--hr-shadow);
    padding: 20px;
    position: relative;
    overflow: hidden;
}

/* Section Header */
.hr-section-header {
    margin-bottom: 35px;
    position: relative;
}

.hr-section-header h2 {
    margin: 0 0 12px 0;
    font-size: 28px;
    font-weight: 700;
    color: var(--hr-dark);
    display: flex;
    align-items: center;
    gap: 12px;
}

.hr-section-header h2 .dashicons {
    width: 40px;
    height: 40px;
    font-size: 24px;
    background: linear-gradient(135deg, #5190d5 0%, #4080c5 100%);
    color: #ffffff !important;
    display: flex;
    align-items: center;
    justify-content: center;
}

.hr-section-desc {
    margin: 0;
    color: var(--hr-gray);
    font-size: 16px;
    max-width: 600px;
}

/* Section Header Row with Actions */
.hr-section-header-row {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 20px;
    flex-wrap: wrap;
}

.hr-section-header-text {
    flex: 1;
    min-width: 0;
}

.hr-section-header-actions {
    flex-shrink: 0;
    display: flex;
    gap: 10px;
    align-items: center;
    padding-top: 5px;
}

.hr-btn-icon {
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.hr-btn-icon .dashicons {
    font-size: 18px;
    width: 18px;
    height: 18px;
}

/* Spin animation for loading state */
.dashicons.spin {
    animation: hr-spin 1s linear infinite;
}

@keyframes hr-spin {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

/* Mobile responsive */
@media (max-width: 600px) {
    .hr-section-header-row {
        flex-direction: column;
        align-items: stretch;
    }

    .hr-section-header-actions {
        padding-top: 15px;
    }

    .hr-section-header-actions .hr-connect-btn {
        width: 100%;
        justify-content: center;
    }
}

/* ========================================
   COURSE CARDS - Using Theme Grid Structure
   ======================================== */

/* Dashboard Course Grid - inherits from theme w-grid */
.hr-connect-section .w-grid.type_grid {
    margin-top: 1rem;
}

.hr-connect-section .w-grid-list {
    display: grid !important;
    grid-template-columns: repeat(3, 1fr);
    /* gap: 0.5rem; */
}

/* Course Card - using theme classes */
.hr-connect-section .w-grid-item {
    position: relative;
    background: #fff;
    overflow: hidden;
    box-shadow: 0 0rem 0rem rgba(0,0,0,0.1), 0 0rem 0rem rgba(0,0,0,0.1);
    transition: all 0.3s ease;
}

.hr-connect-section .w-grid-item:hover {
    box-shadow: 0 0.1rem 0.2rem rgba(0,0,0,0.1), 0 0.33rem 1rem rgba(0,0,0,0.15);
    z-index: 4;
}

.hr-connect-section .w-grid-item-h {
    display: flex;
    flex-direction: column;
    height: 100%;
}

/* Vertical Wrapper */
.hr-connect-section .w-vwrapper {
    display: flex;
    flex-direction: column;
    gap: 0;
}

/* Image Container */
.hr-connect-section .w-post-elm.post_image.has_ratio {
    position: relative;
    display: block;
    overflow: hidden;
    background: #f0f0f0;
}

.hr-connect-section .w-post-elm.post_image.has_ratio a {
    display: block;
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
}

.hr-connect-section .w-post-elm.post_image.has_ratio img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.35s ease, opacity 0.35s ease;
}

.hr-connect-section .w-grid-item:hover .w-post-elm.post_image.has_ratio img {
    transform: scale(1.05);
}

/* Image Placeholder */
.hr-connect-section .hr-course-image-placeholder {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, #f5f7fa 0%, #e4e8ec 100%);
    display: flex;
    align-items: center;
    justify-content: center;
}

.hr-connect-section .hr-course-image-placeholder .dashicons {
    font-size: 48px;
    width: 48px;
    height: 48px;
    color: #c5cdd5;
}

/* Next Date Badge - Matching theme exactly */
.hr-connect-section .course-next-badge {
    position: absolute;
    z-index: 3;
    pointer-events: none;
    width: 100%;
    /* bottom: 0; */
    /* left: 0; */
}

.hr-connect-section .course-next-badge__pill {
    pointer-events: auto;
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    padding: 0.35rem 0.7rem;
    background: var(--color-content-primary, #5190d5);
    color: #fff;
    font-size: 0.78rem;
    line-height: 1.2;
    box-shadow: 0 8px 24px rgba(0,0,0,0.25);
    backdrop-filter: blur(2px);
}

.hr-connect-section .course-next-badge__pill b {
    font-weight: 600;
}

/* Match Badge (green) for recommended */
.hr-connect-section .course-match-badge .course-next-badge__pill {
    background: #00b894;
}

.hr-connect-section .course-match-badge .course-next-badge__pill .dashicons {
    font-size: 14px;
    width: 14px;
    height: 14px;
    vertical-align: middle;
    margin-right: 2px;
}

/* Contact Link */
.hr-connect-section .w-text.icon_atleft {
    padding: 0.5rem 0.8rem;
}

.hr-connect-section .w-text.icon_atleft .w-text-h {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    color: var(--color-content-primary, #5190d5);
    font-size: 0.8rem;
    text-decoration: none;
    transition: color 0.2s ease;
}

.hr-connect-section .w-text.icon_atleft .w-text-h:hover {
    color: #3a70a8;
}

.hr-connect-section .w-text.icon_atleft i,
.hr-connect-section .w-text.icon_atleft .dashicons,
.hr-connect-section .w-text.icon_atleft .fal,
.hr-connect-section .w-text.icon_atleft .fas,
.hr-connect-section .w-text.icon_atleft .far {
    font-size: 14px;
    width: auto;
    height: auto;
    margin-right: 4px;
}

/* Hide course date order (used for sorting) */
.hr-connect-section .w-post-elm.course_date_order {
    display: none;
}

/* Card animation */
.hr-connect-section .w-grid-item.us_animate_afb {
    opacity: 0;
    transform: translateY(20px);
    animation: hrCardFadeIn 0.5s ease forwards;
}

@keyframes hrCardFadeIn {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Taxonomy Rows */
.hr-connect-section .w-post-elm.post_taxonomy {
    padding: 0.25rem 0rem;
    font-size: 0.75rem;
    color: #777;
    line-height: 1.3;
}

.hr-connect-section .w-post-elm.post_taxonomy.has_text_color {
    color: var(--color-content-primary, #5190d5);
}

.hr-connect-section .w-post-elm.post_taxonomy b {
    color: #ccc;
    font-weight: 400;
    padding: 0 0.1rem;
}

/* Course Title */
.hr-connect-section .main-course-title {
    margin: 0;
    padding: 0.5rem 0.8rem 0.3rem;
    font-size: 0.9rem;
    font-weight: 700;
    line-height: 1.35;
}

.hr-connect-section .main-course-title a {
    color: #333;
    text-decoration: none;
    text-transform: uppercase;
    transition: color 0.2s ease;
}

.hr-connect-section .main-course-title a:hover {
    color: var(--color-content-primary, #5190d5);
}

/* Bottom Meta Row */
.hr-connect-section .w-hwrapper {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    padding: 0.3rem 0.8rem 0.8rem;
    gap: 0.8rem;
    margin-top: auto;
}

.hr-connect-section .w-post-elm.post_custom_field.course_length {
    font-size: 0.8rem;
    color: #333;
}

.hr-connect-section .w-post-elm.post_custom_field.course_length .w-post-elm-value {
    font-weight: 500;
}

.hr-connect-section .w-hwrapper .w-post-elm.post_taxonomy {
    padding: 0;
    font-size: 0.8rem;
    color: #666;
}

.hr-connect-section .w-hwrapper .w-post-elm.post_taxonomy b {
    margin: 0 0.15rem;
}

.hr-connect-section .layout_366 .usg_hwrapper_1 {
    padding: 15px 0px;
}

/* RTL Support */
.rtl .hr-connect-section .course-next-badge__pill {
    direction: rtl;
}

.rtl .hr-connect-section .course-match-badge .course-next-badge__pill .dashicons {
    margin-right: 0;
    margin-left: 2px;
}

.rtl .hr-connect-section .w-text.icon_atleft .w-text-h {
    flex-direction: row-reverse;
}

/* Responsive - Course Grid */
@media (max-width: 768px) {
    .hr-connect-section .w-grid-list {
        grid-template-columns: 1fr;
    }

    .hr-connect-section .course-next-badge__pill {
        display: block;
    }
}

/* Empty State */
.hr-empty-state {
    text-align: center;
    padding: 80px 40px;
    color: var(--hr-gray);
}

.hr-empty-state .dashicons {
    font-size: 64px;
    width: 64px;
    height: 64px;
    color: #ddd;
    margin-bottom: 20px;
    background: var(--hr-light);
    padding: 30px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.hr-empty-state p {
    margin: 0 0 25px 0;
    font-size: 18px;
}

/* Dashboard Grid */
.hr-connect-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 30px;
    margin-bottom: 30px;
}

/* Cards */
.hr-connect-card {
    background: var(--hr-white);
    box-shadow: var(--hr-shadow);
    overflow: hidden;
    transition: var(--hr-transition);
}

.hr-connect-card:hover {
    box-shadow: var(--hr-shadow-hover);
}

.hr-connect-card-wide {
    grid-column: span 2;
}

.hr-connect-card-header {
    padding: 24px 28px;
    border-bottom: 1px solid #eee;
    background: var(--hr-light);
}

.hr-connect-card-header h3 {
    margin: 0;
    font-size: 18px;
    font-weight: 700;
    color: var(--hr-dark);
}

.hr-connect-card-body {
    padding: 28px;
}

/* Profile */
.hr-connect-profile {
    display: flex;
    align-items: center;
    margin-bottom: 24px;
    padding-bottom: 24px;
    border-bottom: 1px solid #eee;
}

.hr-connect-avatar {
    margin-right: 20px;
}

.rtl .hr-connect-avatar {
    margin-right: 0;
    margin-left: 20px;
}

.hr-connect-avatar img {
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
}

.hr-connect-profile-info h4 {
    margin: 0 0 6px 0;
    font-size: 20px;
    font-weight: 700;
}

.hr-connect-position {
    margin: 0;
    color: var(--hr-primary);
    font-weight: 600;
}

.hr-connect-company {
    margin: 4px 0 0 0;
    color: var(--hr-gray);
}

.hr-connect-profile-details {
    list-style: none;
    margin: 0;
    padding: 0;
}

.hr-connect-profile-details li {
    padding: 14px 0;
    border-bottom: 1px solid #f0f0f0;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.hr-connect-profile-details li:last-child {
    border-bottom: none;
}

.hr-connect-profile-details .label {
    color: var(--hr-gray);
    font-size: 14px;
}

.hr-connect-profile-details .value {
    font-weight: 600;
    color: var(--hr-dark);
}

.hr-form-row {
    display: flex;
    gap: 24px;
}

.hr-form-row .hr-form-field {
    flex: 1;
}

.hr-form-field {
    margin-bottom: 24px;
}

.hr-form-field label {
    display: block;
    margin-bottom: 10px;
    font-weight: 600;
    color: var(--hr-dark);
    font-size: 14px;
    padding: 10px;
}

.hr-form-field .required {
    color: var(--hr-danger);
}

.hr-form-field input[type="text"],
.hr-form-field input[type="email"],
.hr-form-field input[type="tel"],
.hr-form-field select,
.hr-form-field textarea {
    width: 100%;
    border: 2px solid #e8e8e8;
    font-size: 15px;
    transition: var(--hr-transition);
    box-sizing: border-box;
    background: var(--hr-light);
    color: var(--hr-dark);
}

.hr-dashboard-content .hr-connect-section .hr-quick-links a:hover {
    color: white;
}

.hr-form-field select {
    -webkit-appearance: none;
    -moz-appearance: none;
    appearance: none;
    /* background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%23515151' d='M6 8L1 3h10z'/%3E%3C/svg%3E"); */
    background-repeat: no-repeat;
    background-position: right 16px center;
    padding-right: 40px;
    cursor: pointer;
}

.rtl .hr-form-field select {
    background-position: left 16px center;
    padding-right: 20px;
    padding-left: 40px;
}

.hr-form-field input:focus,
.hr-form-field select:focus,
.hr-form-field textarea:focus {
    outline: none;
    border-color: var(--hr-primary);
    background: var(--hr-white);
    box-shadow: 0 0 0 4px rgba(81, 144, 213, 0.1);
}

.hr-form-actions {
    margin-top: 10px;
}

.hr-form-actions .hr-connect-btn {
    width: auto;
    min-width: 200px;
}

/* Checkbox Group */
.hr-checkbox-group {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(225px, 1fr));
    gap: 7px;
    padding: 20px;
    background: var(--hr-light);
}

.hr-dashboard-tab.active:hover {
    color: white !important;
}

.hr-form-actions button.hr-connect-btn {
    text-transform: inherit !important;
    padding: 20px !important;
    height: 50px;
    line-height: 0 !important;
}

.hr-checkbox-label {
    display: flex;
    align-items: center;
    gap: 10px;
    cursor: pointer;
    font-weight: 500;
    font-size: 14px;
    color: var(--hr-dark);
    padding: 0px 0px;
    background: var(--hr-white);
    transition: var(--hr-transition);
    border: 2px solid transparent;
}

.hr-checkbox-label:hover {
    border-color: var(--hr-primary-light);
}

.hr-checkbox-label input[type="checkbox"] {
    width: 18px;
    height: 18px;
    cursor: pointer;
    accent-color: var(--hr-primary);
}

/* Quick Links */
.hr-quick-links {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 16px;
}

.hr-quick-link {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
    padding: 24px 20px;
    background: var(--hr-light);
    color: var(--hr-dark);
    text-decoration: none;
    font-size: 14px;
    font-weight: 600;
    transition: var(--hr-transition);
    text-align: center;
}

.hr-quick-link:hover {
    background: var(--hr-gradient-1);
    color: var(--hr-white);
    transform: translateY(-4px);
    box-shadow: 0 10px 30px rgba(81, 144, 213, 0.3);
}

.hr-quick-link .dashicons {
    font-size: 28px;
    width: 28px;
    height: 28px;
    color: var(--hr-primary);
    transition: var(--hr-transition);
}

.hr-quick-link:hover .dashicons {
    color: var(--hr-white);
}

/* Creative Modal */
.hr-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.7);
    backdrop-filter: blur(5px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10000;
    animation: fadeIn 0.3s ease;
}

.hr-modal-content {
    background: var(--hr-white);
    padding: 40px;
    max-width: 500px;
    width: 90%;
    position: relative;
    animation: slideUp 0.4s ease;
    box-shadow: 0 25px 80px rgba(0, 0, 0, 0.3);
}

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

.hr-modal-close {
    position: absolute;
    top: 20px;
    right: 24px;
    font-size: 28px;
    color: var(--hr-gray);
    cursor: pointer;
    line-height: 1;
    transition: var(--hr-transition);
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.rtl .hr-modal-close {
    right: auto;
    left: 24px;
}

.hr-modal-close:hover {
    background: var(--hr-light);
    color: var(--hr-dark);
}

.hr-modal h2 {
    margin: 0 0 12px 0;
    font-size: 24px;
    font-weight: 700;
    background: var(--hr-gradient-1);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.hr-modal p {
    color: var(--hr-gray);
    margin-bottom: 24px;
    line-height: 1.6;
}

/* Access Request User Info */
.hr-access-user-info {
    background: var(--hr-light);
    padding: 20px;
    margin-bottom: 24px;
}

.hr-access-user-detail {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 10px;
}

.hr-access-user-detail:last-child {
    margin-bottom: 0;
}

.hr-access-label {
    font-weight: 600;
    color: var(--hr-gray);
    min-width: 80px;
}

.hr-access-value {
    color: var(--hr-dark);
    font-weight: 500;
}

#hr-access-modal .hr-connect-field {
    margin-bottom: 20px;
}

#hr-access-modal .hr-form-actions {
    margin-top: 24px;
}

#hr-access-modal .hr-form-actions .hr-connect-btn {
    width: 100%;
}

/* Loading Animation */
.hr-connect-loading {
    position: relative;
}

.hr-connect-loading::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 30px;
    height: 30px;
    margin: -15px 0 0 -15px;
    border: 3px solid var(--hr-primary-light);
    border-top: 3px solid var(--hr-primary);
    animation: hr-connect-spin 0.8s linear infinite;
}

@keyframes hr-connect-spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

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

@media (max-width: 1024px) {
    .hr-quick-links {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .hr-connect-container {
        padding: 20px 15px;
    }

    .hr-connect-row,
    .hr-form-row {
        flex-direction: column;
        gap: 0;
    }

    .hr-connect-welcome {
        flex-direction: column;
        text-align: center;
        padding: 35px 25px;
    }

    .hr-connect-welcome h1 {
        font-size: 28px;
    }

    .hr-connect-welcome-content {
        margin-bottom: 25px;
    }

    .hr-connect-welcome-actions {
        flex-direction: column;
        width: 100%;
    }

    .hr-connect-welcome-actions .hr-connect-btn {
        width: 100%;
    }

    .hr-connect-grid {
        grid-template-columns: 1fr;
    }

    .hr-connect-card-wide {
        grid-column: span 1;
    }

    .hr-connect-form-container,
    .hr-connect-section {
        padding: 30px 20px;
    }

    .hr-dashboard-layout {
        flex-direction: column;
    }

    .hr-dashboard-sidebar {
        flex: none;
        width: 100%;
        position: relative;
        top: 0;
        margin-bottom: 20px;
    }

    .hr-dashboard-tabs {
        flex-direction: row;
        flex-wrap: wrap;
        padding: 10px;
    }

    .hr-dashboard-tab {
        flex: 1 1 auto;
        padding: 12px 16px;
        min-width: calc(50% - 4px);
    }

    .hr-dashboard-tab .dashicons {
        margin: 0;
    }

    .rtl .hr-dashboard-tab {
        flex-direction: row;
    }

    .hr-connect-section {
        grid-template-columns: 1fr;
    }

    .hr-course-image-link {
        margin: -30px -20px 16px -20px;
    }

    .hr-course-image,
    .hr-course-image-placeholder {
        height: 160px;
    }

    .hr-quick-links {
        grid-template-columns: 1fr;
    }

    .hr-checkbox-group {
        grid-template-columns: 1fr;
    }

    .hr-connect-tabs {
        flex-direction: column;
    }

    .hr-connect-tab {
        width: 100%;
    }

    .hr-section-header h2 {
        font-size: 22px;
    }
}

/* Scrollbar Styling */
.hr-connect-dashboard ::-webkit-scrollbar {
    width: 8px;
    height: 8px;
}

.hr-connect-dashboard ::-webkit-scrollbar-track {
    background: var(--hr-light);
}

.hr-connect-dashboard ::-webkit-scrollbar-thumb {
    background: var(--hr-primary);
}

.hr-connect-dashboard ::-webkit-scrollbar-thumb:hover {
    background: var(--hr-primary-dark);
}

/* ========================================
   VIFM BRAND COLOR OVERRIDES (!important)
   Ensures VIFM purple displays correctly
   ======================================== */

/* Primary Purple Color Overrides */
.hr-connect-container a,
.hr-connect-dashboard a {
    color: #5190d5;
}

.hr-connect-container a:hover,
.hr-connect-dashboard a:hover {
    color: #3a7bc8;
}

/* Course Card Overrides */
.hr-course-card::before {
    background: linear-gradient(135deg, #5190d5 0%, #4080c5 100%) !important;
}

.hr-course-btn {
    background: linear-gradient(135deg, #5190d5 0%, #4080c5 100%) !important;
    color: #ffffff !important;
    box-shadow: 0 4px 15px rgba(81, 144, 213, 0.3) !important;
}

.hr-course-btn:hover {
    box-shadow: 0 8px 25px rgba(81, 144, 213, 0.4) !important;
    color: #ffffff !important;
}

.hr-course-category {
    background: #e8f4fc !important;
    color: #5190d5 !important;
}

.hr-course-title a:hover {
    color: #5190d5 !important;
}

.hr-course-date .dashicons,
.hr-course-location .dashicons {
    color: #5190d5 !important;
}

/* Form Focus State Overrides */
.hr-connect-field input:focus,
.hr-connect-field select:focus,
.hr-connect-field textarea:focus,
.hr-form-field input:focus,
.hr-form-field select:focus,
.hr-form-field textarea:focus {
    border-color: #5190d5 !important;
    box-shadow: 0 0 0 4px rgba(81, 144, 213, 0.1) !important;
}


.hr-connect-tab:hover,
.hr-dashboard-tab:hover {
    border-color: #5190d5 !important;
    color: #5190d5 !important;
}

button.hr-connect-tab.active:hover{
    color: white !important;
}

/* Quick Link Overrides */
.hr-quick-link .dashicons {
    color: #5190d5 !important;
}

.hr-quick-link:hover {
    background: linear-gradient(135deg, #5190d5 0%, #4080c5 100%) !important;
    box-shadow: 0 10px 30px rgba(81, 144, 213, 0.3) !important;
}

.hr-quick-link:hover .dashicons {
    color: #ffffff !important;
}

/* Section Header Icon Override */
.hr-section-header h2 .dashicons {
    background: linear-gradient(135deg, #5190d5 0%, #4080c5 100%) !important;
    color: #ffffff !important;
}

/* Profile Section Overrides */
.hr-connect-position {
    color: #5190d5 !important;
}

/* Form Footer Link Override */
.hr-connect-form-footer a {
    color: #5190d5 !important;
}

.hr-connect-form-footer a:hover {
    color: #4080c5 !important;
}

/* Form Header Title Override */
.hr-connect-form-header h2 {
    background: linear-gradient(135deg, #5190d5 0%, #4080c5 100%) !important;
    -webkit-background-clip: text !important;
    -webkit-text-fill-color: transparent !important;
    background-clip: text !important;
}

/* Modal Title Override */
.hr-modal h2 {
    background: linear-gradient(135deg, #5190d5 0%, #4080c5 100%) !important;
    -webkit-background-clip: text !important;
    -webkit-text-fill-color: transparent !important;
    background-clip: text !important;
}

/* Checkbox Accent Override */
.hr-checkbox-label input[type="checkbox"] {
    accent-color: #5190d5 !important;
}

.hr-checkbox-label:hover {
    border-color: #e8f4fc !important;
}

/* Loading Spinner Override */
.hr-connect-loading::after {
    border-color: #e8f4fc !important;
    border-top-color: #5190d5 !important;
}

/* Scrollbar Override */
.hr-connect-dashboard ::-webkit-scrollbar-thumb {
    background: #5190d5 !important;
}

.hr-connect-dashboard ::-webkit-scrollbar-thumb:hover {
    background: #3a7bc8 !important;
}

/* Form Container Top Border Override */
.hr-connect-form-container::before {
    background: linear-gradient(135deg, #5190d5 0%, #4080c5 100%) !important;
}

/* Button All States */
button.hr-connect-btn-primary,
input[type="submit"].hr-connect-btn-primary,
a.hr-connect-btn-primary {
    background: linear-gradient(135deg, #5190d5 0%, #4080c5 100%) !important;
    color: #ffffff !important;
    box-shadow: 0 4px 15px rgba(81, 144, 213, 0.4) !important;
}

button.hr-connect-btn-primary:hover,
input[type="submit"].hr-connect-btn-primary:hover,
a.hr-connect-btn-primary:hover {
    background: linear-gradient(135deg, #3a7bc8 0%, #3570b5 100%) !important;
    box-shadow: 0 8px 25px rgba(81, 144, 213, 0.5) !important;
}

/* Welcome Banner All Elements */
.hr-connect-welcome,
.hr-connect-welcome * {
    color: #ffffff !important;
}

.hr-connect-welcome {
    background: linear-gradient(135deg, #5190d5 0%, #4080c5 100%) !important;
    box-shadow: 0 20px 60px rgba(81, 144, 213, 0.3) !important;
}

/* White Button in Welcome */
.hr-connect-btn-white:hover {
    color: #5190d5 !important;
}

/* Secondary Button States */
.hr-connect-btn-secondary:hover {
    background: #e8f4fc !important;
    border-color: #5190d5 !important;
    color: #5190d5 !important;
}

/* Export Button */
#hr-export-courses {
    background: linear-gradient(135deg, #5190d5 0%, #4080c5 100%) !important;
    color: #ffffff !important;
}

/* Select Element Fix - Ensure selected value is visible */
.hr-connect-field select,
.hr-form-field select,
.hr-connect-container select,
.hr-connect-dashboard select,
#reg-referral,
#reg-employees,
#request-type,
#request-category,
#request-participants,
#request-timeline,
#pref-industry,
#pref-employees,
select[name="referral"],
select[name="employees"] {
    -webkit-appearance: menulist !important;
    -moz-appearance: menulist !important;
    appearance: menulist !important;
    color: #333333 !important;
    background-color: #f5f8fc !important;
    font-size: 15px !important;
    line-height: 1.5 !important;
    opacity: 1 !important;
    -webkit-text-fill-color: #333333 !important;
}

.hr-connect-field select:focus,
.hr-form-field select:focus,
.hr-connect-container select:focus,
.hr-connect-dashboard select:focus,
#reg-referral:focus,
#reg-employees:focus,
select[name="referral"]:focus,
select[name="employees"]:focus {
    background-color: #ffffff !important;
    color: #333333 !important;
    -webkit-text-fill-color: #333333 !important;
}

.rtl .hr-connect-field select,
.rtl .hr-form-field select,
.rtl .hr-connect-container select,
.rtl .hr-connect-dashboard select {
    text-align: right !important;
}

/* Ensure select option text is visible */
.hr-connect-field select option,
.hr-form-field select option,
.hr-connect-container select option,
.hr-connect-dashboard select option,
#reg-referral option,
#reg-employees option,
select[name="referral"] option,
select[name="employees"] option {
    color: #333333 !important;
    background: #ffffff !important;
    padding: 10px !important;
    -webkit-text-fill-color: #333333 !important;
}

/* ========================================
   NEW FORM STYLES - Conditional Fields
   ======================================== */

/* Full width form field */
.hr-form-field-full {
    flex: 0 0 100% !important;
    max-width: 100%;
}

/* Inline Checkboxes (In-House, Virtual) */
.hr-checkbox-inline {
    display: flex;
    gap: 20px;
    flex-wrap: wrap;
    padding: 16px 20px;
    background: var(--hr-light);
}

.hr-checkbox-inline .hr-checkbox-label {
    flex: 0 0 auto;
    margin: 0;
    padding: 12px 20px;
    background: var(--hr-white);
    border: 2px solid #e8e8e8;
    cursor: pointer;
    transition: var(--hr-transition);
}

.hr-checkbox-inline .hr-checkbox-label:hover {
    border-color: #5190d5;
    background: #e8f4fc;
}

.hr-checkbox-inline .hr-checkbox-label input[type="checkbox"]:checked + span,
.hr-checkbox-inline .hr-checkbox-label:has(input:checked) {
    border-color: #5190d5;
    background: #e8f4fc;
}

/* Radio Buttons Inline (Phone, Online) */
.hr-radio-inline {
    display: flex;
    gap: 20px;
    flex-wrap: wrap;
    padding: 16px 0px;
    background: var(--hr-light);
}

.hr-radio-label {
    display: flex;
    align-items: center;
    gap: 10px;
    cursor: pointer;
    font-weight: 500;
    font-size: 14px;
    color: var(--hr-dark);
    padding: 12px 20px;
    background: var(--hr-white);
    transition: var(--hr-transition);
    border: 2px solid #e8e8e8;
}

.hr-radio-label:hover {
    border-color: #5190d5;
    background: #e8f4fc;
}

.hr-radio-label:has(input:checked) {
    border-color: #5190d5;
    background: #e8f4fc;
}

.hr-radio-label input[type="radio"] {
    width: 18px;
    height: 18px;
    cursor: pointer;
    accent-color: #5190d5;
}

/* Form Section (Schedule a Meeting) */
.hr-form-section {
    margin-top: 30px;
    padding: 25px;
    background: var(--hr-light);
    border: 1px solid #e8e8e8;
}

.hr-form-section-title {
    display: flex;
    align-items: center;
    gap: 10px;
    margin: 0 0 20px 0;
    font-size: 18px;
    font-weight: 700;
    color: #5190d5;
    padding-bottom: 15px;
    border-bottom: 2px solid #e8e8e8;
}

.hr-form-section-title .dashicons {
    width: 24px;
    height: 24px;
    font-size: 24px;
    color: #5190d5;
}

.hr-form-section .hr-form-field {
    margin-bottom: 20px;
}

.hr-form-section .hr-form-field:last-child {
    margin-bottom: 0;
}

/* Date/Time Input Styling */
.hr-form-field input[type="datetime-local"] {
    width: 100%;
    padding: 14px 16px;
    border: 2px solid #e8e8e8;
    font-size: 15px;
    transition: var(--hr-transition);
    box-sizing: border-box;
    background: var(--hr-light);
    color: var(--hr-dark);
    font-family: inherit;
}

.hr-form-field input[type="datetime-local"]:focus {
    outline: none;
    border-color: #5190d5;
    background: var(--hr-white);
    box-shadow: 0 0 0 4px rgba(81, 144, 213, 0.1);
}

/* Conditional Fields Animation */
.hr-conditional-fields {
    animation: slideDown 0.3s ease;
}

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

form#hr-export-form .hr-form-field label {
    padding: inherit;
}

/* Mobile Responsive for new elements */
@media (max-width: 768px) {
    .hr-checkbox-inline,
    .hr-radio-inline {
        flex-direction: column;
        gap: 12px;
    }

    .hr-checkbox-inline .hr-checkbox-label,
    .hr-radio-label {
        width: 100%;
        justify-content: flex-start;
    }

    .hr-form-section {
        padding: 20px 15px;
    }

    .hr-form-section-title {
        font-size: 16px;
    }
}

/* ========================================
   MY REQUESTS TAB STYLES - NEW DESIGN
   ======================================== */

/* Requests Grid Layout */
.hr-requests-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
    gap: 24px;
}

/* New Request Card */
.hr-request-card-new {
    background: var(--hr-white);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.06);
    overflow: hidden;
    transition: var(--hr-transition);
    position: relative;
    border: 1px solid #e8e8e8;
}

.hr-request-card-new:hover {
    box-shadow: 0 12px 40px rgba(81, 144, 213, 0.15);
    transform: translateY(-6px);
    border-color: #5190d5;
}

/* Status-based left border accent */
.hr-request-card-new::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 4px;
    background: #f39c12;
    transition: var(--hr-transition);
}

.hr-request-pending::before {
    background: linear-gradient(180deg, #f39c12 0%, #e67e22 100%);
}

.hr-request-completed::before {
    background: linear-gradient(180deg, #27ae60 0%, #2ecc71 100%);
}

.hr-request-cancelled::before {
    background: linear-gradient(180deg, #95a5a6 0%, #7f8c8d 100%);
}

/* Status Ribbon */
.hr-request-ribbon {
    position: absolute;
    top: 16px;
    right: 16px;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 8px 14px;
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    z-index: 5;
}

.hr-ribbon-pending {
    background: linear-gradient(135deg, #fff3cd 0%, #ffeaa7 100%);
    color: #856404;
    box-shadow: 0 3px 10px rgba(243, 156, 18, 0.2);
}

.hr-ribbon-completed {
    background: linear-gradient(135deg, #d4edda 0%, #a8e6cf 100%);
    color: #155724;
    box-shadow: 0 3px 10px rgba(39, 174, 96, 0.2);
}

.hr-ribbon-cancelled {
    background: linear-gradient(135deg, #e9ecef 0%, #dee2e6 100%);
    color: #6c757d;
    box-shadow: 0 3px 10px rgba(108, 117, 125, 0.2);
}

.hr-request-ribbon .dashicons {
    font-size: 14px;
    width: 14px;
    height: 14px;
}

/* Card Content */
.hr-request-card-content {
    padding: 24px 24px 20px;
    display: flex;
    flex-direction: column;
}

/* Type Badge with Icon */
.hr-request-type-badge {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 16px;
}

.hr-type-icon {
    width: 40px;
    height: 40px;
    background: linear-gradient(135deg, #5190d5 0%, #4080c5 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 12px rgba(81, 144, 213, 0.3);
}

.hr-type-icon .dashicons {
    color: #ffffff;
    font-size: 20px;
    width: 20px;
    height: 20px;
}

.hr-type-text {
    font-size: 15px;
    font-weight: 700;
    color: var(--hr-dark);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* Request Title */
.hr-request-card-title {
    margin: 0 0 12px 0;
    font-size: 18px;
    font-weight: 700;
    color: var(--hr-dark);
    line-height: 1.4;
    padding-right: 80px; /* Space for ribbon */
}

/* Category Tag */
.hr-request-category-tag {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: #f0f4f8;
    color: #5190d5;
    padding: 8px 14px;
    font-size: 13px;
    font-weight: 600;
    margin-bottom: 14px;
}

.hr-request-category-tag .dashicons {
    font-size: 14px;
    width: 14px;
    height: 14px;
    color: #5190d5;
}

/* Request Description */
.hr-request-card-desc {
    margin: 0 0 18px 0;
    color: var(--hr-gray);
    font-size: 14px;
    line-height: 1.7;
    padding: 14px;
    background: #f8f9fa;
    border-left: 3px solid #e8e8e8;
}

/* Meta Info */
.hr-request-card-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 16px;
    padding-top: 16px;
    border-top: 1px dashed #e8e8e8;
}

.hr-meta-item {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-size: 13px;
    color: var(--hr-gray);
    background: #f5f8fc;
    padding: 8px 12px;
}

.hr-meta-item .dashicons {
    color: #5190d5;
    font-size: 16px;
    width: 16px;
    height: 16px;
}

/* Card Footer */
.hr-request-card-footer {
    padding: 16px 24px;
    background: linear-gradient(180deg, #fafbfc 0%, #f5f6f7 100%);
    border-top: 1px solid #e8e8e8;
}

/* Cancel Request Button - New Style */
.hr-cancel-request-btn {
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 12px 20px;
    background: #fff;
    color: #dc3545;
    border: 2px solid #dc3545;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: var(--hr-transition);
}

.hr-cancel-request-btn:hover {
    background: linear-gradient(135deg, #dc3545 0%, #c82333 100%);
    color: #ffffff;
    border-color: transparent;
    box-shadow: 0 6px 20px rgba(220, 53, 69, 0.35);
    transform: translateY(-2px);
}

.hr-cancel-request-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    transform: none;
}

.hr-cancel-request-btn .dashicons {
    font-size: 18px;
    width: 18px;
    height: 18px;
}

/* Completed card styling */
.hr-request-completed {
    opacity: 0.85;
}

.hr-request-completed:hover {
    opacity: 1;
}

/* Cancelled card styling */
.hr-request-cancelled {
    opacity: 0.7;
}

.hr-request-cancelled:hover {
    opacity: 0.9;
}

.hr-request-cancelled .hr-request-card-content {
    position: relative;
}

/* RTL Support for new design */
.rtl .hr-request-card-new::before {
    left: auto;
    right: 0;
}

.rtl .hr-request-ribbon {
    right: auto;
    left: 16px;
}

.rtl .hr-request-card-title {
    padding-right: 0;
    padding-left: 80px;
}

.rtl .hr-request-card-desc {
    border-left: none;
    border-right: 3px solid #e8e8e8;
}

/* Mobile Responsive for new design */
@media (max-width: 768px) {
    .hr-requests-grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }

    .hr-request-card-content {
        padding: 20px;
    }

    .hr-request-ribbon {
        position: relative;
        top: 0;
        right: 0;
        margin-bottom: 16px;
        display: inline-flex;
    }

    .hr-request-card-title {
        padding-right: 0;
        font-size: 16px;
    }

    .hr-request-card-meta {
        flex-direction: column;
        gap: 10px;
    }

    .hr-meta-item {
        width: fit-content;
    }

    .hr-request-card-footer {
        padding: 14px 20px;
    }
}

@media (max-width: 480px) {
    .hr-request-type-badge {
        flex-direction: column;
        align-items: flex-start;
        gap: 8px;
    }

    .hr-type-icon {
        width: 36px;
        height: 36px;
    }

    .hr-type-icon .dashicons {
        font-size: 18px;
        width: 18px;
        height: 18px;
    }
}

/* ========================================
   CITY AUTOCOMPLETE STYLES
   ======================================== */

.hr-autocomplete-wrapper {
    position: relative;
    width: 100%;
}

.hr-autocomplete-dropdown {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: #fff;
    border: 1px solid #e0e0e0;
    border-top: none;
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
    max-height: 300px;
    overflow-y: auto;
    z-index: 1000;
    display: none;
}

.hr-autocomplete-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 16px;
    cursor: pointer;
    border-bottom: 1px solid #f0f0f0;
    transition: all 0.2s ease;
}

.hr-autocomplete-item:last-child {
    border-bottom: none;
}

.hr-autocomplete-item:hover,
.hr-autocomplete-item.active {
    background: linear-gradient(135deg, #f0f7ff 0%, #e8f4fc 100%);
}

.hr-autocomplete-city {
    font-weight: 600;
    color: var(--hr-dark);
    font-size: 14px;
}

.hr-autocomplete-country {
    font-size: 12px;
    color: var(--hr-gray);
    background: #f5f5f5;
    padding: 4px 10px;
}

.hr-autocomplete-item:hover .hr-autocomplete-country,
.hr-autocomplete-item.active .hr-autocomplete-country {
    background: #5190d5;
    color: #fff;
}

/* Scrollbar styling for autocomplete */
.hr-autocomplete-dropdown::-webkit-scrollbar {
    width: 6px;
}

.hr-autocomplete-dropdown::-webkit-scrollbar-track {
    background: #f5f5f5;
}

.hr-autocomplete-dropdown::-webkit-scrollbar-thumb {
    background: #ccc;
}

.hr-autocomplete-dropdown::-webkit-scrollbar-thumb:hover {
    background: #999;
}

/* RTL Support for autocomplete */
.rtl .hr-autocomplete-dropdown {
    left: 0;
    right: 0;
}

.rtl .hr-autocomplete-item {
    flex-direction: row-reverse;
}

/* Mobile responsive */
@media (max-width: 768px) {
    .hr-autocomplete-item {
        padding: 14px 12px;
        flex-direction: column;
        align-items: flex-start;
        gap: 6px;
    }

    .hr-autocomplete-country {
        align-self: flex-start;
    }

    .rtl .hr-autocomplete-item {
        align-items: flex-end;
    }

    .rtl .hr-autocomplete-country {
        align-self: flex-end;
    }
}

/* ========================================
   PROFILE EDIT STYLES
   ======================================== */

.hr-connect-card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.hr-edit-profile-btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 8px 16px;
    background: transparent;
    color: #5190d5;
    border: 1px solid #5190d5;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
}

.hr-edit-profile-btn:hover {
    background: #5190d5;
    color: #fff;
}

.hr-edit-profile-btn .dashicons {
    font-size: 16px;
    width: 16px;
    height: 16px;
}

.hr-profile-form {
    display: flex;
    flex-direction: column;
    gap: 0px;
}

.hr-form-section-divider {
    display: flex;
    align-items: center;
    margin: 10px 0;
    color: var(--hr-gray);
    font-size: 13px;
    font-weight: 600;
}

.hr-form-section-divider::before,
.hr-form-section-divider::after {
    content: '';
    flex: 1;
    height: 1px;
    background: #e0e0e0;
}

.hr-form-section-divider span {
    padding: 0 15px;
    white-space: nowrap;
}

.hr-form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
}

.hr-connect-btn-secondary {
    background: #f5f5f5 !important;
    color: var(--hr-gray) !important;
    border: 1px solid #e0e0e0;
}

.hr-connect-btn-secondary:hover {
    background: #e8e8e8 !important;
    color: var(--hr-dark) !important;
}

.hr-profile-message {
    padding: 12px 16px;
    font-size: 14px;
    margin-top: 10px;
}

.hr-profile-message.success {
    background: #d4edda;
    color: #155724;
    border: 1px solid #c3e6cb;
}

.hr-profile-message.error {
    background: #f8d7da;
    color: #721c24;
    border: 1px solid #f5c6cb;
}

/* Spin animation for loading */
.dashicons.spin {
    animation: spin 1s linear infinite;
}

@keyframes spin {
    100% {
        transform: rotate(360deg);
    }
}

/* RTL support */
.rtl .hr-connect-card-header {
    flex-direction: row-reverse;
}

.rtl .hr-edit-profile-btn {
    flex-direction: row-reverse;
}

.rtl .hr-form-section-divider {
    flex-direction: row-reverse;
}

.hr-connect-section .layout_366 .usg_vwrapper_1 {
    min-height: 270px !important;
}

.hr-connect-section .cols_3>div[class*="list"]>* {
    width: 100%;
}

/* Mobile responsive */
@media (max-width: 768px) {
    .hr-form-row {
        grid-template-columns: 1fr;
    }

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

    .rtl .hr-connect-card-header {
        align-items: flex-end;
    }

    .hr-edit-profile-btn {
        width: 100%;
        justify-content: center;
    }

}
