/*
Theme Name: Benih Harapan
Theme URI: https://benihharapan.com
Author: Benih Team
Author URI: https://benihharapan.com
Description: Custom crowdfunding theme for Benih Harapan platform
Version: 1.0.0
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: benih-harapan
Tags: crowdfunding, donations, campaigns

This theme, like WordPress, is licensed under the GPL.
*/

/* ========================================
   Custom Fonts
======================================== */
@font-face {
    font-family: 'Lilita One';
    src: url('fonts/LILITAONE-REGULAR.TTF') format('truetype');
    font-weight: normal;
    font-style: normal;
    font-display: swap;
}

/* ========================================
   CSS Reset & Base Styles
======================================== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --color-primary: #2c3e50;
    --color-secondary: #3498db;
    --color-accent: #e74c3c;
    --color-success: #27ae60;
    --color-text: #333333;
    --color-text-light: #7f8c8d;
    --color-bg: #ffffff;
    --color-bg-dark: #1a1a1a;
    --color-border: #e0e0e0;
    --color-card-bg: #f8f9fa;
}

body {
    font-family: 'Lilita One', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    font-size: 16px;
    line-height: 1.6;
    color: var(--color-text);
    background-color: var(--color-bg);
}

a {
    color: var(--color-secondary);
    text-decoration: none;
    transition: all 0.3s ease;
}

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

/* ========================================
   Header & Navigation
======================================== */
.site-header {
    min-height: 116px;
    color: #ffffff;
    position: sticky;
    top: 0;
    z-index: 1000;
    overflow: hidden;
}

.header-bg-image-wrapper {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 0;
    pointer-events: none;
}

.header-bg-image {
    width: 100%;
    height: auto;
    display: block;
    object-fit: cover;
    object-position: top;
    opacity: 1;
    pointer-events: none;
    user-select: none;
}

.header-container {
    position: relative;
    z-index: 1;
}

.header-container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.site-branding {
    font-size: 1.5rem;
    font-weight: 700;
    color: #ffffff;
    letter-spacing: 1px;
}

.main-navigation ul {
    list-style: none;
    display: flex;
    gap: 2rem;
    align-items: center;
}

.main-navigation a {
    color: #ffffff;
    font-weight: 500;
    transition: color 0.3s;
}

.main-navigation a:hover {
    color: var(--color-secondary);
}

.header-actions {
    display: flex;
    gap: 1rem;
}

.btn-login,
.btn-register {
    padding: 0.5rem 1.5rem;
    border-radius: 6px;
    font-weight: 500;
    transition: all 0.3s;
}

.btn-login {
    background: transparent;
    color: #ffffff;
    border: 1px solid rgba(255, 255, 255, 0.3);
}

.btn-login:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: #ffffff;
}

.btn-register {
    background: var(--color-secondary);
    color: #ffffff;
}

.btn-register:hover {
    background: var(--color-accent);
}

/* ========================================
   Hero Section (Featured Campaign)
======================================== */
.hero-section {
    max-width: 1400px;
    margin: 2rem auto;
    padding: 0 2rem;
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 2rem;
}

.featured-campaign {
    background: var(--color-primary);
    border-radius: 20px;
    padding: 3rem;
    min-height: 400px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
    color: #ffffff;
    border: 2px solid rgba(255, 255, 255, 0.1);
}

.featured-campaign-link {
    text-decoration: none;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.featured-campaign-link::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, rgba(52, 152, 219, 0.1), rgba(39, 174, 96, 0.1));
    opacity: 0;
    transition: opacity 0.3s ease;
    pointer-events: none;
}

.featured-campaign-link:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 30px rgba(52, 152, 219, 0.3);
    border-color: var(--color-secondary);
}

.featured-campaign-link:hover::before {
    opacity: 1;
}

.featured-campaign-link:hover h1 {
    color: var(--color-secondary);
}

.featured-campaign-link:hover .featured-amount {
    transform: scale(1.05);
}

.featured-campaign h1 {
    font-size: 2.5rem;
    margin-bottom: 1rem;
    font-weight: 700;
    transition: color 0.3s ease;
}

