/* ============================================================
   WADAI Resources Page - Professional UI/UX Design
   ============================================================ */

/* Remove main padding for Resources Page */
main.wad-main {
    padding-top: 0 !important;
}

:root {
    --wadai-red: #d90217;
    --wadai-red-dark: #a60112;
    --wadai-red-light: #ef233c;
    --wadai-red-soft: rgba(217, 2, 23, 0.08);
    --wadai-red-medium: rgba(217, 2, 23, 0.15);
    --wadai-text-black: #1a1a1a;
    --wadai-text-gray: #6c757d;
    --wadai-text-light: #9ca3af;
    --wadai-light-grey: #e9ecef;
    --wadai-bg-light: #f8f9fa;
    --wadai-white: #ffffff;
    --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.04);
    --shadow-md: 0 4px 16px rgba(0, 0, 0, 0.08);
    --shadow-lg: 0 8px 32px rgba(0, 0, 0, 0.12);
    --shadow-xl: 0 16px 48px rgba(0, 0, 0, 0.16);
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    --transition-slow: all 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}

/* ========== Hero Section ========== */
.resources-hero {
    position: relative;
    min-height: 60vh;
    display: flex;
    align-items: center;
    padding: 2rem 0 4rem;
    background: linear-gradient(180deg, #ffffff 0%, #f8f9fa 50%, #ffffff 100%);
    overflow: hidden;
    margin-top: 0;
}

.hero-background {
    position: absolute;
    inset: 0;
    z-index: 0;
    overflow: hidden;
}

.hero-shapes {
    position: absolute;
    inset: 0;
}

.shape {
    position: absolute;
    border-radius: 50%;
    background: radial-gradient(circle, var(--wadai-red-soft) 0%, transparent 70%);
    animation: floatShape 25s ease-in-out infinite;
    opacity: 0.6;
}

.shape-1 {
    width: 300px;
    height: 300px;
    top: -100px;
    right: -50px;
    animation-delay: 0s;
}

.shape-2 {
    width: 250px;
    height: 250px;
    bottom: -80px;
    left: -40px;
    animation-delay: 5s;
}

.shape-3 {
    width: 200px;
    height: 200px;
    top: 40%;
    right: 20%;
    animation-delay: 10s;
}

@keyframes floatShape {
    0%, 100% { 
        transform: translate(0, 0) scale(1) rotate(0deg); 
        opacity: 0.6;
    }
    33% { 
        transform: translate(40px, -40px) scale(1.1) rotate(120deg); 
        opacity: 0.8;
    }
    66% { 
        transform: translate(-30px, 30px) scale(0.9) rotate(240deg); 
        opacity: 0.5;
    }
}

.hero-content {
    position: relative;
    z-index: 1;
    text-align: center;
    max-width: 900px;
    margin: 0 auto;
}

.hero-title {
    font-size: clamp(2.5rem, 6vw, 4rem);
    font-weight: 800;
    line-height: 1.15;
    color: var(--wadai-text-black);
    margin-bottom: 1.75rem;
    letter-spacing: -0.03em;
}

.hero-subtitle {
    font-size: clamp(1.15rem, 2vw, 1.4rem);
    color: var(--wadai-text-gray);
    font-weight: 400;
    line-height: 1.7;
    margin-bottom: 3rem;
    max-width: 700px;
    margin-left: auto;
    margin-right: auto;
}

.hero-cta {
    margin-bottom: 2rem;
}

.btn-primary-large {
    display: inline-flex;
    align-items: center;
    gap: 0.75rem;
    padding: 1.125rem 2.75rem;
    background: linear-gradient(135deg, var(--wadai-red) 0%, var(--wadai-red-dark) 100%);
    color: white;
    border: none;
    border-radius: 50px;
    font-weight: 700;
    font-size: 1.1rem;
    text-decoration: none;
    box-shadow: var(--shadow-lg);
    transition: var(--transition);
    position: relative;
    overflow: hidden;
}

.btn-primary-large:hover {
    transform: translateY(-3px);
    box-shadow: 0 12px 40px rgba(217, 2, 23, 0.4);
    color: white;
}

.btn-primary-large i {
    transition: transform 0.3s ease;
}

.btn-primary-large:hover i {
    transform: translateY(4px);
}

/* ========== Section Styles ========== */
.section-header {
    text-align: center;
    margin-bottom: 3.5rem;
}

.section-label {
    display: inline-block;
    padding: 0.5rem 1.25rem;
    background: rgba(217, 2, 23, 0.1);
    border-radius: 50px;
    color: var(--wadai-red);
    font-size: 0.8rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.8px;
    margin-bottom: 1.25rem;
}

.section-title {
    font-size: clamp(2rem, 4.5vw, 2.75rem);
    font-weight: 800;
    color: var(--wadai-text-black);
    margin-bottom: 1rem;
    line-height: 1.3;
    letter-spacing: -0.02em;
}

.section-description {
    font-size: 1.15rem;
    color: var(--wadai-text-gray);
    max-width: 600px;
    margin: 0 auto;
    line-height: 1.7;
}

/* ========== Resource Categories Section ========== */
.resources-categories {
    padding: 5rem 0;
    background: white;
}

.categories-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 2rem;
}

