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

html {
    scroll-behavior: smooth;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    background: #0f1419;
    color: #e6edf3;
    padding: 20px;
    padding-top: 0;
    line-height: 1.6;
    transition: opacity 0.3s ease;
    max-width: 100vw;
    overflow-x: clip;
}

/* Smooth transitions for all interactive elements */
button, a, input, select, textarea {
    transition: all 0.2s ease;
}

/* Header */
.header {
    background: #161b22;
    padding: 20px;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.3);
    transition: transform 0.2s ease;
    margin-bottom: 20px;
    border: 1px solid #30363d;
}

.header-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 15px;
    margin-bottom: 10px;
}

.header h1 {
    font-size: 24px;
    font-weight: 600;
}

.header-controls {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

.header-status {
    display: flex;
    gap: 20px;
    font-size: 14px;
    color: #8b949e;
    flex-wrap: wrap;
}

.snapshot-info {
    color: #58a6ff;
    font-weight: 500;
}

.assets-count {
    font-weight: 500;
    color: #e6edf3;
}

/* Quick Stats */
.quick-stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 10px;
    margin-bottom: 15px;
}

.stat-item {
    background: #161b22;
    padding: 10px 15px;
    border-radius: 6px;
    border: 1px solid #30363d;
    display: flex;
    flex-direction: column;
    gap: 5px;
    transition: all 0.2s ease;
}

.stat-item:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.4);
    border-color: #484f58;
}

.stat-label {
    font-size: 11px;
    color: #8b949e;
    font-weight: 500;
}

.stat-value {
    font-size: 16px;
    font-weight: 600;
    color: #e6edf3;
}

.stat-positive .stat-value {
    color: #22c55e;
}

.stat-negative .stat-value {
    color: #ef4444;
}

/* Buttons */
.btn {
    padding: 8px 16px;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    font-size: 14px;
    font-weight: 500;
    transition: all 0.2s ease;
}

.btn-primary {
    background: #238636;
    color: white;
}

.btn-primary:hover {
    background: #2ea043;
    transform: translateY(-1px);
    box-shadow: 0 4px 8px rgba(35, 134, 54, 0.3);
}

.btn-success {
    background: #1f6feb;
    color: white;
}

.btn-success:hover {
    background: #388bfd;
    transform: translateY(-1px);
    box-shadow: 0 4px 8px rgba(31, 111, 235, 0.3);
}

.btn-secondary {
    background: #21262d;
    color: #c9d1d9;
    border: 1px solid #30363d;
}

.btn-secondary:hover {
    background: #30363d;
    border-color: #8b949e;
    transform: translateY(-1px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.3);
}

.btn-danger {
    background: #da3633;
    color: white;
    border: 1px solid #f85149;
}

.btn-danger:hover {
    background: #f85149;
    transform: translateY(-1px);
    box-shadow: 0 4px 8px rgba(218, 54, 51, 0.3);
}

.btn-icon {
    background: transparent;
    border: none;
    cursor: pointer;
    font-size: 16px;
    padding: 4px 8px;
    transition: transform 0.1s;
}

.btn-icon:hover {
    transform: scale(1.2);
}

.btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

/* Summary Cards */
.summary {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 10px;
    margin-bottom: 10px;
}

.summary-split {
    grid-template-columns: 1fr 1fr;
    gap: 8px;
    margin-bottom: 2px;
}

.summary-grid {
    grid-template-columns: repeat(4, 1fr);
    gap: 8px;
    margin-bottom: 10px;
}

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

.dividend-summary {
    margin: 15px 0;
}

.dividend-summary h2 {
    margin-bottom: 10px;
    color: #22c55e;
    font-size: 16px;
}

.dividend-summary .card {
    padding: 8px 10px;
}

.dividend-summary .card h3 {
    font-size: 12px;
    margin-bottom: 5px;
}

.dividend-summary .card-value {
    font-size: 16px;
}

.dividend-summary .card-label {
    font-size: 10px;
    margin-top: 3px;
}

.card {
    background: #161b22;
    padding: 12px 15px;
    border-radius: 6px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.3);
    border: 1px solid #30363d;
}

.summary-split .card {
    padding: 8px 12px;
}

.summary-grid .card {
    padding: 8px 12px;
}

.card h3 {
    font-size: 11px;
    color: #8b949e;
    margin-bottom: 6px;
    text-transform: uppercase;
    font-weight: 500;
    letter-spacing: 0.5px;
}