.featured-amount {
    font-size: 1.5rem;
    margin-bottom: 0.5rem;
    color: var(--color-success);
    transition: transform 0.3s ease;
}

.featured-donors {
    font-size: 1.1rem;
    opacity: 0.9;
}

/* ========================================
   Leaderboard
======================================== */
.leaderboard-widget {
    background: var(--color-primary);
    border-radius: 20px;
    padding: 1.5rem;
    color: #ffffff;
}

.leaderboard-header {
    text-align: center;
    margin-bottom: 1.5rem;
}

.leaderboard-header h2 {
    font-size: 1.2rem;
    margin-bottom: 1rem;
}

.leaderboard-tabs {
    display: flex;
    gap: 0.5rem;
    background: rgba(0, 0, 0, 0.2);
    padding: 0.25rem;
    border-radius: 8px;
}

.tab-btn {
    flex: 1;
    padding: 0.5rem;
    background: transparent;
    color: #ffffff;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    font-weight: 500;
    transition: all 0.3s;
}

.tab-btn.active {
    background: var(--color-secondary);
}

.leaderboard-list {
    list-style: none;
}

.leaderboard-item {
    display: flex;
    justify-content: space-between;
    padding: 0.75rem 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.leaderboard-item:last-child {
    border-bottom: none;
}

.leaderboard-rank {
    font-weight: 700;
    margin-right: 1rem;
}

.leaderboard-name {
    flex: 1;
}

.leaderboard-projects {
    color: var(--color-success);
    font-weight: 600;
}

/* ========================================
   Other Projects Section
======================================== */
.other-projects {
    max-width: 1400px;
    margin: 3rem auto;
    padding: 0 2rem;
}

.other-projects h2 {
    color: #ffffff;
    font-size: 1.5rem;
    margin-bottom: 2rem;
}

.projects-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 2rem;
}

/* ========================================
   Campaign Card
======================================== */
.campaign-card {
    background: var(--color-primary);
    border-radius: 20px;
    overflow: hidden;
    border: 2px solid rgba(255, 255, 255, 0.1);
    transition: transform 0.3s, box-shadow 0.3s;
}

.campaign-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
}

.campaign-header {
    padding: 1rem;
    text-align: center;
    color: #ffffff;
    font-weight: 600;
    font-size: 1.4rem;
}

.campaign-image {
    width: 100%;
    height: 250px;
    background: rgba(0, 0, 0, 0.3);
    display: flex;
    align-items: center;
    justify-content: center;
    color: rgba(255, 255, 255, 0.5);
    font-size: 1.5rem;
}

.campaign-progress {
    padding: 1rem;
    text-align: center;
    color: #ffffff;
}

.progress-fraction {
    font-size: 1.5rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
}

