/* ============ CSS STYLING FOR TUGAS MANDIRI 15 ============ */
:root {
    --primary-green: #2ecc71;
    --primary-dark: #27ae60;
    --text-primary: #333333;
    --text-secondary: #666666;
    --bg-main: #f9f9f9;
    --bg-card: #ffffff;
    --sidebar-bg: #ffffff;
    --sidebar-text: #333333;
    --sidebar-active: #27ae60;
    --border-color: #e0e0e0;
    --transition: all 0.3s ease;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background-color: var(--bg-main);
    color: var(--text-primary);
    line-height: 1.6;
}

h1, h2, h3, h4, h5, h6 {
    font-family: 'Outfit', sans-serif;
    color: var(--text-primary);
    font-weight: 700;
}

/* ============ APP LAYOUT ============ */
.app-container {
    display: flex;
    min-height: 100vh;
}

/* ============ SIDEBAR ============ */
.sidebar {
    width: 280px;
    background-color: var(--sidebar-bg);
    color: var(--sidebar-text);
    padding: 30px 20px;
    position: fixed;
    height: 100vh;
    left: 0;
    top: 0;
    display: flex;
    flex-direction: column;
    z-index: 10;
    box-shadow: 2px 0 10px rgba(0, 0, 0, 0.05);
    border-right: 1px solid var(--border-color);
}

.sidebar-header {
    margin-bottom: 30px;
}

.back-link {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    color: var(--text-primary);
    text-decoration: none;
    font-size: 14px;
    font-weight: 600;
    transition: var(--transition);
}

.back-link:hover {
    color: var(--primary-green);
    transform: translateX(-3px);
}

.student-profile {
    display: flex;
    align-items: center;
    gap: 15px;
    padding: 15px;
    background: #e8f5e9;
    border-radius: 12px;
    margin-bottom: 30px;
}

.avatar {
    width: 44px;
    height: 44px;
    background: var(--primary-green);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    color: white;
}

.profile-info h4 {
    color: var(--text-primary);
    font-size: 14px;
    margin-bottom: 2px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 170px;
}

.profile-info .role {
    font-size: 11px;
    color: var(--primary-dark);
    font-weight: 700;
}

.profile-info .subject {
    font-size: 11px;
    color: var(--text-secondary);
}

.sidebar-menu {
    flex: 1;
}

.menu-label {
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: var(--text-secondary);
    margin-bottom: 15px;
    font-weight: 600;
}

.sidebar-menu ul {
    list-style: none;
}

.sidebar-menu li {
    margin-bottom: 8px;
}

.menu-item {
    display: flex;
    align-items: center;
    gap: 12px;
    color: var(--text-secondary);
    text-decoration: none;
    padding: 12px 15px;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 500;
    transition: var(--transition);
}

.menu-item i {
    font-size: 16px;
    width: 20px;
    text-align: center;
}

.menu-item:hover, .menu-item.active {
    color: var(--primary-dark);
    background: #e8f5e9;
}

.menu-item.active {
    border-left: 3px solid var(--primary-green);
    border-radius: 0 8px 8px 0;
    background: #e8f5e9;
    color: var(--primary-dark);
    font-weight: 600;
}

.sidebar-footer {
    font-size: 12px;
    color: var(--text-secondary);
    text-align: center;
    border-top: 1px solid var(--border-color);
    padding-top: 15px;
}

/* ============ MAIN CONTENT ============ */
.main-content {
    margin-left: 280px;
    flex: 1;
    padding: 40px;
    max-width: 1000px;
}

/* Top Bar */
.top-bar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-bottom: 20px;
    border-bottom: 1px solid var(--border-color);
    margin-bottom: 30px;
}

.breadcrumb {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 13px;
    color: var(--text-secondary);
}

.breadcrumb .current {
    color: var(--text-primary);
    font-weight: 600;
}

.breadcrumb i {
    font-size: 10px;
}

.theme-badge {
    display: flex;
    align-items: center;
    gap: 8px;
    background-color: white;
    padding: 6px 12px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
    border: 1px solid var(--border-color);
}

.theme-badge i {
    font-size: 14px;
}

.text-green {
    color: var(--primary-green);
}

/* Document Hero */
.doc-hero {
    background: linear-gradient(135deg, var(--primary-green) 0%, var(--primary-dark) 100%);
    color: white;
    padding: 40px;
    border-radius: 16px;
    margin-bottom: 40px;
    box-shadow: 0 10px 25px rgba(46, 204, 113, 0.15);
}

