body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    margin: 0;
    padding: 0;
    background-color: #eaeaea;
    /*background: linear-gradient(180deg, #0a1024 0%, #13182d 100%);*/
    min-height: 100vh;
    color: #333;
}

header {
    text-align: center;
    padding: 0 20px 0 20px;
    background: rgba(26, 26, 46, 0.95);
    backdrop-filter: blur(10px);
    border-bottom: 2px solid rgba(79, 172, 254, 0.3);
    color: #ffffff;
}

/* Website Title */
.website-title {
    font-size: 3em;
    font-weight: bold;
    color: #ffffff;
    text-align: center;
}

header h1 {
    margin: 0;
    font-size: 3em;
}

/* Main content page titles */
main h1 {
    font-size: 2.5rem;
    font-weight: 300;
    margin: 2rem 0;
    text-align: center;
    background: linear-gradient(45deg, #4facfe, #00f2fe);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    color: #4facfe; /* Fallback for browsers that don't support background-clip */
}

/* Header content */
.header-content {
    display: flex;
    align-items: center; /* Vertically center items */
    justify-content: space-between; /* Space between the title and the search box */
    padding: 20px;
    color: #ffffff;
}

/* Center the h1 title */
.header-content h1 {
    margin: 0;
    font-size: 3em;
    text-align: left; /* Align the title to the left */
}

/* Header actions (search form and add photo icon) */
.header-actions {
    display: flex;
    align-items: center;
    gap: 15px;
}

/* Search form */
.search-form {
    display: flex;
    align-items: center;
    gap: 10px;
}

.search-form input[type="text"] {
    padding: 8px 12px;
    border: 1px solid #ccc;
    border-radius: 20px;
    font-size: 1em;
    outline: none;
    width: 200px;
    transition: width 0.3s ease-in-out;
}

.search-form input[type="text"]:focus {
    width: 300px; /* Expand the input field on focus */
    border-color: #007acc;
}

/* Search button */
.search-button {
    background: none;
    border: none;
    cursor: pointer;
    padding: 0;
    display: flex;
    align-items: center;
    justify-content: center;
}

.search-button img {
    width: 20px;
    height: 20px;
    filter: invert(1); /* Make the icon white to match the header */
}

/* Add Photo Icon */
.icon-button {
    background: none;
    border: none;
    cursor: pointer;
    padding: 0;
    display: flex;
    align-items: center;
    justify-content: center;
}

.header-content .icon-button img {
    filter: invert(1); /* Make the icon white to match the header */
}


nav a {
    color: #00bfff;
    text-decoration: none;
    font-size: 1.2em;
}

nav a:hover {
    text-decoration: underline;
}

.search-box {
    text-align: center;
    margin: 20px 0;
}

search-box input {
    padding: 8px; /* Reduced padding for smaller input size */
    font-size: 1em;
    width: 250px; /* Reduced width for better layout */
    border: 1px solid #ccc;
    border-radius: 5px;
}

.search-box button {
    padding: 8px 15px; /* Reduced padding for smaller button */
    font-size: 1em;
    background-color: #00bfff;
    color: white;
    border: none;
    border-radius: 5px;
    cursor: pointer;
}

search-box button:hover {
    background-color: #007acc;
}

.container {
    width: 80%;
    margin: auto;
    overflow: hidden;
}

form.add_photo {
    margin: 20px auto;
}

form {
    border-radius: 10px;
}

form label {
    display: block;
    margin-bottom: 5px;
    font-weight: bold;
}

form input, form select, form textarea {
    width: 100%; /* Make inputs take full width of the form */
    padding: 10px;
    margin-bottom: 15px;
    border: 1px solid #ccc;
}

.header-actions form input {
    margin-bottom: 0px;
}

input[type="text"],
input[type="date"],
input[type="number"],
select {
    width: 100%;
    border: 1px solid #ccc;
    border-radius: 4px;
}

input[type="submit"] {
    background: #35424a;
    color: #ffffff;
    border: none;
    padding: 10px 15px;
    cursor: pointer;
}

input[type="submit"]:hover {
    background: #45a049;
}

/* Photo gallery container */
.photo-gallery {
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
    justify-content: center;
    padding: 20px;
}

/* Photo card */
.photo-card {
    display: block;
    text-decoration: none;
    color: inherit;
    background-color: #ffffff; /* White background */
    border-radius: 10px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1); /* Subtle shadow */
    overflow: hidden;
    transition: transform 0.2s, box-shadow 0.2s;
    width: 300px; /* Fixed width for cards */
}