.progress-meta {
    display: flex;
    justify-content: space-around;
    font-size: 0.85rem;
    margin-top: 1rem;
    padding-top: 1rem;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.meta-item span {
    display: block;
    color: rgba(255, 255, 255, 0.7);
    margin-bottom: 0.25rem;
}

.meta-value {
    color: #ffffff;
    font-weight: 600;
}

.campaign-footer {
    padding: 1rem;
    background: rgba(0, 0, 0, 0.2);
}

.donor-info {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.donor-group {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.donor-label {
    color: var(--color-secondary);
    font-size: 0.85rem;
    font-weight: 600;
}

.group-name {
    color: #ffffff;
    font-size: 0.9rem;
}

.raised-amount {
    color: rgba(255, 255, 255, 0.7);
    font-size: 0.85rem;
}

.goal-amount {
    color: #ffffff;
    font-weight: 600;
}

/* ========================================
   CTA Buttons Section
======================================== */
.cta-section {
    max-width: 1400px;
    margin: 3rem auto;
    padding: 0 2rem;
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
}

.cta-box {
    background: var(--color-primary);
    border-radius: 20px;
    padding: 3rem 2rem;
    text-align: center;
    color: #ffffff;
    border: 2px solid rgba(255, 255, 255, 0.1);
    min-height: 150px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    font-weight: 600;
    transition: all 0.3s;
    cursor: pointer;
}

.cta-box:hover {
    transform: translateY(-5px);
    background: var(--color-secondary);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
}

/* ========================================
   Footer
======================================== */
.site-footer {
    background: var(--color-bg-dark);
    color: #ffffff;
    padding: 2rem 0 1rem;
    margin-top: 4rem;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

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

.footer-top {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2rem;
}

.footer-branding {
    font-size: 1.3rem;
    font-weight: 700;
}

.footer-links {
    display: flex;
    gap: 2rem;
}

.footer-link {
    color: rgba(255, 255, 255, 0.7);
    font-size: 0.9rem;
}

.footer-link:hover {
    color: #ffffff;
}

.footer-bottom {
    text-align: right;
    padding-top: 1rem;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.footer-platform {
    color: rgba(255, 255, 255, 0.7);
    font-size: 0.9rem;
    margin-bottom: 0.5rem;
}

.footer-contact {
    color: rgba(255, 255, 255, 0.5);
    font-size: 0.85rem;
}

/* ========================================
   Responsive Design
======================================== */
@media (max-width: 1024px) {
    .hero-section {
        grid-template-columns: 1fr;
    }
    
    .cta-section {
        grid-template-columns: 1fr;
    }
    
    .projects-grid {
        grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    }
}

@media (max-width: 768px) {
    /* Mobile Layout - Vertical Stack */
    body {
        background-color: #000000;
    }
    
    .header-container {
        padding: 0 1rem;
        flex-direction: row;
        justify-content: space-between;
    }
    
    .site-branding {
        font-size: 1rem;
        line-height: 1.2;
    }
    
    /* Hide main nav on mobile */
    .main-navigation {
        display: none;
    }
    
    .header-actions {
        flex-direction: row;
        gap: 0.5rem;
    }
    
    .btn-login,
    .btn-register {
        padding: 0.4rem 1rem;
        font-size: 0.85rem;
    }
    
    /* Mobile Hero - Vertical Stack */
    .hero-section {
        grid-template-columns: 1fr;
        gap: 1rem;
        margin: 1rem auto;
        padding: 0 1rem;
    }
    
    /* Featured Campaign Mobile */
    .featured-campaign {
        padding: 2rem 1.5rem;
        min-height: 200px;
        border-radius: 15px;
    }
    
    .featured-campaign h1 {
        font-size: 1.5rem;
        margin-bottom: 0.75rem;
    }
    
    .featured-amount {
        font-size: 1.2rem;
    }
    
    .featured-donors {
        font-size: 0.95rem;
    }
    
    /* Leaderboard Mobile - Full Width Below Featured */
    .leaderboard-widget {
        order: 2;
        padding: 1rem;
        border-radius: 15px;
    }
    
    .leaderboard-header h2 {
        font-size: 1.1rem;
        margin-bottom: 0.75rem;
    }
    
    .leaderboard-tabs {
        gap: 0.25rem;
    }
    
    .tab-btn {
        padding: 0.4rem;
        font-size: 0.9rem;
    }
    
    .leaderboard-item {
        padding: 0.5rem 0;
        font-size: 0.9rem;
    }
    
    .leaderboard-rank {
        font-size: 0.85rem;
    }
    
    .leaderboard-projects {
        font-size: 0.85rem;
    }
    
    /* Other Projects Mobile */
    .other-projects {
        margin: 1.5rem auto;
        padding: 0 1rem;
    }
    
    .other-projects h2 {
        font-size: 1.2rem;
        margin-bottom: 1rem;
    }
    
    /* Projects Grid - Single Column */
    .projects-grid {
        grid-template-columns: 1fr;
        gap: 1rem;
    }
    
    /* Campaign Cards Mobile - Smaller */
    .campaign-card {
        border-radius: 15px;
    }
    
    .campaign-header {
        padding: 0.75rem;
        font-size: 1.2rem;
    }
    
    .campaign-image {
        height: 180px;
        font-size: 1.2rem;
    }
    
    .campaign-progress {
        padding: 0.75rem;
    }
    
    .progress-fraction {
        font-size: 1.2rem;
    }
    
    .progress-meta {
        font-size: 0.8rem;
        margin-top: 0.75rem;
        padding-top: 0.75rem;
    }
    
    .campaign-footer {
        padding: 0.75rem;
    }
    
    .donor-info {
        flex-direction: column;
        gap: 0.5rem;
        align-items: flex-start;
    }
    
    .donor-group {
        gap: 0.5rem;
    }
    
    .donor-label {
        font-size: 0.8rem;
    }
    
    .group-name {
        font-size: 0.85rem;
    }
    
    .raised-amount,
    .goal-amount {
        font-size: 0.8rem;
    }
    
    /* CTA Section Mobile */
    .cta-section {
        grid-template-columns: 1fr;
        gap: 1rem;
        margin: 1.5rem auto;
        padding: 0 1rem;
    }
    
    .cta-box {
        padding: 2rem 1.5rem;
        min-height: 100px;
        font-size: 1.2rem;
        border-radius: 15px;
    }
    
    /* Footer Mobile */
    .site-footer {
        margin-top: 2rem;
        padding: 1.5rem 0 1rem;
    }
    
    .footer-container {
        padding: 0 1rem;
    }
    
    .footer-top {
        flex-direction: column;
        gap: 1rem;
        text-align: center;
    }
    
    .footer-branding {
        font-size: 1.1rem;
    }
    
    .footer-links {
        flex-direction: row;
        justify-content: center;
        gap: 1rem;
        flex-wrap: wrap;
    }
    
    .footer-link {
        font-size: 0.85rem;
    }
    
    .footer-bottom {
        text-align: center;
        padding-top: 1rem;
    }
    
    .footer-platform {
        font-size: 0.85rem;
    }
    
    .footer-contact {
        font-size: 0.8rem;
    }
}

/* ========================================
   HEADER WITH IMAGE BACKGROUND
======================================== */
.site-header-wave {
    position: sticky;
    top: 0;
    z-index: 1000;
    width: 100%;
    overflow: hidden; /* Contain header within body width */
}

.header-bg-wrapper {
    position: relative;
    width: 100%;
    height: auto;
    overflow: hidden; /* Prevent image from overflowing */
}

.header-bg-image {
    width: 100%;
    height: auto;
    display: block;
}

.header-content-container {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    max-width: 100%; /* Respect parent body max-width (480px) */
    margin: 0 auto;
    padding: 15px 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.header-logo .logo-img {
    width: 60px;
    height: 60px;
    object-fit: contain;
}

.header-notification {
    position: relative;
}

.header-auth-buttons {
    display: flex;
    align-items: center;
    gap: 10px;
}

.btn-login-header {
    padding: 10px 24px;
    background: #FFFFFF;
    color: #14b8a6;
    border-radius: 8px;
    font-weight: 600;
    font-size: 14px;
    text-decoration: none;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
    display: inline-block;
}

.btn-login-header:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    background: #f0f0f0;
}

.notification-icon {
    position: relative;
    width: 50px;
    height: 50px;
    background: #FFFFFF;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
}

.notification-icon:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.notification-icon i {
    font-size: 24px;
    color: #666666;
}

.notification-dot {
    position: absolute;
    top: 8px;
    right: 8px;
    width: 12px;
    height: 12px;
    background: #F1FF4D;
    border: 2px solid #FFFFFF;
    border-radius: 50%;
}

/* ========================================
   MOBILE BOTTOM NAVIGATION WITH IMAGE BACKGROUND
======================================== */
.mobile-nav-container {
    position: fixed;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    max-width: 480px;
    width: 100%;
    z-index: 999;
    height: auto;
    pointer-events: none;
}

.nav-bg-image {
    width: 100%;
    height: auto;
    display: block;
}

.mobile-bottom-nav {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    display: flex;
    justify-content: space-around;
    align-items: center;
    padding: 20px 30px 25px;
    pointer-events: auto;
}

.mobile-bottom-nav .nav-item {
    display: flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    transition: all 0.3s ease;
}

.mobile-bottom-nav .nav-item:hover {
    transform: translateY(-3px);
}

.mobile-bottom-nav .nav-icon {
    width: 42px;
    height: 42px;
    object-fit: contain;
    filter: brightness(0) invert(1);
}

.mobile-bottom-nav .nav-item.active .nav-icon {
    filter: brightness(0) invert(1);
    transform: scale(1.1);
}

/* ========================================
   BOTTOM NAVIGATION (Global)
======================================== */
.bottom-navigation {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: #14b8a6;
    display: flex;
    justify-content: space-around;
    align-items: center;
    padding: 15px 0;
    box-shadow: 0 -3px 10px rgba(0, 0, 0, 0.1);
    z-index: 1000;
}

.bottom-navigation .nav-item {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    color: rgba(255, 255, 255, 0.7);
    font-size: 22px;
    text-decoration: none;
    transition: all 0.3s;
}

.bottom-navigation .nav-item:hover {
    color: #FFFFFF;
}

.bottom-navigation .nav-item.active {
    background: #FFFFFF;
    color: #14b8a6;
}

@media (max-width: 768px) {
    body.has-mobile-nav .site-main {
        padding-bottom: 140px;
    }

    /* Ensure main content containers use full width on mobile */
    .container,
    .main-content,
    .site-content,
    .site-main {
        width: 100% !important;
        max-width: none !important;
        padding-left: 0 !important;
        padding-right: 0 !important;
        margin-left: 0 !important;
        margin-right: 0 !important;
    }
}

/* =====================================================
   BENIH CROWDFUNDING - COMMUNITIES & GROUPS
   ===================================================== */

/* Communities List Page */
.community-content {
    max-width: 500px;
    width: 100%;
    margin: 40px auto;
    padding: 20px;
    background: #FFFFFF;
}

.communities-container {
    background: white;
    border-radius: 20px;
    padding: 30px 20px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.08);
    margin-bottom: 20px;
}

.communities-title {
    color: #14b8a6;
    font-size: 38px;
    font-weight: 700;
    text-align: center;
    margin-bottom: 25px;
}

.community-list {
    list-style: none;
    margin: 0;
    padding: 0;
}

.community-item {
    background: #f8f9fa;
    padding: 18px 20px;
    margin-bottom: 12px;
    border-radius: 12px;
    font-size: 18px;
    font-weight: 500;
    color: #1f2937;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.community-item:hover {
    background: #e5e7eb;
    transform: translateX(5px);
}

.community-item-number {
    margin-right: 10px;
}

.community-item-name {
    flex: 1;
}

.community-arrow {
    color: #14b8a6;
    font-size: 16px;
}

.empty-state {
    text-align: center;
    padding: 40px 20px;
    color: #6b7280;
}

.empty-state-icon {
    font-size: 64px;
    margin-bottom: 15px;
    opacity: 0.5;
}

.empty-state-text {
    font-size: 18px;
    margin-bottom: 20px;
}

/* Guest Message Box */
.guest-message-box {
    text-align: center;
    padding: 60px 20px;
    background: linear-gradient(135deg, #f0fdfa 0%, #e0f2fe 100%);
    border-radius: 20px;
    margin: 20px 0;
}

.guest-icon {
    font-size: 72px;
    margin-bottom: 20px;
    opacity: 0.8;
}

.guest-message-box h2 {
    color: #0f766e;
    font-size: 28px;
    font-weight: 700;
    margin-bottom: 15px;
}

.guest-message-box p {
    color: #475569;
    font-size: 16px;
    margin-bottom: 30px;
    line-height: 1.5;
}

.btn-login-guest {
    display: inline-block;
    background: linear-gradient(135deg, #14b8a6 0%, #0d9488 100%);
    color: white;
    padding: 14px 40px;
    border-radius: 50px;
    font-weight: 600;
    font-size: 16px;
    text-decoration: none;
    margin: 8px;
    box-shadow: 0 4px 20px rgba(20, 184, 166, 0.3);
    transition: all 0.3s ease;
}

.btn-login-guest:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 25px rgba(20, 184, 166, 0.4);
}

.btn-register-guest {
    display: inline-block;
    background: white;
    color: #14b8a6;
    padding: 14px 40px;
    border-radius: 50px;
    font-weight: 600;
    font-size: 16px;
    text-decoration: none;
    margin: 8px;
    border: 2px solid #14b8a6;
    transition: all 0.3s ease;
}

.btn-register-guest:hover {
    background: #f0fdfa;
    transform: translateY(-2px);
}

/* Create Group Button */
.create-group-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    background: white;
    color: #14b8a6;
    font-size: 20px;
    font-weight: 700;
    padding: 12px 30px;
    border-radius: 50px;
    text-decoration: none;
    box-shadow: 0 4px 20px rgba(91, 91, 91, 0.3);
    transition: all 0.3s ease;
    width: auto;
    max-width: 306px;
    margin: 0 auto;
}

.create-group-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 25px rgba(91, 91, 91, 0.4);
    color: #0d9488;
}

.create-group-btn::before {
    content: '+';
    font-size: 32px;
    font-weight: 700;
    line-height: 1;
}

/* Create Group Form Page */
.create-group-page {
    padding: 20px;
    background: #FFFFFF;
}

.back-button-container {
    margin-bottom: 15px;
    max-width: 500px;
    margin-left: auto;
    margin-right: auto;
}

.back-button {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: transparent;
    border: none;
    color: #14b8a6;
    font-size: 16px;
    font-weight: 700;
    text-decoration: none;
    transition: all 0.3s ease;
}

.back-button i {
    width: 20px;
    height: 20px;
    background: #F1FF4D;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 10px;
    color: #333333;
}

.back-button:hover {
    transform: translateX(-3px);
}

.create-group-content {
    max-width: 500px;
    width: 100%;
    margin: 0 auto;
    padding: 20px;
    background: #ffffff;
}

.page-title {
    color: #14b8a6;
    font-size: 28px;
    font-weight: 700;
    text-align: center;
    margin-bottom: 20px;
}

/* Photo Upload */
.photo-upload-section {
    display: flex;
    flex-direction: column;
    align-items: center;
    margin-bottom: 20px;
}

.photo-preview {
    width: 100px;
    height: 100px;
    border-radius: 50%;
    background: #d1d5db;
    margin-bottom: 12px;
    position: relative;
    overflow: hidden;
    cursor: pointer;
}

.photo-preview img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.photo-preview-placeholder {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 32px;
    color: #9ca3af;
}

.upload-button {
    display: flex;
    align-items: center;
    gap: 8px;
    background: #14b8a6;
    color: white;
    padding: 10px 20px;
    border-radius: 8px;
    cursor: pointer;
    font-size: 14px;
    font-weight: 600;
    transition: all 0.3s ease;
}

.upload-button:hover {
    background: #0d9488;
    transform: translateY(-2px);
}

.upload-button::before {
    content: '↑';
    width: 20px;
    height: 20px;
    background: white;
    color: #14b8a6;
    border-radius: 4px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    font-weight: 700;
}

#group_photo {
    display: none;
}

/* Group Form */
.group-form {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.form-input {
    width: 100%;
    padding: 14px 16px;
    border: none;
    border-radius: 12px;
    font-size: 14px;
    background: white;
    box-shadow: 0 2px 10px rgba(0,0,0,0.05);
    transition: all 0.3s ease;
}

.form-input::placeholder {
    color: #d1d5db;
}

.form-input:focus {
    outline: none;
    box-shadow: 0 4px 15px rgba(20, 184, 166, 0.2);
    transform: translateY(-2px);
}

textarea.form-input {
    min-height: 90px;
    resize: vertical;
    font-family: inherit;
}

/* Submit Button */
.submit-button {
    background: #14b8a6;
    color: white;
    font-size: 18px;
    font-weight: 700;
    padding: 14px 32px;
    border: none;
    border-radius: 50px;
    cursor: pointer;
    margin-top: 15px;
    transition: all 0.3s ease;
    box-shadow: 0 4px 20px rgba(20, 184, 166, 0.3);
}

.submit-button:hover {
    background: #0d9488;
    transform: translateY(-2px);
    box-shadow: 0 6px 25px rgba(20, 184, 166, 0.4);
}

.submit-button:disabled {
    background: #9ca3af;
    cursor: not-allowed;
    transform: none;
}

/* Success Overlay */
.success-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.95);
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 9999;
    animation: fadeIn 0.3s ease;
}

.success-overlay.show {
    display: flex;
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

.success-content {
    text-align: center;
    animation: scaleIn 0.5s ease;
}

@keyframes scaleIn {
    from {
        transform: scale(0.8);
        opacity: 0;
    }
    to {
        transform: scale(1);
        opacity: 1;
    }
}

.success-text {
    color: #14b8a6;
    font-size: 32px;
    font-weight: 700;
    margin-bottom: 12px;
    text-transform: uppercase;
}

.success-message {
    color: #14b8a6;
    font-size: 24px;
    font-weight: 600;
    margin-bottom: 40px;
}

.success-button {
    background: #14b8a6;
    color: white;
    font-size: 24px;
    font-weight: 700;
    padding: 16px 60px;
    border: none;
    border-radius: 50px;
    cursor: pointer;
    text-transform: uppercase;
    box-shadow: 0 8px 30px rgba(20, 184, 166, 0.5);
    transition: all 0.3s ease;
}

.success-button:hover {
    transform: translateY(-3px);
    box-shadow: 0 12px 40px rgba(20, 184, 166, 0.6);
}

/* Responsive Styles */
@media (max-width: 600px) {
    .communities-title {
        font-size: 32px;
    }

    .community-item {
        font-size: 16px;
        padding: 15px 18px;
    }

    .create-group-btn {
        font-size: 18px;
        padding: 10px 25px;
    }
    
    .create-group-btn::before {
        font-size: 28px;
    }

    .page-title {
        font-size: 36px;
    }

    .success-text {
        font-size: 32px;
    }

    .success-message {
        font-size: 24px;
    }

    .success-button {
        font-size: 24px;
        padding: 15px 60px;
    }
}

/* =====================================================
   JOIN GROUP WITH INVITE CODE - MODERN UX
   ===================================================== */

.join-with-code-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    background: linear-gradient(135deg, #14b8a6 0%, #0d9488 100%);
    color: white;
    font-size: 18px;
    font-weight: 700;
    padding: 12px 30px;
    border-radius: 50px;
    text-decoration: none;
    box-shadow: 0 4px 20px rgba(20, 184, 166, 0.3);
    transition: all 0.3s ease;
    width: auto;
    max-width: 306px;
    margin: 0 auto 20px;
}

.join-with-code-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 25px rgba(20, 184, 166, 0.5);
    background: linear-gradient(135deg, #0d9488 0%, #14b8a6 100%);
}

.join-with-code-btn::before {
    content: '🔗';
    font-size: 24px;
    line-height: 1;
}

/* Join Group Modal */
.join-group-modal {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.8);
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 9999;
    animation: fadeIn 0.3s ease;
}

.join-group-modal.show {
    display: flex;
}

.join-group-modal-content {
    background: white;
    border-radius: 20px;
    padding: 40px 30px;
    max-width: 400px;
    width: 90%;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.3);
    animation: slideUp 0.4s ease;
    position: relative;
}

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

