@import url('https://fonts.googleapis.com/css2?family=Cairo:wght@400;700&display=swap');

html {
  font-size: 14px;
}

@media (min-width: 768px) {
  html {
    font-size: 16px;
  }
}

html {
  position: relative;
  min-height: 100%;
}

body {
  margin-bottom: 60px;
}

spinner {
    border: 16px solid silver;
    border-top: 16px solid red;
    border-radius: 50%;
    width: 80px;
    height: 80px;
    animation: spin 700ms linear infinite;
    top: 40%;
    left: 55%;
    position: absolute;
}

/* Apply base styles */
body {
    font-family: 'Cairo', sans-serif;
}

/* Main container for centering and max-width */
.department-container {
    max-width: 900px;
    margin: 40px auto; /* Adds space top/bottom and centers horizontally */
    padding: 20px;
    text-align: center;
    color: #333;
}

/* Header section styles */
.department-header h1 {
    font-size: 2.5rem; /* Large heading */
    margin-bottom: 20px;
    font-weight: 700;
}

.department-header p {
    font-size: 1rem;
    line-height: 1.8;
    max-width: 800px; /* Constrain line width for readability */
    margin: 0 auto 40px auto; /* Center the paragraph block */
}

/* Info section paragraph */
.department-info p {
    margin-bottom: 50px; /* Space between text and the cards */
}

/* Flexbox container for the two sections */
.department-sections {
    display: flex;
    justify-content: center; /* Center the cards within the container */
    gap: 40px; /* Space between the two cards */
    flex-wrap: wrap; /* Allows cards to stack on smaller screens */
}

/* Styling for each individual card */
.section-card {
    width: 250px;
    padding: 20px;
}

    .section-card h3 {
        font-size: 1.4rem;
        margin-top: 15px; /* Space between icon and text */
        font-weight: 700;
    }

/* Icon styling */
.section-icon {
    font-size: 3rem; /* Makes the icon large */
    color: #555;
}

selection-container {
    text-align: center;
    padding: 20px;
}

.selection-title {
    font-size: 2rem;
    color: #4A4A4A;
    margin-bottom: 40px;
    font-weight: 600;
}

/* This is the Flexbox container */
.selection-grid {
    display: flex;
    justify-content: center;
    gap: 20px; /* This creates the space between cards */
    flex-wrap: wrap; /* Allows cards to stack on smaller screens */
}

/* Styling for each individual card */
.selection-card {
    display: flex;
    flex-direction: column; /* Stacks icon and text vertically */
    align-items: center;
    justify-content: center;
    width: 150px;
    height: 200px;
    padding: 20px;
    background-color: #fff;
    border: 2px dotted #FFDDE6; /* Light pink dotted border */
    border-radius: 16px; /* Rounded corners */
    cursor: pointer;
    transition: transform 0.2s ease-in-out, box-shadow 0.2s ease-in-out;
}

    /* A subtle hover effect */
    .selection-card:hover {
        transform: translateY(-5px);
        box-shadow: 0 4px 15px rgba(0, 0, 0, 0.05);
    }

    /* Style the icon image */
    .selection-card img {
        width: 60px; /* Adjust size as needed */
        height: 60px;
        margin-bottom: 15px;
    }

    /* Style the text below the icon */
    .selection-card p {
        margin: 0;
        font-size: 1rem;
        font-weight: 600;
        color: #555;
    }

/* Main carousel container */
.hero-carousel {
    height: 85vh;
    color: white;
}

    /* Ensure each slide and the inner container fill the height */
    .hero-carousel .carousel-inner,
    .hero-carousel .carousel-item {
        height: 100%;
    }

        .hero-carousel .carousel-item img {
            /* Make the image cover the slide without distortion */
            width: 100%;
            height: 100%;
            object-fit: cover;
        }

/* --- Content & Shape Styling (The Important Part) --- */
/* This is our custom content overlay, replacing .carousel-caption default behavior */
.hero-content {
    position: absolute;
    top: 50%;
    right: 10%;
    transform: translateY(-50%);
    z-index: 2; /* Ensures text is above the shape */
    max-width: 500px;
    text-align: right;
    text-shadow: 0 2px 5px rgba(0,0,0,0.5);
}

    .hero-content h1 {
        font-size: 3rem;
        margin-bottom: 15px;
    }

    .hero-content p {
        font-size: 1.1rem;
        line-height: 1.7;
        margin-bottom: 30px;
    }

.cta-button {
    background-color: #5b9dff;
    color: white;
    padding: 12px 25px;
    border-radius: 8px;
    text-decoration: none;
    font-weight: 700;
    transition: background-color 0.3s ease;
    direction: ltr;
    display: inline-block;
}

    .cta-button:hover {
        background-color: #4a80d1;
    }

/* --- Curved Shape Styling --- */
.hero-shape {
    position: absolute;
    bottom: -1px;
    left: 0;
    width: 100%;
    z-index: 1; /* Places the shape below the text but above the image */
    line-height: 0;
}

    .hero-shape svg {
        display: block;
        width: 100%;
        height: auto;
    }

.news-carousel-wrapper {
    position: relative;
}

.news-carousel {
    overflow-x: auto;
    scroll-behavior: smooth;
    scrollbar-width: none; /* Firefox */
}

    .news-carousel::-webkit-scrollbar {
        display: none; /* Chrome, Safari */
    }

/* --- Arrow Buttons --- */
.carousel-btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background-color: rgba(0, 0, 0, 0.4);
    color: white;
    border: none;
    border-radius: 50%;
    width: 40px;
    height: 40px;
    cursor: pointer;
    z-index: 10;
    transition: all 0.3s ease;
    opacity: 0;
}

    .carousel-btn:hover {
        background-color: rgba(0, 0, 0, 0.7);
        transform: translateY(-50%) scale(1.1);
    }

.news-carousel-wrapper:hover .carousel-btn {
    opacity: 1;
}

.left-btn {
    left: 10px;
}

.right-btn {
    right: 10px;
}

/* --- Card Tweaks --- */
.news-carousel .card {
    transition: transform 0.3s ease;
}

    .news-carousel .card:hover {
        transform: translateY(-5px);
    }

@media (max-width: 768px) {
    .news-carousel .card {
        width: 200px;
    }

    .carousel-btn {
        width: 35px;
        height: 35px;
    }
}

@media (max-width: 768px) {
    .carousel-btn {
        opacity: 1 !important;
    }

    /* Optional: make them smaller or move slightly inward for better UX */
    .carousel-btn {
        width: 35px;
        height: 35px;
        background-color: rgba(0, 0, 0, 0.5);
    }

    .left-btn {
        left: 5px;
    }

    .right-btn {
        right: 5px;
    }
}

.announcement-section {
    background-color: white;
}

    .announcement-section h2 {
        font-size: 2rem;
    }

    .announcement-section a.btn {
        background-color: #5ca8ff;
        border: none;
    }

        .announcement-section a.btn:hover {
            background-color: #3d91f2;
        }