﻿/* =============================================================================
   CSS VARIABLES & ROOT CONFIGURATION
   ============================================================================= */
:root {
    /* Color Palette */
    --primary-color: #0e8d44; /*#522c82*/
    --secondary-color: #522c82; /*#0e8d44*/
    --accent-color: #1f4e79;
    --background-dark: #080838;
    --background-light: #f9f9f9;
    --background-card: rgba(255, 255, 255, 0.9);
    --hover-bg: #f0f0f0;
    --text-muted: #666;
    --border-color: #ddd;
    /* Layout & Spacing */
    --border-radius: 16px;
    --border-radius-small: 12px;
    --border-radius-large: 20px;
    --shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
    --shadow-hover: 0 6px 16px rgba(41, 24, 109, 0.3);
    --shadow-light: 0 2px 6px rgba(0, 0, 0, 0.05);
    /* Typography */
    --heading-font: inherit;
    --font-size-base: 1rem;
    --font-size-large: 1.3rem;
    --font-weight-normal: 400;
    --font-weight-medium: 500;
    --font-weight-bold: 600;
    /* Transitions */
    --transition-fast: 0.2s ease;
    --transition-normal: 0.3s ease;
    /* Responsive Breakpoints */
    --breakpoint-xs: 576px;
    --breakpoint-sm: 768px;
    --breakpoint-md: 992px;
    --breakpoint-lg: 1200px;
    --breakpoint-xl: 1400px;
}

/* =============================================================================
   RTL SUPPORT
   ============================================================================= */

html[dir="ltr"], body[dir="ltr"] {
    font-family: 'Ubuntu', system-ui, sans-serif;
}

html[dir="rtl"], body[dir="rtl"] {
    font-family: 'Tajawal', system-ui, sans-serif;
}

    html[dir="rtl"] .link-button:hover i {
        transform: translateX(-4px);
    }

    html[dir="rtl"] .social-links a {
        margin-right: 0;
        margin-left: 10px;
    }

    html[dir="rtl"] .dropdown-menu {
        text-align: right;
        right: 0;
        left: auto;
    }

    html[dir="rtl"] .modal-header {
        flex-direction: row; /* keep LTR order even in RTL */
    }

        html[dir="rtl"] .modal-header .modal-title {
            text-align: left; /* keep title on the left */
        }

        html[dir="rtl"] .modal-header .btn-close {
            margin-left: 0;
            margin-right: auto; /* push close button to the far right */
        }

@font-face {
    font-family: 'Ubuntu';
    src: url('../fonts/Ubuntu-Regular.ttf') format('truetype');
    font-weight: normal;
    font-style: normal;
}

@font-face {
    font-family: 'Tajawal';
    src: url('../fonts/Tajawal-Regular.ttf') format('truetype');
    font-weight: normal;
    font-style: normal;
}

html, body {
    height: 100%;
    margin: 0;
}

body {
    display: flex;
    flex-direction: column;
    /*min-height: 100vh;*/
}

/* =============================================================================
   BASE LAYOUT & TYPOGRAPHY
   ============================================================================= */
