:root {
    --primary-color: #ff8fa3; /* Soft pink/red */
    --secondary-color: #fff0f3;
    --text-color: #333;
    --bg-color: #ffffff;
    --accent-color: #ff4d6d;
    --gradient-1: linear-gradient(135deg, #ff8fa3 0%, #ff4d6d 100%);
    --gradient-2: linear-gradient(135deg, #fff0f3 0%, #ffffff 100%);
}

* {
    box-sizing: border-box;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background-color: var(--bg-color);
    color: var(--text-color);
    margin: 0;
    padding: 0;
    line-height: 1.6;
}

.navbar {
    background-color: rgba(255, 255, 255, 0.95);
    box-shadow: 0 2px 10px rgba(0,0,0,0.05);
    padding: 1rem 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    position: sticky;
    top: 0;
    z-index: 1000;
    backdrop-filter: blur(10px);
}

.navbar-brand {
    font-size: 1.5rem;
    font-weight: bold;
    color: var(--accent-color);
    text-decoration: none;
}

.nav-links {
    display: flex;
    align-items: center;
}

.nav-links a {
    margin-left: 20px;
    text-decoration: none;
    color: var(--text-color);
    font-weight: 500;
    transition: color 0.3s;
}

.nav-links a:hover {
    color: var(--accent-color);
}

.mobile-menu-btn {
    display: none;
    background: none;
    border: none;
    font-size: 1.5rem;
    color: var(--accent-color);
    cursor: pointer;
}

.container {
    max-width: 1200px;
    margin: 2rem auto;
    padding: 0 20px;
}

/* Login Page */
.login-container {
    height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    background: linear-gradient(135deg, var(--secondary-color) 0%, #ffffff 100%);
}

.login-box {
    background: white;
    padding: 3rem;
    border-radius: 20px;
    box-shadow: 0 10px 25px rgba(0,0,0,0.05);
    text-align: center;
    width: 100%;
    max-width: 400px;
}

.login-box h1 {
    margin-bottom: 1.5rem;
    color: var(--accent-color);
}

.login-input {
    width: 100%;
    padding: 12px;
    margin-bottom: 1rem;
    border: 2px solid #eee;
    border-radius: 8px;
    font-size: 1rem;
    transition: border-color 0.3s;
    box-sizing: border-box;
}

.login-input:focus {
    border-color: var(--primary-color);
    outline: none;
}

.btn {
    background-color: var(--accent-color);
    color: white;
    border: none;
    padding: 12px 24px;
    border-radius: 8px;
    cursor: pointer;
    font-size: 1rem;
    font-weight: 600;
    transition: transform 0.2s, background-color 0.2s;
    width: 100%;
}

.btn:hover {
    background-color: #ff2a50;
    transform: translateY(-2px);
}

/* Album Grid */
.album-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    flex-wrap: wrap;
    gap: 10px;
}

.album-stats {
    display: flex;
    gap: 20px;
    color: #666;
    font-size: 0.9rem;
}

.album-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 20px;
    padding: 20px 0;
}

.album-item {
    position: relative;
    border-radius: 15px;
    overflow: hidden;
    box-shadow: 0 4px 15px rgba(0,0,0,0.1);
    transition: transform 0.3s, box-shadow 0.3s;
    aspect-ratio: 1;
    cursor: pointer;
}

.album-item:hover {
    transform: scale(1.03);
    box-shadow: 0 8px 25px rgba(0,0,0,0.15);
}

.album-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.album-item::after {
    content: '\f002'; /* Font Awesome magnifying glass */
    font-family: 'Font Awesome 6 Free';
    font-weight: 900;
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    color: white;
    font-size: 2rem;
    opacity: 0;
    transition: opacity 0.3s;
}

.album-item:hover::after {
    opacity: 0.8;
}

/* Chat */
.chat-container {
    background: white;
    border-radius: 20px;
    box-shadow: 0 5px 20px rgba(0,0,0,0.05);
    overflow: hidden;
    height: 70vh;
    min-height: 400px;
    display: flex;
    flex-direction: column;
}

.chat-messages {
    flex: 1;
    padding: 20px;
    overflow-y: auto;
    background-color: #f9f9f9;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.message {
    background: white;
    padding: 10px 15px;
    border-radius: 15px;
    border-bottom-left-radius: 2px;
    box-shadow: 0 2px 5px rgba(0,0,0,0.03);
    max-width: 80%;
    word-wrap: break-word;
    align-self: flex-start;
    animation: fadeIn 0.3s ease;
}

.message a {
    color: var(--accent-color);
    text-decoration: none;
}

.message a:hover {
    text-decoration: underline;
}

.message iframe {
    max-width: 100%;
    border-radius: 8px;
    margin-top: 5px;
}

.chat-form {
    padding: 20px;
    background: white;
    border-top: 1px solid #eee;
    display: flex;
    gap: 10px;
}

.chat-input {
    flex: 1;
    padding: 12px;
    border: 2px solid #eee;
    border-radius: 25px;
    outline: none;
}

.chat-input:focus {
    border-color: var(--primary-color);
}

.chat-btn {
    width: auto;
    border-radius: 25px;
    padding: 0 25px;
}

/* Rules List */
.rules-header {
    text-align: center;
    margin-bottom: 40px;
}

.rules-header h1 {
    color: var(--accent-color);
    margin-bottom: 10px;
}

.rules-header p {
    color: #666;
    font-size: 1.1rem;
}

.rules-container {
    background: var(--gradient-2);
    padding: 30px;
    border-radius: 20px;
}

.rules-list {
    list-style: none;
    padding: 0;
    counter-reset: rule-counter;
}

.rule-item {
    background: white;
    margin-bottom: 15px;
    padding: 20px;
    border-radius: 12px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.03);
    display: flex;
    align-items: center;
    transition: transform 0.2s, box-shadow 0.2s;
    border-left: 4px solid var(--accent-color);
    position: relative;
    overflow: hidden;
}

