/* ========================================
   HOMEPAGE - REBUILT FROM SCRATCH
   Mobile First Design
======================================== */

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

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

body {
    font-family: 'Lilita One', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    background: #FFFFFF !important;
    color: #333333;
}

/* ========================================
   HEADER WITH WAVE BACKGROUND
======================================== */
.site-header-new {
    position: relative;
    width: 100%;
    height: 108px;
    background: linear-gradient(135deg, #1CA9BA 0%, #00A99D 100%);
    overflow: visible;
}

.header-wave-bg::after {
    content: '';
    position: absolute;
    bottom: -30px;
    left: 0;
    width: 100%;
    height: 50px;
    background: linear-gradient(135deg, #1CA9BA 0%, #00A99D 100%);
    border-radius: 0 0 50% 50% / 0 0 100% 100%;
}

.header-content-wrapper {
    position: relative;
    max-width: 440px;
    margin: 0 auto;
    height: 108px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 20px;
    z-index: 10;
}

.header-logo {
    position: relative;
}

.logo-icon {
    display: block;
    width: 54px;
    height: 54px;
}

.logo-icon svg {
    width: 100%;
    height: 100%;
    filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.1));
}

.header-notification {
    position: relative;
}

.notification-icon {
    position: relative;
    width: 49px;
    height: 49px;
    background: #FFFFFF;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    cursor: pointer;
    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: #FFD700;
    border: 2px solid #FFFFFF;
    border-radius: 50%;
}

/* ========================================
   MAIN CONTENT AREA
======================================== */
.mobile-homepage {
    position: relative;
    max-width: 440px;
    margin: 0 auto;
    background: #FCFCFC;
    min-height: calc(100vh - 108px);
    padding-top: 20px;
    padding-bottom: 10px;
}

/* ========================================
   FEATURED PROJECT SECTION
======================================== */
.featured-section-v2 {
    padding: 0 15px 30px;
}

.featured-title-section {
    text-align: center;
    margin-bottom: 20px;
}

.featured-title-section h2 {
    font-size: 28px;
    font-weight: 700;
    color: #00A99D;
    margin: 0;
}

.featured-card-v2 {
    position: relative;
    width: 100%;
}

.featured-link-wrapper {
    display: block;
    text-decoration: none;
    color: inherit;
}

.featured-img-container {
    position: relative;
    width: 100%;
    height: 211px;
    border-radius: 20px;
    overflow: hidden;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
}

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

.featured-img-placeholder {
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, #E0E0E0 0%, #BDBDBD 100%);
}

/* Overlay only on right half */
.featured-overlay-right {
    position: absolute;
    top: 0;
    right: 0;
    width: 50%;
    height: 100%;
    background: linear-gradient(90deg, rgba(0, 0, 0, 0) 0%, rgba(0, 0, 0, 0.75) 30%, rgba(0, 0, 0, 0.9) 100%);
    display: flex;
    align-items: flex-end;
    padding: 15px 12px;
}

.overlay-content {
    width: 100%;
    color: #FFFFFF;
}

.project-name {
    font-size: 14px;
    font-weight: 700;
    margin: 0 0 6px 0;
    line-height: 1.3;
}

.project-meta-info {
    display: flex;
    flex-direction: column;
    gap: 3px;
    margin-bottom: 8px;
    font-size: 9px;
    opacity: 0.95;
}

.meta-location {
    display: block;
}

.meta-time {
    display: block;
}

.meta-time i {
    font-size: 8px;
    margin-right: 2px;
}

.project-amount-big {
    font-size: 20px;
    font-weight: 700;
    margin-bottom: 3px;
    color: #FFFFFF;
}

.project-donors-count {
    font-size: 11px;
    margin-bottom: 10px;
    opacity: 0.9;
}

.project-actions-bottom {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
}

.progress-dots-row {
    display: flex;
    gap: 4px;
}

.progress-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.4);
    border: 1px solid rgba(255, 255, 255, 0.6);
}

.btn-donate-teal {
    background: #00A99D;
    color: #FFFFFF;
    border: none;
    padding: 6px 16px;
    border-radius: 20px;
    font-size: 11px;
    font-weight: 600;
    cursor: pointer;
    white-space: nowrap;
    transition: all 0.3s;
}

.btn-donate-teal:hover {
    background: #138496;
    transform: scale(1.05);
}

.more-info-text {
    font-size: 10px;
    color: #FFFFFF;
    white-space: nowrap;
}