.category-card {
    background: white;
    border-radius: 1.5rem;
    padding: 2.5rem 2rem;
    text-align: center;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
    border: 2px solid rgba(0, 0, 0, 0.08);
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
}

.category-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, var(--wadai-red) 0%, var(--wadai-red-dark) 100%);
    transform: scaleX(0);
    transform-origin: left;
    transition: transform 0.4s ease;
}

.category-card:hover::before {
    transform: scaleX(1);
}

.category-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 20px 50px rgba(217, 2, 23, 0.2);
    border-color: var(--wadai-red);
}

.category-icon {
    width: 72px;
    height: 72px;
    background: rgba(217, 2, 23, 0.12);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1.5rem;
    box-shadow: 0 4px 15px rgba(217, 2, 23, 0.2);
    transition: all 0.3s ease;
}

.category-icon i {
    font-size: 2rem;
    color: var(--wadai-red);
}

.category-card:hover .category-icon {
    transform: scale(1.1) rotate(5deg);
    background: rgba(217, 2, 23, 0.2);
    box-shadow: 0 8px 25px rgba(217, 2, 23, 0.3);
}

.category-title {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--wadai-text-black);
    margin-bottom: 1rem;
}

.category-description {
    font-size: 1rem;
    line-height: 1.7;
    color: var(--wadai-text-gray);
    margin-bottom: 1.5rem;
}

.category-link {
    color: var(--wadai-red);
    text-decoration: none;
    font-weight: 600;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    transition: var(--transition);
}

.category-link:hover {
    gap: 0.75rem;
    color: var(--wadai-red-dark);
}

/* ========== Featured Resources Section ========== */
.featured-resources {
    padding: 5rem 0;
    background: #f8f9fa;
}

.featured-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
}

.resource-card {
    background: white;
    border-radius: 1.5rem;
    padding: 2.5rem;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
    border: 2px solid rgba(0, 0, 0, 0.08);
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

.resource-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, var(--wadai-red) 0%, var(--wadai-red-dark) 100%);
    transform: scaleX(0);
    transform-origin: left;
    transition: transform 0.4s ease;
}

.resource-card:hover::before {
    transform: scaleX(1);
}

.resource-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 20px 50px rgba(217, 2, 23, 0.2);
    border-color: var(--wadai-red);
}

.resource-type-icon {
    width: 60px;
    height: 60px;
    background: rgba(217, 2, 23, 0.12);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 1.5rem;
    transition: all 0.3s ease;
}

.resource-type-icon i {
    font-size: 1.75rem;
    color: var(--wadai-red);
}

.resource-type-icon.video {
    background: rgba(217, 2, 23, 0.15);
}

.resource-card:hover .resource-type-icon {
    transform: scale(1.1) rotate(-5deg);
    background: rgba(217, 2, 23, 0.2);
}

.resource-type {
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--wadai-red);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 0.75rem;
    display: block;
}

.resource-title {
    font-size: 1.4rem;
    font-weight: 700;
    color: var(--wadai-text-black);
    margin-bottom: 1rem;
    line-height: 1.3;
}

.resource-description {
    font-size: 1rem;
    line-height: 1.7;
    color: var(--wadai-text-gray);
    margin-bottom: 1.5rem;
    flex: 1;
}

.resource-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-bottom: 1.5rem;
}

.tag {
    padding: 0.4rem 0.9rem;
    background: rgba(217, 2, 23, 0.1);
    color: var(--wadai-red);
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: 500;
}

.resource-cta {
    color: var(--wadai-red);
    text-decoration: none;
    font-weight: 600;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    transition: var(--transition);
}

.resource-cta:hover {
    gap: 0.75rem;
    color: var(--wadai-red-dark);
}

/* ========== Search & Filter Section ========== */
.search-filter-section {
    padding: 3rem 0;
    background: white;
}

.search-container {
    margin-bottom: 2rem;
}

.search-box {
    max-width: 800px;
    margin: 0 auto;
    position: relative;
    display: flex;
    align-items: center;
}

.search-box i {
    position: absolute;
    left: 1.5rem;
    color: var(--wadai-text-gray);
    font-size: 1.25rem;
    z-index: 1;
}

.search-input {
    width: 100%;
    padding: 1.25rem 1.25rem 1.25rem 3.5rem;
    border: 2px solid rgba(0, 0, 0, 0.08);
    border-radius: 50px;
    font-size: 1rem;
    transition: var(--transition);
    background: white;
}

.search-input:focus {
    outline: none;
    border-color: var(--wadai-red);
    box-shadow: 0 0 0 4px rgba(217, 2, 23, 0.1);
}

.filter-container {
    display: flex;
    justify-content: center;
}

.filter-pills {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    justify-content: center;
}

.filter-pill {
    padding: 0.75rem 1.5rem;
    background: white;
    border: 2px solid rgba(0, 0, 0, 0.08);
    border-radius: 50px;
    font-size: 0.95rem;
    font-weight: 600;
    color: var(--wadai-text-gray);
    cursor: pointer;
    transition: var(--transition);
}

