/* Remix Icon base style for icon classes */
:where([class^="ri-"])::before { content: "\f3c2"; }

/* Base styles for HTML and body elements */
html, body {
    overflow-x: hidden;
    width: 100%;
    position: relative;
}

/* Custom font classes for different font families */
.font-playfair {
    font-family: 'Playfair Display', serif;
}

.font-inter {
    font-family: 'Inter', sans-serif;
}

/* Background gradient styles for primary and secondary sections */
.bg-gradient-primary {
    background: linear-gradient(135deg, #2A2A2A 0%, #4A4A4A 100%);
}

.bg-gradient-secondary {
    background: linear-gradient(135deg, #4A4A4A 0%, #2A2A2A 100%);
}

/* Custom background opacity classes for semi-transparent white backgrounds */
.bg-white-10 {
    background-color: rgba(255, 255, 255, 0.1);
}

.bg-white-20 {
    background-color: rgba(255, 255, 255, 0.2);
}

/* Custom text color for semi-transparent white text */
.text-white-50 {
    color: rgba(255, 255, 255, 0.5);
}

/* Hover effect for primary color elements */
.hover-primary:hover {
    color: #2A2A2A !important;
}

/* Navigation styles for desktop menu */
.nav-item {
    position: relative;
}

.nav-link {
    color: white;
    transition: color 0.3s ease;
    position: relative;
}

.nav-link:hover {
    color: #FFD700;
}

/* Underline animation for navigation links */
.nav-link::after {
    content: '';
    position: absolute;
    width: 0;
    height: 2px;
    bottom: -4px;
    left: 0;
    background-color: white;
    transition: width 0.3s ease;
}

.nav-link:hover::after {
    width: 100%;
}

/* Dropdown menu styles for navigation */
.nav-submenu {
    position: absolute;
    top: 100%;
    background: rgba(42, 42, 42, 0.98);
    backdrop-filter: blur(12px);
    border-radius: 8px;
    padding: 0.5rem;
    min-width: 200px;
    opacity: 0;
    visibility: hidden;
    transform: translateY(10px);
    transition: all 0.3s ease;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.nav-item:hover .nav-submenu {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.nav-submenu a {
    display: block;
    padding: 0.75rem 1rem;
    color: white;
    text-decoration: none;
    border-radius: 4px;
    transition: all 0.3s ease;
}

.nav-submenu a:hover {
    background: rgba(255, 255, 255, 0.1);
}

/* Mobile menu styles and animations */
#mobileMenu {
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    position: fixed;
    top: 0;
    right: -100%;
    width: 85%;
    max-width: 320px;
    height: 100vh;
    background: linear-gradient(135deg, rgba(42, 42, 42, 0.98) 0%, rgba(30, 30, 30, 0.98) 100%);
    backdrop-filter: blur(12px);
    z-index: 100;
    display: flex;
    flex-direction: column;
    padding: 1.5rem;
    box-shadow: -4px 0 20px rgba(0, 0, 0, 0.3);
    border-left: 1px solid rgba(255, 255, 255, 0.1);
}

#mobileMenu.show {
    right: 0;
}

/* Mobile menu header styles */
#mobileMenu .menu-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-bottom: 1.5rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    margin-bottom: 1.5rem;
    position: relative;
}

#mobileMenu .menu-header::after {
    content: '';
    position: absolute;
    bottom: -1px;
    left: 0;
    width: 50px;
    height: 2px;
    background: linear-gradient(90deg, #fff, transparent);
}

#mobileMenu .menu-header h2 {
    color: white;
    font-size: 1.5rem;
    margin: 0;
    font-weight: 600;
    letter-spacing: 0.5px;
    background: linear-gradient(45deg, #fff, #aaa);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

/* Mobile menu close button styles */
#mobileMenu .close-btn {
    color: white;
    background: rgba(255, 255, 255, 0.1);
    border: none;
    font-size: 1.5rem;
    cursor: pointer;
    padding: 0.5rem;
    border-radius: 50%;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
}

#mobileMenu .close-btn:hover {
    background: rgba(255, 255, 255, 0.2);
    transform: rotate(90deg);
}

/* Mobile menu navigation link styles */
#mobileMenu .nav-link {
    display: block;
    color: white;
    text-decoration: none;
    padding: 1rem 1.25rem;
    margin: 0.5rem 0;
    border-radius: 8px;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
    font-size: 1.1rem;
    font-weight: 500;
    letter-spacing: 0.5px;
}

#mobileMenu .nav-link::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 4px;
    height: 100%;
    background: linear-gradient(to bottom, #fff, transparent);
    opacity: 0;
    transition: all 0.3s ease;
}