/* ========================================
   OTHER PROJECTS TO FUND SECTION
======================================== */
.other-projects-section {
    padding: 30px 20px;
    background: #FFFFFF;
}

.section-title-bar {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 20px;
}

.title-highlight {
    width: 32px;
    height: 8px;
    background: #F1FF4D;
    border-radius: 4px;
}

.section-title-bar h2 {
    font-size: 22px;
    font-weight: 700;
    color: #00A99D;
    margin: 0;
}

.other-projects-list {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.project-card {
    background: #FFFFFF;
    border-radius: 20px;
    overflow: hidden;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
}

.project-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
}

.project-card-link {
    display: flex;
    flex-direction: row;
    text-decoration: none;
    color: inherit;
}

/* Left side - Thumbnail */
.project-card-thumbnail {
    position: relative;
    width: 35%;
    min-width: 130px;
    height: 160px;
    overflow: hidden;
    flex-shrink: 0;
    padding: 10px;
}

.card-thumb-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 12px;
}

.card-thumb-placeholder {
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, #E0E0E0 0%, #BDBDBD 100%);
    border-radius: 12px;
}

.thumbnail-overlay {
    position: absolute;
    bottom: 18px;
    left: 18px;
    right: 18px;
    background: rgba(0, 0, 0, 0.75);
    padding: 5px 8px;
    border-radius: 6px;
}

.overlay-time {
    font-size: 9px;
    color: #FFFFFF;
    display: flex;
    align-items: center;
    gap: 3px;
    line-height: 1.2;
}

.overlay-time i {
    font-size: 8px;
}

/* Right side - Content */
.project-card-info {
    flex: 1;
    padding: 10px 12px 10px 0;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    align-items: flex-end;
}

.card-info-title {
    font-size: 15px;
    font-weight: 700;
    color: #333333;
    margin: 0 0 2px 0;
    line-height: 1.2;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    text-align: left;
    width: 100%;
}

.card-info-location {
    font-size: 11px;
    color: #757575;
    margin: 0 0 6px 0;
    line-height: 1.2;
    text-align: left;
    width: 100%;
}

.card-info-amount-raised {
    font-size: 20px;
    font-weight: 700;
    color: #00A99D;
    margin-bottom: 3px;
    line-height: 1.1;
    text-align: right;
    width: 100%;
}

.card-info-amount-goal {
    font-size: 13px;
    font-weight: 600;
    color: #333333;
    background: #F1FF4D;
    padding: 3px 10px;
    border-radius: 12px;
    display: inline-block;
    align-self: flex-end;
    margin-bottom: 2px;
    line-height: 1.1;
}

.info-donors {
    font-size: 11px;
    color: #00A99D;
    font-weight: 600;
    text-align: right;
    line-height: 1.2;
    margin-bottom: 0;
    width: 100%;
}

.card-info-footer {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 0;
    margin-top: 6px;
    width: 100%;
}

.info-more-link {
    font-size: 11px;
    color: #757575;
    font-weight: 500;
    text-align: right;
    line-height: 1.2;
}

/* ========================================
   LEADERBOARD SECTION
======================================== */
.leaderboard-section {
    padding: 30px 15px 100px;
    background: #FFFFFF;
}

.leaderboard-card {
    background: #FFFFFF;
    border-radius: 30px;
    overflow: hidden;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
    border-bottom: 25px solid #00A99D;
}

.leaderboard-title {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    padding: 20px 15px 15px;
    background: #FFFFFF;
}

.title-highlight-left,
.title-highlight-right {
    width: 40px;
    height: 8px;
    background: #F1FF4D;
    border-radius: 4px;
}

.leaderboard-title h2 {
    font-size: 24px;
    font-weight: 700;
    color: #00A99D;
    margin: 0;
}

.leaderboard-tabs {
    display: grid;
    grid-template-columns: 1fr 1fr;
    background: #00A99D;
    padding: 0;
    gap: 0;
    margin: 0;
}

.tab-button {
    padding: 15px 20px;
    font-size: 18px;
    font-weight: 700;
    border: none;
    cursor: pointer;
    transition: all 0.3s ease;
    background: #0D7C8A;
    color: rgba(255, 255, 255, 0.5);
    text-transform: capitalize;
}

.tab-button.active {
    background: #00A99D;
    color: #FFFFFF;
}

.tab-button:hover {
    opacity: 0.9;
}

.leaderboard-content {
    background: #FFFFFF;
    position: relative;
}

.tab-content {
    display: none;
}

.tab-content.active {
    display: block;
}

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