.filter-pill:hover,
.filter-pill.active {
    background: var(--wadai-red);
    color: white;
    border-color: var(--wadai-red);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(217, 2, 23, 0.3);
}

/* ========== Resources Grid Section ========== */
.resources-grid-section {
    padding: 3rem 0 5rem;
    background: #f8f9fa;
}

.resources-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
}

.resource-card.hidden {
    display: none;
}

/* ========== Testimonials Section ========== */
.resources-testimonials {
    padding: 5rem 0;
    background: white;
}

.testimonials-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
}

.testimonial-card {
    background: white;
    border-radius: 1.5rem;
    padding: 2.5rem;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
    border: 2px solid rgba(0, 0, 0, 0.08);
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
}

.testimonial-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 20px 50px rgba(217, 2, 23, 0.15);
    border-color: var(--wadai-red-soft);
}

.testimonial-quote {
    font-size: 3rem;
    color: var(--wadai-red-soft);
    margin-bottom: 1.5rem;
    line-height: 1;
}

.testimonial-text {
    font-size: 1.1rem;
    line-height: 1.8;
    color: var(--wadai-text-gray);
    margin-bottom: 2rem;
    font-style: italic;
}

.testimonial-author {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.author-info {
    flex: 1;
}

.author-name {
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--wadai-text-black);
    margin-bottom: 0.25rem;
}

.author-role {
    font-size: 0.9rem;
    color: var(--wadai-text-gray);
    margin: 0;
}

/* ========== Call to Action Section ========== */
.resources-cta {
    padding: 5rem 0;
    background: #f8f9fa;
    position: relative;
    overflow: hidden;
}

.cta-background {
    position: absolute;
    inset: 0;
    z-index: 0;
}

.cta-pattern {
    position: absolute;
    inset: 0;
    background-image: 
        radial-gradient(circle at 20% 30%, rgba(217, 2, 23, 0.04) 0%, transparent 50%),
        radial-gradient(circle at 80% 70%, rgba(217, 2, 23, 0.04) 0%, transparent 50%);
    opacity: 0.6;
}

.cta-content {
    position: relative;
    z-index: 1;
    text-align: center;
    max-width: 800px;
    margin: 0 auto;
}

.cta-title {
    font-size: clamp(2rem, 4vw, 2.75rem);
    font-weight: 800;
    color: var(--wadai-text-black);
    margin-bottom: 1.25rem;
    line-height: 1.3;
}

.cta-description {
    font-size: 1.2rem;
    line-height: 1.7;
    color: var(--wadai-text-gray);
    margin-bottom: 2.5rem;
}

.cta-buttons {
    display: flex;
    gap: 1.5rem;
    justify-content: center;
    flex-wrap: wrap;
}

.btn-secondary-large {
    display: inline-flex;
    align-items: center;
    gap: 0.75rem;
    padding: 1.125rem 2.75rem;
    background: white;
    color: var(--wadai-red);
    border: 2px solid var(--wadai-red);
    border-radius: 50px;
    font-weight: 700;
    font-size: 1.1rem;
    text-decoration: none;
    box-shadow: var(--shadow-md);
    transition: var(--transition);
    position: relative;
    overflow: hidden;
}

.btn-secondary-large::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, var(--wadai-red) 0%, var(--wadai-red-dark) 100%);
    transform: scaleX(0);
    transform-origin: left;
    transition: transform 0.3s ease;
    z-index: 0;
}

.btn-secondary-large:hover::before {
    transform: scaleX(1);
}

.btn-secondary-large:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow-lg);
    color: white;
    border-color: var(--wadai-red);
}

.btn-secondary-large span,
.btn-secondary-large i {
    position: relative;
    z-index: 1;
}

.btn-secondary-large i {
    transition: transform 0.3s ease;
}

.btn-secondary-large:hover i {
    transform: translateX(4px);
}

/* ========== Animations ========== */
[data-animate] {
    opacity: 0;
    transition: opacity 0.8s ease, transform 0.8s ease;
}

[data-animate="fadeInUp"] {
    transform: translateY(40px);
}

[data-animate].animated {
    opacity: 1;
    transform: translate(0, 0);
}

/* ========== Responsive Design ========== */
@media (max-width: 1200px) {
    .categories-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .featured-grid,
    .resources-grid,
    .testimonials-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 991.98px) {
    .resources-hero {
        min-height: 50vh;
        padding: 2rem 0 3rem;
    }
    
    .categories-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .resources-hero {
        min-height: auto;
        padding: 1.5rem 0 2.5rem;
    }
    
    .categories-grid,
    .featured-grid,
    .resources-grid,
    .testimonials-grid {
        grid-template-columns: 1fr;
    }
    
    .cta-buttons {
        flex-direction: column;
        align-items: stretch;
    }
    
    .btn-primary-large,
    .btn-secondary-large {
        width: 100%;
        justify-content: center;
    }
}