.summary-split .card h3 {
    font-size: 10px;
    margin-bottom: 4px;
}

.summary-grid .card h3 {
    font-size: 10px;
    margin-bottom: 4px;
}

.card-value {
    font-size: 20px;
    font-weight: 600;
    margin-bottom: 0;
}

.card-percent {
    font-size: 12px;
    color: #8b949e;
    margin-top: 4px;
}

.summary-split .card-value {
    font-size: 18px;
}

.summary-grid .card-value {
    font-size: 18px;
}

.card-pl {
    font-size: 16px;
    font-weight: 500;
}

.card-pl.positive {
    color: #22c55e;
}

.card-pl.negative {
    color: #ef4444;
}

/* General positive/negative color classes */
.positive {
    color: #3fb950 !important;
    font-weight: 600;
}

.negative {
    color: #f85149 !important;
    font-weight: 600;
}

/* Controls */
.controls {
    background: #161b22;
    padding: 15px 20px;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.3);
    margin-bottom: 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 15px;
    border: 1px solid #30363d;
}

.controls-left {
    display: flex;
    gap: 15px;
    align-items: center;
    flex-wrap: wrap;
}

.filter-group {
    display: flex;
    gap: 8px;
    align-items: center;
}

.filter-group label {
    font-size: 14px;
    font-weight: 500;
    color: #8b949e;
}

.filter-btn {
    padding: 6px 12px;
    border: 1px solid #30363d;
    background: #0d1117;
    color: #c9d1d9;
    border-radius: 6px;
    cursor: pointer;
    font-size: 13px;
    transition: all 0.2s;
}

.filter-btn:hover {
    background: #161b22;
    border-color: #8b949e;
}

.filter-btn.active {
    background: #238636;
    color: white;
    border-color: #238636;
}

.search-input {
    padding: 8px 12px;
    border: 1px solid #30363d;
    border-radius: 6px;
    font-size: 14px;
    min-width: 200px;
    background: #0d1117;
    color: #e6edf3;
}

.search-input:focus {
    outline: none;
    border-color: #238636;
}

/* Holdings Table */
.holdings-section {
    background: #161b22;
    padding: 20px;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.3);
    border: 1px solid #30363d;
}

.table-wrapper {
    overflow-x: auto;
    max-width: 100%;
    -webkit-overflow-scrolling: touch;
}

.holdings-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 14px;
    table-layout: auto;
}

.holdings-table th {
    background: #0d1117;
    padding: 12px 8px;
    text-align: left;
    font-weight: 600;
    border-bottom: 2px solid #30363d;
    white-space: nowrap;
    color: #e6edf3;
}

.holdings-table th.sortable {
    cursor: pointer;
    user-select: none;
}

.holdings-table th.sortable:hover {
    background: #161b22;
}

.holdings-table .sub-header th {
    font-weight: 500;
    font-size: 12px;
    color: #8b949e;
}

.holdings-table td {
    padding: 12px 8px;
    border-bottom: 1px solid #21262d;
    transition: background-color 0.2s ease, transform 0.1s ease;
}

.holdings-table tbody tr {
    transition: background-color 0.2s ease, transform 0.1s ease;
}

.holdings-table tbody tr:hover {
    background: #0d1117;
    transform: translateX(2px);
}

.empty-state {
    text-align: center;
    padding: 40px !important;
    color: #6e7681;
}

.asset-name {
    font-weight: 500;
}

.asset-type {
    text-transform: capitalize;
    color: #8b949e;
}

.price-cell {
    font-weight: 600;
}

.price-wrapper {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.price-indicator {
    font-size: 10px;
    font-weight: 500;
}

.price-up {
    color: #22c55e;
}

.price-down {
    color: #ef4444;
}

.price-error {
    color: #ef4444;
    font-size: 12px;
}

.price-na {
    color: #6b7280;
    font-size: 13px;
    font-style: italic;
}

.pl-positive {
    color: #22c55e;
}

.pl-negative {
    color: #ef4444;
}

.action-btns {
    display: flex;
    gap: 8px;
}

.action-btns button {
    padding: 4px 8px;
    border: 1px solid #30363d;
    background: #0d1117;
    color: #c9d1d9;
    border-radius: 4px;
    cursor: pointer;
    font-size: 12px;
}

.action-btns button:hover {
    background: #161b22;
    border-color: #8b949e;
}

.action-btns .delete-btn {
    color: #ef4444;
}

/* Modal */
.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.8);
    z-index: 1000;
    align-items: center;
    justify-content: center;
}