.photo-card:hover {
    transform: translateY(-5px); /* Slight lift on hover */
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.2); /* Enhanced shadow on hover */
}

/* Photo card content */
.photo-card-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 15px;
}

/* Photo thumbnail */
.photo-thumbnail {
    width: 100%;
    height: auto;
    border-radius: 10px;
    margin-bottom: 10px;
}

/* Photo thumbnail */
.photo-card-content img {
    max-height: 450px; /* Limit the height to 450px */
    width: auto; /* Maintain aspect ratio */
    object-fit: cover; /* Ensure the image fills the space without distortion */
    border-radius: 10px; /* Optional: Add rounded corners */
}

/* Photo info */
.photo-info h2 {
    margin: 10px 0 5px;
    font-size: 1.5em;
}

.photo-info p {
    margin: 5px 0;
    font-size: 1em;
    color: #555;
}

.photo-list {
    list-style: none;
    padding: 0;
}

.photo-list li {
    background: #ffffff;
    margin: 10px 0;
    padding: 10px;
    border-radius: 5px;
    box-shadow: 0 0 5px rgba(0, 0, 0, 0.1);
}

.flash-messages {
    margin: 20px auto;
    max-width: 500px;
    text-align: center;
}

.flash-message {
    padding: 10px;
    margin-bottom: 10px;
    border-radius: 5px;
    font-size: 1em;
}

.flash-message.success {
    background-color: #4caf50;
    color: white;
}

.flash-message.error {
    background-color: #f44336;
    color: white;
}

footer {
    margin-top: 4rem;
    padding: 2.5rem 2rem;
    background: linear-gradient(135deg, rgba(26, 26, 46, 0.95) 0%, rgba(22, 33, 62, 0.95) 100%);
    backdrop-filter: blur(15px);
    border-top: 2px solid rgba(79, 172, 254, 0.3);
    box-shadow: 0 -8px 32px rgba(0, 0, 0, 0.3);
    color: #ffffff;
    position: relative;
    text-align: center;
}

footer::before {
    content: '';
    position: absolute;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 60px;
    height: 4px;
    background: linear-gradient(45deg, #4facfe, #00f2fe);
    border-radius: 2px;
}

.footer-content {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1.5rem;
}

.footer-brand {
    font-size: 1.5rem;
    font-weight: 300;
    background: linear-gradient(45deg, #4facfe, #00f2fe);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    color: #4facfe;
    margin-bottom: 0.5rem;
}

.footer-tagline {
    font-size: 0.9rem;
    color: rgba(255, 255, 255, 0.7);
    font-weight: 300;
    letter-spacing: 0.5px;
    margin-bottom: 1rem;
}

.footer-links {
    display: flex;
    gap: 2rem;
    flex-wrap: wrap;
    justify-content: center;
}

.footer-links a {
    color: rgba(255, 255, 255, 0.8);
    text-decoration: none;
    font-size: 0.9rem;
    font-weight: 400;
    transition: all 0.3s ease;
    padding: 0.5rem 1rem;
    border-radius: 8px;
    border: 1px solid transparent;
}

.footer-links a:hover {
    color: #4facfe;
    background: rgba(79, 172, 254, 0.1);
    border-color: rgba(79, 172, 254, 0.3);
    transform: translateY(-2px);
}

.footer-divider {
    width: 100%;
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(79, 172, 254, 0.3), transparent);
    margin: 1rem 0;
}

.footer-copyright {
    font-size: 0.8rem;
    color: rgba(255, 255, 255, 0.5);
    font-weight: 300;
    letter-spacing: 0.3px;
}

.footer-tech {
    font-size: 0.75rem;
    color: rgba(255, 255, 255, 0.4);
    font-weight: 300;
    margin-top: 0.5rem;
}

.footer-tech span {
    color: rgba(79, 172, 254, 0.7);
}

@media (max-width: 768px) {
    footer {
        padding: 2rem 1rem;
    }
    
    .footer-links {
        gap: 1rem;
    }
    
    .footer-links a {
        padding: 0.4rem 0.8rem;
        font-size: 0.85rem;
    }
}

/* Photo Title */
.photo-title {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 20px;
}

.photo-title h1 {
    font-size: 2.5em;
    font-weight: bold;
    margin: 0;
}

.actions {
    display: flex;
    gap: 10px;
}

.add-photo-details {
    display: flex;
    flex-direction: column;
    gap: 20px;
    padding: 20px;
    margin: 20px auto;
    max-width: 1200px; /* Limit the width of the content */
    background-color: #ffffff; /* White background for the content */
    border-radius: 10px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1); /* Subtle shadow for better visibility */
}

