/* Global Styles */
:root {
    /* Light Theme (default) */
    --primary-color: #9c5cb8;
    --text-color: #333;
    --background-color: #f9f9f9;
    --navbar-bg: #fff;
    --card-bg: #fff;
    --border-color: #ddd;
    --shadow-color: rgba(0, 0, 0, 0.1);
    --footer-bg: #333;
}

[data-theme="dark"] {
    /* Dark Theme */
    --primary-color: #771bce;
    --text-color: #f0f0f0;
    --background-color: #121212;
    --navbar-bg: #1e1e1e;
    --card-bg: #1e1e1e;
    --border-color: #333;
    --shadow-color: rgba(0, 0, 0, 0.3);
    --footer-bg: #000;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

body {
    background-color: var(--background-color);
    color: var(--text-color);
    line-height: 1.6;
}

/* Navbar Styles */
.navbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 2rem;
    background-color: var(--navbar-bg);
    box-shadow: 0 2px 10px var(--shadow-color);
    position: sticky;
    top: 0;
    z-index: 1000;
}

.logo-container {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.logo img {
    height: 50px;
    width: auto;
    border-radius: 50%;
}

.brand-name {
    font-size: 1.5rem;
    font-weight: 600;
    color: var(--text-color);
}

.nav-links,
.sidebar-links {
    display: flex;
    list-style: none;
    gap: 1.5rem;
}

.nav-links a,
.sidebar-links a {
    text-decoration: none;
    color: var(--text-color);
    font-weight: 500;
    transition: color 0.3s;
    padding: 0.5rem 1rem;
    border-radius: 5px;
}

.nav-links a:hover, 
.nav-links a.active,
.sidebar-links a:hover, 
.sidebar-links a.active {
    color: #fff;
    background-color: var(--primary-color);
}

.menu-toggle {
    display: none;
    cursor: pointer;
    font-size: 1.5rem;
}

/* Sidebar Styles */
.sidebar {
    position: fixed;
    top: 0;
    right: -300px;
    width: 300px;
    height: 100%;
    background-color: var(--navbar-bg);
    box-shadow: -2px 0 10px rgba(0, 0, 0, 0.1);
    z-index: 1001;
    transition: right 0.3s ease;
    padding: 2rem;
}

.sidebar.active {
    right: 0;
}

.sidebar-links {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 1rem;
    margin-top: 2rem;
}

.sidebar-links a {
    text-decoration: none;
    color: #ffffff;
    font-weight: 500;
    padding: 0.5rem 1rem;
    border-radius: 5px;
    display: block;
}

.close-btn {
    position: absolute;
    top: 1rem;
    right: 1rem;
    font-size: 1.5rem;
    cursor: pointer;
}

.overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    z-index: 1000;
    display: none;
}

.overlay.active {
    display: block;
}

/* Gallery Container */
.gallery-container {
    max-width: 1200px;
    margin: 2rem auto;
    padding: 0 1rem;
}

.gallery-title {
    text-align: center;
    margin-bottom: 2rem;
    color: #8e44ad;
    font-size: 2.5rem;
}

/* Search Bar */
.search-container {
    position: relative;
    max-width: 500px;
    margin: 0 auto 2rem;
}

.search-container input {
    width: 100%;
    padding: 0.8rem 1rem 0.8rem 2.5rem;
    border: 1px solid var(--border-color);
    background-color: var(--card-bg);
    color: var(--text-color);
    border-radius: 30px;
    font-size: 1rem;
    outline: none;
    transition: border-color 0.3s;
}

.search-container input:focus {
    border-color: #8e44ad;
}

.search-container i {
    position: absolute;
    left: 1rem;
    top: 50%;
    transform: translateY(-50%);
    color: #777;
}

/* Gallery Grid */
.gallery-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 1.5rem;
    margin-bottom: 2rem;
    padding: 20px;
}