.modal.active {
    display: flex;
}

.modal-content {
    background: #161b22;
    border-radius: 8px;
    width: 90%;
    max-width: 600px;
    max-height: 90vh;
    overflow-y: auto;
    box-shadow: 0 4px 6px rgba(0,0,0,0.5);
    border: 1px solid #30363d;
    animation: modalSlideIn 0.3s ease-out;
    margin-top: 60px;
}

@keyframes modalSlideIn {
    from {
        opacity: 0;
        transform: translateY(-30px) scale(0.95);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 24px 28px;
    border-bottom: 1px solid #30363d;
}

.modal-header h2 {
    font-size: 20px;
    font-weight: 600;
}

.close-btn {
    background: none;
    border: none;
    font-size: 28px;
    cursor: pointer;
    color: #8b949e;
    line-height: 1;
    padding: 0;
    margin: -4px;
}

.close-btn:hover {
    color: #e6edf3;
}

/* Form */
#assetForm,
#settingsForm {
    padding: 28px;
}

.form-group {
    margin-bottom: 20px;
    position: relative;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 500;
    font-size: 14px;
    color: #e6edf3;
}

.form-group input,
.form-group select {
    width: 100%;
    padding: 10px 14px;
    border: 1px solid #30363d;
    border-radius: 6px;
    font-size: 14px;
    background: #0d1117;
    color: #e6edf3;
    transition: border-color 0.2s, background-color 0.2s;
}

.form-group input:focus,
.form-group select:focus {
    outline: none;
    border-color: #238636;
    background: #010409;
}

.form-group input::placeholder {
    color: #6e7681;
}

.form-group small {
    display: block;
    margin-top: 6px;
    color: #8b949e;
    font-size: 12px;
    line-height: 1.5;
}

.form-group small a {
    color: #58a6ff;
    text-decoration: none;
    transition: color 0.2s;
}

.form-group small a:hover {
    color: #79c0ff;
    text-decoration: underline;
}

.help-text {
    display: block;
    font-size: 12px;
    color: #8b949e;
    margin-top: 4px;
}

.form-section {
    margin: 20px 0;
    padding: 15px;
    background: #0d1117;
    border-radius: 6px;
    border: 1px solid #21262d;
}

.form-section h3 {
    font-size: 16px;
    margin-bottom: 10px;
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 15px;
}

.qty-adjust {
    margin-top: 8px;
    padding: 10px;
    background: #0d1117;
    border-radius: 4px;
    border: 1px solid #30363d;
    display: flex;
    align-items: center;
    gap: 8px;
}

.btn-adjust {
    padding: 6px 12px;
    border: 1px solid #30363d;
    border-radius: 4px;
    background: #21262d;
    color: #e6edf3;
    cursor: pointer;
    font-size: 13px;
    transition: all 0.2s;
}

.btn-adjust:hover {
    background: #30363d;
}

.btn-adjust.btn-add {
    background: #1a7f37;
    border-color: #1a7f37;
}

.btn-adjust.btn-add:hover {
    background: #2ea043;
}

.btn-adjust.btn-remove {
    background: #da3633;
    border-color: #da3633;
}

.btn-adjust.btn-remove:hover {
    background: #f85149;
}

.qty-adjust input {
    background: #161b22;
    border: 1px solid #30363d;
    color: #e6edf3;
    padding: 6px 10px;
    border-radius: 4px;
    text-align: center;
    width: 100px;
    flex-shrink: 0;
}

.form-actions {
    display: flex;
    justify-content: flex-end;
    gap: 10px;
    margin-top: 24px;
    padding-top: 24px;
    border-top: 1px solid #30363d;
}

/* Autocomplete Dropdown */
.autocomplete-dropdown {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    max-height: 300px;
    overflow-y: auto;
    background: #161b22;
    border: 1px solid #30363d;
    border-radius: 6px;
    margin-top: 4px;
    z-index: 1000;
    box-shadow: 0 4px 8px rgba(0,0,0,0.4);
}

.autocomplete-item {
    padding: 10px 12px;
    cursor: pointer;
    border-bottom: 1px solid #21262d;
    transition: background 0.2s;
}

.autocomplete-item:last-child {
    border-bottom: none;
}

.autocomplete-item:hover {
    background: #21262d;
}