/* Layout for the photo details */
.photo-details {
    display: flex;
    flex-direction: row; /* Align text and image side by side */
    gap: 20px;
    max-width: 1200px; /* Limit the width of the content */
    border-radius: 10px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1); /* Subtle shadow for better visibility */
}

.photo_left {
    display: flex;
    flex-direction: column; /* Stack the image and text vertically */
    align-items: center; /* Center the image */
    justify-content: center; /* Center the image vertically */
    max-width: 40%; /* Limit the width of the image container */
    max-width: 60%; /* Limit the width of the image container */
}

/* Photo Info */
.photo-info {
    flex: 1; /* Allow the text to take up available space */
    font-size: 1.1em;
    line-height: 1.6;
    margin-right: 20px; /* Add spacing between the text and the image */
}

.photo-info p {
    margin: 10px 0;
}

/* Photo container in details view */
.photo-container {
    flex-shrink: 0; /* Prevent the image from shrinking */
    align-self: flex-start; /* Align the image to the top */
}

.photo-full {
    width: 100%;
    height: auto;
    border-radius: 10px;
}

/* Action buttons */
.icon-button {
    background: none;
    border: none;
    cursor: pointer;
    padding: 5px;
    border-radius: 50%;
    transition: background-color 0.3s;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 32px; /* Set consistent size for buttons */
    height: 32px;
}

.icon-button img {
    width: 20px; /* Smaller icon size */
    height: 20px;
}

.icon-button:hover {
    background-color: rgba(0, 0, 0, 0.1); /* Add a subtle hover effect */
}

.spinner {
    display: none; /* Hidden by default */
    border: 4px solid rgba(0, 0, 0, 0.1);
    border-top: 4px solid #00bfff;
    border-radius: 50%;
    width: 40px;
    height: 40px;
    animation: spin 1s linear infinite;
    margin: 20px auto;
}

@keyframes spin {
    0% {
        transform: rotate(0deg);
    }
    100% {
        transform: rotate(360deg);
    }
}

/* Lightbox styles */
.lightbox-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.8);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 1000;
}

.lightbox-content {
    position: relative;
    max-width: 90%;
    max-height: 90%;
}

lightbox-content img {
    width: 100%;
    height: auto;
    border-radius: 10px;
}

.lightbox-close {
    position: absolute;
    top: 10px;
    right: 10px;
    background: none;
    border: none;
    font-size: 2em;
    color: #fff;
    cursor: pointer;
}

/* Home link styles */
.home-link {
    top: 20px;
    left: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    background-color: #ffffff;
    border-radius: 50%;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
    transition: background-color 0.3s;
}

.home-link img {
    width: 24px;
    height: 24px;
}

.home-link:hover {
    background-color: #005f99;
}

/* Loader overlay */
.loader-overlay {
    display: none; /* Hidden by default */
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5); /* Semi-transparent black background */
    justify-content: center;
    align-items: center;
    z-index: 1000; /* Ensure it overlays other elements */
}

