:root {
    --primary: #FF8BA7;
    --primary-hover: #FF7496;
    --secondary: #84DCC6;
    --secondary-hover: #75C6B2;
    --bg-color: #FAFAFA;
    --text-color: #4A4A4A;
    --text-light: #7A7A7A;
    --white: #FFFFFF;
    --border: #EAEAEA;
    --shadow: 0 10px 30px rgba(0, 0, 0, 0.05);
    --shadow-hover: 0 15px 40px rgba(255, 139, 167, 0.2);
    --radius: 20px;
    --radius-sm: 12px;
}

* { box-sizing: border-box; margin: 0; padding: 0; }

body {
    font-family: 'Quicksand', sans-serif;
    color: var(--text-color);
    background-color: var(--bg-color);
    background-image: radial-gradient(circle at top left, rgba(255, 139, 167, 0.05), transparent 40%),
                      radial-gradient(circle at bottom right, rgba(132, 220, 198, 0.05), transparent 40%);
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    line-height: 1.6;
}

h1, h2, h3, h4, h5, h6 {
    font-family: 'Nunito', sans-serif;
    font-weight: 800;
    line-height: 1.2;
}

.hidden { display: none !important; }

/* Hero Section */
.hero {
    position: relative;
    padding: 80px 20px;
    background-size: cover;
    background-position: center;
    color: var(--text-color);
    text-align: center;
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 40vh;
}

.hero::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(to bottom, rgba(255,255,255,0.2), rgba(255,255,255,0.5));
}

.hero-content {
    position: relative;
    z-index: 1;
    max-width: 800px;
    margin: 0 auto;
}

.hero-logo {
    max-width: 280px;
    height: auto;
    margin-bottom: 20px;
    background: rgba(255, 255, 255, 0.95);
    padding: 15px 25px;
    border-radius: var(--radius-sm);
    box-shadow: 0 4px 15px rgba(0,0,0,0.1);
}

.hero h1 {
    font-size: clamp(2.5rem, 5vw, 4rem);
    margin-bottom: 10px;
    text-shadow: 0 2px 10px rgba(255,255,255,0.8);
    color: var(--text-color);
}

#countdown {
    margin-top: 20px;
    font-size: 1.5rem;
    font-weight: 700;
    background: rgba(255,255,255,0.8);
    backdrop-filter: blur(10px);
    padding: 10px 20px;
    border-radius: 50px;
    display: inline-block;
    border: 1px solid rgba(255,255,255,0.9);
    color: var(--text-color);
    box-shadow: 0 4px 15px rgba(0,0,0,0.05);
}

/* Container */
.container {
    width: 100%;
    max-width: 1000px;
    margin: -40px auto 40px;
    padding: 0 20px;
    flex-grow: 1;
    position: relative;
    z-index: 2;
    display: flex;
    flex-direction: column;
}

/* Tabs */
.tabs {
    display: flex;
    justify-content: center;
    gap: 10px;
    margin-bottom: 30px;
}

.tab-btn {
    background: var(--white);
    border: none;
    padding: 15px 30px;
    font-size: 1.1rem;
    font-family: 'Nunito', sans-serif;
    font-weight: 700;
    color: var(--text-light);
    border-radius: 50px;
    cursor: pointer;
    box-shadow: var(--shadow);
    transition: all 0.3s ease;
}

.tab-btn:hover {
    color: var(--primary);
    transform: translateY(-2px);
}

.tab-btn.active {
    background: var(--primary);
    color: var(--white);
    box-shadow: var(--shadow-hover);
}

/* Cards */
.card {
    background: var(--white);
    border-radius: var(--radius);
    padding: 40px;
    box-shadow: var(--shadow);
    margin-bottom: 30px;
}

.text-center { text-align: center; }

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 14px 28px;
    border-radius: 50px;
    font-family: 'Nunito', sans-serif;
    font-weight: 700;
    font-size: 1.1rem;
    cursor: pointer;
    transition: all 0.3s ease;
    border: none;
    text-decoration: none;
}

.btn-block { width: 100%; }
.btn-sm { padding: 8px 16px; font-size: 0.9rem; }

.btn-primary {
    background: var(--primary);
    color: var(--white);
    box-shadow: 0 4px 15px rgba(255, 139, 167, 0.3);
}

.btn-primary:hover:not(:disabled) {
    background: var(--primary-hover);
    transform: translateY(-2px);
    box-shadow: var(--shadow-hover);
}