#mobileMenu .nav-link:hover {
    background: rgba(255, 255, 255, 0.1);
    transform: translateX(5px);
}

#mobileMenu .nav-link:hover::before {
    opacity: 1;
}

#mobileMenu .nav-link.active {
    background: rgba(255, 255, 255, 0.15);
    transform: translateX(5px);
}

#mobileMenu .nav-link.active::before {
    opacity: 1;
}

/* Mobile menu submenu styles */
#mobileMenu .nav-submenu {
    position: static;
    background: transparent;
    padding: 0;
    margin-left: 1.5rem;
    border: none;
    box-shadow: none;
    display: none;
    opacity: 1;
    visibility: visible;
    transform: none;
}

#mobileMenu .nav-item.active .nav-submenu {
    display: block;
}

#mobileMenu .nav-submenu a {
    padding: 0.75rem 1rem;
    color: rgba(255, 255, 255, 0.8);
    font-size: 0.95rem;
}

#mobileMenu .nav-submenu a:hover {
    color: white;
    background: transparent;
}

/* Card component styles with hover effect */
.card {
    transition: transform 0.3s ease;
}

.card:hover {
    transform: translateY(-10px);
}

/* Particle effect container and animation styles */
#particles {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 0;
    pointer-events: none;
    overflow: hidden;
}

.particle {
    position: absolute;
    background: rgba(255, 255, 255, 0.3);
    border-radius: 50%;
    pointer-events: none;
    animation: float 6s infinite;
    z-index: 1;
    will-change: transform;
}

/* Floating animation keyframes */
@keyframes float {
    0% {
        transform: translateY(0) translateX(0);
    }
    50% {
        transform: translateY(-20px) translateX(10px);
    }
    100% {
        transform: translateY(0) translateX(0);
    }
}

/* Ghost image styles and positioning */
.ghost-image {
    position: absolute;
    width: 120px;
    height: 120px;
    pointer-events: none;
    z-index: 50;
    opacity: 0.8;
    transition: transform 0.3s ease;
    animation: ghostFloat 8s infinite;
}

/* Left and right ghost image positioning */
.ghost-image.left {
    left: -60px;
    animation: ghostFloatLeft 15s infinite;
}

.ghost-image.right {
    right: -60px;
    animation: ghostFloatRight 15s infinite;
}

/* Ghost floating animation keyframes */
@keyframes ghostFloatLeft {
    0% { transform: translateX(-100%) translateY(0); }
    50% { transform: translateX(100px) translateY(-30px); }
    100% { transform: translateX(-100%) translateY(0); }
}

@keyframes ghostFloatRight {
    0% { transform: translateX(100%) translateY(0); }
    50% { transform: translateX(-100px) translateY(-30px); }
    100% { transform: translateX(100%) translateY(0); }
}

/* Responsive design adjustments for mobile devices */
@media (max-width: 768px) {
    /* Mobile navigation submenu adjustments */
    .nav-submenu {
        position: static;
        background: transparent;
        padding: 0;
        margin-left: 1.5rem;
        border: none;
        box-shadow: none;
        display: none;
    }
    
    .nav-item.active .nav-submenu {
        display: block;
    }
    
    /* Mobile menu padding adjustments */
    #mobileMenu {
        padding: 2rem 1.5rem;
    }
    
    #mobileMenu .nav-link {
        padding: 1.25rem 1.5rem;
        margin: 0.75rem 0;
    }
}

/* Small screen adjustments */
@media (max-width: 640px) {
    /* Ghost image size adjustments for small screens */
    .ghost-image {
        display: block;
        width: 80px;
        height: auto;
        opacity: 0.7;
    }
    
    /* Header adjustments for small screens */
    header {
        padding: 0.5rem;
    }
    
    header a {
        font-size: 1.25rem;
    }
}

/* Desktop navigation adjustments */
@media (min-width: 768px) {
    /* Hide mobile menu on desktop */
    #mobileMenu {
        display: none;
    }
    
    /* Desktop navigation link styles */
    .nav-link {
        display: inline-block;
        text-align: center;
        padding: 0;
        border-bottom: none;
    }
}

/* Links Container Styles */
#links-container.links-content {
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    border-radius: 1rem;
    padding: 2rem;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.2);
}

#links-container .link-item {
    display: flex;
    align-items: center;
    padding: 1rem;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 0.5rem;
    transition: all 0.3s ease;
    color: white;
    text-decoration: none;
}

#links-container .link-item:hover {
    background: rgba(255, 255, 255, 0.1);
    transform: translateY(-2px);
}

