
* { margin: 0; padding: 0; box-sizing: border-box; }
body { font-family: 'Segoe UI', sans-serif; background: linear-gradient(135deg, #1b5e20 0%, #2e7d32 100%); min-height: 100vh; padding: 15px; }
.container { max-width: 1000px; margin: 5px auto; background: white; border-radius: 12px; box-shadow: 0 20px 60px rgba(0,0,0,0.3); overflow: hidden; }
.header { background: linear-gradient(135deg, #1b5e20, #2e7d32); color: white; padding: 15px 20px; display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 10px; }
.header h2 { font-size: 18px; }
.header-right { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
.btn-link { background: rgba(255,255,255,0.2); color: white; border: 2px solid white; padding: 7px 13px; border-radius: 6px; font-weight: 600; font-size: 12px; text-decoration: none; }
.btn-add { background: white; color: #1b5e20; border: none; padding: 8px 16px; border-radius: 8px; font-weight: 700; font-size: 13px; cursor: pointer; }
.content { padding: 15px 20px; }

/* Hero */
.hero { text-align: center; padding: 18px; border-radius: 12px; margin-bottom: 14px; background: #e8f5e9; }
.hero-label { font-size: 11px; font-weight: 700; text-transform: uppercase; color: #2e7d32; margin-bottom: 4px; }
.hero-value { font-size: 34px; font-weight: 900; color: #1b5e20; }
.hero-sub { font-size: 12px; color: #388e3c; margin-top: 6px; }

/* Cards */
.cards-row { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin-bottom: 14px; }
.dash-card { border-radius: 10px; padding: 12px; text-align: center; }
.dash-card .dc-label { font-size: 9px; font-weight: 700; text-transform: uppercase; opacity: 0.8; }
.dash-card .dc-value { font-size: 17px; font-weight: 800; margin-top: 4px; }
.dash-card .dc-sub { font-size: 10px; margin-top: 2px; opacity: 0.7; }

/* Tabs */
.view-tabs { display: flex; gap: 6px; margin-bottom: 14px; }
.view-tab { flex: 1; text-align: center; padding: 9px; border-radius: 10px; border: 2px solid #ddd; background: white; font-size: 12px; font-weight: 700; cursor: pointer; color: #555; transition: all 0.2s; }
.view-tab.active { background: #2e7d32; color: white; border-color: #2e7d32; }

/* Period card */
.period-card { border: 1px solid #e8e8e8; border-radius: 10px; padding: 12px; margin-bottom: 8px; }
.period-header { display: flex; justify-content: space-between; align-items: center; }
.period-label { font-size: 14px; font-weight: 800; color: #333; }
.period-pools { font-size: 11px; color: #888; margin-top: 3px; }
.period-value { font-size: 18px; font-weight: 900; color: #1b5e20; }
.period-toggle { background: none; border: 1px solid #ddd; border-radius: 12px; padding: 3px 10px; font-size: 10px; font-weight: 600; color: #888; cursor: pointer; margin-left: 8px; }
.period-details { display: none; margin-top: 10px; }
.period-details.show { display: block; }

/* Fee row */
.fee-row { display: flex; justify-content: space-between; align-items: center; padding: 8px 0; border-bottom: 1px solid #f5f5f5; font-size: 12px; }
.fee-row:last-child { border-bottom: none; }
.fee-row-left { display: flex; flex-direction: column; gap: 2px; }
.fee-row-pool { font-weight: 700; color: #1b5e20; }
.fee-row-date { color: #aaa; font-size: 11px; }
.fee-row-right { display: flex; align-items: center; gap: 8px; }
.fee-row-value { font-weight: 800; color: #1b5e20; }
.btn-del { background: none; border: none; cursor: pointer; color: #e53935; font-size: 14px; padding: 2px 4px; opacity: 0.6; }
.btn-del:hover { opacity: 1; }
.source-badge { display: inline-block; padding: 1px 6px; border-radius: 8px; font-size: 9px; font-weight: 700; background: #e8f5e9; color: #2e7d32; }
.source-pool { background: #e3f2fd; color: #1565c0; }

/* Pool breakdown */
.pool-fee-row { display: flex; justify-content: space-between; align-items: center; padding: 10px 12px; border: 1px solid #e8e8e8; border-radius: 8px; margin-bottom: 6px; }
.pool-fee-name { font-size: 13px; font-weight: 700; color: #333; }
.pool-fee-sub { font-size: 11px; color: #888; margin-top: 2px; }
.pool-fee-total { font-size: 16px; font-weight: 800; color: #1b5e20; }

/* Modal */
.modal-overlay { display: none; position: fixed; top:0; left:0; right:0; bottom:0; background: rgba(0,0,0,0.5); z-index: 1000; justify-content: center; align-items: center; padding: 15px; }
.modal-overlay.show { display: flex; }
.modal { background: white; border-radius: 14px; padding: 22px; width: 100%; max-width: 420px; }
.modal-title { font-size: 16px; font-weight: 800; color: #1b5e20; margin-bottom: 16px; }
.form-group { margin-bottom: 14px; }
.form-group label { display: block; font-size: 12px; font-weight: 700; color: #555; margin-bottom: 5px; }
.form-group input, .form-group select { width: 100%; border: 2px solid #e0e0e0; border-radius: 8px; padding: 10px 12px; font-size: 14px; font-family: 'Segoe UI', sans-serif; transition: border 0.2s; }
.form-group input:focus, .form-group select:focus { outline: none; border-color: #2e7d32; }
.modal-btns { display: flex; gap: 10px; margin-top: 18px; }
.btn-save { flex:1; background: #2e7d32; color: white; border: none; padding: 12px; border-radius: 8px; font-weight: 700; font-size: 14px; cursor: pointer; }
.btn-cancel { flex:1; background: #f0f0f0; color: #555; border: none; padding: 12px; border-radius: 8px; font-weight: 700; font-size: 14px; cursor: pointer; }

@media (max-width: 600px) {
    .cards-row { grid-template-columns: repeat(3, 1fr); }
    .header { flex-direction: column; text-align: center; }
}

