/* 
 * About Page Styles
 * Styles for the About page template
 */

/*
 * 1. Base Styles & Typography
 * Basic typography and shared styles across the page
 */

/* Consolidated heading styles */
.about-section h2,
.founder-content h2 {
    font-size: clamp(2rem, 4vw, 2.8rem);
    margin-bottom: 1.5rem;
    color: var(--c-fg);
    line-height: 1.2;
    font-weight: 700;
}


/*
 * 2. Section Variants & Layout
 * Different section background colors and spacing
 */

/* Section variants */
.about-section--dark {
    background-color: #000;
    color: #fff;
}

/* Dark section text colors */
.about-section--dark h2,
.about-section--dark h3 {
    color: #fff;
}

.about-section--dark p {
    color: rgba(255, 255, 255, 0.7);
}

.about-section--dark .section-tag {
    background-color: rgba(125, 237, 6, 0.2);
    color: var(--c-accent);
}

/* Section padding - standardized for consistency */
.about-intro-section {
    padding: 2rem 0 4rem;
}

.about-founder-section,
.about-work-section,
.about-services-section,
.about-resources-section {
    padding: 4.5rem 0;
}



/*
 * 3. UI Components
 * Reusable UI components across the page
 */

/* Section tag styling */
.section-tag {
    display: inline-block;
    padding: 0.5rem 1rem;
    background-color: var(--c-fg, #1F1F1F);
    color: #ffffff;
    border-radius: 50px;
    font-size: 0.9rem;
    font-weight: 500;
    margin-bottom: 1rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/*
 * 4. Layout Components
 * Grid and structural layout components
 */

/* Grid layouts - simplified and optimized */
.about-section__grid {
    display: grid;
    grid-template-columns: 4fr 3fr;
    gap: 4rem;
    align-items: center;
}

/* Reverse grid using RTL direction */
.about-section__grid--reverse {
    grid-template-columns: 4fr 3fr;
    direction: rtl;
}

.about-section__grid--reverse .about-section__content,
.about-section__grid--reverse .about-section__image {
    direction: ltr;
}

/* Section headers - consolidated styles */
.about-section__header {
    text-align: center;
    margin: 0 auto 3rem;
}

/* Intro section content */
.about-intro-content {
    margin: 0 auto;
    text-align: center;
    max-width: 900px;
}

/* Special case for intro section header */
.about-intro-section .about-section__header {
    width: 100%;
    margin-bottom: 2rem;
}

/* Content styling */
.about-section__content h3 {
    font-size: clamp(1.5rem, 3vw, 1.8rem);
    margin: 2rem 0 1rem;
    color: var(--c-fg);
    font-weight: 600;
}

.about-section__content h4 {
    font-size: clamp(1.2rem, 2.5vw, 1.5rem);
    margin-bottom: 0.5rem;
    color: var(--c-fg);
    font-weight: 600;
}

/* Image styling - simplified */
.about-section__image {
    display: flex;
    justify-content: center;
    align-items: center;
}

.about-section__image img {
    width: 100%;
    height: auto;
    border-radius: var(--about-card-radius);
    box-shadow: var(--about-card-shadow);
    object-fit: cover;
}

/*
 * 5. Work Principles
 * Styling for the work principles section
 */

/* Work principles layout */
.work-principles {
    display: flex;
    flex-direction: column;
    gap: 0;
    margin-top: 2.5rem;
}

.work-principle {
    display: grid;
    grid-template-columns: minmax(200px, 1fr) 3fr;
    gap: 2rem;
    padding: 2rem 0;
    border-bottom: 1px solid #e0e4e2;
    align-items: flex-start;
}

.work-principle:first-child {
    padding-top: 0;
}

.work-principle:last-child {
    border-bottom: none;
}

.work-principle__title h3 {
    font-size: clamp(1.35rem, 3vw, 1.5rem);
    margin: 0;
    color: var(--c-fg);
    font-weight: 600;
}

.work-principle__content p {
    margin-bottom: 0;
    max-width: 900px;
}

/* Responsive adjustments for work principles */
@media (max-width: 768px) {
    .work-principle {
        grid-template-columns: 1fr;
        gap: 0.75rem;
        padding: 1.5rem 0;
    }
    
    .work-principle__title h3 {
        margin-bottom: 0.5rem;
    }
}

/*
 * 6. Service Cards
 * Service card components matching homepage design
 */

/* Services grid - Matching homepage service card design */
.services-section__grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 1.75rem;
    margin-top: 1rem;
}

/* Specific override for about page service grid to ensure 2 columns */
.about-services-section .services-section__grid {
    grid-template-columns: repeat(2, 1fr);
}

@media (max-width: 767px) {
    .about-services-section .services-section__grid {
        grid-template-columns: 1fr;
    }
}

.service-card {
    background-color: var(--c-card-bg, #1a1a1a);
    border: 1px solid var(--c-card-border, #333);
    border-radius: 8px;
    padding: 2rem;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.service-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.3);
}

.service-card__icon {
    margin-bottom: 1.5rem;
    color: var(--c-accent);
}

.service-card__header {
    margin-top: 0;
    margin-bottom: 1rem;
    font-size: clamp(1.25rem, 3vw, 1.4rem);
    color: var(--c-card-heading, white);
}

/* Override the general paragraph styles for service card descriptions */
.about-section .service-card__description {
    font-size: clamp(1.15rem, 2vw, 1.25rem);
    margin-bottom: 1.5rem;
    color: var(--c-card-text, #ccc);
    line-height: 1.65;
}

.service-card__link {
    font-weight: 600;
    color: var(--c-accent);
    text-decoration: underline;
    text-underline-offset: 3px;
    display: inline-flex;   
    align-items: center;
}

.service-card__link:hover {
    text-decoration: underline;
}

/*
 * 6. Founder Section
 * Founder profile and content layout
 */

/* Founder section - consolidated styles */
/* Ensure the founder section uses 5fr 3fr grid layout */
.about-founder-section .about-section__grid {
    display: grid;
    grid-template-columns: 5fr 3fr;
    gap: 4rem;
    align-items: center;
}

.founder-content {
    padding-right: 2rem;
}

.founder-image {
    display: flex;
    justify-content: center;
    align-items: center;
}

.founder-image .image-wrapper {
    position: relative;
    max-width: 100%;
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 8px;
    overflow: hidden;
}

.founder-image img {
    width: 100%;
    height: auto;
    object-fit: cover;
    display: block;
}

.founder-image .image-wrapper::after {
    content: '';
    background-image: linear-gradient(to bottom, transparent 50%, rgba(0, 0, 0, 0.7));
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 1;
    pointer-events: none;
}

/* Founder name and social icons overlay */
.founder-overlay {
    position: absolute;
    bottom: 2rem;
    left: 2rem;
    z-index: 3;
    color: white;
}

.founder-name {
    font-size: 1.6rem;
    font-weight: 600;
    margin: 0 0 0.75rem;
}

.founder-social {
    display: flex;
    gap: 1rem;
}

.founder-social a {
    display: flex;
    align-items: center;
    justify-content: center;
    transition: transform 0.2s ease;
}

.founder-social img {
    width: 32px;
    height: 32px;
}

.founder-social a:hover {
    transform: translateY(-3px);
}

/*
 * 7. Resources Section
 * Resources list and content layout
 */

/* Resources section */
/* Friends section with two columns */
.friends-container {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 3rem;
    margin-top: 3rem;
}

.friends-column-title {
    font-size: clamp(1.35rem, 3vw, 1.5rem);
    margin: 0 0 1.5rem;
    color: var(--c-fg);
}

.resources-container {
    display: flex;
    flex-direction: column;
    gap: 2.5rem;
    margin-top: 2rem;
}

.resource-row {
    display: grid;
    grid-template-columns: 1fr 2fr;
    gap: 2rem;
    padding-top: 1rem;
    align-items: flex-start;
    border-bottom: 1px solid #e0e4e2;
}

.resource-row:last-child {
    border-bottom: none;
    padding-bottom: 0;
}

.resource-name h3,
.resource-name h4 {
    font-size: clamp(1.1rem, 2vw, 1.2rem);
    margin: 0 0 0.5rem;
    color: var(--c-fg-dark, #1a1a1a);
}

.resource-name h4 a {
    color: var(--c-fg);
    text-decoration: underline;
    text-underline-offset: 2px;
    text-decoration-thickness: 2px;
    text-decoration-color: var(--c-fg);
}

.resource-name h4 a:hover {
    text-decoration-thickness: 3px;
}

.resource-description p {
    color: var(--c-fg-light, #333);
    font-size: clamp(1.1rem, 2vw, 1.15rem);
    margin-bottom: 1rem;
}

/*
 * 9. Responsive Styles
 * Media queries for different screen sizes
 */

/* Tablet and smaller screens */
@media (max-width: 992px) {
    /* Unified section padding for consistency */
    .about-intro-section {
        padding: 2rem 0 2.5rem;
    }

    /* Grid layout adjustments */
    .about-section__grid,
    .about-section__grid--reverse,
    .about-founder-section .about-section__grid {
        grid-template-columns: 1fr;
        gap: 3rem;
        direction: ltr;
    }
    
    /* Control visual order in responsive layout */
    .about-section__grid--reverse .about-section__image {
        order: 1;
    }
    
    .about-section__grid--reverse .about-section__content {
        order: 2;
    }
    
    /* Special case for founder section - image below content */
    .founder-content {
        order: 1;
    }
    
    .founder-image {
        order: 2;
    }
}

/* Mobile-specific adjustments */
@media (max-width: 768px) {
    /* Resources layout for mobile */
    .friends-container {
        grid-template-columns: 1fr;
        gap: 2rem;
    }
    
    .resource-row {
        grid-template-columns: 1fr;
        gap: 1rem;
    }
}

@media (max-width: 576px) {
    /* Unified padding for all sections on small screens */
    .about-section {
        padding: 5rem 0;
    }

    .about-intro-section {
        padding: 2rem 0 2.5rem;
    }
    
    /* Reduced grid gap */
    .about-section__grid,
    .about-section__grid--reverse,
    .about-founder-section .about-section__grid {
        gap: 2rem;
    }
    
    /* Founder section adjustments */
    .founder-image {
        justify-content: center;
    }
    
    .founder-content {
        padding-right: 0;
    }
    
    /* Work principles layout */
    .work-principle {
        grid-template-columns: 1fr;
        gap: 1rem;
        padding: 1.5rem 0;
    }
    
    .work-principle__icon {
        margin-bottom: 0.5rem;
    }
    
    /* Single column layouts */
    .service-cards {
        grid-template-columns: 1fr;
    }
}