#links-container .link-item i {
    color: rgba(255, 255, 255, 0.7);
    transition: color 0.3s ease;
}

#links-container .link-item:hover i {
    color: white;
}

@media (max-width: 768px) {
    #links-container.links-content {
        padding: 1.5rem;
    }
    
    #links-container .link-item {
        padding: 0.75rem;
    }
}

/* Banner container styles with decorative elements */
.banner-container {
    position: relative;
    z-index: 40;
    margin-bottom: 2rem;
}

.banner-container::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.5), transparent);
}

.banner-container::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.5), transparent);
}

/* Ghost float animation styles */
.ghost-float-1 {
    position: absolute;
    width: 120px;
    height: 120px;
    opacity: 0.7;
    animation: float 8s ease-in-out infinite;
    top: 20%;
    left: 5%;
    filter: drop-shadow(0 0 10px rgba(255, 255, 255, 0.3));
}

.ghost-float-2 {
    position: absolute;
    width: 100px;
    height: 100px;
    opacity: 0.6;
    animation: float 10s ease-in-out infinite;
    top: 40%;
    right: 10%;
    filter: drop-shadow(0 0 10px rgba(255, 255, 255, 0.3));
}

.ghost-float-3 {
    position: absolute;
    width: 80px;
    height: 80px;
    opacity: 0.5;
    animation: float 12s ease-in-out infinite;
    bottom: 20%;
    left: 15%;
    filter: drop-shadow(0 0 10px rgba(255, 255, 255, 0.3));
}

/* Timeline styles and layout */
.timeline-container {
    position: relative;
    max-width: 1200px;
    margin: 0 auto;
    padding: 2rem 0;
}

.timeline-container::before {
    content: '';
    position: absolute;
    width: 2px;
    background: rgba(255, 255, 255, 0.2);
    top: 0;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
}

.timeline-item {
    position: relative;
    margin-bottom: 4rem;
    width: 100%;
}

.timeline-year {
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
    background: rgba(255, 255, 255, 0.1);
    padding: 0.5rem 1rem;
    border-radius: 1rem;
    font-weight: bold;
    margin-bottom: 1rem;
}

.timeline-content {
    width: calc(50% - 2rem);
    position: relative;
    padding: 1rem;
}

/* Timeline item positioning */
.timeline-item:nth-child(odd) .timeline-content {
    margin-left: auto;
}

.timeline-item:nth-child(even) .timeline-content {
    margin-right: auto;
}

/* Lord card styles with hover effects */
.lord-card {
    background: rgba(128, 128, 128, 0.1);
    border-radius: 1rem;
    overflow: hidden;
    transition: transform 0.3s ease;
    display: flex;
    flex-direction: column;
}

.lord-card:hover {
    transform: translateY(-5px);
}

.lord-image {
    position: relative;
    width: 100%;
    padding-top: 100%;
    overflow: hidden;
}

.lord-image img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.lord-card:hover .lord-image img {
    transform: scale(1.05);
}

.lord-info {
    padding: 1.5rem;
    background: rgba(128, 128, 128, 0.2);
    backdrop-filter: blur(10px);
}

.lord-name {
    font-size: 1.5rem;
    font-weight: bold;
    margin-bottom: 0.5rem;
    color: white;
}

.lord-title {
    font-size: 1.1rem;
    color: rgba(255, 255, 255, 0.8);
    margin-bottom: 1rem;
}

.lord-description {
    color: rgba(255, 255, 255, 0.7);
    font-size: 0.9rem;
    line-height: 1.5;
}

/* Responsive adjustments for timeline and lord cards */
@media (max-width: 768px) {
    .timeline-container::before {
        left: 2rem;
    }

    .timeline-year {
        left: 2rem;
        transform: translateX(-50%);
    }

    .timeline-content {
        width: calc(100% - 4rem);
        margin-left: 4rem !important;
    }

    .timeline-item {
        margin-bottom: 3rem;
    }

    .lord-image {
        padding-top: 80%;
    }
}

/* Gallery styles and grid layout */
.gallery-item {
    position: relative;
    overflow: hidden;
    border-radius: 0.5rem;
    transition: transform 0.3s ease;
}

.gallery-item:hover {
    transform: translateY(-4px);
}

.gallery-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

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

.gallery-item::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(to bottom, transparent 0%, rgba(0, 0, 0, 0.3) 100%);
    opacity: 0;
    transition: opacity 0.3s ease;
}

.gallery-item:hover::after {
    opacity: 1;
}

/* Responsive gallery grid layout */
.gallery-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 1rem;
    padding: 1rem;
}