.leaderboard-item {
    display: grid;
    grid-template-columns: 40px 1fr auto;
    align-items: center;
    padding: 14px 20px;
    gap: 12px;
    font-size: 15px;
}

.leaderboard-item.odd {
    background: #F5F5F5;
}

.leaderboard-item.even {
    background: #FFFFFF;
}

.leaderboard-item .rank {
    font-weight: 700;
    color: #333333;
    font-size: 16px;
}

.leaderboard-item .name {
    font-weight: 600;
    color: #333333;
}

.leaderboard-item .count {
    font-weight: 600;
    color: #333333;
    font-size: 14px;
    text-align: right;
}

/* Placeholder for next sections */


/* ========================================
   FEATURED SECTION
======================================== */
.featured-section {
    position: relative;
    width: 100%;
    padding: 0 15px;
    margin-top: 20px;
}

.featured-title-banner {
    position: relative;
    width: 100%;
    margin-bottom: 15px;
    text-align: center;
}

.featured-title-banner h2 {
    font-size: 28px;
    font-weight: 700;
    color: #00A99D;
    margin: 0;
}

.featured-card-main {
    position: relative;
    display: block;
    width: 100%;
    border-radius: 20px;
    overflow: hidden;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    text-decoration: none;
    color: inherit;
}

.featured-img-wrapper {
    position: relative;
    width: 100%;
    aspect-ratio: 16/9;
    overflow: hidden;
}

.featured-img-wrapper img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.featured-placeholder {
    width: 100%;
    height: 100%;
    background: #E0E0E0;
}

.featured-info-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(180deg, rgba(0, 0, 0, 0) 0%, rgba(0, 0, 0, 0.85) 50%);
    padding: 60px 20px 20px;
    color: #FFFFFF;
}

.featured-project-title {
    font-size: 18px;
    font-weight: 700;
    margin: 0 0 8px 0;
    color: #FFFFFF;
}

.featured-project-meta {
    font-size: 11px;
    margin-bottom: 12px;
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    opacity: 0.95;
}

.featured-amount-display {
    font-size: 32px;
    font-weight: 700;
    color: #FFFFFF;
    margin-bottom: 4px;
}

.featured-donors-info {
    font-size: 14px;
    margin-bottom: 16px;
    opacity: 0.9;
}

.featured-bottom-actions {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
}

.progress-dots-indicator {
    display: flex;
    gap: 6px;
    align-items: center;
}

.progress-dots-indicator .dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.4);
    border: 1px solid rgba(255, 255, 255, 0.6);
}

.progress-dots-indicator .dot.active {
    background: #FFFFFF;
}

.btn-donate-featured {
    background: #00A99D;
    color: #FFFFFF;
    border: none;
    padding: 10px 24px;
    border-radius: 25px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s;
}

.btn-donate-featured:hover {
    background: #138496;
    transform: scale(1.05);
}

.more-info-link {
    font-size: 12px;
    color: #FFFFFF;
    white-space: nowrap;
}

/* ========================================
   OTHER PROJECTS SECTION
======================================== */
.other-projects-section-new {
    position: relative;
    padding: 30px 15px 20px;
}

.section-title-other {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 20px;
}

.title-bar-yellow {
    width: 80px;
    height: 8px;
    background: #C8E265;
    border-radius: 4px;
}

.section-title-other h2 {
    font-size: 24px;
    font-weight: 700;
    color: #00A99D;
    margin: 0;
}

.projects-list-wrapper {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.other-project-card {
    position: relative;
    display: grid;
    grid-template-columns: 120px 1fr;
    gap: 12px;
    padding: 12px;
    background: #FFFFFF;
    border-radius: 12px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    text-decoration: none;
    color: inherit;
    transition: all 0.3s;
}

.other-project-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.other-project-img {
    position: relative;
    width: 120px;
    height: 120px;
    border-radius: 10px;
    overflow: hidden;
}

.other-project-img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.other-placeholder {
    width: 100%;
    height: 100%;
    background: #E0E0E0;
}

.other-time-badge {
    position: absolute;
    bottom: 6px;
    left: 6px;
    right: 6px;
    background: rgba(0, 0, 0, 0.8);
    color: #FFFFFF;
    font-size: 9px;
    padding: 4px 6px;
    border-radius: 4px;
    text-align: center;
}

.other-project-details {
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.other-project-details h3 {
    font-size: 14px;
    font-weight: 700;
    margin: 0 0 4px 0;
    color: #333333;
    line-height: 1.3;
}

.other-location {
    font-size: 11px;
    color: #666666;
    margin: 0 0 10px 0;
}

.other-amounts-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 10px;
}

.other-raised {
    font-size: 16px;
    font-weight: 700;
    color: #00A99D;
}

.other-goal {
    font-size: 13px;
    font-weight: 600;
    color: #333333;
    background: #C8E265;
    padding: 4px 12px;
    border-radius: 12px;
}

.other-footer-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 11px;
}