.btn-secondary {
    background: var(--secondary);
    color: var(--white);
    box-shadow: 0 4px 15px rgba(132, 220, 198, 0.3);
}

.btn-secondary:hover:not(:disabled) {
    background: var(--secondary-hover);
    transform: translateY(-2px);
}

.btn:disabled {
    background: #ccc;
    cursor: not-allowed;
    box-shadow: none;
    transform: none;
}

.btn-social {
    color: white;
    padding: 10px 20px;
    border-radius: 50px;
    text-decoration: none;
    font-weight: 700;
    font-size: 0.9rem;
}
.btn-social.fb { background: #1877F2; }
.btn-social.tw { background: #000000; }

/* Form Styles */
.form-group {
    margin-bottom: 25px;
    text-align: left;
}

label {
    display: block;
    margin-bottom: 8px;
    font-weight: 700;
    color: var(--text-color);
}

input[type="text"],
input[type="email"],
input[type="tel"],
input[type="number"],
input[type="file"] {
    width: 100%;
    padding: 15px;
    border: 2px solid var(--border);
    border-radius: var(--radius-sm);
    font-family: 'Quicksand', sans-serif;
    font-size: 1rem;
    transition: all 0.3s ease;
    background: #FAFAFA;
}

input[type="text"]:focus,
input[type="email"]:focus,
input[type="tel"]:focus,
input[type="number"]:focus,
input[type="file"]:focus {
    outline: none;
    border-color: var(--primary);
    background: var(--white);
    box-shadow: 0 0 0 4px rgba(255, 139, 167, 0.1);
}

/* Checkbox Group */
.checkbox-group {
    background: #FAFAFA;
    padding: 15px;
    border-radius: var(--radius-sm);
    border: 1px solid var(--border);
}

.checkbox-label {
    display: flex;
    align-items: flex-start;
    font-weight: 500;
    margin-bottom: 0;
    cursor: pointer;
}

.checkbox-label input[type="checkbox"] {
    margin-top: 3px;
    margin-right: 12px;
    width: 18px;
    height: 18px;
    accent-color: var(--primary);
    flex-shrink: 0;
    cursor: pointer;
}

.checkbox-label input[type="checkbox"]:focus {
    outline: 2px solid var(--primary);
    outline-offset: 2px;
}

.disclaimer-text {
    font-size: 0.85rem;
    line-height: 1.5;
    color: var(--text-light);
}

/* Upload Area */
.upload-area {
    position: relative;
    border: 2px dashed var(--border);
    border-radius: var(--radius-sm);
    padding: 40px 20px;
    text-align: center;
    background: #FAFAFA;
    cursor: pointer;
    transition: all 0.3s ease;
    overflow: hidden;
}

.upload-area:hover {
    border-color: var(--primary);
    background: rgba(255, 139, 167, 0.02);
}

.upload-area input[type="file"] {
    position: absolute;
    inset: 0;
    opacity: 0;
    cursor: pointer;
    height: 100%;
}

.upload-placeholder span {
    color: var(--text-light);
    font-weight: 600;
}

#photo-preview {
    max-width: 100%;
    max-height: 250px;
    border-radius: var(--radius-sm);
    object-fit: contain;
    position: relative;
    z-index: 1;
}

.error-message {
    background: #FFE5E5;
    color: #D32F2F;
    padding: 15px;
    border-radius: var(--radius-sm);
    margin-bottom: 20px;
    font-weight: 600;
    text-align: center;
}

/* Gallery Grid */
.gallery-header {
    text-align: center;
    margin-bottom: 30px;
}

.gallery-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 25px;
    margin-bottom: 40px;
}

.gallery-item {
    background: var(--white);
    border-radius: var(--radius);
    overflow: hidden;
    box-shadow: var(--shadow);
    transition: all 0.3s ease;
    cursor: pointer;
    position: relative;
}

.gallery-item:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-hover);
}

.gallery-img-wrapper {
    position: relative;
    padding-top: 100%; /* Square */
    overflow: hidden;
}

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

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

.gallery-info {
    padding: 15px;
    text-align: center;
}