.rule-item::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    width: 4px;
    height: 100%;
    background: var(--gradient-1);
    transition: width 0.3s;
}

.rule-item:hover {
    transform: translateX(5px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.08);
}

.rule-item:hover::before {
    width: 8px;
}

.rule-icon {
    color: #28a745;
    margin-right: 15px;
    font-size: 1.2rem;
    min-width: 24px;
}

.rule-text {
    font-size: 1.05rem;
    font-weight: 500;
    flex: 1;
}

.rule-number {
    position: absolute;
    right: 20px;
    top: 50%;
    transform: translateY(-50%);
    font-size: 2rem;
    font-weight: bold;
    color: rgba(255, 77, 109, 0.1);
    pointer-events: none;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

/* Modal for Image Preview */
.modal {
    display: none; 
    position: fixed; 
    z-index: 2000; 
    padding-top: 50px; 
    left: 0;
    top: 0;
    width: 100%; 
    height: 100%; 
    overflow: auto; 
    background-color: rgba(0,0,0,0.9); 
}

.modal-content {
    margin: auto;
    display: block;
    max-width: 90%;
    max-height: 90vh;
    border-radius: 5px;
}

.close {
    position: absolute;
    top: 15px;
    right: 35px;
    color: #f1f1f1;
    font-size: 40px;
    font-weight: bold;
    transition: 0.3s;
    cursor: pointer;
}

.close:hover,
.close:focus {
    color: #bbb;
    text-decoration: none;
    cursor: pointer;
}

/* Mobile Navigation */
@media (max-width: 768px) {
    .navbar {
        padding: 1rem;
    }

    .navbar-brand {
        font-size: 1.2rem;
    }

    .mobile-menu-btn {
        display: block;
    }

    .nav-links {
        position: fixed;
        top: 60px;
        left: -100%;
        width: 100%;
        background: white;
        flex-direction: column;
        padding: 20px;
        box-shadow: 0 5px 15px rgba(0,0,0,0.1);
        transition: left 0.3s ease;
    }

    .nav-links.active {
        left: 0;
    }

    .nav-links a {
        margin: 10px 0;
        padding: 10px;
        width: 100%;
        text-align: center;
        border-bottom: 1px solid #eee;
    }

    .container {
        padding: 0 15px;
        margin: 1rem auto;
    }

    .login-box {
        padding: 2rem 1.5rem;
        margin: 0 15px;
    }

    .album-grid {
        grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
        gap: 10px;
    }

    .chat-container {
        height: calc(100vh - 180px);
        border-radius: 15px;
    }

    .chat-messages {
        padding: 15px;
    }

    .message {
        max-width: 90%;
        font-size: 0.95rem;
    }

    .chat-form {
        padding: 15px;
        flex-wrap: wrap;
    }

    .chat-input {
        font-size: 16px; /* Prevents zoom on iOS */
    }

    .rule-item {
        padding: 15px;
        flex-wrap: wrap;
    }

    .rule-text {
        font-size: 0.95rem;
    }

    .rule-number {
        font-size: 1.5rem;
    }

    .rules-container {
        padding: 15px;
    }

    h1 {
        font-size: 1.5rem !important;
    }
}

@media (max-width: 480px) {
    .album-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 8px;
    }

    .navbar {
        padding: 0.75rem;
    }
}

/* Loading spinner */
.spinner {
    border: 3px solid #f3f3f3;
    border-top: 3px solid var(--accent-color);
    border-radius: 50%;
    width: 30px;
    height: 30px;
    animation: spin 1s linear infinite;
    margin: 20px auto;
}

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

/* Scroll to top button */
.scroll-to-top {
    position: fixed;
    bottom: 30px;
    right: 30px;
    background: var(--gradient-1);
    color: white;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    display: none;
    justify-content: center;
    align-items: center;
    cursor: pointer;
    box-shadow: 0 4px 15px rgba(0,0,0,0.2);
    transition: transform 0.3s;
    z-index: 999;
}

.scroll-to-top:hover {
    transform: translateY(-5px);
}

.scroll-to-top.show {
    display: flex;
}