.doc-hero-badge {
    background: white;
    color: var(--primary-dark);
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 1px;
    display: inline-block;
    margin-bottom: 20px;
}

.doc-title {
    color: white;
    font-size: 32px;
    line-height: 1.3;
    margin-bottom: 15px;
}

.doc-subtitle {
    color: white;
    opacity: 0.9;
    font-size: 16px;
    margin-bottom: 30px;
    max-width: 800px;
}

/* Meta Cards Grid */
.meta-cards-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 15px;
}

.meta-card {
    background: rgba(255, 255, 255, 0.2);
    border: 1px solid rgba(255, 255, 255, 0.3);
    border-radius: 10px;
    padding: 15px;
    display: flex;
    align-items: center;
    gap: 12px;
}

.meta-card .card-icon {
    width: 40px;
    height: 40px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
    background: rgba(255, 255, 255, 0.25);
    color: white;
}

.card-details {
    display: flex;
    flex-direction: column;
}

.card-label {
    font-size: 10px;
    letter-spacing: 0.5px;
    color: white;
    opacity: 0.85;
    font-weight: 600;
}

.card-value {
    font-size: 13px;
    font-weight: 700;
    color: white;
}

/* ============ DOCUMENT SECTIONS ============ */
.doc-section {
    background: var(--bg-card);
    border-radius: 16px;
    padding: 35px;
    margin-bottom: 30px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.02), 0 10px 30px rgba(0, 0, 0, 0.02);
    border: 1px solid var(--border-color);
}

.section-header {
    display: flex;
    align-items: center;
    gap: 15px;
    margin-bottom: 25px;
    border-bottom: 2px solid var(--border-color);
    padding-bottom: 12px;
}

.section-num {
    background: #e8f5e9;
    color: var(--primary-dark);
    width: 32px;
    height: 32px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: 'Outfit', sans-serif;
    font-weight: 700;
    font-size: 14px;
}

.section-header h2 {
    font-size: 22px;
    color: var(--text-primary);
}

.section-body p {
    color: var(--text-primary);
    margin-bottom: 20px;
    font-size: 15px;
    text-align: justify;
}

.section-body p:last-child {
    margin-bottom: 0;
}

/* Callout Box */
.callout-box {
    background-color: #e8f5e9;
    border-left: 4px solid var(--primary-green);
    padding: 20px;
    border-radius: 0 12px 12px 0;
    display: flex;
    gap: 15px;
    margin: 25px 0;
}

.callout-icon {
    font-size: 20px;
    color: var(--primary-dark);
}

.callout-text {
    font-size: 14px;
    color: #1b5e20;
    line-height: 1.6;
}

.callout-text strong {
    display: block;
    margin-bottom: 4px;
    font-weight: 700;
}

/* ============ TREND GRID ============ */
.trend-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
    margin: 25px 0;
}

.trend-card {
    background: var(--bg-main);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 20px;
    transition: var(--transition);
}

.trend-card:hover {
    transform: translateY(-3px);
    border-color: var(--primary-green);
    box-shadow: 0 4px 12px rgba(46, 204, 113, 0.1);
}

.trend-icon {
    width: 50px;
    height: 50px;
    background: var(--primary-green);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 22px;
    color: white;
    margin-bottom: 15px;
}

.trend-card h4 {
    font-size: 15px;
    margin-bottom: 10px;
    color: var(--text-primary);
}

.trend-card p {
    font-size: 13px;
    color: var(--text-secondary);
    margin: 0;
    line-height: 1.5;
}

/* ============ DATA GRID ============ */
.data-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 20px;
    margin: 25px 0;
}

.data-card {
    background: linear-gradient(135deg, var(--primary-green) 0%, var(--primary-dark) 100%);
    color: white;
    border-radius: 12px;
    padding: 25px;
    text-align: center;
    box-shadow: 0 4px 15px rgba(46, 204, 113, 0.2);
}

.data-number {
    font-size: 36px;
    font-weight: 800;
    margin-bottom: 10px;
    line-height: 1;
}

.data-label {
    font-size: 13px;
    margin-bottom: 8px;
    opacity: 0.95;
    line-height: 1.4;
}

.data-source {
    font-size: 11px;
    opacity: 0.8;
    font-style: italic;
}

/* ============ INSIGHTS ============ */
.insights-container {
    background: var(--bg-main);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 25px;
    margin: 30px 0;
}

.insights-container h4 {
    font-size: 16px;
    margin-bottom: 20px;
    color: var(--text-primary);
    display: flex;
    align-items: center;
    gap: 8px;
}

.insight-item {
    display: flex;
    align-items: flex-start;
    gap: 15px;
    margin-bottom: 15px;
}