.join-modal-close {
    position: absolute;
    top: 15px;
    right: 15px;
    background: #f0f0f0;
    border: none;
    border-radius: 50%;
    width: 36px;
    height: 36px;
    cursor: pointer;
    font-size: 20px;
    color: #666;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
}

.join-modal-close:hover {
    background: #e0e0e0;
    transform: rotate(90deg);
}

.join-modal-title {
    color: #14b8a6;
    font-size: 28px;
    font-weight: 700;
    text-align: center;
    margin-bottom: 10px;
}

.join-modal-subtitle {
    color: #6b7280;
    font-size: 14px;
    text-align: center;
    margin-bottom: 30px;
}

.invite-code-input-wrapper {
    position: relative;
    margin-bottom: 20px;
}

.invite-code-input {
    width: 100%;
    padding: 16px 50px 16px 16px;
    border: 2px solid #e5e7eb;
    border-radius: 12px;
    font-size: 16px;
    font-weight: 500;
    letter-spacing: 1px;
    transition: all 0.3s ease;
    text-transform: uppercase;
}

.invite-code-input:focus {
    outline: none;
    border-color: #14b8a6;
    box-shadow: 0 0 0 4px rgba(20, 184, 166, 0.1);
}

.invite-code-input::placeholder {
    text-transform: none;
    letter-spacing: normal;
    color: #d1d5db;
}