.gallery-caption {
    font-weight: 700;
    margin-bottom: 5px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.gallery-author {
    font-size: 0.85rem;
    color: var(--text-light);
}

.vote-overlay {
    position: absolute;
    bottom: 15px;
    left: 0;
    right: 0;
    display: flex;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.3s ease;
}

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

.btn-vote {
    padding: 8px 16px;
    font-size: 0.9rem;
}

.btn-vote.voted {
    background: #EAEAEA;
    color: var(--text-light);
    box-shadow: none;
    cursor: default;
}

.vote-badge {
    position: absolute;
    top: 10px;
    right: 10px;
    background: rgba(255,255,255,0.9);
    padding: 5px 10px;
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: 700;
    color: var(--primary);
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
    backdrop-filter: blur(5px);
}

.empty-state {
    text-align: center;
    padding: 60px 20px;
    background: var(--white);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
}
.empty-state svg {
    color: var(--text-light);
    margin-bottom: 20px;
}
.empty-state h3 { margin-bottom: 10px; }
.empty-state p { margin-bottom: 25px; color: var(--text-light); }

.load-more-container { text-align: center; }

/* Lightbox */
.lightbox {
    position: fixed;
    inset: 0;
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: center;
}

.lightbox-overlay {
    position: absolute;
    inset: 0;
    background: rgba(0,0,0,0.85);
    backdrop-filter: blur(5px);
}

.lightbox-content {
    position: relative;
    z-index: 1;
    width: 100%;
    max-width: 900px;
    max-height: 90vh;
    display: flex;
    flex-direction: column;
    background: var(--bg-color);
    border-radius: var(--radius);
    overflow: hidden;
    box-shadow: 0 20px 60px rgba(0,0,0,0.5);
    margin: 20px;
}

.lightbox-close {
    position: absolute;
    top: 15px;
    right: 15px;
    background: rgba(0,0,0,0.5);
    color: white;
    border: none;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    font-size: 24px;
    cursor: pointer;
    z-index: 2;
    transition: background 0.3s;
}

.lightbox-close:hover { background: var(--primary); }

.lightbox-body {
    display: flex;
    flex-direction: column;
    height: 100%;
    overflow-y: auto;
}

@media (min-width: 768px) {
    .lightbox-body {
        flex-direction: row;
        overflow: hidden;
    }
}

.lightbox-body img {
    width: 100%;
    max-height: 60vh;
    object-fit: contain;
    background: #000;
}

@media (min-width: 768px) {
    .lightbox-body img {
        width: 65%;
        max-height: 90vh;
    }
}

.lb-info {
    padding: 30px;
    display: flex;
    flex-direction: column;
    flex-grow: 1;
}

.lb-info h3 { margin-bottom: 5px; font-size: 1.5rem; }
.lb-info .lb-author { color: var(--text-light); margin-bottom: 25px; }

.lb-actions {
    margin-top: auto;
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.vote-container {
    display: flex;
    align-items: center;
    gap: 15px;
}

.vote-count { font-weight: 700; color: var(--primary); }

.lightbox-nav {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(255,255,255,0.2);
    backdrop-filter: blur(5px);
    color: white;
    border: none;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    font-size: 30px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s;
}

.lightbox-nav:hover { background: var(--primary); }
.lightbox-nav.prev { left: -70px; }
.lightbox-nav.next { right: -70px; }
@media (max-width: 1040px) {
    .lightbox-nav.prev { left: 10px; }
    .lightbox-nav.next { right: 10px; }
}

/* Post Entry / Success */
.success-icon {
    font-size: 4rem;
    margin-bottom: 10px;
}
.my-entry-preview {
    margin: 30px 0;
    display: inline-block;
    background: #FAFAFA;
    padding: 15px;
    border-radius: var(--radius-sm);
    border: 1px solid var(--border);
}
.my-entry-preview img {
    max-width: 250px;
    border-radius: 8px;
    margin-bottom: 10px;
}
.caption-text { font-weight: 700; font-size: 1.1rem; }

.share-panel {
    background: rgba(132, 220, 198, 0.1);
    padding: 30px;
    border-radius: var(--radius-sm);
    margin-top: 20px;
    border: 1px dashed var(--secondary);
}

.share-input-group {
    display: flex;
    gap: 10px;
    margin: 20px 0;
}
.share-input-group input { margin-bottom: 0; background: var(--white); }

.social-shares {
    display: flex;
    justify-content: center;
    gap: 15px;
    flex-wrap: wrap;
}

#wbx-powered-by-slot {
    margin-top: 40px;
    display: flex;
    justify-content: center;
}