.autocomplete-symbol {
    font-weight: 600;
    color: #58a6ff;
    font-size: 14px;
    margin-bottom: 2px;
}

.autocomplete-name {
    font-size: 12px;
    color: #8b949e;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

/* Charts Page */
.charts-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(400px, 1fr));
    gap: 20px;
    margin-bottom: 20px;
}

.chart-card {
    background: #161b22;
    padding: 20px;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.3);
    border: 1px solid #30363d;
}

.chart-card h3 {
    font-size: 16px;
    font-weight: 600;
    color: #e6edf3;
    margin-bottom: 15px;
}

.chart-card-wide {
    grid-column: 1 / -1;
}

.chart-card canvas {
    max-height: 300px;
}

.chart-card-wide canvas {
    max-height: 400px;
}

/* Performers Section */
.performers-section {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(400px, 1fr));
    gap: 20px;
    margin-bottom: 20px;
}

.performers-card {
    background: #161b22;
    padding: 20px;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.3);
    border: 1px solid #30363d;
}

.performers-card h3 {
    font-size: 16px;
    font-weight: 600;
    color: #e6edf3;
    margin-bottom: 15px;
}

.performers-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.performer-item {
    display: grid;
    grid-template-columns: minmax(180px, 2fr) minmax(150px, 1.5fr) minmax(120px, 1fr);
    align-items: center;
    padding: 12px;
    background: #0d1117;
    border-radius: 6px;
    border: 1px solid #30363d;
    transition: background 0.2s;
    gap: 20px;
}

.performer-item:hover {
    background: #161b22;
}

.performer-info {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.performer-name {
    font-weight: 500;
    color: #e6edf3;
    font-size: 14px;
}

.performer-symbol {
    font-size: 12px;
    color: #8b949e;
    font-family: 'Courier New', monospace;
}

.performer-type {
    font-size: 11px;
    color: #6e7681;
    text-transform: uppercase;
}

.performer-holdings {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 4px;
}

.performer-quantity {
    font-size: 12px;
    color: #8b949e;
    font-family: 'Courier New', monospace;
    white-space: nowrap;
}

.performer-value {
    font-size: 13px;
    font-weight: 500;
    color: #58a6ff;
    white-space: nowrap;
}

.performer-stats {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 4px;
}

.performer-price {
    font-weight: 600;
    color: #e6edf3;
    font-size: 14px;
}

.performer-change {
    font-weight: 600;
    font-size: 13px;
    padding: 2px 6px;
    border-radius: 4px;
}

.performer-change.positive {
    color: #3fb950;
    background: rgba(63, 185, 80, 0.15);
}

.performer-change.negative {
    color: #f85149;
    background: rgba(248, 81, 73, 0.15);
}

.performers-list .no-data {
    text-align: center;
    color: #8b949e;
    padding: 20px;
}

/* History Page */
.history-stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 15px;
    margin-bottom: 20px;
}

.stat-card {
    background: #161b22;
    padding: 20px;
    border-radius: 8px;
    border: 1px solid #30363d;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.stat-card .stat-label {
    font-size: 12px;
    color: #8b949e;
    text-transform: uppercase;
    font-weight: 600;
}

.stat-card .stat-value {
    font-size: 20px;
    font-weight: 600;
    color: #e6edf3;
}

.stat-card .stat-value.positive {
    color: #3fb950;
}

.stat-card .stat-value.negative {
    color: #f85149;
}

.history-table-container {
    background: #161b22;
    padding: 20px;
    border-radius: 8px;
    border: 1px solid #30363d;
    overflow-x: auto;
}

/* Compare Page */
.compare-selector {
    background: #161b22;
    padding: 20px;
    border-radius: 6px;
    border: 1px solid #30363d;
    margin-bottom: 20px;
}

.asset-checkboxes {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin: 15px 0;
    max-height: 400px;
    overflow-y: auto;
}

.asset-checkbox-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px;
    background: #0f1419;
    border: 1px solid #30363d;
    border-radius: 6px;
    cursor: pointer;
}

.asset-checkbox-item:hover {
    border-color: #58a6ff;
}

.asset-info {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.asset-info small {
    color: #8b949e;
    font-size: 12px;
}

.comparison-results {
    margin-top: 30px;
}

.compare-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 15px;
    margin-bottom: 30px;
}

.compare-section {
    background: #161b22;
    padding: 20px;
    border-radius: 6px;
    border: 1px solid #30363d;
    margin-bottom: 20px;
}

