/* Modern CSS with CSS variables for easy customization */
:root {
    --primary-color: #0d6efd;
    --primary-dark: #0b5ed7;
    --text-dark: #333;
    --text-light: #6c757d;
    --bg-light: #f8f9fa;
    --border-color: #dee2e6;
    --success-color: #28a745;
    --shadow-sm: 0 2px 4px rgba(0,0,0,0.1);
    --shadow-md: 0 4px 6px rgba(0,0,0,0.1);
    --transition: all 0.3s ease;
}

/* Base responsive container */
.nursing-container {
    width: 100%;
    max-width: 100%;
    font-family: 'Roboto', sans-serif;
}

/* Flex container with mobile-first approach */
.nursing-flex-container {
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

/* Sidebar styles - mobile first */
.nursing-sidebar {
    width: 100%;
    background-color: var(--bg-light);
    border-bottom: 1px solid var(--border-color);
    padding: 15px;
}

/* Logo container */
.nursing-logo-container {
    text-align: center;
    margin-bottom: 20px;
}

.nursing-logo {
    max-width: 100px;
    height: auto;
    margin-bottom: 12px;
    display: block;
    margin-left: auto;
    margin-right: auto;
}

.nursing-title {
    color: var(--primary-color);
    font-weight: bold;
    margin-bottom: 0;
    font-size: 16px;
    line-height: 1.4;
}

/* Menu container - horizontal scroll on mobile */
.nursing-menu-container {
    display: flex;
    overflow-x: auto;
    overflow-y: hidden;
    white-space: nowrap;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: thin;
    padding: 5px 0 15px 0;
    gap: 5px;
}

/* Menu items - touch friendly */
.nursing-menu-item {
    display: inline-flex;
    align-items: center;
    padding: 12px 15px;
    margin: 0;
    color: var(--text-dark);
    text-decoration: none;
    border-left: 3px solid transparent;
    background-color: white;
    border-radius: 8px;
    box-shadow: var(--shadow-sm);
    font-size: 14px;
    transition: var(--transition);
    cursor: pointer;
    flex-shrink: 0;
}

.nursing-menu-item i {
    margin-right: 8px;
    width: 18px;
    color: var(--text-light);
    font-size: 14px;
}

.nursing-menu-item.active {
    color: var(--primary-color);
    font-weight: 600;
    border-left-color: var(--primary-color);
    background-color: rgba(13, 110, 253, 0.05);
}

.nursing-menu-item.active i {
    color: var(--primary-color);
}

.nursing-menu-item:hover {
    background-color: #e9ecef;
}

/* Content area */
.nursing-content {
    width: 100%;
    padding: 20px;
    background-color: #fff;
}

/* Tab content */
.nursing-tab-content {
    display: none;
    animation: fadeIn 0.3s ease;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

.nursing-tab-content.active {
    display: block;
}

/* Headings */
.nursing-heading {
    color: var(--primary-color);
    margin-bottom: 20px;
    font-size: 24px;
    font-weight: 600;
    line-height: 1.3;
    border-bottom: 3px solid var(--primary-color);
    padding-bottom: 10px;
    display: inline-block;
}

/* Cards */
.nursing-card {
    background-color: var(--bg-light);
    padding: 20px;
    border-radius: 12px;
    box-shadow: var(--shadow-sm);
}

/* Text styles */
.nursing-text {
    font-size: 16px;
    line-height: 1.6;
    margin-bottom: 15px;
    color: var(--text-dark);
}

.nursing-text-large {
    font-size: 18px;
}

.nursing-text-bold {
    font-weight: bold;
}

/* Lists */
.nursing-list {
    list-style: none;
    padding-left: 0;
    margin: 0;
}

.nursing-list li {
    margin-bottom: 12px;
    display: flex;
    align-items: flex-start;
    font-size: 15px;
    line-height: 1.5;
}

.nursing-list i {
    margin-right: 12px;
    margin-top: 3px;
    flex-shrink: 0;
}

.nursing-check-icon {
    color: var(--success-color);
}

.nursing-primary-icon {
    color: var(--primary-color);
}

/* Grid system */
.nursing-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 20px;
}

.nursing-grid-2 {
    display: grid;
    grid-template-columns: 1fr;
    gap: 20px;
}

/* Tables */
.nursing-table-responsive {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    margin: 15px 0;
    border-radius: 8px;
}

.nursing-table {
    width: 100%;
    border-collapse: collapse;
    min-width: 600px;
    border: 1px solid var(--border-color);
}

.nursing-table th {
    background-color: var(--primary-color);
    color: white;
    padding: 12px 10px;
    text-align: left;
    font-size: 14px;
    white-space: nowrap;
}

.nursing-table td {
    padding: 10px;
    border: 1px solid var(--border-color);
    font-size: 14px;
}

.nursing-table tr:nth-child(even) {
    background-color: #f2f2f2;
}

/* Function boxes */
.nursing-function-box {
    background-color: white;
    padding: 15px;
    border-radius: 10px;
    box-shadow: var(--shadow-sm);
    height: 100%;
}

.nursing-function-box h5 {
    color: var(--primary-color);
    margin-bottom: 12px;
    font-size: 16px;
    display: flex;
    align-items: center;
}

.nursing-function-box h5 i {
    margin-right: 8px;
    font-size: 18px;
}

.nursing-function-box ul {
    padding-left: 20px;
    margin: 0;
}

.nursing-function-box li {
    margin-bottom: 8px;
    font-size: 14px;
}

/* Contact section */
.nursing-contact-info {
    background-color: white;
    padding: 20px;
    border-radius: 10px;
}

.nursing-contact-info p {
    margin-bottom: 15px;
    font-size: 15px;
    line-height: 1.6;
}

.nursing-contact-info i {
    color: var(--primary-color);
    width: 25px;
}

.nursing-contact-links a {
    color: var(--primary-color);
    text-decoration: none;
    word-break: break-all;
}

.nursing-contact-links a:hover {
    text-decoration: underline;
}

/* Downloads section */
.nursing-download-item {
    display: flex;
    align-items: center;
    padding: 12px;
    background-color: white;
    border-radius: 8px;
    margin-bottom: 10px;
    transition: var(--transition);
}

.nursing-download-item:hover {
    transform: translateX(5px);
    box-shadow: var(--shadow-sm);
}

.nursing-download-item i {
    margin-right: 12px;
    font-size: 20px;
}

.nursing-download-item a {
    color: var(--primary-color);
    text-decoration: none;
    flex: 1;
}

.nursing-download-item span {
    color: var(--text-light);
    font-size: 13px;
}

/* Button styles */
.nursing-btn {
    display: inline-flex;
    align-items: center;
    padding: 10px 20px;
    border-radius: 8px;
    text-decoration: none;
    font-weight: 500;
    transition: var(--transition);
    cursor: pointer;
    border: none;
    font-size: 14px;
}

.nursing-btn-primary {
    background-color: var(--primary-color);
    color: white;
}

.nursing-btn-primary:hover {
    background-color: var(--primary-dark);
    transform: translateY(-2px);
}

.nursing-btn-success {
    background-color: var(--success-color);
    color: white;
}

.nursing-btn-success:hover {
    background-color: #218838;
    transform: translateY(-2px);
}

.nursing-btn i {
    margin-right: 8px;
}

/* Program Outcomes Styles */
.outcomes-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 15px;
    margin-top: 20px;
}

