/* =========================
   Reset & Base
========================= */
* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Arial, sans-serif;
    background: #f3f4f6; /* soft executive gray */
    color: #1f2937;
    line-height: 1.65;
    padding-top: 280px; /* Offset for the sticky header */
}

/* =========================
   Sticky Header & Controls
========================= */
header {
    background: linear-gradient(135deg, #0f172a, #020617);
    color: #ffffff;
    padding: 40px 20px;
    text-align: center;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1000;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
}

header h1 {
    margin: 0;
    font-size: 2.2rem;
    font-weight: 700;
    letter-spacing: -0.02em;
}

header p {
    margin: 8px 0;
    opacity: 0.92;
    font-size: 1rem;
}

.header-controls {
    margin-top: 25px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
}

#meta {
    font-size: 0.85rem;
    opacity: 0.75;
    font-weight: 500;
}

.archive-box {
    display: flex;
    align-items: center;
    gap: 10px;
}

.archive-box label {
    font-size: 0.9rem;
    color: rgba(255, 255, 255, 0.8);
}

#history-select {
    background-color: rgba(255, 255, 255, 0.05);
    color: white;
    border: 1px solid rgba(255, 255, 255, 0.3);
    padding: 6px 12px;
    border-radius: 6px;
    font-family: inherit;
    font-size: 0.85rem;
    cursor: pointer;
    transition: all 0.3s ease;
    outline: none;
}

#history-select:hover {
    border-color: white;
    background-color: rgba(255, 255, 255, 0.15);
}

#history-select option {
    background-color: #020617;
    color: white;
}

/* =========================
   Main container
========================= */
main {
    max-width: 850px;
    margin: 40px auto;
    padding: 0 20px;
}

/* =========================
   STORY CARD (EXECUTIVE STYLE)
========================= */
.story {
    background: #ffffff;
    border-radius: 16px;
    padding: 35px 40px;
    margin-bottom: 40px;
    border: 1px solid #e5e7eb;
    border-left: 5px solid #0f172a; /* Navy accent */
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.05);
    transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.story:hover {
    transform: translateY(-4px);
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1);
}

.story h2 {
    margin-top: 0;
    margin-bottom: 20px;
    font-size: 1.6rem;
    font-weight: 800;
    color: #0f172a;
    line-height: 1.3;
}

.story h3 {
    margin-top: 28px;
    margin-bottom: 8px;
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    font-weight: 800;
}

.story h3:nth-of-type(1) { color: #4b5563; } /* Summary */
.story h3:nth-of-type(2) { color: #2563eb; } /* Technical Takeaway */
.story h3:nth-of-type(3) { color: #dc2626; } /* Risk */
.story h3:nth-of-type(4) { color: #16a34a; } /* Opportunity */

.story p {
    margin-top: 0;
    font-size: 1.05rem;
    color: #374151;
    line-height: 1.7;
}

.story .source {
    margin-top: 25px;
    font-size: 0.85rem;
    border-top: 1px solid #f3f4f6;
    padding-top: 20px;
    color: #6b7280;
}

.story .source a {
    color: #2563eb;
    text-decoration: none;
    font-weight: 600;
}

/* =========================
   Jargon Decoder Styling
========================= */
#jargon-decoder {
    margin-bottom: 50px;
    background: #ffffff;
    padding: 30px;
    border-radius: 16px;
    border: 1px solid #e5e7eb;
}

.section-title {
    font-size: 1.2rem;
    color: #0f172a;
    margin-bottom: 20px;
    display: flex;
    align-items: center;
    gap: 10px;
    font-weight: 700;
}

.jargon-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
}

.jargon-card {
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    padding: 20px;
    border-radius: 12px;
}

/* =========================
   TOOLBOX (DEVELOPER TOOLS) - PROJECT D
========================= */
#ai-toolbox {
    margin-bottom: 50px;
    background: #ffffff;
    padding: 35px;
    border-radius: 16px;
    border: 1px solid #e5e7eb;
    border-top: 6px solid #10b981; /* Emerald accent */
}

.toolbox-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 20px;
}

.tool-card {
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    padding: 20px;
    border-radius: 12px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.tool-header {
    margin-bottom: 12px;
}

.category-pill {
    display: inline-block;
    font-size: 0.65rem;
    font-weight: 800;
    text-transform: uppercase;
    background: #d1fae5;
    color: #065f46;
    padding: 2px 8px;
    border-radius: 4px;
    margin-bottom: 8px;
}

.tool-card h4 {
    margin: 0;
    color: #064e3b;
    font-size: 1.1rem;
}

.tool-desc {
    font-size: 0.9rem;
    color: #374151;
    margin: 10px 0;
}

.tool-usage {
    font-size: 0.85rem;
    color: #6b7280;
    background: white;
    padding: 8px;
    border-radius: 6px;
    border: 1px dashed #d1d5db;
}

.tool-link {
    display: block;
    margin-top: 15px;
    color: #10b981;
    text-decoration: none;
    font-weight: 700;
    font-size: 0.85rem;
}

/* =========================
   LAB REPORT (RESEARCH)
========================= */
#lab-report {
    margin-bottom: 50px;
    background: #ffffff;
    padding: 35px;
    border-radius: 16px;
    border: 1px solid #e5e7eb;
    border-top: 6px solid #6366f1; /* Indigo accent */
}

.lab-grid {
    display: flex;
    flex-direction: column;
    gap: 25px;
}

.lab-card {
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    padding: 25px;
    border-radius: 12px;
    border-left: 4px solid #6366f1;
}

.lab-card h4 {
    margin-top: 0;
    margin-bottom: 12px;
    color: #1e1b4b;
    font-size: 1.2rem;
    font-weight: 700;
}

.lab-link {
    display: inline-block;
    margin-top: 10px;
    color: #6366f1;
    text-decoration: none;
    font-weight: 700;
    font-size: 0.9rem;
}

/* =========================
   Footer
========================= */
footer {
    text-align: center;
    padding: 60px 20px;
    font-size: 0.85rem;
    color: #9ca3af;
    border-top: 1px solid #e5e7eb;
    background: white;
}

.update-tag {
    font-size: 0.75rem;
    background: #e2e8f0;
    color: #475569;
    padding: 2px 10px;
    border-radius: 12px;
    margin-left: 10px;
}

/* Add to your existing style.css */

.section-divider {
    border: 0;
    height: 1px;
    background: #e5e7eb;
    margin: 40px 0;
}

/* Jargon Card Enhancements */
.jargon-card {
    background: #ffffff;
    border: 1px solid #e2e8f0;
    padding: 25px;
    border-radius: 12px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.02);
}

.jargon-card h4 {
    margin-top: 0;
    color: #7c3aed; /* Purple Theme for Jargon */
    font-size: 1.2rem;
    border-bottom: 2px solid #f5f3ff;
    padding-bottom: 10px;
}

.jargon-def {
    font-size: 0.95rem;
    color: #374151;
    margin-bottom: 15px;
}

.jargon-meta-box {
    background: #f9fafb;
    padding: 15px;
    border-radius: 8px;
    border-left: 3px solid #8b5cf6;
}

.jargon-analogy {
    font-size: 0.85rem;
    font-style: italic;
    color: #6b7280;
    margin: 0 0 8px 0;
}

.jargon-biz {
    font-size: 0.85rem;
    font-weight: 600;
    color: #1e1b4b;
    margin: 0;
}

/* Update Toolbox for consistency */
#ai-toolbox {
    border-top: 6px solid #10b981;
}

.tool-usage {
    background: #f0fdf4;
    border: 1px solid #d1fae5;
    color: #065f46;
}