.paste-btn {
    position: absolute;
    right: 8px;
    top: 50%;
    transform: translateY(-50%);
    background: #f0f0f0;
    border: none;
    border-radius: 8px;
    padding: 8px 12px;
    cursor: pointer;
    font-size: 12px;
    font-weight: 600;
    color: #14b8a6;
    transition: all 0.3s ease;
}

.paste-btn:hover {
    background: #14b8a6;
    color: white;
}

.join-submit-btn {
    width: 100%;
    background: linear-gradient(135deg, #14b8a6 0%, #0d9488 100%);
    color: white;
    font-size: 18px;
    font-weight: 700;
    padding: 16px 32px;
    border: none;
    border-radius: 50px;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 20px rgba(20, 184, 166, 0.3);
}

.join-submit-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 25px rgba(20, 184, 166, 0.5);
}

.join-submit-btn:disabled {
    background: #9ca3af;
    cursor: not-allowed;
    transform: none;
    box-shadow: none;
}

.join-help-text {
    color: #6b7280;
    font-size: 13px;
    text-align: center;
    margin-top: 20px;
    line-height: 1.6;
}

.join-help-text strong {
    color: #14b8a6;
}

/* Success State */
.join-success-state {
    display: none;
    text-align: center;
    padding: 20px 0;
}