.insight-item:last-child {
    margin-bottom: 0;
}

.insight-marker {
    width: 28px;
    height: 28px;
    background: var(--primary-green);
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 14px;
    flex-shrink: 0;
}

.insight-item p {
    font-size: 14px;
    color: var(--text-secondary);
    margin: 0;
    line-height: 1.5;
}

.insight-item strong {
    color: var(--text-primary);
}

/* ============ OPPORTUNITY OVERVIEW ============ */
.opportunity-overview {
    margin: 30px 0;
}

.opportunity-overview h4 {
    font-size: 16px;
    margin-bottom: 15px;
    color: var(--text-primary);
    display: flex;
    align-items: center;
    gap: 8px;
}

.opportunity-card {
    background: linear-gradient(135deg, #e8f5e9 0%, #f0fdf4 100%);
    border: 2px solid var(--primary-green);
    border-radius: 12px;
    padding: 25px;
}

.opportunity-card h5 {
    font-size: 18px;
    margin-bottom: 10px;
    color: var(--primary-dark);
}

.opportunity-card p {
    font-size: 14px;
    color: var(--text-secondary);
    margin: 0;
    line-height: 1.6;
}

/* ============ PROBLEM-SOLUTION GRID ============ */
.problem-solution-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 25px;
    margin: 30px 0;
}

