/* TEFA Redesign Styles */

/* --- Layout & Typography --- */
.tefa-container {
    width: 100%;
    background-color: var(--bg-light-grey);
    /* Very light subtle grey bg */
    min-height: 100vh;
    padding-bottom: 80px;
    font-family: var(--tertiary-font-family);
    /* Clean sans-serif */
}

/* --- Hero Section --- */
.tefa-hero {
    background: var(--primary-theme-color);
    color: white;
    padding: 100px 20px 80px;
    text-align: center;
    position: relative;
    clip-path: ellipse(150% 100% at 50% 0%);
    /* Curved bottom */
    margin-bottom: -40px;
    /* Pull content up */
}

.tefa-hero-logo {
    width: 300px;
    height: 150px;
    background-image: url('../images/home/TEFAlogo.png');
    background-size: contain;
    background-repeat: no-repeat;
    background-position: center;
    margin: 0 auto 20px;
    filter: drop-shadow(0 4px 6px rgba(0, 0, 0, 0.3));
}

.tefa-hero-title {
    font-family: var(--secondary-font-family);
    /* Schoolwork */
    font-size: clamp(3rem, 5vw, 5rem);
    margin: 0;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.3);
}

.tefa-hero-subtitle {
    font-family: var(--quaternary-font-family);
    /* Cafe */
    font-size: clamp(1.2rem, 2vw, 2rem);
    font-weight: 300;
    opacity: 0.9;
    margin-top: 10px;
}

.tefa-hero-tagline {
    display: inline-block;
    background-color: rgba(255, 255, 255, 0.2);
    padding: 5px 15px;
    border-radius: 20px;
    margin-top: 20px;
    font-size: 0.9rem;
    font-weight: bold;
    letter-spacing: 1px;
    text-transform: uppercase;
}

/* --- Main Content Area --- */
.tefa-main-content {
    max-width: 1100px;
    margin: 0 auto;
    padding: 0 20px;
    position: relative;
    z-index: 10;
}

/* --- Cards --- */
.tefa-card {
    background: white;
    border-radius: 12px;
    padding: 40px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.08);
    /* Premium shadow */
    margin-bottom: 30px;
    transition: transform 0.3s ease;
}

/* Removed hover effect */

.tefa-card-intro {
    text-align: center;
    margin-top: 0;
}

.tefa-card h3 {
    font-family: var(--tertiary-font-family);
    color: var(--primary-theme-color);
    font-size: 2rem;
    margin-top: 0;
    margin-bottom: 20px;
    font-weight: 700;
}

.tefa-card p {
    font-size: 1.2rem;
    line-height: 1.6;
    color: var(--text-medium-grey);
}

/* Stats in Intro */
.tefa-intro-stat {
    display: flex;
    justify-content: center;
    align-items: center;
    margin-top: 30px;
    gap: 40px;
    flex-wrap: wrap;
}

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

.stat-value {
    display: block;
    font-size: clamp(1.8rem, 4vw, 2.5rem);
    /* Responsive font size */
    font-weight: 800;
    color: var(--secondary-theme-color);
    /* Green */
    line-height: 1;
    overflow: visible;
    /* Prevent scrollbars caused by global overflow-x: hidden */
}

.stat-label {
    font-size: 0.9rem;
    color: #888;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-top: 5px;
    display: block;
}

.stat-divider {
    width: 2px;
    height: 50px;
    background-color: #eee;
}

/* Grid for Features */
.tefa-grid-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 30px;
    margin-bottom: 50px;
}

.tefa-check-list {
    list-style: none;
    padding: 0;
    margin: 0;
    text-align: left;
}

.tefa-check-list li {
    position: relative;
    padding-left: 30px;
    margin-bottom: 15px;
    font-size: 1.1rem;
    color: #555;
    line-height: 1.4;
}

.tefa-check-list li::before {
    content: "✓";
    position: absolute;
    left: 0;
    color: var(--secondary-theme-color);
    font-weight: bold;
}

/* --- Tiers Section --- */
.tefa-tiers-section {
    margin-bottom: 60px;
    text-align: center;
}

.section-badge-title {
    display: inline-block;
    background-color: var(--primary-theme-color);
    color: white;
    padding: 10px 30px;
    border-radius: 50px;
    font-size: 1.5rem;
    font-weight: bold;
    font-family: var(--tertiary-font-family);
    margin-bottom: 10px;
    box-shadow: 0 5px 15px rgba(32, 46, 71, 0.3);
}

.section-subtitle {
    margin-bottom: 40px;
    font-size: 1.1rem;
    color: #666;
}

.tefa-tiers-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
    align-items: starch;
    /* Equal height */
}

.tefa-tier-card {
    background: white;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.05);
    display: flex;
    flex-direction: column;
    border: 1px solid #eee;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

/* Removed hover effect */

.tier-header {
    padding: 20px 10px;
    color: white;
}

.tier-1 .tier-header {
    background-color: var(--tier-1-color);
}

.tier-2 .tier-header {
    background-color: var(--tier-2-color);
}