.outcome-card {
    background: #f8f9fa;
    border-left: 4px solid var(--primary-color);
    padding: 15px;
    border-radius: 8px;
    transition: all 0.3s ease;
}

.outcome-card:hover {
    transform: translateX(5px);
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}

.outcome-title {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 8px;
}

.outcome-title i {
    color: var(--primary-color);
    font-size: 18px;
    width: 20px;
}

.outcome-title strong {
    color: var(--primary-color);
    font-size: 15px;
}

.outcome-card p {
    margin: 0 0 0 30px;
    color: var(--text-dark);
    font-size: 14px;
    line-height: 1.5;
}

/* Additional styles for the modal */
#pdfModal {
    font-family: Arial, sans-serif;
}

#pdfModal iframe {
    background: white;
}

/* Gallery Categories */
.gallery-categories {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-bottom: 30px;
    justify-content: center;
}

.gallery-cat-btn {
    padding: 8px 20px;
    background: #f0f0f0;
    border: none;
    border-radius: 25px;
    cursor: pointer;
    font-size: 14px;
    transition: all 0.3s ease;
}

.gallery-cat-btn.active {
    background: var(--primary-color);
    color: white;
}

.gallery-cat-btn:hover {
    background: var(--primary-color);
    color: white;
    transform: translateY(-2px);
}

/* Gallery Grid */
.gallery-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 20px;
}

.gallery-item {
    position: relative;
    overflow: hidden;
    border-radius: 10px;
    cursor: pointer;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
    transition: all 0.3s ease;
}

.gallery-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 5px 20px rgba(0,0,0,0.2);
}

.gallery-img {
    width: 100%;
    height: 220px;
    object-fit: cover;
    transition: all 0.3s ease;
}

.gallery-item:hover .gallery-img {
    transform: scale(1.1);
}