/* Loader animation */
.loader {
    border: 8px solid rgba(255, 255, 255, 0.3); /* Light border */
    border-top: 8px solid #ffffff; /* White border for the spinner */
    border-radius: 50%;
    width: 50px;
    height: 50px;
    animation: spin 1s linear infinite; /* Spinning animation */
}

@keyframes spin {
    0% {
        transform: rotate(0deg);
    }
    100% {
        transform: rotate(360deg);
    }
}

/* Pagination styles */
.pagination {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1.5rem;
    margin: 3rem auto;
    padding: 2rem;
    max-width: 600px;
    background: linear-gradient(135deg, rgba(26, 26, 46, 0.95) 0%, rgba(22, 33, 62, 0.95) 100%);
    backdrop-filter: blur(15px);
    border-radius: 20px;
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.4);
    border: 1px solid rgba(79, 172, 254, 0.2);
    color: #ffffff;
}

.pagination .pager {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    justify-content: center;
}

.pagination .pager a {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 120px;
    padding: 0.75rem 1.5rem;
    text-decoration: none;
    color: #ffffff;
    background: linear-gradient(45deg, rgba(79, 172, 254, 0.8), rgba(0, 242, 254, 0.8));
    border-radius: 12px;
    font-weight: 500;
    font-size: 0.9rem;
    transition: all 0.3s ease;
    border: 1px solid rgba(79, 172, 254, 0.3);
    backdrop-filter: blur(10px);
}

.pagination .pager a:hover {
    background: linear-gradient(45deg, rgba(79, 172, 254, 1), rgba(0, 242, 254, 1));
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(79, 172, 254, 0.4);
    border-color: rgba(79, 172, 254, 0.6);
}

.pagination .pager span {
    padding: 0.75rem 1.5rem;
    color: rgba(255, 255, 255, 0.8);
    font-size: 0.9rem;
    font-weight: 300;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 12px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
}

/* Star rating styles */
.star-list {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    max-width: 1400px;
    margin: 0 auto;
    padding: 1rem;
}

.star-card {
    border-radius: 16px;
    padding: 0;
    text-align: center;
    background: linear-gradient(135deg, rgba(26, 26, 46, 0.95) 0%, rgba(22, 33, 62, 0.95) 100%);
    backdrop-filter: blur(10px);
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.5);
    transition: all 0.3s ease;
    overflow: hidden;
    color: white;
}

.star-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.4);
}

.star-thumbnail {
    width: 100%;
    height: 200px;
    object-fit: cover;
    background: #ddd;
}

.star-thumbnail.placeholder {
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(255, 255, 255, 0.1);
    color: rgba(255, 255, 255, 0.6);
    font-size: 1.2rem;
    height: 200px;
}

/* Star card content */
.star-card a {
    text-decoration: none;
    color: inherit;
    display: block;
}