.tier-3 .tier-header {
    background-color: var(--tier-3-color);
}

.tier-4 .tier-header {
    background-color: var(--tier-4-color);
}

.tier-number {
    display: block;
    font-size: 0.8rem;
    opacity: 0.8;
    text-transform: uppercase;
}

.tier-name {
    display: block;
    font-size: 1.2rem;
    font-weight: bold;
}

.tier-body {
    padding: 20px;
    font-family: var(--tertiary-font-family);
    flex-grow: 1;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.tier-body p {
    margin: 5px 0;
    font-size: 0.95rem;
    color: var(--text-medium-grey);
}

.tier-body hr {
    border: 0;
    height: 1px;
    background: #eee;
    margin: 15px 0;
    width: 80%;
    margin-left: auto;
    margin-right: auto;
}

.tefa-note-box {
    margin-top: 20px;
    font-size: 0.9rem;
    color: #888;
}

/* --- Checklist Timeline --- */
.tefa-checklist-section {
    margin-top: 6rem;
    /* margin-bottom: 60px; */
    text-align: center;
}

.timeline {
    position: relative;
    max-width: 800px;
    margin: 40px auto;
}

.timeline::before {
    content: '';
    position: absolute;
    left: 20px;
    /* Adjust for marker centering */
    top: 0;
    bottom: 0;
    width: 2px;
    background: #ddd;
}

.timeline-item {
    padding: 0 0 40px 60px;
    position: relative;
    text-align: left;
}

.timeline-marker {
    position: absolute;
    left: 0;
    top: 0;
    width: 40px;
    height: 40px;
    background: white;
    border: 3px solid var(--secondary-theme-color);
    border-radius: 50%;
    color: var(--secondary-theme-color);
    font-weight: bold;
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 1.2rem;
    z-index: 2;
}

.timeline-content h4 {
    margin: 0 0 5px;
    color: var(--primary-theme-color);
    font-size: 1.3rem;
}

.timeline-content p {
    margin: 0;
    color: #555;
}

/* --- Footer Actions --- */
.tefa-footer-actions {
    display: flex;
    justify-content: center;
    gap: 30px;
    flex-wrap: wrap;
    /* padding-top: 20px; */
    /* border-top: 1px solid #ddd; */
}

.action-button {
    display: flex;
    align-items: center;
    gap: 15px;
    padding: 15px 30px;
    border-radius: 50px;
    color: white;
    font-weight: bold;
    text-decoration: none;
    transition: transform 0.2s, box-shadow 0.2s;
    font-size: 1.1rem;
    font-family: var(--tertiary-font-family);
}

.action-button:hover {
    transform: translateY(-3px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
}

.download-btn {
    background-color: var(--primary-theme-color);
}

.apply-btn {
    background-color: var(--secondary-theme-color);
}

.btn-icon {
    font-size: 1.5rem;
}

/* --- Responsive --- */
@media (max-width: 900px) {
    .tefa-tiers-grid {
        grid-template-columns: 1fr 1fr;
    }
}

@media (max-width: 768px) {
    .tefa-grid-row {
        grid-template-columns: 1fr;
    }

    .tefa-tiers-grid {
        grid-template-columns: 1fr;
        /* Stack tiers */
    }

    .stat-divider {
        display: none;
    }

    .tefa-hero {
        padding: 80px 20px 60px;
        clip-path: ellipse(180% 100% at 50% 0%);
    }

    .timeline::before {
        left: 15px;
    }

    .timeline-marker {
        width: 30px;
        height: 30px;
        font-size: 1rem;
        left: 0px;
    }

    .timeline-item {
        padding-left: 50px;
    }
}

/* --- Income Guidelines Table --- */
.tefa-guidelines-card {
    text-align: center;
}

.tefa-table-container {
    overflow-x: auto;
    margin-top: 20px;
    border-radius: 8px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.05);
}

.tefa-guidelines-table {
    width: 100%;
    border-collapse: collapse;
    font-family: var(--tertiary-font-family);
    min-width: 500px;
    /* Ensure table doesn't squish too much */
}

.tefa-guidelines-table th,
.tefa-guidelines-table td {
    padding: 15px 20px;
    text-align: center;
    border-bottom: 1px solid #eee;
}

.tefa-guidelines-table th {
    background-color: var(--primary-theme-color);
    color: white;
    font-weight: bold;
    text-transform: uppercase;
    font-size: 0.95rem;
    letter-spacing: 0.5px;
}

.tefa-guidelines-table th small {
    display: block;
    font-weight: normal;
    font-size: 0.75rem;
    opacity: 0.8;
    margin-top: 4px;
}

.tefa-guidelines-table tr:nth-child(even) {
    background-color: #f9f9f9;
}

.tefa-guidelines-table tr:hover {
    background-color: #f1f1f1;
}

.tefa-guidelines-table td {
    color: var(--text-medium-grey);
    font-size: 1.1rem;
}

.tefa-guidelines-table td:first-child {
    font-weight: bold;
    color: var(--primary-theme-color);
}