@media (min-width: 640px) {
    .gallery-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (min-width: 768px) {
    .gallery-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (min-width: 1024px) {
    .gallery-grid {
        grid-template-columns: repeat(4, 1fr);
    }
}

/* Custom select styles */
select {
    background-image: none;
}

/* Gallery container and overlay styles */
.gallery-container {
    position: relative;
    min-height: 400px;
}

.gallery-item {
    position: relative;
    overflow: hidden;
    border-radius: 1rem;
    aspect-ratio: 1;
    transition: transform 0.3s ease;
}

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

.gallery-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.gallery-item:hover .gallery-image {
    transform: scale(1.1);
}

.gallery-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(to top, rgba(0,0,0,0.8), transparent);
    display: flex;
    align-items: flex-end;
    padding: 1.5rem;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.gallery-item:hover .gallery-overlay {
    opacity: 1;
}

.gallery-content {
    transform: translateY(20px);
    transition: transform 0.3s ease;
}

.gallery-item:hover .gallery-content {
    transform: translateY(0);
}

 /*Custom styles for pointer and task popup */
/* Pointer animation styles */
.pointer-container {
    transform-origin: bottom center;
    transition: transform 0.1s ease-out;
}
.pointer-lean-left {
    transform: rotate(-30deg);
}
.pointer-lean-right {
    transform: rotate(30deg);
}

/* Task popup styles */
.task-popup {
    display: none;
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: rgba(42, 42, 42, 0.95);
    padding: 2rem;
    border-radius: 1rem;
    z-index: 100;
    max-width: 90%;
    width: 400px;
    text-align: center;
    box-shadow: 0 0 20px rgba(0, 0, 0, 0.5);
}
.task-popup h3 {
    color: white;
    font-size: 1.5rem;
    margin-bottom: 1rem;
}
.task-popup p {
    color: #ccc;
    font-size: 1.2rem;
    margin-bottom: 1.5rem;
}
.task-popup button {
    background: white;
    color: #2A2A2A;
    border: none;
    padding: 0.5rem 1rem;
    border-radius: 0.5rem;
    cursor: pointer;
    font-weight: bold;
}

/* Gallery styles */
#weekly-gallery {
    position: relative;
    min-height: 400px;
}

#weekly-gallery .gallery-item {
    position: relative;
    overflow: hidden;
    border-radius: 1rem;
    aspect-ratio: 1;
    transition: all 0.3s ease;
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.2);
}

#weekly-gallery .gallery-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.3);
    border-color: rgba(255, 255, 255, 0.4);
}

#weekly-gallery .gallery-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

#weekly-gallery .gallery-item:hover .gallery-image {
    transform: scale(1.1);
}

/* Custom select styles */
select {
    background-image: none;
}

/* Ghost Gallery styles */

.gallery-pagination .pagination-button.active {
    background-color: #ffffff;
    color: #000000;
}

#ghost-gallery {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 1rem;
    padding: 1rem;
}

#ghost-gallery .gallery-item {
    position: relative;
    overflow: hidden;
    border-radius: 1rem;
    aspect-ratio: 1;
    cursor: pointer;
    transition: transform 0.3s ease;
}

#ghost-gallery .gallery-item:hover {
    transform: scale(1.02);
}

#ghost-gallery .gallery-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

#ghost-gallery .gallery-item:hover .gallery-image {
    transform: scale(1.1);
}

#ghost-gallery .gallery-overlay {
    display: none;
}

@media (min-width: 768px) {
    #ghost-gallery {
        grid-template-columns: repeat(3, 1fr);
    }
    
    #ghost-gallery .gallery-item:nth-child(3n+2) {
        grid-column: span 2;
    }
    
    #ghost-gallery .gallery-item:nth-child(3n+3) {
        grid-row: span 2;
    }
}

/* History Timeline Styles */
#history-timeline {
    max-width: 1200px;
    margin: 0 auto;
}

#history-timeline .history-item {
    display: flex;
    align-items: stretch;
    gap: 2rem;
    margin-bottom: 4rem;
    position: relative;
}

#history-timeline .history-item:nth-child(odd) {
    flex-direction: row-reverse;
}

#history-timeline .history-content {
    flex: 1;
    position: relative;
    padding: 2rem;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 1rem;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

#history-timeline .history-image {
    flex: 1;
    position: relative;
    border-radius: 1rem;
    overflow: hidden;
    min-height: 300px;
}

#history-timeline .history-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

#history-timeline .history-image:hover img {
    transform: scale(1.05);
}

#history-timeline .history-title {
    font-size: 1.5rem;
    font-weight: bold;
    margin-bottom: 1rem;
    color: white;
}