.ps-column h4 {
    font-size: 16px;
    margin-bottom: 20px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.ps-column:first-child h4 { color: #e74c3c; }
.ps-column:last-child h4 { color: #27ae60; }

.ps-item {
    background: var(--bg-main);
    border: 1px solid var(--border-color);
    border-radius: 10px;
    padding: 20px;
    margin-bottom: 15px;
}

.ps-item.success {
    border-left: 4px solid var(--primary-green);
}

.ps-item h5 {
    font-size: 14px;
    margin-bottom: 8px;
    color: var(--text-primary);
}

.ps-item p {
    font-size: 13px;
    color: var(--text-secondary);
    margin: 0;
    line-height: 1.5;
}

/* ============ TARGET MARKET ============ */
.target-market {
    margin: 30px 0;
}

.target-market h4 {
    font-size: 16px;
    margin-bottom: 20px;
    color: var(--text-primary);
    display: flex;
    align-items: center;
    gap: 8px;
}

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

.market-card {
    background: var(--bg-main);
    border: 1px solid var(--border-color);
    border-radius: 10px;
    padding: 20px;
    transition: var(--transition);
}

.market-card:hover {
    transform: translateY(-3px);
    border-color: var(--primary-green);
}

.market-icon {
    width: 45px;
    height: 45px;
    background: var(--primary-green);
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    color: white;
    margin-bottom: 12px;
}

.market-card h5 {
    font-size: 15px;
    margin-bottom: 8px;
    color: var(--text-primary);
}

.market-card p {
    font-size: 13px;
    color: var(--text-secondary);
    margin: 0;
    line-height: 1.5;
}

/* ============ TECH STACK ============ */
.tech-stack {
    margin: 30px 0;
}

.tech-stack h4 {
    font-size: 16px;
    margin-bottom: 20px;
    color: var(--text-primary);
    display: flex;
    align-items: center;
    gap: 8px;
}

.tech-items {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.tech-item {
    background: var(--bg-main);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    padding: 15px 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    transition: var(--transition);
}

.tech-item:hover {
    border-color: var(--primary-green);
}

.tech-name {
    font-size: 14px;
    font-weight: 600;
    color: var(--text-primary);
}

.tech-desc {
    font-size: 12px;
    color: var(--text-secondary);
}

/* ============ STEPS CONTAINER ============ */
.steps-container {
    margin: 30px 0;
}

.steps-container h4 {
    font-size: 16px;
    margin-bottom: 25px;
    color: var(--text-primary);
    display: flex;
    align-items: center;
    gap: 8px;
}

.step-item {
    display: flex;
    gap: 20px;
    margin-bottom: 25px;
    padding-bottom: 25px;
    border-bottom: 1px dashed var(--border-color);
}

.step-item:last-child {
    margin-bottom: 0;
    padding-bottom: 0;
    border-bottom: none;
}

.step-number {
    width: 45px;
    height: 45px;
    background: var(--primary-green);
    color: white;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    font-weight: 800;
    flex-shrink: 0;
}

.step-content {
    flex: 1;
}

.step-content h5 {
    font-size: 16px;
    margin-bottom: 8px;
    color: var(--text-primary);
}

.step-content p {
    font-size: 14px;
    color: var(--text-secondary);
    margin-bottom: 10px;
    line-height: 1.6;
}

.step-cost {
    background: #fffbeb;
    border-left: 3px solid #f1c40f;
    padding: 8px 12px;
    border-radius: 0 6px 6px 0;
    font-size: 12px;
    color: #78350f;
    font-weight: 600;
}

/* ============ COST BREAKDOWN ============ */
.cost-breakdown {
    margin: 30px 0;
}

.cost-breakdown h4 {
    font-size: 16px;
    margin-bottom: 20px;
    color: var(--text-primary);
    display: flex;
    align-items: center;
    gap: 8px;
}

.cost-table {
    background: var(--bg-main);
    border: 1px solid var(--border-color);
    border-radius: 10px;
    overflow: hidden;
}

.cost-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 20px;
    border-bottom: 1px solid var(--border-color);
}

.cost-row:last-child {
    border-bottom: none;
}

.cost-row.total {
    background: #e8f5e9;
    border-top: 2px solid var(--primary-green);
}

.cost-item {
    font-size: 14px;
    color: var(--text-secondary);
}

.cost-row.total .cost-item {
    font-weight: 700;
    color: var(--primary-dark);
}

.cost-value {
    font-size: 14px;
    font-weight: 600;
    color: var(--text-primary);
}

.cost-row.total .cost-value {
    font-size: 16px;
    color: var(--primary-dark);
}

/* ============ REVENUE PROJECTION ============ */
.revenue-projection {
    margin: 30px 0;
}

.revenue-projection h4 {
    font-size: 16px;
    margin-bottom: 20px;
    color: var(--text-primary);
    display: flex;
    align-items: center;
    gap: 8px;
}

.projection-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
    margin-bottom: 20px;
}

.projection-item {
    background: var(--bg-main);
    border: 1px solid var(--border-color);
    border-radius: 10px;
    padding: 20px;
    text-align: center;
}

.proj-month {
    font-size: 12px;
    color: var(--text-secondary);
    margin-bottom: 8px;
    font-weight: 600;
}

.proj-desc {
    font-size: 13px;
    color: var(--text-secondary);
    margin-bottom: 12px;
    line-height: 1.4;
}

.proj-revenue {
    font-size: 18px;
    font-weight: 800;
    color: var(--primary-green);
}

.projection-note {
    background: white;
    padding: 15px;
    border-left: 4px solid var(--primary-green);
    border-radius: 0 8px 8px 0;
    font-size: 13px;
    color: var(--text-secondary);
}

.projection-note strong {
    color: var(--text-primary);
}

/* ============ BIBLIOGRAPHY (DAFTAR PUSTAKA) ============ */
.pustaka-note {
    font-size: 13px;
    color: var(--text-secondary);
    background: #eeeeee;
    padding: 10px 15px;
    border-radius: 8px;
    margin-bottom: 20px !important;
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.pustaka-list {
    list-style: none;
}

.pustaka-list li {
    font-size: 14px;
    color: var(--text-primary);
    margin-bottom: 15px;
    padding-left: 20px;
    text-indent: -20px;
    line-height: 1.6;
}

.pustaka-list li a {
    color: var(--primary-dark);
    text-decoration: none;
    word-break: break-all;
}

.pustaka-list li a:hover {
    text-decoration: underline;
}

/* Animations */
@keyframes fadeIn {
    from { opacity: 0; transform: translateY(8px); }
    to { opacity: 1; transform: translateY(0); }
}

/* ============ RESPONSIVE BREAKPOINTS ============ */
@media (max-width: 992px) {
    .sidebar {
        width: 100%;
        height: auto;
        position: relative;
        box-shadow: none;
        padding: 20px;
        border-right: none;
        border-bottom: 1px solid var(--border-color);
    }
    
    .app-container {
        flex-direction: column;
    }

    .main-content {
        margin-left: 0;
        padding: 20px;
    }

    .doc-hero {
        padding: 25px;
    }

    .doc-title {
        font-size: 26px;
    }

    .problem-solution-grid {
        grid-template-columns: 1fr;
    }

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

@media (max-width: 576px) {
    .top-bar {
        flex-direction: column;
        align-items: flex-start;
        gap: 12px;
    }

    .meta-cards-grid {
        grid-template-columns: 1fr;
    }

    .doc-section {
        padding: 20px;
    }

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

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

    .market-segments {
        grid-template-columns: 1fr;
    }

    .step-item {
        flex-direction: column;
        gap: 15px;
    }

    .step-number {
        width: 35px;
        height: 35px;
        font-size: 16px;
    }
}