.compare-details {
    margin-top: 10px;
    padding-top: 10px;
    border-top: 1px solid #30363d;
    font-size: 13px;
}

.compare-details div {
    margin: 5px 0;
    color: #8b949e;
}

.compare-details strong {
    color: #e6edf3;
}

/* News Page */
.news-filters {
    display: flex;
    gap: 10px;
    margin-bottom: 20px;
}

.news-status {
    padding: 10px;
    border-radius: 6px;
    margin-bottom: 20px;
    text-align: center;
}

.news-status.loading {
    background: #58a6ff20;
    color: #58a6ff;
}

.news-status.error {
    background: #da363320;
    color: #f85149;
}

.news-container {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
    gap: 20px;
}

.news-card {
    background: #161b22;
    border: 1px solid #30363d;
    border-radius: 6px;
    overflow: hidden;
    transition: transform 0.2s, box-shadow 0.2s;
}

.news-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
}

.news-image {
    width: 100%;
    height: 200px;
    background-size: cover;
    background-position: center;
    background-color: #0f1419;
    display: flex;
    align-items: center;
    justify-content: center;
}

.no-image-text {
    font-size: 48px;
    opacity: 0.3;
}

.news-content {
    padding: 15px;
}

.news-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 10px;
    font-size: 12px;
    color: #8b949e;
}

.news-source {
    font-weight: 600;
    color: #58a6ff;
}

.news-date {
    color: #8b949e;
}

.news-headline {
    margin: 0 0 10px 0;
    font-size: 16px;
    line-height: 1.4;
}

.news-headline a {
    color: #e6edf3;
    text-decoration: none;
}

.news-headline a:hover {
    color: #58a6ff;
    text-decoration: underline;
}

.news-summary {
    font-size: 14px;
    line-height: 1.5;
    color: #8b949e;
    margin: 0 0 10px 0;
}

.news-tags {
    font-size: 12px;
    color: #58a6ff;
    font-style: italic;
}

.no-data {
    grid-column: 1 / -1;
    text-align: center;
    padding: 40px;
    color: #8b949e;
    font-size: 16px;
}

/* Responsive */
@media (max-width: 768px) {
    body {
        padding: 10px;
    }
    
    .header-content {
        flex-direction: column;
        align-items: stretch;
    }
    
    .header-controls {
        justify-content: center;
    }
    
    .summary {
        grid-template-columns: 1fr;
    }
    
    .controls {
        flex-direction: column;
        align-items: stretch;
    }
    
    .controls-left {
        flex-direction: column;
        align-items: stretch;
    }
    
    .filter-group {
        flex-wrap: wrap;
    }
    
    .form-row {
        grid-template-columns: 1fr;
    }
}

/* Loading States & Spinners */
.loading-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(15, 20, 25, 0.9);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    z-index: 10000;
    backdrop-filter: blur(4px);
}

