/* ============================================
   PokéAgent Challenge - Minimal Stylesheet
   Inspired by academic blog style
   ============================================ */

/* CSS Variables */
:root {
    --text-primary: #1a1a1a;
    --text-secondary: #4a4a4a;
    --text-muted: #6a6a6a;
    --accent-color: #2563eb;
    --accent-hover: #1d4ed8;
    --success-color: #16a34a;
    --fail-color: #dc2626;
    --bg-primary: #ffffff;
    --bg-secondary: #f8fafc;
    --border-color: #e2e8f0;
    --highlight-bg: #fef9c3;
}

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

body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    font-size: 17px;
    line-height: 1.7;
    color: var(--text-primary);
    background-color: var(--bg-primary);
}

a {
    color: var(--accent-color);
    text-decoration: none;
}

a:hover {
    text-decoration: underline;
}

/* ============================================
   HERO SECTION
   ============================================ */
.hero {
    position: relative;
    min-height: 70vh;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    color: #fff;
    overflow: hidden;
}

.hero-background {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
}

.hero-bg-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    filter: brightness(0.4) blur(2px);
}

.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, rgba(46, 139, 87, 0.35) 0%, rgba(26, 26, 26, 0.7) 100%);
}

.hero-content {
    max-width: 800px;
    margin: 0 auto;
    padding: 40px 20px;
    position: relative;
    z-index: 1;
}

.hero-badge {
    display: inline-block;
    background: var(--highlight-bg);
    color: var(--text-primary);
    padding: 8px 20px;
    border-radius: 20px;
    font-size: 14px;
    font-weight: 600;
    margin-bottom: 24px;
}

.hero-title {
    font-size: 3rem;
    font-weight: 700;
    margin-bottom: 20px;
    letter-spacing: -0.02em;
    text-shadow: 0 2px 10px rgba(0,0,0,0.3);
}

.hero-subtitle {
    font-size: 1.25rem;
    color: rgba(255, 255, 255, 0.9);
    margin-bottom: 24px;
    line-height: 1.6;
    text-shadow: 0 1px 5px rgba(0,0,0,0.3);
}

.hero-author {
    font-size: 1rem;
    color: rgba(255, 255, 255, 0.8);
    margin-bottom: 24px;
}

.hero-links {
    font-size: 0.95rem;
}

.hero-links a {
    color: rgba(255, 255, 255, 0.9);
    font-weight: 500;
    transition: color 0.2s;
}

.hero-links a:hover {
    color: #fff;
    text-decoration: underline;
}

.hero .separator {
    color: rgba(255, 255, 255, 0.5);
    margin: 0 10px;
}

.separator {
    color: var(--text-muted);
    margin: 0 8px;
}

/* ============================================
   MAIN CONTENT
   ============================================ */
.content {
    max-width: 800px;
    margin: 0 auto;
    padding: 0 20px;
}

.section {
    padding: 50px 0;
    border-bottom: 1px solid var(--border-color);
}

.section:last-child {
    border-bottom: none;
}

.section h2 {
    font-size: 1.8rem;
    font-weight: 700;
    margin-bottom: 24px;
    letter-spacing: -0.01em;
    padding-bottom: 12px;
    position: relative;
}

.section h2::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 50px;
    height: 3px;
    background: linear-gradient(90deg, #2E8B57, #50C878);
    border-radius: 2px;
}

.section h3 {
    font-size: 1.3rem;
    font-weight: 600;
    margin-top: 35px;
    margin-bottom: 15px;
    color: var(--text-primary);
}

.section p {
    margin-bottom: 16px;
    color: var(--text-secondary);
}

.section-intro {
    font-size: 1.1rem;
    color: var(--text-secondary);
    margin-bottom: 24px;
}

/* Lists */
.section ul,
.section ol {
    margin: 16px 0;
    padding-left: 24px;
}

.section li {
    margin-bottom: 10px;
    color: var(--text-secondary);
}

.section li strong {
    color: var(--text-primary);
}

/* ============================================
   VIDEO SECTION
   ============================================ */
.video-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(340px, 1fr));
    gap: 30px;
    margin-top: 24px;
}

.video-item video {
    width: 100%;
    border-radius: 8px;
    background: #000;
}