.gallery-overlay {
    position: absolute;
    bottom: -100%;
    left: 0;
    right: 0;
    background: linear-gradient(transparent, rgba(0,0,0,0.9));
    color: white;
    padding: 20px;
    transition: bottom 0.3s ease;
    text-align: center;
}

.gallery-item:hover .gallery-overlay {
    bottom: 0;
}

.gallery-overlay h5 {
    margin: 0 0 5px;
    font-size: 16px;
}

.gallery-overlay p {
    margin: 0 0 10px;
    font-size: 12px;
    opacity: 0.9;
}

.gallery-view-btn {
    background: var(--primary-color);
    color: white;
    border: none;
    padding: 5px 15px;
    border-radius: 20px;
    cursor: pointer;
    font-size: 12px;
    transition: all 0.3s ease;
}

.gallery-view-btn:hover {
    background: white;
    color: var(--primary-color);
}

/* Lightbox */
.lightbox {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.95);
    z-index: 10000;
    cursor: pointer;
}

.lightbox-content {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    max-width: 90%;
    max-height: 90%;
    object-fit: contain;
}

.close-lightbox {
    position: absolute;
    top: 20px;
    right: 40px;
    color: white;
    font-size: 40px;
    font-weight: bold;
    cursor: pointer;
    z-index: 10001;
}

.close-lightbox:hover {
    color: var(--primary-color);
}

.lightbox-prev,
.lightbox-next {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    color: white;
    font-size: 40px;
    font-weight: bold;
    padding: 10px;
    cursor: pointer;
    user-select: none;
    z-index: 10001;
    background: rgba(0,0,0,0.5);
    border-radius: 50%;
    width: 50px;
    height: 50px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.lightbox-prev {
    left: 20px;
}

.lightbox-next {
    right: 20px;
}

.lightbox-prev:hover,
.lightbox-next:hover {
    background: var(--primary-color);
}

.lightbox-caption {
    position: absolute;
    bottom: 20px;
    left: 0;
    right: 0;
    text-align: center;
    color: white;
    font-size: 16px;
    padding: 10px;
    background: rgba(0,0,0,0.7);
}

/* Tablet styles (min-width: 768px) */
@media (min-width: 768px) {
    .nursing-flex-container {
        flex-direction: row;
    }

    .nursing-sidebar {
        width: 280px;
        border-right: 1px solid var(--border-color);
        border-bottom: none;
        padding: 20px;
        min-height: 100vh;
        overflow-y: auto;
    }

    .nursing-logo {
        max-width: 120px;
    }

    .nursing-title {
        font-size: 18px;
    }

    .nursing-menu-container {
        flex-direction: column;
        overflow-x: visible;
        white-space: normal;
        gap: 0;
        padding: 0;
    }

    .nursing-menu-item {
        display: block;
        padding: 12px 15px;
        margin-bottom: 5px;
        background-color: transparent;
        border-radius: 0;
        box-shadow: none;
        border-left: 3px solid transparent;
        font-size: 14px;
    }

    .nursing-menu-item.active {
        background-color: transparent;
    }

    .nursing-content {
        width: calc(100% - 280px);
        padding: 30px;
    }

    .nursing-heading {
        font-size: 28px;
    }

    .nursing-grid-2 {
        grid-template-columns: repeat(2, 1fr);
    }

    .nursing-text {
        font-size: 16px;
    }
    
    .gallery-grid {
        grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
        gap: 15px;
    }
    
    .lightbox-prev,
    .lightbox-next {
        font-size: 30px;
        width: 40px;
        height: 40px;
    }
}

/* ==================== GOLD MEDALIST POPUP STYLES ==================== */

/* Popup Overlay */
.gold-medalist-popup-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.85);
    z-index: 999999;
    display: flex;
    align-items: center;
    justify-content: center;
    animation: fadeIn 0.3s ease;
    overflow-y: auto;
    padding: 20px;
}

/* Popup Container - Wider for 2 images */
.gold-medalist-popup {
    background: linear-gradient(135deg, #fff9e6, #ffffff);
    border-radius: 20px;
    max-width: 900px;
    width: 100%;
    max-height: 90vh;
    overflow-y: auto;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    animation: popupSlideIn 0.4s cubic-bezier(0.68, -0.55, 0.265, 1.55);
    border: 3px solid #ffd700;
}

/* Custom scrollbar for popup */
.gold-medalist-popup::-webkit-scrollbar {
    width: 6px;
}

.gold-medalist-popup::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 10px;
}

.gold-medalist-popup::-webkit-scrollbar-thumb {
    background: #ffd700;
    border-radius: 10px;
}