.gallery-item {
    overflow: hidden;
    border-radius: 8px;
    box-shadow: 0 4px 8px var(--shadow-color);
    background-color: var(--card-bg);
    transition: transform 0.3s ease;
    aspect-ratio: 1/1;
    position: relative;
}

.gallery-item:hover {
    transform: translateY(-5px) scale(1.03);
}

.img-container {
    position: relative;
    height: 100%;
    background-color: #f8f9fa;
}

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

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

.image-title {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(to top, rgba(0,0,0,0.7), transparent);
    color: white;
    padding: 1rem;
    transform: translateY(100%);
    transition: transform 0.3s ease;
    text-align: center;
    font-weight: 500;
}

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

/* Status Messages */
.loading {
    text-align: center;
    padding: 2rem;
    font-size: 1.2rem;
    color: #8e44ad;
}

.error-message, 
.no-images {
    text-align: center;
    grid-column: 1 / -1;
    padding: 40px;
    color: #666;
}

.error-message i, 
.no-images i {
    font-size: 2rem;
    margin-bottom: 15px;
    color: #dc3545;
}

/* Toast Notifications */
.toast-container {
    position: fixed;
    bottom: 20px;
    right: 20px;
    z-index: 1000;
}

.toast {
    padding: 12px 20px;
    border-radius: 4px;
    color: white;
    margin-bottom: 10px;
    display: flex;
    align-items: center;
}

.toast.info {
    background: #17a2b8;
}

.toast.success {
    background: #28a745;
}

.toast.danger {
    background: #dc3545;
}

.toast i {
    margin-right: 10px;
}

/* WhatsApp Button */
.botao-whatsapp {
    position: fixed;
    bottom: 40px;
    right: 20px;
    background-color: #25d366;
    color: #fff;
    border-radius: 50%;
    padding: 15px;
    font-size:12px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    transition: background-color 0.3s ease, transform 0.3s ease;
    z-index: 3;
}

.botao-whatsapp:hover {
    background-color: #25d366;
    transform: scale(1.1);
}

.botao-whatsapp i {
    margin-right: 0;
    font-size: 40px;
}

/* Footer Styles */
footer {
    background-color: var(--footer-bg);
    color: #fff;
    padding: 2rem;
    text-align: center;
}

footer .logo-container {
    justify-content: center;
    margin-bottom: 1rem;
}

footer .logo img {
    height: 60px;
}

footer .brand-name {
    color: #fff;
    font-size: 1.8rem;
}

.social-links {
    display: flex;
    justify-content: center;
    gap: 1.5rem;
    margin: 1rem 0;
}

.social-links a {
    color: #fff;
    font-size: 1.5rem;
    transition: color 0.3s;
}

.social-links a:hover {
    color: #8e44ad;
}

footer p {
    margin: 0.5rem 0;
    font-size: 0.9rem;
    color: #ddd;
}

/* Responsive Styles */
@media (max-width: 992px) {
    .gallery-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .nav-links {
        display: none;
    }
    
    .menu-toggle {
        display: block;
    }
    
    .gallery-grid {
        grid-template-columns: 1fr;
    }
    
    .gallery-title {
        font-size: 2rem;
    }
}

@media (max-width: 480px) {
    .navbar {
        padding: 1rem;
    }
    
    .brand-name {
        font-size: 1.2rem;
    }
    
    .sidebar {
        width: 250px;
        padding: 1rem;
    }
    
    .gallery-title {
        font-size: 1.8rem;
    }
    
    .search-container {
        margin-bottom: 1rem;
    }
}

.theme-toggle {
    background: none;
    border: none;
    color: var(--text-color);
    font-size: 1.2rem;
    cursor: pointer;
    padding: 0.5rem;
    margin-left: 1rem;
    transition: transform 0.3s ease;
}

.theme-toggle:hover {
    transform: scale(1.1);
}

[data-theme="dark"] .theme-toggle .fa-moon::before {
    content: "\f185"; /* Ícone de sol quando estiver no tema escuro */
}