.star-card h2 {
    font-size: 1.5rem;
    font-weight: 300;
    margin: 1rem;
    background: linear-gradient(45deg, #4facfe, #00f2fe);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    color: #4facfe;
}

.star-meta {
    margin: 0 1rem 1.5rem 1rem;
    color: rgba(255, 255, 255, 0.7);
    font-size: 0.9rem;
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
}

.pagination form {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1rem;
    width: 100%;
}

.pagination form label {
    color: rgba(255, 255, 255, 0.9);
    font-size: 0.9rem;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.pagination select {
    background: linear-gradient(135deg, rgba(0, 0, 0, 0.4), rgba(26, 26, 46, 0.4));
    color: white;
    border: 1px solid rgba(79, 172, 254, 0.3);
    border-radius: 12px;
    padding: 0.75rem 1rem;
    font-size: 0.9rem;
    font-weight: 500;
    transition: all 0.3s ease;
    backdrop-filter: blur(10px);
    cursor: pointer;
    min-width: 120px;
}

.pagination select:hover {
    border-color: rgba(79, 172, 254, 0.6);
    background: linear-gradient(135deg, rgba(0, 0, 0, 0.6), rgba(26, 26, 46, 0.6));
    transform: translateY(-1px);
}

.pagination select:focus {
    outline: none;
    border-color: #4facfe;
    box-shadow: 0 0 0 3px rgba(79, 172, 254, 0.2);
}

.pagination select option {
    background: rgba(26, 26, 46, 0.95);
    color: white;
    padding: 0.5rem;
}

/* Form Pages Styles */
.form-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 1rem;
}

.form-panel {
    background: linear-gradient(135deg, rgba(26, 26, 46, 0.95) 0%, rgba(22, 33, 62, 0.95) 100%);
    backdrop-filter: blur(10px);
    border-radius: 16px;
    padding: 2rem;
    color: white;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
}

.form-panel h1 {
    font-size: 2rem;
    font-weight: 300;
    margin: 0 0 2rem 0;
    padding-bottom: 1rem;
    border-bottom: 2px solid rgba(79, 172, 254, 0.3);
    background: linear-gradient(45deg, #4facfe, #00f2fe);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    color: #4facfe;
}

.form-panel form {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 1.5rem 3rem;
}

/* Full width fields */
.form-panel form > div:has(textarea),
.form-panel form > div:has(input[type="file"]),
.form-panel form > button {
    grid-column: 1 / -1;
}

.form-panel div {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.form-panel label {
    font-size: 0.9rem;
    color: rgba(255, 255, 255, 0.8);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    font-weight: 500;
}

.form-panel input,
.form-panel select,
.form-panel textarea {
    padding: 0.75rem;
    border: 1px solid rgba(79, 172, 254, 0.3);
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.1);
    color: white;
    font-size: 1rem;
    transition: all 0.3s ease;
}

.form-panel input:focus,
.form-panel select:focus,
.form-panel textarea:focus {
    outline: none;
    border-color: #4facfe;
    background: rgba(255, 255, 255, 0.15);
    box-shadow: 0 0 0 3px rgba(79, 172, 254, 0.1);
}

.form-panel input::placeholder,
.form-panel textarea::placeholder {
    color: rgba(255, 255, 255, 0.5);
}

.submit-btn {
    background: linear-gradient(45deg, #4facfe, #00f2fe);
    color: white;
    border: none;
    padding: 1rem 2rem;
    border-radius: 8px;
    font-size: 1.1rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
    margin-top: 1rem;
}

.submit-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(79, 172, 254, 0.3);
}

.error {
    color: #ff6b6b;
    font-size: 0.85rem;
    margin-top: 0.25rem;
}

/* Star Details Page Styles */
.star-details-container {
    display: grid;
    grid-template-columns: 3fr 2fr;
    gap: 2rem;
    max-width: 1400px;
    margin: 0 auto;
    padding: 1rem;
    align-items: stretch;
    height: calc(100vh - 140px);
    max-height: 800px;
    min-height: 500px;
}

.star-info-panel {
    background: linear-gradient(135deg, rgba(26, 26, 46, 0.95) 0%, rgba(22, 33, 62, 0.95) 100%);
    backdrop-filter: blur(10px);
    border-radius: 16px;
    padding: 2rem;
    color: white;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.star-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2rem;
    padding-bottom: 1rem;
    border-bottom: 2px solid rgba(79, 172, 254, 0.3);
    flex-shrink: 0;
}

.star-title {
    font-size: 2rem;
    font-weight: 300;
    margin: 0;
    background: linear-gradient(45deg, #4facfe, #00f2fe);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.star-actions {
    display: flex;
    gap: 0.5rem;
}

.action-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.1);
    transition: all 0.3s ease;
    text-decoration: none;
}

.action-btn:hover {
    background: rgba(255, 255, 255, 0.2);
    transform: translateY(-2px);
}

.action-btn img {
    width: 20px;
    height: 20px;
    filter: invert(1);
}

.add-btn img {
    filter: none !important;
}

.delete-btn:hover {
    background: rgba(220, 53, 69, 0.2);
}

.star-info-grid {
    display: grid;
    gap: 1rem;
    flex: 1;
    overflow-y: auto;
    min-height: 0;
}

.info-item {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
}

.info-label {
    font-size: 0.85rem;
    color: rgba(255, 255, 255, 0.7);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    font-weight: 500;
}

.info-value {
    font-size: 1rem;
    color: white;
    font-weight: 300;
}

.description-item {
    grid-column: 1 / -1;
    margin-top: 1rem;
    padding-top: 1rem;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.description-item .info-value {
    line-height: 1.6;
}

.photos-section {
    display: flex;
    flex-direction: column;
    height: 100%;
    overflow: hidden;
}

.carousel-container {
    position: relative;
    border-radius: 16px;
    overflow: visible;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
    height: 100%;
}

/* Ensure carousel items are properly hidden */
.carousel-inner {
    position: relative;
    width: 100%;
    height: 100%;
    overflow: visible;
    border-radius: 16px;
}

.carousel-item {
    position: relative;
    display: none;
    float: left;
    width: 100%;
    height: 100%;
    margin-right: -100%;
    backface-visibility: hidden;
    transition: transform 0.6s ease-in-out;
}

.carousel-item.active {
    display: block;
}

.photo-container {
    position: relative;
    height: 100%;
    cursor: pointer;
    display: flex;
    flex-direction: column;
}

.image-container {
    position: relative;
    width: 100%;
    max-height: 60vh;
    overflow: hidden;
    border-radius: 16px 16px 0 0;
    flex-shrink: 0;
}

.carousel-image {
    width: 100%;
    height: 60vh;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.photo-container:hover .carousel-image {
    transform: scale(1.05);
}

.photo-info-panel {
    background: linear-gradient(135deg, rgba(26, 26, 46, 0.95) 0%, rgba(22, 33, 62, 0.95) 100%);
    backdrop-filter: blur(10px);
    border-radius: 0 0 16px 16px;
    padding: 1.5rem;
    color: white;
    border-top: 2px solid rgba(79, 172, 254, 0.3);
    flex: 1;
    min-height: 0;
    overflow-y: auto;
}

.photo-details {
    color: white !important;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.photo-meta {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1rem;
}

.meta-item {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
}

.meta-label {
    font-size: 0.85rem;
    color: rgba(255, 255, 255, 0.7);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    font-weight: 500;
}

.meta-value {
    font-size: 1rem;
    color: white;
    font-weight: 300;
}

.additional-info {
    grid-column: 1 / -1;
    margin-top: 0.5rem;
    padding-top: 0.75rem;
    border-top: 1px solid rgba(255, 255, 255, 0.3);
}

.additional-info .meta-label {
    margin-bottom: 0.25rem;
}

.additional-info .meta-value {
    font-style: italic;
    color: rgba(255, 255, 255, 0.9) !important;
}

.delete-button-container {
    align-self: flex-start;
}

.delete-photo-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.25rem;
    background: rgba(220, 53, 69, 0.9);
    color: white !important;
    border: none;
    padding: 0.4rem 0.8rem;
    border-radius: 12px;
    font-size: 0.75rem;
    cursor: pointer;
    transition: all 0.3s ease;
    height: auto;
    width: auto;
}

.delete-photo-btn:hover {
    background: rgba(220, 53, 69, 1);
    transform: translateY(-1px);
}

.delete-photo-btn img {
    width: 12px;
    height: 12px;
    filter: invert(1);
}

.carousel-control-prev,
.carousel-control-next {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 50px;
    height: 50px;
    background: rgba(0, 0, 0, 0.7);
    border: none;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10;
    transition: all 0.3s ease;
    opacity: 0.8;
}

.carousel-control-prev:hover,
.carousel-control-next:hover {
    background: rgba(0, 0, 0, 0.9);
    opacity: 1;
    transform: translateY(-50%) scale(1.1);
}

.carousel-control-prev {
    left: 15px;
}

.carousel-control-next {
    right: 15px;
}

.carousel-control-prev-icon,
.carousel-control-next-icon {
    width: 0;
    height: 0;
    border-style: solid;
}

.carousel-control-prev-icon {
    border-right: 12px solid white;
    border-top: 8px solid transparent;
    border-bottom: 8px solid transparent;
}

.carousel-control-next-icon {
    border-left: 12px solid white;
    border-top: 8px solid transparent;
    border-bottom: 8px solid transparent;
}

.carousel-indicators-custom {
    display: flex;
    justify-content: center;
    gap: 0.5rem;
    padding: 1rem;
    background: rgba(0, 0, 0, 0.1);
}

.carousel-indicators-custom button {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    border: none;
    background: rgba(255, 255, 255, 0.5);
    cursor: pointer;
    transition: background 0.3s ease;
}

.carousel-indicators-custom button.active {
    background: white;
}

.no-photos {
    display: flex;
    align-items: center;
    justify-content: center;
    height: 600px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-radius: 16px;
    color: white;
    text-align: center;
}

.no-photos-content {
    max-width: 300px;
}

.no-photos-icon {
    width: 80px;
    height: 80px;
    filter: invert(1);
    opacity: 0.7;
    margin-bottom: 1rem;
}

.no-photos h3 {
    margin: 0 0 0.5rem 0;
    font-weight: 300;
}

.no-photos p {
    margin: 0 0 1.5rem 0;
    opacity: 0.8;
}

.add-first-photo-btn {
    display: inline-block;
    background: rgba(255, 255, 255, 0.2);
    color: white;
    padding: 0.75rem 1.5rem;
    border-radius: 25px;
    text-decoration: none;
    transition: all 0.3s ease;
}

.add-first-photo-btn:hover {
    background: rgba(255, 255, 255, 0.3);
    transform: translateY(-2px);
    color: white;
}

/* Lightbox Styles */
.lightbox {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.95);
    backdrop-filter: blur(5px);
}

.lightbox-content {
    position: absolute;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: auto;
}

.lightbox-image {
    max-width: 100vw;
    max-height: 100vh;
    width: auto;
    height: auto;
    object-fit: contain;
    cursor: grab;
    transition: transform 0.3s ease;
}

.lightbox-close {
    position: absolute;
    top: 20px;
    right: 30px;
    color: #4facfe;
    font-size: 40px;
    font-weight: bold;
    cursor: pointer;
    background: rgba(0, 0, 0, 0.7);
    border-radius: 50%;
    width: 50px;
    height: 50px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
}

.lightbox-close:hover {
    color: #00f2fe;
    background: rgba(0, 0, 0, 0.9);
    transform: scale(1.1);
}

.lightbox-info {
    position: fixed;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%);
    background: rgba(26, 26, 46, 0.95);
    color: white;
    padding: 1rem 2rem;
    border-radius: 12px;
    border: 1px solid rgba(79, 172, 254, 0.3);
    text-align: center;
    z-index: 1001;
    backdrop-filter: blur(10px);
}

/* Responsive adjustments for smaller screens */
@media (max-height: 800px) {
    .star-details-container {
        height: calc(100vh - 120px);
        max-height: none;
    }
}

@media (max-height: 700px) {
    .star-details-container {
        height: calc(100vh - 100px);
        min-height: 400px;
    }
    
    .photo-meta {
        grid-template-columns: 1fr;
        gap: 0.4rem;
    }
}

@media (max-width: 768px) {
    .star-details-container {
        grid-template-columns: 1fr;
        gap: 1rem;
        height: auto;
        min-height: auto;
    }
    
    .star-header {
        flex-direction: column;
        gap: 1rem;
        text-align: center;
    }
    
    .photo-meta {
        grid-template-columns: 1fr;
    }
    
    .lightbox-close {
        top: 10px;
        right: 15px;
        font-size: 30px;
        width: 40px;
        height: 40px;
    }
    
    .lightbox-info {
        bottom: 10px;
        padding: 0.75rem 1.5rem;
    }
}