/* ==========================================================================
   GMIPSR - Premium & Professional Global Design System
   ========================================================================== */

:root {
    --primary-color: #0d6efd;
    --primary-hover: #0b5ed7;
    --primary-gradient: linear-gradient(135deg, #0d6efd 0%, #0b5ed7 100%);
    --dark-gradient: linear-gradient(135deg, #0f172a 0%, #1e293b 100%);
    --navy-gradient: linear-gradient(135deg, #0b1329 0%, #0f172a 100%);
    --canvas-bg: #f8fafc;
    --card-bg: #ffffff;
    --text-main: #1e293b;
    --text-muted: #64748b;
    --border-light: #e2e8f0;
    --glass-bg: rgba(255, 255, 255, 0.85);
    --glass-border: rgba(226, 232, 240, 0.8);
    --shadow-sm: 0 4px 12px rgba(15, 23, 42, 0.04);
    --shadow-md: 0 10px 30px -10px rgba(15, 23, 42, 0.08);
    --shadow-lg: 0 20px 40px -15px rgba(15, 23, 42, 0.12);
    --shadow-hover: 0 20px 40px -12px rgba(13, 110, 253, 0.18);
}

/* ==========================================================================
   Base Canvas & Body Background
   ========================================================================== */
html {
    scroll-behavior: smooth;
}

body {
    background-color: var(--canvas-bg);
    background-image: 
        radial-gradient(at 0% 0%, rgba(13, 110, 253, 0.04) 0px, transparent 50%),
        radial-gradient(at 100% 100%, rgba(5, 81, 96, 0.04) 0px, transparent 50%);
    background-attachment: fixed;
    font-family: 'Plus Jakarta Sans', 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    color: var(--text-main);
    font-size: 0.95rem;
    line-height: 1.65;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    text-rendering: optimizeLegibility;
    overflow-x: hidden;
}

.website-wrapper {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

/* ==========================================================================
   Typography & Headings
   ========================================================================== */
h1, h2, h3, h4, h5, h6, 
.display-1, .display-2, .display-3, .display-4, .display-5, .display-6,
.h1, .h2, .h3, .h4, .h5, .h6 {
    font-family: 'Plus Jakarta Sans', 'Outfit', sans-serif;
    font-weight: 700;
    letter-spacing: -0.02em;
    color: #091e42;
}

p {
    color: #334155;
    line-height: 1.7;
}

.text-muted {
    color: var(--text-muted) !important;
}

/* ==========================================================================
   Premium Section Background Variations
   ========================================================================== */
.bg-light:not([class*="bg-opacity"]) {
    background-color: #f1f5f9;
    background-image: radial-gradient(rgba(13, 110, 253, 0.025) 1px, transparent 0);
    background-size: 24px 24px;
}

.bg-white:not([class*="bg-opacity"]) {
    background-color: #ffffff;
}

.bg-premium-dark {
    background: var(--dark-gradient) !important;
    color: #ffffff !important;
}

.bg-navy-dark {
    background: var(--navy-gradient) !important;
    color: #ffffff !important;
}

/* ==========================================================================
   Cards & Glassmorphism
   ========================================================================== */
.card {
    background: #ffffff;
    border: 1px solid var(--border-light);
    border-radius: 1.25rem;
    box-shadow: var(--shadow-md);
    transition: transform 0.35s cubic-bezier(0.16, 1, 0.3, 1), 
                box-shadow 0.35s cubic-bezier(0.16, 1, 0.3, 1), 
                border-color 0.35s ease;
}

.card:hover, .hover-lift:hover {
    transform: translateY(-6px);
    box-shadow: var(--shadow-hover) !important;
    border-color: rgba(13, 110, 253, 0.3) !important;
}

.glass-card {
    background: var(--glass-bg);
    -webkit-backdrop-filter: blur(12px);
    backdrop-filter: blur(12px);
    border: 1px solid var(--glass-border);
    border-radius: 1.25rem;
    box-shadow: var(--shadow-md);
}

.backdrop-blur {
    -webkit-backdrop-filter: blur(10px);
    backdrop-filter: blur(10px);
}

/* ==========================================================================
   Buttons & Micro-Interactions
   ========================================================================== */
.btn {
    font-family: 'Outfit', sans-serif;
    font-weight: 600;
    border-radius: 50rem;
    padding: 0.65rem 1.6rem;
    transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.btn-primary {
    background: var(--primary-gradient);
    border: none;
    box-shadow: 0 4px 15px rgba(13, 110, 253, 0.28);
    color: #ffffff;
}

.btn-primary:hover, .btn-primary:focus {
    background: linear-gradient(135deg, #0b5ed7 0%, #0a58ca 100%);
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(13, 110, 253, 0.4);
    color: #ffffff;
}

.btn-outline-primary {
    border-color: #0d6efd;
    color: #0d6efd;
}

.btn-outline-primary:hover {
    background: var(--primary-gradient);
    border-color: transparent;
    color: #ffffff;
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(13, 110, 253, 0.3);
}

.btn-light {
    background: #ffffff;
    color: #0d6efd;
    border: 1px solid var(--border-light);
    box-shadow: var(--shadow-sm);
}

.btn-light:hover {
    background: #f8fafc;
    color: #0b5ed7;
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}

/* ==========================================================================
   Badges & Pills
   ========================================================================== */
.badge {
    font-family: 'Outfit', sans-serif;
    letter-spacing: 0.03em;
    font-weight: 600;
    padding: 0.45em 0.9em;
    border-radius: 50rem;
}

.bg-primary-subtle {
    background-color: rgba(13, 110, 253, 0.08) !important;
    color: #0d6efd !important;
    border: 1px solid rgba(13, 110, 253, 0.15);
}

.bg-success-subtle {
    background-color: rgba(25, 135, 84, 0.08) !important;
    color: #198754 !important;
    border: 1px solid rgba(25, 135, 84, 0.15);
}

.bg-warning-subtle {
    background-color: rgba(255, 193, 7, 0.12) !important;
    color: #b8860b !important;
    border: 1px solid rgba(255, 193, 7, 0.25);
}

.bg-info-subtle {
    background-color: rgba(13, 202, 240, 0.1) !important;
    color: #0aa2c0 !important;
    border: 1px solid rgba(13, 202, 240, 0.2);
}

/* ==========================================================================
   Gallery Items
   ========================================================================== */
.gallery-item {
    overflow: hidden;
    border-radius: 1rem;
    box-shadow: var(--shadow-md);
    transition: transform 0.35s ease;
}

.gallery-item img {
    width: 100%;
    height: 280px;
    object-fit: cover;
    transition: transform 0.5s cubic-bezier(0.16, 1, 0.3, 1);
}

.gallery-item:hover img {
    transform: scale(1.08);
}

/* ==========================================================================
   Recruiter Logos
   ========================================================================== */
.recruiter-logo {
    max-height: 70px;
    transition: all 0.35s ease;
    filter: grayscale(100%);
    opacity: 0.75;
}

.recruiter-logo:hover {
    filter: none;
    opacity: 1;
    transform: scale(1.08);
}

/* ==========================================================================
   Form Controls
   ========================================================================== */
.form-control, .form-select {
    border-radius: 0.75rem;
    padding: 0.75rem 1rem;
    border: 1px solid var(--border-light);
    box-shadow: var(--shadow-sm);
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.form-control:focus, .form-select:focus {
    border-color: #0d6efd;
    box-shadow: 0 0 0 4px rgba(13, 110, 253, 0.15);
}

/* ==========================================================================
   Footer Customization
   ========================================================================== */
footer, .main-site-footer {
    background: linear-gradient(135deg, #022c22 0%, #064e3b 50%, #022c22 100%) !important;
    color: #ffffff !important;
}

footer h4, footer h5, footer h6,
.main-site-footer h4, .main-site-footer h5, .main-site-footer h6 {
    color: #ffffff !important;
}

footer p, footer span, footer small, footer .small, footer div, footer li, footer strong,
.main-site-footer p, .main-site-footer span, .main-site-footer small, .main-site-footer .small, .main-site-footer div, .main-site-footer li, .main-site-footer strong {
    color: #ffffff !important;
}

footer a, .main-site-footer a {
    color: #ffffff !important;
    text-decoration: none;
    transition: color 0.25s ease;
}

footer a:hover, .main-site-footer a:hover {
    color: #fde047 !important;
}

/* Max-width Utility */
.max-w-700 {
    max-width: 700px;
}

/* ==========================================================================
   Universal Icon & Logo Spacing (Across All Pages)
   ========================================================================== */
.site-logo-wrap {
    margin-right: 14px !important;
}

.main-site-footer .footer-contact-item,
.admin-main-footer .admin-footer-contact-item {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    margin-bottom: 12px;
}

.main-site-footer .footer-contact-item i,
.admin-main-footer .admin-footer-contact-item i {
    width: 20px;
    min-width: 20px;
    text-align: center;
    margin-top: 3px;
    margin-right: 8px !important;
    flex-shrink: 0;
}

.footer-link i,
.admin-footer-link i {
    margin-right: 10px !important;
    display: inline-block;
}

.top-bar-strip i {
    margin-right: 8px !important;
}

/* Gap-2.5 Polyfill for Bootstrap 5 */
.gap-2\.5, .gap-2-5 {
    gap: 0.75rem !important;
}

/* Ensure any icon followed by text has breathing room */
.btn > i:first-child:not(.ms-auto):not(.float-end) {
    margin-right: 8px;
}

.badge > i:first-child {
    margin-right: 6px;
}

.nav-link > i:first-child,
.dropdown-item > i:first-child {
    margin-right: 8px;
}

/* Universal Text White Opacity Utilities */
.text-white-75, .text-white-80, .text-white-90 {
    color: rgba(255, 255, 255, 0.92) !important;
}

/* ==========================================================================
   Universal Responsive System (All Devices: Mobile, Tablet, Desktop)
   ========================================================================== */

/* 1. Global Viewport & Container Reset */
html, body {
    width: 100%;
    max-width: 100vw;
    overflow-x: hidden !important;
    -webkit-text-size-adjust: 100%;
    text-size-adjust: 100%;
}

*, *::before, *::after {
    box-sizing: border-box;
}

/* Prevent Media from Overflowing Container */
img:not(.site-logo):not(.footer-logo-img):not(.recruiter-logo), svg, video, canvas, audio, iframe, embed, object {
    max-width: 100%;
    height: auto;
}

/* Universal Table Responsiveness */
.table-responsive {
    width: 100%;
    margin-bottom: 1rem;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
}

/* 2. Tablets & Small Laptops (max-width: 991.98px) */
@media (max-width: 991.98px) {
    .container {
        max-width: 100% !important;
        padding-left: 16px !important;
        padding-right: 16px !important;
    }

    .gallery-item img {
        height: 220px;
    }

    .recruiter-logo {
        max-height: 55px;
    }
}

/* 3. Mobile Devices & Smartphones (max-width: 767.98px) */
@media (max-width: 767.98px) {
    /* Responsive Spacing & Containers */
    .container {
        padding-left: 12px !important;
        padding-right: 12px !important;
    }

    /* Prevent text zooming on focus in iOS */
    .form-control, .form-select, input[type="text"], input[type="email"], input[type="tel"], input[type="number"], select, textarea {
        font-size: 16px !important;
    }

    /* Fluid Typography */
    h1, .h1, .display-4, .display-5 {
        font-size: clamp(1.4rem, 5vw, 1.85rem) !important;
        line-height: 1.25 !important;
    }

    h2, .h2 {
        font-size: clamp(1.25rem, 4.5vw, 1.6rem) !important;
        line-height: 1.3 !important;
    }

    h3, .h3 {
        font-size: clamp(1.1rem, 4vw, 1.35rem) !important;
    }

    h4, .h4 {
        font-size: clamp(1rem, 3.5vw, 1.2rem) !important;
    }

    h5, .h5 {
        font-size: 0.95rem !important;
    }

    h6, .h6 {
        font-size: 0.875rem !important;
    }

    /* Cards & Glassmorphic Elements */
    .card, .glass-card {
        border-radius: 1rem !important;
        padding: 1.15rem !important;
    }

    /* Compact Buttons */
    .btn {
        padding: 0.5rem 1.2rem;
        font-size: 0.9rem;
    }

    .btn-lg {
        padding: 0.6rem 1.4rem !important;
        font-size: 0.95rem !important;
    }

    /* Gallery & Media */
    .gallery-item img {
        height: 180px;
    }

    .recruiter-logo {
        max-height: 44px;
    }

    /* Footer on Mobile */
    footer {
        padding-top: 2.5rem !important;
    }

    .main-site-footer .footer-social-btn {
        width: 34px;
        height: 34px;
        font-size: 13px;
    }
}

/* 4. Extra Small Phones (max-width: 480px) */
@media (max-width: 480px) {
    .container {
        padding-left: 8px !important;
        padding-right: 8px !important;
    }

    .card, .glass-card {
        padding: 1rem !important;
        border-radius: 0.85rem !important;
    }

    .badge {
        font-size: 0.72rem !important;
        padding: 0.35em 0.7em !important;
    }

    .gallery-item img {
        height: 150px;
    }
}

/* ==========================================================================
   Universal Icon Spacing & Typography Alignment Engine
   ========================================================================== */

/* Universal Prefix Icon Gap (Any icon immediately preceding words/text) */
i[class*="fa-"],
i[class*="bi-"],
i.fa,
i.fas,
i.far,
i.fab,
i.fa-solid,
i.fa-regular,
i.fa-brands,
i.fa-light,
i.fa-duotone,
svg.svg-inline--fa {
    margin-right: 0.45rem;
    display: inline-block;
    vertical-align: -0.125em;
}

/* Explicit Bootstrap Spacing Utility Classes (Enforce minimum distinct gap) */
.me-1 > i, i.me-1 { margin-right: 0.35rem !important; }
.me-1\.5 > i, i.me-1\.5 { margin-right: 0.45rem !important; }
.me-2 > i, i.me-2 { margin-right: 0.55rem !important; }
.me-2\.5 > i, i.me-2\.5 { margin-right: 0.65rem !important; }
.me-3 > i, i.me-3 { margin-right: 0.85rem !important; }

/* Suffix / Trailing Directional Icons (Icons placed AFTER words, e.g. right arrow, external link, dropdown caret) */
i.fa-arrow-right,
i.fa-arrow-right-long,
i.fa-angles-right,
i.fa-chevron-right,
i.fa-angle-right,
i.fa-caret-right,
i.fa-arrow-up-right-from-square,
i.fa-external-link-alt,
i.fa-external-link,
i.fa-chevron-down.dropdown-caret,
i[class*="fa-"].ms-1,
i[class*="fa-"].ms-1\.5,
i[class*="fa-"].ms-2,
i[class*="fa-"].ms-3 {
    margin-right: 0 !important;
    margin-left: 0.45rem !important;
}

/* Exceptions: Isolated / Centered Icon Containers (Never offset centered icons) */
.rounded-circle > i,
.rounded-circle > svg,
.icon-box > i,
.tab-icon-wrap > i,
.social-icon > i,
.avatar > i,
.avatar-circle > i,
.btn-icon > i,
.action-btn > i,
.badge-icon > i,
.site-logo-placeholder > i,
.footer-social-btn > i,
.d-flex.align-items-center.justify-content-center > i:only-child,
.d-inline-flex.align-items-center.justify-content-center > i:only-child,
button.btn-close > i,
.carousel-control-prev-icon,
.carousel-control-next-icon,
i.me-0,
i.m-0,
i.mx-0,
.me-0 > i {
    margin-right: 0 !important;
    margin-left: 0 !important;
}

/* Dropdown Menu Item Icon Alignment */
.dropdown-item i {
    min-width: 1.25rem;
    text-align: center;
    margin-right: 0.6rem !important;
    margin-left: 0 !important;
}
.dropdown-item i.fa-chevron-right,
.dropdown-item i.fa-arrow-right {
    min-width: auto;
    margin-left: auto !important;
    margin-right: 0 !important;
}

/* Badge Icon Spacing */
.badge i:not(:only-child) {
    margin-right: 0.35rem;
}

/* List Item Icon Spacing */
ul.list-unstyled li i,
.list-group-item i {
    margin-right: 0.45rem;
}