.page-background {
    flex: 1;
    background: linear-gradient(135deg, #e9dbd1, #f9f6f3);
    min-height: 90vh;
    padding-top:2.5rem;
    display: flex;
    justify-content: center;
    align-items: flex-start;
}

.navbar {
    border-radius: 10px;
}

h1, h2, h3, h4, h5, h6 {
    color: var(--primary-color);
    font-family: var(--heading-font);
    margin-bottom: 1rem;
}

    h3.fw-bold {
        color: var(--primary-color) !important;
        font-weight: var(--font-weight-medium);
    }

h4 {
    font-weight: var(--font-weight-medium);
    color: var(--primary-color);
}

    h4.fw-bold {
        color: var(--primary-color) !important;
        font-weight: var(--font-weight-medium);
    }


.text-muted {
    color: var(--text-muted) !important;
}

.profile-photo {
    width: 150px;
    height: 150px;
    object-fit: cover;
    border-radius: 50%;
    border: 2px solid #00a859;
    box-shadow: 0px 4px 8px rgba(0,0,0,0.1);
}
/* =============================================================================
   MAIN CARD COMPONENT
   ============================================================================= */
.link-card {
    background: var(--background-card);
    border-radius: var(--border-radius);
    box-shadow: var(--shadow);
    max-width: 500px;
    width: 100%;
    padding: 2rem;
    margin: 1rem auto;
    text-align: center;
    position: relative;
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.logo {
    max-width: 250px;
    width: 100%;
    height: auto;
    margin-bottom: 2rem;
    object-fit: contain;
}

/* =============================================================================
   NAVIGATION & LANGUAGE TOGGLE
   ============================================================================= */
.language-toggle {
    font-size: var(--font-size-large);
    transition: transform var(--transition-fast);
    color: var(--secondary-color);
    text-decoration: none;
    display: inline-block;
    padding: 0.5rem;
    border-radius: 8px;
}

    .language-toggle:hover {
        transform: scale(1.2);
        color: var(--primary-color);
        background-color: rgba(255, 255, 255, 0.1);
    }

/* =============================================================================
   BUTTONS & INTERACTIVE ELEMENTS
   ============================================================================= */
.link-button {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    border: 2px solid var(--secondary-color);
    color: var(--secondary-color);
    background-color: transparent;
    transition: all var(--transition-normal);
    font-weight: var(--font-weight-bold);
    font-size: var(--font-size-base);
    padding: 1rem 1.5rem;
    border-radius: var(--border-radius-small);
    text-decoration: none;
    width: 100%;
    box-shadow: var(--shadow-light);
    margin-bottom: 1rem;
    position: relative;
    overflow: hidden;
}

    .link-button::before {
        content: '';
        position: absolute;
        top: 0;
        left: -100%;
        width: 100%;
        height: 100%;
        background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
        transition: left 0.5s ease;
    }

    .link-button:hover::before {
        left: 100%;
    }

    .link-button i {
        font-size: 1.1rem;
        transition: transform var(--transition-normal), color var(--transition-normal);
        color: inherit;
        flex-shrink: 0;
    }

    .link-button:hover {
        background-color: var(--primary-color);
        color: #fff;
        transform: translateY(-2px);
        box-shadow: var(--shadow-hover);
        border-color: var(--primary-color);
    }

        .link-button:hover i {
            color: #fff !important;
            transform: translateX(4px);
        }

    .link-button:active {
        transform: translateY(0);
        box-shadow: var(--shadow-light);
    }

/* =============================================================================
   ICON LINKS & SOCIAL MEDIA
   ============================================================================= */
.icon-link {
    width: 48px;
    height: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 2px solid var(--primary-color);
    border-radius: 50%;
    font-size: var(--font-size-large);
    color: var(--secondary-color);
    text-decoration: none;
    transition: all var(--transition-normal);
    position: relative;
    overflow: hidden;
}

    .icon-link::before {
        content: '';
        position: absolute;
        top: 50%;
        left: 50%;
        width: 0;
        height: 0;
        background-color: var(--primary-color);
        border-radius: 50%;
        transition: all var(--transition-normal);
        transform: translate(-50%, -50%);
        z-index: -1;
    }

    .icon-link:hover::before {
        width: 100%;
        height: 100%;
    }

    .icon-link:hover {
        transform: scale(1.1);
        color: #fff;
        border-color: var(--primary-color);
    }

.social-links {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 1rem;
    flex-wrap: wrap;
    margin-top: 1.5rem;
}

    .social-links a {
        display: flex;
        align-items: center;
        justify-content: center;
        width: 44px;
        height: 44px;
        border-radius: 50%;
        border: 1px solid color-mix(in srgb, var(--primary-color), transparent 50%);
        font-size: 18px;
        color: color-mix(in srgb, var(--primary-color), transparent 20%);
        transition: var(--transition-normal);
        position: relative;
        overflow: hidden;
    }

        .social-links a::before {
            content: '';
            position: absolute;
            top: 50%;
            left: 50%;
            width: 0;
            height: 0;
            background-color: var(--accent-color);
            border-radius: 50%;
            transition: all var(--transition-normal);
            transform: translate(-50%, -50%);
            z-index: -1;
        }

        .social-links a:hover::before {
            width: 100%;
            height: 100%;
        }

        .social-links a:hover {
            color: #fff;
            border-color: var(--accent-color);
            transform: translateY(-2px);
        }

/* =============================================================================
   MODAL COMPONENTS
   ============================================================================= */
.modal-content {
    background-color: #fefefe;
    border: 2px solid var(--primary-color);
    border-radius: var(--border-radius-small);
    box-shadow: 0 0 30px rgba(0, 0, 0, 0.3);
    overflow: hidden;
}

.modal-header {
    background-color: var(--primary-color);
    color: white;
    border-bottom: none;
    padding: 1.5rem;
}

.modal-body {
    padding: 2rem;
}

.modal-footer {
    background-color: #f8f9fa;
    border-top: 1px solid #e9ecef;
    padding: 1rem 1.5rem;
}

    .modal-footer .btn-secondary {
        background-color: #b01c14;
        border: none;
        padding: 0.75rem 1.5rem;
        border-radius: 8px;
        font-weight: var(--font-weight-bold);
        transition: var(--transition-normal);
    }

        .modal-footer .btn-secondary:hover {
            background-color: #b01c14;
            transform: translateY(-1px);
        }

/* =============================================================================
   DROPDOWN COMPONENTS
   ============================================================================= */
.dropdown-menu {
    border-radius: var(--border-radius-small);
    border: 1px solid var(--border-color);
    padding: 0.5rem 0;
    font-weight: 500;
    box-shadow: var(--shadow);
    backdrop-filter: blur(10px);
    background: rgba(255, 255, 255, 0.95);
}

.dropdown-item {
    padding: 0.75rem 1.25rem;
    transition: background-color var(--transition-fast);
    color: var(--primary-color);
}

    .dropdown-item:hover {
        background-color: var(--hover-bg);
        color: #fff;
    }

    .dropdown-item:active {
        background-color: var(--primary-color);
        color: #fff;
    }

/* Highlight the selected dropdown item */
/*input[type="radio"]:checked + label.dropdown-item {
    background-color: #29186d !important;
    color: white !important;
}*/

/* Optional: Change hover color */
label.dropdown-item:hover {
    background-color: #29186d;
    color: white;
}

/* =============================================================================
   UTILITY CLASSES
   ============================================================================= */
a {
    color: var(--accent-color);
    text-decoration: none;
    transition: color var(--transition-fast);
}

    a:hover {
        color: color-mix(in srgb, var(--accent-color), transparent 25%);
    }

.text-center {
    text-align: center;
}

.d-flex {
    display: flex;
}

.align-items-center {
    align-items: center;
}

.justify-content-center {
    justify-content: center;
}

.gap-3 {
    gap: 1rem;
}

.mb-3 {
    margin-bottom: 1rem;
}

.mt-3 {
    margin-top: 1rem;
}

/* =============================================================================
   RESPONSIVE BREAKPOINTS
   ============================================================================= */

/* Extra Large Screens (1400px and up) */
@media (min-width: 1400px) {
    .link-card {
        max-width: 600px;
        padding: 3rem;
    }

    .logo {
        max-width: 280px;
    }

    .link-button {
        font-size: 1.1rem;
        padding: 1.25rem 2rem;
    }
}

/* Large Screens (1200px to 1399px) */
@media (min-width: 1200px) and (max-width: 1399px) {
    .link-card {
        max-width: 550px;
        padding: 2.5rem;
    }

    .logo {
        max-width: 250px;
    }
}

/* Medium Screens (992px to 1199px) */
@media (min-width: 992px) and (max-width: 1199px) {
    .link-card {
        max-width: 500px;
        padding: 2rem;
    }

    .page-background {
        padding: 2rem;
    }
}

/* Small Screens (768px to 991px) */
@media (min-width: 768px) and (max-width: 991px) {
    .link-card {
        max-width: 480px;
        padding: 2rem;
        margin: 1rem;
    }

    .logo {
        max-width: 200px;
        margin-bottom: 1.5rem;
    }

    .link-button {
        font-size: 0.95rem;
        padding: 0.875rem 1.25rem;
        gap: 10px;
    }

    .icon-link {
        width: 44px;
        height: 44px;
        font-size: 1.2rem;
    }

    .social-links a {
        width: 40px;
        height: 40px;
        font-size: 16px;
    }
}

/* Extra Small Screens (up to 767px) */
@media (max-width: 767px) {
    .page-background {
        padding: 1rem 0.5rem;
        min-height: 100vh;
    }

    .link-card {
        margin: 0.5rem;
        padding: 1.5rem;
        max-width: none;
        width: calc(100% - 1rem);
        border-radius: var(--border-radius-small);
    }

    .logo {
        max-width: 180px;
        margin-bottom: 1.5rem;
    }

    .link-button {
        font-size: 0.9rem;
        padding: 0.75rem 1rem;
        gap: 8px;
        margin-bottom: 0.75rem;
    }

        .link-button i {
            font-size: 1rem;
        }

    .icon-link {
        width: 40px;
        height: 40px;
        font-size: 1.1rem;
    }

    .social-links {
        gap: 0.75rem;
        margin-top: 1rem;
    }

        .social-links a {
            width: 36px;
            height: 36px;
            font-size: 14px;
        }

    .language-toggle {
        font-size: 1.1rem;
        padding: 0.25rem;
    }

    h4 {
        font-size: 1.1rem;
    }

    .modal-content {
        margin: 0.5rem;
        width: calc(100% - 1rem);
    }

    .modal-header,
    .modal-body,
    .modal-footer {
        padding: 1rem;
    }
}

/* Very Small Screens (up to 480px) */
@media (max-width: 480px) {
    .page-background {
        padding: 0.5rem 0.25rem;
    }

    .link-card {
        margin: 0.25rem;
        padding: 1rem;
        width: calc(100% - 0.5rem);
        border-radius: 12px;
    }

    .logo {
        max-width: 150px;
        margin-bottom: 1rem;
    }

    .link-button {
        font-size: 0.85rem;
        padding: 0.625rem 0.75rem;
        gap: 6px;
        flex-direction: row;
        text-align: center;
    }

        .link-button i {
            font-size: 0.9rem;
        }

    .icon-link {
        width: 36px;
        height: 36px;
        font-size: 1rem;
    }

    .social-links {
        gap: 0.5rem;
        margin-top: 0.75rem;
    }

        .social-links a {
            width: 32px;
            height: 32px;
            font-size: 12px;
        }

    .language-toggle {
        font-size: 1rem;
    }

    h4 {
        font-size: 1rem;
        margin-bottom: 0.75rem;
    }

    .text-muted {
        font-size: 0.85rem;
    }
}

/* Landscape orientation adjustments for mobile */
@media (max-height: 500px) and (orientation: landscape) {
    .page-background {
        padding: 0.5rem;
        align-items: flex-start;
    }

    .link-card {
        margin: 0.5rem auto;
        padding: 1rem;
    }

    .logo {
        max-width: 120px;
        margin-bottom: 0.75rem;
    }

    .link-button {
        padding: 0.5rem 0.75rem;
        margin-bottom: 0.5rem;
    }

    .social-links {
        margin-top: 0.5rem;
    }
}

/* High DPI screens */
@media (-webkit-min-device-pixel-ratio: 2), (min-resolution: 192dpi) {
    .link-card {
        border: 0.5px solid rgba(255, 255, 255, 0.3);
    }

    .link-button,
    .icon-link {
        border-width: 1.5px;
    }
}

/* Dark mode support */
@media (prefers-color-scheme: dark) {
    .modal-content {
        background-color: #2a2a2a;
        color: #fff;
    }

    .modal-footer {
        background-color: #1a1a1a;
    }

    .dropdown-menu {
        background: rgba(42, 42, 42, 0.95);
        color: #fff;
    }

    .dropdown-item {
        color: #fff;
    }

        .dropdown-item:hover {
            background-color: rgba(255, 255, 255, 0.1);
        }
}

/* Reduced motion support */
@media (prefers-reduced-motion: reduce) {
    * {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }

    .link-button::before,
    .icon-link::before,
    .social-links a::before {
        display: none;
    }
}

/* Match primary buttons to #29186d */
.btn-primary {
    background-color: #29186d !important;
    border-color: #29186d !important;
}

    .btn-primary:hover,
    .btn-primary:focus,
    .btn-primary:active {
        background-color: #4630a3 !important; /* Slightly lighter for hover */
        border-color: #4630a3 !important;
    }


/* Print styles */
@media print {
    .page-background {
        background-color: white;
        padding: 0;
    }

    .link-card {
        box-shadow: none;
        border: 1px solid #ccc;
        background: white;
    }

    .link-button,
    .icon-link,
    .social-links a {
        border-color: #000;
        color: #000;
    }

    .language-toggle {
        display: none;
    }
}

.service-item {
    background: linear-gradient(135deg, #391f5b, #75569b);
    border-radius: 12px;
    color: white;
    padding: 15px 20px;
    margin-bottom: 12px;
    box-shadow: 0 3px 12px rgba(102, 126, 234, 0.2);
    transition: all 0.3s ease;
    cursor: pointer;
    position: relative;
    overflow: hidden;
}

    .service-item:hover {
        transform: translateY(-2px);
        box-shadow: 0 5px 20px rgba(102, 126, 234, 0.3);
    }

    .service-item:last-child {
        margin-bottom: 0;
    }

    .service-item::before {
        content: '';
        position: absolute;
        top: 0;
        left: 0;
        right: 0;
        bottom: 0;
        background: linear-gradient(135deg, rgba(255,255,255,0.1) 0%, rgba(255,255,255,0.05) 100%);
        border-radius: 12px;
    }

/* Service Content Styles */
.service-content {
    position: relative;
    z-index: 2;
}

.service-icon {
    font-size: 1.5rem;
    margin-right: 15px;
    opacity: 0.9;
}

.service-title {
    font-size: 1.1rem;
    font-weight: 600;
    margin: 0;
    opacity: 0.95;
    margin-right: 15px;
}

/* Modal Styles */
.modal-body {
    padding: 20px;
}

/* Responsive Adjustments */
@media (max-width: 576px) {
    .service-item {
        padding: 12px 15px;
        margin-bottom: 10px;
    }

    .service-icon {
        font-size: 1.3rem;
        margin-right: 12px;
        margin-left: 12px;
    }

    .service-title {
        font-size: 1rem;
    }

    .modal-body {
        padding: 15px;
    }
}

/* Additional utility classes */
.service-list {
    /* Container for service items if needed */
}

/* Button hover effects for modal triggers */
.btn-primary:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(0, 123, 255, 0.3);
}

/* Custom scrollbar for modal body */
.modal-body::-webkit-scrollbar {
    width: 6px;
}

.modal-body::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 10px;
}

.modal-body::-webkit-scrollbar-thumb {
    background: #667eea;
    border-radius: 10px;
}

    .modal-body::-webkit-scrollbar-thumb:hover {
        background: #5a67d8;
    }