.spinner {
    width: 50px;
    height: 50px;
    border: 4px solid #30363d;
    border-top-color: #58a6ff;
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

.spinner-small {
    width: 20px;
    height: 20px;
    border-width: 3px;
}

.spinner-inline {
    display: inline-block;
    vertical-align: middle;
    margin-left: 8px;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

.loading-text {
    margin-top: 20px;
    font-size: 16px;
    color: #8b949e;
    font-weight: 500;
}

.btn-loading {
    position: relative;
    pointer-events: none;
    opacity: 0.7;
}

.btn-loading::after {
    content: "";
    position: absolute;
    width: 16px;
    height: 16px;
    top: 50%;
    right: 10px;
    margin-top: -8px;
    border: 2px solid #ffffff;
    border-radius: 50%;
    border-top-color: transparent;
    animation: spin 0.6s linear infinite;
}

/* Enhanced Error Messages */
.error-message {
    background: linear-gradient(135deg, #2d1e14 0%, #1c1410 100%);
    border-left: 4px solid #f85149;
    padding: 16px 20px;
    border-radius: 6px;
    margin: 15px 0;
    box-shadow: 0 4px 12px rgba(248, 81, 73, 0.15);
    animation: slideIn 0.3s ease-out;
}

.error-message-header {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 8px;
}

.error-icon {
    font-size: 20px;
    color: #f85149;
}

.error-title {
    font-weight: 600;
    color: #f85149;
    font-size: 15px;
}

.error-content {
    color: #c9d1d9;
    font-size: 14px;
    line-height: 1.6;
}

.error-actions {
    margin-top: 12px;
    display: flex;
    gap: 10px;
}

.error-action-btn {
    padding: 6px 12px;
    background: #21262d;
    border: 1px solid #30363d;
    color: #c9d1d9;
    border-radius: 4px;
    font-size: 13px;
    cursor: pointer;
    transition: all 0.2s;
}

.error-action-btn:hover {
    background: #30363d;
    border-color: #484f58;
}

.success-message {
    background: linear-gradient(135deg, #14291e 0%, #0d1f14 100%);
    border-left: 4px solid #22c55e;
    padding: 16px 20px;
    border-radius: 6px;
    margin: 15px 0;
    box-shadow: 0 4px 12px rgba(34, 197, 94, 0.15);
    animation: slideIn 0.3s ease-out;
}

.success-message-header {
    display: flex;
    align-items: center;
    gap: 10px;
}

.success-icon {
    font-size: 20px;
    color: #22c55e;
}

.success-title {
    font-weight: 600;
    color: #22c55e;
    font-size: 15px;
}

.success-content {
    color: #c9d1d9;
    font-size: 14px;
    margin-top: 8px;
    line-height: 1.6;
}

.warning-message {
    background: linear-gradient(135deg, #2d2514 0%, #1c1810 100%);
    border-left: 4px solid #f59e0b;
    padding: 16px 20px;
    border-radius: 6px;
    margin: 15px 0;
    box-shadow: 0 4px 12px rgba(245, 158, 11, 0.15);
    animation: slideIn 0.3s ease-out;
}

.warning-icon {
    color: #f59e0b;
}

.warning-title {
    color: #f59e0b;
}

@keyframes slideIn {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Progress Bar */
.progress-container {
    width: 100%;
    height: 4px;
    background: #161b22;
    border-radius: 2px;
    overflow: hidden;
    margin: 10px 0;
}

.progress-bar {
    height: 100%;
    background: linear-gradient(90deg, #238636 0%, #22c55e 100%);
    border-radius: 2px;
    transition: width 0.3s ease;
    position: relative;
    overflow: hidden;
}

.progress-bar::after {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    bottom: 0;
    right: 0;
    background: linear-gradient(
        90deg,
        transparent,
        rgba(255, 255, 255, 0.3),
        transparent
    );
    animation: shimmer 2s infinite;
}

@keyframes shimmer {
    0% { transform: translateX(-100%); }
    100% { transform: translateX(100%); }
}

/* Skeleton Loading */
.skeleton {
    background: linear-gradient(90deg, #161b22 25%, #1c2128 50%, #161b22 75%);
    background-size: 200% 100%;
    animation: loading 1.5s ease-in-out infinite;
    border-radius: 4px;
}

@keyframes loading {
    0% { background-position: 200% 0; }
    100% { background-position: -200% 0; }
}

.skeleton-text {
    height: 16px;
    margin: 8px 0;
}

.skeleton-title {
    height: 24px;
    width: 60%;
    margin: 8px 0;
}

/* Toast Notifications */
.toast-container {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 9999;
    display: flex;
    flex-direction: column;
    gap: 10px;
    max-width: 400px;
}

.toast {
    background: #161b22;
    border: 1px solid #30363d;
    border-radius: 8px;
    padding: 16px;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.5);
    animation: slideInRight 0.3s ease-out;
    display: flex;
    align-items: flex-start;
    gap: 12px;
}

.toast-success {
    border-left: 4px solid #22c55e;
}

.toast-error {
    border-left: 4px solid #f85149;
}

.toast-warning {
    border-left: 4px solid #f59e0b;
}

.toast-info {
    border-left: 4px solid #58a6ff;
}

.toast-icon {
    font-size: 20px;
    flex-shrink: 0;
}

.toast-content {
    flex: 1;
}

.toast-title {
    font-weight: 600;
    font-size: 14px;
    margin-bottom: 4px;
}

.toast-message {
    font-size: 13px;
    color: #8b949e;
    line-height: 1.5;
}

.toast-close {
    background: none;
    border: none;
    color: #8b949e;
    cursor: pointer;
    font-size: 18px;
    padding: 0;
    width: 20px;
    height: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.toast-close:hover {
    color: #e6edf3;
}

@keyframes slideInRight {
    from {
        opacity: 0;
        transform: translateX(100%);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@media (max-width: 768px) {
    .toast-container {
        left: 20px;
        right: 20px;
        max-width: none;
    }
}