.other-donors {
    color: #00A99D;
    font-weight: 600;
}

.other-more-link {
    color: #666666;
}

/* ========================================
   LEADERBOARD SECTION
======================================== */
.leaderboard-section-new {
    position: relative;
    padding: 30px 15px 40px;
}

.section-title-leaderboard-new {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    margin-bottom: 25px;
}

.title-bar-yellow-left,
.title-bar-yellow-right {
    width: 60px;
    height: 8px;
    background: #C8E265;
    border-radius: 4px;
}

.section-title-leaderboard-new h2 {
    font-size: 24px;
    font-weight: 700;
    color: #00A99D;
    margin: 0;
}

.leaderboard-card-wrapper {
    position: relative;
    background: linear-gradient(135deg, #00A99D 0%, #1B98A6 100%);
    border-radius: 20px;
    padding: 20px 16px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
}

.leaderboard-tabs-new {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
    margin-bottom: 20px;
}

.lb-tab-btn {
    background: rgba(255, 255, 255, 0.25);
    color: #FFFFFF;
    border: none;
    padding: 12px;
    border-radius: 10px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s;
}

.lb-tab-btn.active {
    background: #FFFFFF;
    color: #00A99D;
}

.leaderboard-table-wrapper {
    position: relative;
}

.leaderboard-table {
    display: none;
}

.leaderboard-table.active {
    display: block;
}

.lb-list {
    list-style: none;
    padding: 0;
    margin: 0;
    background: #FFFFFF;
    border-radius: 12px;
    overflow: hidden;
}

.lb-row {
    display: grid;
    grid-template-columns: 40px 1fr 1fr;
    gap: 8px;
    padding: 12px 16px;
    align-items: center;
    background: #FFFFFF;
}

.lb-row.lb-alt {
    background: #F5F5F5;
}

.lb-rank {
    font-size: 14px;
    font-weight: 700;
    color: #00A99D;
}

.lb-name {
    font-size: 14px;
    font-weight: 600;
    color: #333333;
}

.lb-project {
    font-size: 13px;
    color: #666666;
    text-align: right;
}

/* ========================================
   RESPONSIVE - SMALL SCREENS
======================================== */
@media (max-width: 380px) {
    .other-projects-section {
        padding: 30px 15px;
    }
    
    .project-card-thumbnail {
        min-width: 110px;
        height: 140px;
    }
    
    .project-card-info {
        padding: 10px 12px;
    }
    
    .card-info-title {
        font-size: 14px;
    }
    
    .card-info-amount-raised {
        font-size: 18px;
    }
    
    .card-info-amount-goal {
        font-size: 12px;
        padding: 2px 8px;
    }
}

/* ========================================
   RESPONSIVE - TABLET & UP
======================================== */
@media (min-width: 768px) {
    .mobile-homepage {
        max-width: 768px;
        padding-bottom: 0;
    }
    
    .featured-section,
    .other-projects-section,
    .other-projects-section-new,
    .leaderboard-section-new {
        padding-left: 30px;
        padding-right: 30px;
    }
    
    /* Keep single column for mobile container */
    .other-projects-list {
        display: flex;
        flex-direction: column;
        gap: 15px;
    }
    
    .project-card-thumbnail {
        width: 40%;
        height: 180px;
    }
    
    /* Keep single column for projects in mobile container */
    .projects-list-wrapper {
        display: flex;
        flex-direction: column;
        gap: 20px;
    }
    
    .other-project-card {
        grid-template-columns: 120px 1fr;
    }
    
    .other-project-img {
        width: 120px;
        height: 120px;
    }
    
    .leaderboard-card-wrapper {
        max-width: 600px;
        margin: 0 auto;
    }
}

@media (min-width: 1024px) {
    .mobile-homepage {
        max-width: 1200px;
    }
    
    .featured-section,
    .other-projects-section-new,
    .leaderboard-section-new {
        padding-left: 50px;
        padding-right: 50px;
    }
    
    .featured-card-main {
        max-width: 900px;
        margin: 0 auto;
    }
}
