/* ============================================
   BTVN Day 6 Landing Page - Flexbox Edition
   ============================================ */

/* CSS Variables */
:root {
    --primary-color: #22c55e;
    --primary-hover: #16a34a;
    --primary-light: #dcfce7;
    --text-dark: #1f2937;
    --text-gray: #6b7280;
    --text-light: #9ca3af;
    --bg-white: #ffffff;
    --bg-light: #f8fafc;
    --border-color: #e5e7eb;
    --shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.08);
    --shadow-md: 0 4px 15px rgba(0, 0, 0, 0.1);
    --shadow-lg: 0 10px 40px rgba(0, 0, 0, 0.15);
    --radius: 16px;
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Reset & Base */
*,
*::before,
*::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family:
        "Inter",
        -apple-system,
        BlinkMacSystemFont,
        sans-serif;
    background: linear-gradient(135deg, #f0fdf4 0%, #ecfdf5 50%, #f0f9ff 100%);
    color: var(--text-dark);
    line-height: 1.6;
    min-height: 100vh;
    padding: 20px;
}

/* Container - Wide for 5 cards */
.container {
    max-width: 1600px;
    margin: 0 auto;
    padding: 20px;
}

/* Header */
.header {
    text-align: center;
    margin-bottom: 50px;
    padding: 40px 20px;
}

.header h1 {
    font-size: clamp(2rem, 5vw, 3rem);
    font-weight: 700;
    color: var(--text-dark);
    margin-bottom: 12px;
    letter-spacing: -0.02em;
}

.subtitle {
    font-size: 1.125rem;
    color: var(--text-gray);
    font-weight: 500;
}

/* Cards Grid - 5 columns on desktop */
.cards-grid {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 20px;
    margin-bottom: 50px;
}

/* Card - Using <a> tag */
a.card {
    display: flex;
    flex-direction: column;
    background: var(--bg-white);
    border: 1px solid var(--border-color);
    border-radius: var(--radius);
    box-shadow: var(--shadow-sm);
    position: relative;
    overflow: hidden;
    transition: var(--transition);
    text-decoration: none;
    color: inherit;
    cursor: pointer;
}

a.card:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-lg);
    border-color: var(--primary-color);
}

a.card:focus {
    outline: 3px solid var(--primary-color);
    outline-offset: 2px;
}

/* Card Header - Compact */
.card-header {
    padding: 20px 18px 16px;
    border-bottom: 1px solid var(--border-color);
}

.card-header h2 {
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--text-dark);
    margin-bottom: 10px;
    letter-spacing: -0.01em;
}

.slogan {
    font-style: italic;
    font-size: 0.8rem;
    color: var(--text-light);
    line-height: 1.4;
}

/* Card Body - Compact */
.card-body {
    padding: 16px 18px;
    flex: 1;
}

/* Feature List */
.feature-list {
    list-style: none;
}

.feature-list li {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    padding: 8px 0;
    font-size: 0.85rem;
    color: var(--text-gray);
    line-height: 1.4;
    border-bottom: 1px dashed rgba(229, 231, 235, 0.6);
}

.feature-list li:last-child {
    border-bottom: none;
}

.feature-list li::before {
    content: "✓";
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 20px;
    height: 20px;
    min-width: 20px;
    background: var(--primary-light);
    color: var(--primary-color);
    font-size: 0.75rem;
    font-weight: 700;
    border-radius: 50%;
    margin-top: 2px;
}

/* Card Footer - Compact */
.card-footer {
    padding: 14px 18px 20px;
    margin-top: auto;
}

/* Button (Visual only - inside <a> tag) */
.btn {
    display: block;
    width: 100%;
    padding: 12px 16px;
    text-align: center;
    font-size: 0.875rem;
    font-weight: 600;
    border-radius: 10px;
    transition: var(--transition);
    background: var(--bg-light);
    color: var(--text-dark);
    border: 1px solid var(--border-color);
}

.btn-featured {
    background: linear-gradient(135deg, var(--primary-color) 0%, #16a34a 100%);
    color: var(--bg-white);
    border: none;
    box-shadow: 0 4px 15px rgba(34, 197, 94, 0.3);
}

/* Button hover effect when card is hovered */
a.card:hover .btn-featured {
    background: linear-gradient(135deg, #16a34a 0%, #15803d 100%);
    box-shadow: 0 6px 20px rgba(34, 197, 94, 0.4);
}

/* Footer */
.footer {
    text-align: center;
    padding: 30px 20px;
    color: var(--text-light);
    font-size: 0.875rem;
}

/* Large Desktop - 5 columns */
@media (min-width: 1200px) {
    .cards-grid {
        grid-template-columns: repeat(5, 1fr);
    }
}

/* Medium Desktop - 3 columns */
@media (max-width: 1199px) and (min-width: 769px) {
    .container {
        max-width: 95%;
    }

    .cards-grid {
        grid-template-columns: repeat(3, 1fr);
        gap: 20px;
    }
}

/* Tablets - 2 columns */
@media (max-width: 768px) {
    .container {
        max-width: 100%;
    }

    .cards-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 16px;
    }
}

/* Mobile - 1 column */
@media (max-width: 640px) {
    body {
        padding: 12px;
    }

    .container {
        padding: 12px;
    }

    .header {
        margin-bottom: 30px;
        padding: 24px 16px;
    }

    .header h1 {
        font-size: 1.75rem;
    }

    .subtitle {
        font-size: 1rem;
    }

    .cards-grid {
        grid-template-columns: 1fr;
        gap: 16px;
    }

    .card-header {
        padding: 24px 20px 16px;
    }

    .card-header h2 {
        font-size: 1.2rem;
    }

    .card-body {
        padding: 20px;
    }

    .feature-list li {
        font-size: 0.875rem;
        padding: 8px 0;
    }

    .card-footer {
        padding: 16px 20px 24px;
    }

    .btn {
        padding: 12px 20px;
        font-size: 0.9rem;
    }
}

/* Hover States - Touch Devices */
@media (hover: none) {
    a.card:hover {
        transform: none;
        box-shadow: var(--shadow-sm);
    }

    a.card:hover .btn-featured {
        background: linear-gradient(
            135deg,
            var(--primary-color) 0%,
            #16a34a 100%
        );
        box-shadow: 0 4px 15px rgba(34, 197, 94, 0.3);
    }
}

/* Reduced Motion */
@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}