.join-success-state.show {
    display: block;
}

.join-success-icon {
    font-size: 64px;
    margin-bottom: 20px;
    animation: scaleIn 0.5s ease;
}

.join-success-title {
    color: #14b8a6;
    font-size: 24px;
    font-weight: 700;
    margin-bottom: 10px;
}

.join-success-message {
    color: #6b7280;
    font-size: 16px;
    margin-bottom: 30px;
}

.join-success-btn {
    background: #14b8a6;
    color: white;
    font-size: 16px;
    font-weight: 700;
    padding: 12px 40px;
    border: none;
    border-radius: 50px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.join-success-btn:hover {
    background: #0d9488;
    transform: translateY(-2px);
}

/* Loading State */
.join-loading {
    display: none;
    text-align: center;
    padding: 20px 0;
}

.join-loading.show {
    display: block;
}

.join-loading-spinner {
    width: 50px;
    height: 50px;
    border: 4px solid #e5e7eb;
    border-top-color: #14b8a6;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin: 0 auto 20px;
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

.join-loading-text {
    color: #6b7280;
    font-size: 14px;
}

/* Error Message */
.join-error-message {
    display: none;
    background: #fee2e2;
    border: 1px solid #fecaca;
    border-radius: 8px;
    padding: 12px;
    margin-bottom: 20px;
    color: #dc2626;
    font-size: 14px;
    text-align: center;
}

.join-error-message.show {
    display: block;
    animation: shake 0.5s ease;
}

@keyframes shake {
    0%, 100% { transform: translateX(0); }
    25% { transform: translateX(-10px); }
    75% { transform: translateX(10px); }
}

@media (max-width: 600px) {
    .join-with-code-btn {
        font-size: 16px;
        padding: 10px 25px;
    }

    .join-group-modal-content {
        padding: 30px 20px;
    }

    .join-modal-title {
        font-size: 24px;
    }

    .invite-code-input {
        font-size: 14px;
    }
}