#history-timeline .history-text {
    color: rgba(255, 255, 255, 0.8);
    font-size: 1rem;
    line-height: 1.6;
}

@media (max-width: 768px) {
    #history-timeline {
        display: flex;
        flex-direction: column;
    }

    #history-timeline .history-item {
        flex-direction: column;
        gap: 1rem;
        margin-bottom: 2rem;
    }

    #history-timeline .history-item:nth-child(odd) {
        flex-direction: column;
    }

    #history-timeline .history-content {
        padding: 1.5rem;
    }

    #history-timeline .history-image {
        height: 200px;
        min-height: auto;
    }
}


/* Custom styles for the impressum page */

.impressum-content {
    background: rgba(128, 128, 128, 0.1);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.impressum-section {
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    padding-bottom: 1.5rem;
}

.impressum-section:last-child {
    border-bottom: none;
}

@media (max-width: 768px) {
    .impressum-content {
        padding: 1.5rem;
    }
}

/* Event Styles */
#events-container .event-block {
    background: rgba(128, 128, 128, 0.1);
    border-radius: 1rem;
    overflow: hidden;
    transition: transform 0.3s ease;
    display: flex;
    flex-direction: column;
}

#events-container .event-block:hover {
    transform: translateY(-5px);
}

#events-container .event-image-wrapper {
    width: 100%;
    display: block;
    line-height: 0;
    margin: 0;
    padding: 0;
    aspect-ratio: 1;
    overflow: hidden;
}

#events-container .event-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    margin: 0;
    padding: 0;
    border: none;
    line-height: 0;
    transition: transform 0.3s ease;
}

#events-container .event-block:hover .event-image {
    transform: scale(1.05);
}

#events-container .event-content {
    padding: 1.5rem;
    background: rgba(128, 128, 128, 0.2);
    backdrop-filter: blur(10px);
    transition: background-color 0.3s ease;
}

#events-container .event-block:hover .event-content {
    background-color: rgba(128, 128, 128, 0.4);
}

#events-container .event-date {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: rgba(255, 255, 255, 0.8);
    font-size: 0.875rem;
    margin-bottom: 0.75rem;
}

#events-container .event-date i {
    color: rgba(255, 255, 255, 0.6);
}

#events-container .event-title {
    font-size: 1.25rem;
    font-weight: bold;
    margin-bottom: 0.5rem;
    color: white;
}

#events-container .event-description {
    color: rgba(255, 255, 255, 0.8);
    font-size: 0.875rem;
    line-height: 1.5;
    margin: 0;
}

@media (max-width: 768px) {
    #events-container .event-image-wrapper {
        position: relative;
        width: 100%;
        height: 250px;
    }
    
    #events-container .event-image {
        position: absolute;
        top: 0;
        left: 0;
        width: 100%;
        height: 100%;
        object-fit: cover;
    }
    
    #events-container .event-block {
        margin-bottom: 2rem;
    }
}

/* Team Grid Styles */
#team-grid.team-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    padding: 2rem;
    max-width: 1200px;
    margin: 0 auto;
    width: 100%;
}

#team-grid .team-member {
    background: rgba(255, 255, 255, 0.05);
    border-radius: 1rem;
    overflow: hidden;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    display: flex;
    flex-direction: column;
    width: 100%;
}

#team-grid .team-member:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.2);
}

#team-grid .member-image {
    position: relative;
    width: 100%;
    padding-top: 100%;
    overflow: hidden;
}

#team-grid .member-image img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

#team-grid .team-member:hover .member-image img {
    transform: scale(1.05);
}

#team-grid .member-info {
    padding: 1.5rem;
    text-align: center;
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

#team-grid .member-name {
    font-size: 1.25rem;
    font-weight: bold;
    margin-bottom: 0.5rem;
    color: white;
}

#team-grid .member-title {
    color: rgba(255, 255, 255, 0.8);
    font-size: 1rem;
}

@media (max-width: 768px) {
    #team-grid.team-grid {
        grid-template-columns: 1fr;
        gap: 3rem;
        padding: 0;
        max-width: 100%;
    }

    #team-grid .team-member {
        max-width: 100%;
        margin: 0;
        background: rgba(255, 255, 255, 0.08);
        border-radius: 0;
    }

    #team-grid .member-image {
        padding-top: 100%;
    }

    #team-grid .member-info {
        padding: 2.5rem 1.5rem;
    }

    #team-grid .member-name {
        font-size: 1.75rem;
        margin-bottom: 1rem;
    }

    #team-grid .member-title {
        font-size: 1.3rem;
    }
}