.video-caption {
    margin-top: 12px;
    font-size: 0.95rem;
    color: var(--text-secondary);
    line-height: 1.5;
}

.video-caption strong {
    color: var(--text-primary);
}

/* ============================================
   CHALLENGE LIST
   ============================================ */
.challenge-list {
    list-style: none;
    padding-left: 0;
    margin: 20px 0;
}

.challenge-list li {
    padding: 12px 0;
    padding-left: 24px;
    position: relative;
    border-bottom: 1px solid var(--border-color);
}

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

.challenge-list li::before {
    content: "•";
    position: absolute;
    left: 0;
    color: var(--accent-color);
    font-weight: bold;
}

/* ============================================
   APPROACH COMPARISON
   ============================================ */
.approach-comparison {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
    margin: 24px 0;
}

.approach-item {
    padding: 24px;
    background: var(--bg-secondary);
    border-radius: 8px;
    border: 1px solid var(--border-color);
}

.approach-item h3 {
    margin-top: 0;
    margin-bottom: 16px;
    font-size: 1.1rem;
}

.approach-item ul {
    list-style: none;
    padding-left: 0;
    margin: 0;
}

.approach-item li {
    padding: 8px 0;
    padding-left: 28px;
    position: relative;
    font-size: 0.95rem;
}

.approach-item li.pro::before {
    content: "(+)";
    position: absolute;
    left: 0;
    color: var(--success-color);
    font-weight: 600;
}

.approach-item li.con::before {
    content: "(−)";
    position: absolute;
    left: 0;
    color: var(--fail-color);
    font-weight: 600;
}

.key-question {
    text-align: center;
    font-size: 1.3rem;
    font-weight: 600;
    color: var(--text-primary);
    margin-top: 30px;
    padding: 20px;
    background: var(--highlight-bg);
    border-radius: 8px;
}

/* ============================================
   APPROACH STEPS
   ============================================ */
.approach-steps {
    margin: 24px 0;
    padding-left: 24px;
}

.approach-steps > li {
    margin-bottom: 20px;
    padding-bottom: 20px;
    border-bottom: 1px solid var(--border-color);
}

.approach-steps > li:last-child {
    border-bottom: none;
    margin-bottom: 0;
    padding-bottom: 0;
}

.approach-steps ul {
    margin-top: 10px;
    margin-bottom: 0;
}

/* ============================================
   TABLES
   ============================================ */
.table-wrapper {
    overflow-x: auto;
    margin: 20px 0;
}

table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.95rem;
}

thead {
    background: var(--bg-secondary);
}

th, td {
    padding: 12px 16px;
    text-align: left;
    border-bottom: 1px solid var(--border-color);
}

th {
    font-weight: 600;
    color: var(--text-primary);
}

td {
    color: var(--text-secondary);
}

.highlight-row {
    background: var(--highlight-bg);
}

.highlight-row td {
    color: var(--text-primary);
}

.fail {
    color: var(--fail-color);
    font-style: italic;
}

.best {
    color: var(--success-color);
}

/* ============================================
   FOOTER
   ============================================ */
.footer {
    padding: 40px 20px;
    text-align: center;
    border-top: 1px solid var(--border-color);
    margin-top: 20px;
}

.footer-content {
    max-width: 800px;
    margin: 0 auto;
}

.footer p {
    color: var(--text-muted);
    font-size: 0.9rem;
    margin-bottom: 8px;
}

.footer a {
    color: var(--text-muted);
}

.footer a:hover {
    color: var(--accent-color);
}

/* ============================================
   RESPONSIVE
   ============================================ */
@media (max-width: 768px) {
    .hero {
        min-height: 60vh;
    }

    .hero-title {
        font-size: 2.2rem;
    }

    .hero-subtitle {
        font-size: 1rem;
    }

    .section {
        padding: 40px 0;
    }

    .section h2 {
        font-size: 1.5rem;
    }

    .video-grid {
        grid-template-columns: 1fr;
    }

    .approach-comparison {
        grid-template-columns: 1fr;
    }

    table {
        font-size: 0.85rem;
    }

    th, td {
        padding: 10px 12px;
    }
}

@media (max-width: 480px) {
    body {
        font-size: 16px;
    }

    .hero-title {
        font-size: 1.75rem;
    }

    .section h2 {
        font-size: 1.35rem;
    }
}