/* Popup Header */
.gold-medalist-popup-header {
    background: linear-gradient(135deg, #ffd700, #ffed4e);
    padding: 15px 20px;
    text-align: center;
    position: relative;
}

.gold-medalist-popup-header h3 {
    margin: 0;
    color: #b8860b;
    font-size: 24px;
    font-weight: bold;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
}

.gold-medalist-popup-header h3 i {
    font-size: 28px;
}

.close-popup {
    position: absolute;
    top: 12px;
    right: 18px;
    font-size: 28px;
    font-weight: bold;
    color: #b8860b;
    cursor: pointer;
    transition: all 0.2s;
}

.close-popup:hover {
    color: #8b6914;
    transform: scale(1.1);
}

/* Popup Body - Grid layout for 2 images */
.gold-medalist-popup-body {
    padding: 30px;
    text-align: center;
}

/* Two Column Grid for Images */
.popup-images-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 25px;
    margin-bottom: 20px;
}

/* Individual Image Card */
.popup-image-card {
    background: #f8f9fa;
    border-radius: 15px;
    overflow: hidden;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease;
}

.popup-image-card:hover {
    transform: translateY(-5px);
}

/* Image Styling - Square with no radius */
.popup-image {
    width: 100%;
    height: 280px;
    object-fit: cover;
    border-bottom: 3px solid #ffd700;
}

/* Image Title */
.popup-image-title {
    padding: 15px;
    background: white;
}

.popup-image-title h4 {
    margin: 0;
    color: #b8860b;
    font-size: 18px;
    font-weight: bold;
}

.popup-image-title p {
    margin: 5px 0 0;
    color: #666;
    font-size: 14px;
}

/* Badge */
.medalist-badge {
    display: inline-block;
    background: linear-gradient(135deg, #ffd700, #ffed4e);
    padding: 10px 25px;
    border-radius: 50px;
    color: #b8860b;
    font-weight: bold;
    font-size: 18px;
    margin: 15px 0 5px;
}

/* Popup Footer */
.gold-medalist-popup-footer {
    padding: 10px 25px 25px 25px;
    text-align: center;
}

.gold-medalist-popup-footer button {
    background: linear-gradient(135deg, #ffd700, #ffed4e);
    border: none;
    padding: 10px 35px;
    border-radius: 50px;
    font-size: 16px;
    font-weight: bold;
    color: #b8860b;
    cursor: pointer;
    transition: all 0.3s;
}

.gold-medalist-popup-footer button:hover {
    transform: scale(1.05);
    box-shadow: 0 5px 15px rgba(255, 215, 0, 0.4);
}

/* Animations */
@keyframes popupSlideIn {
    from {
        opacity: 0;
        transform: scale(0.3) translateY(-100px);
    }
    to {
        opacity: 1;
        transform: scale(1) translateY(0);
    }
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

@keyframes goldFlash {
    0%, 100% {
        box-shadow: 0 0 0 0 rgba(255, 215, 0, 0.7);
    }
    50% {
        box-shadow: 0 0 0 20px rgba(255, 215, 0, 0);
    }
}

/* Responsive for tablets */
@media (max-width: 768px) {
    .gold-medalist-popup {
        max-width: 650px;
    }
    
    .popup-images-grid {
        gap: 15px;
    }
    
    .popup-image {
        height: 220px;
    }
    
    .popup-image-title h4 {
        font-size: 16px;
    }
    
    .popup-image-title p {
        font-size: 12px;
    }
    
    .medalist-badge {
        font-size: 16px;
        padding: 8px 20px;
    }
}

/* Responsive for mobile - stack vertically */
@media (max-width: 550px) {
    .gold-medalist-popup {
        max-width: 450px;
    }
    
    .popup-images-grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }
    
    .popup-image {
        height: 250px;
    }
    
    .gold-medalist-popup-header h3 {
        font-size: 18px;
    }
    
    .gold-medalist-popup-body {
        padding: 20px;
    }
}

/* For very small devices */
@media (max-width: 450px) {
    .gold-medalist-popup {
        max-width: 380px;
    }
    
    .popup-image {
        height: 200px;
    }
}

/* Large desktop styles */
@media (min-width: 1440px) {
    .nursing-container {
        max-width: 1400px;
        margin: 0 auto;
    }
}

/* Print styles */
@media print {
    .nursing-sidebar {
        display: none;
    }

    .nursing-content {
        width: 100%;
    }
}

/* Touch-friendly improvements */
@media (hover: none) and (pointer: coarse) {
    .nursing-menu-item {
        padding: 14px 18px;
        font-size: 16px;
    }

    .nursing-menu-item i {
        font-size: 16px;
    }

    .nursing-download-item {
        padding: 15px;
    }

    button, 
    .nursing-menu-item,
    .nursing-download-item {
        cursor: default;
    }
}