/* Spreadsheet Content Type Styles */

.spreadsheet-container {
    width: 100%;
}

.spreadsheet-wrapper {
    min-height: 100px;
}

/* Jspreadsheet base overrides */
.jspreadsheet {
    font-family: inherit;
}

/* Dark mode support */
.dark .jspreadsheet {
    background: #1f2937;
    color: #e5e7eb;
}

.dark .jspreadsheet td {
    border-color: #374151;
    background: #111827;
}

.dark .jspreadsheet td.readonly {
    background: #1f2937;
}

.dark .jspreadsheet thead td {
    background: #374151;
    color: #e5e7eb;
    border-color: #4b5563;
}

.dark .jspreadsheet tbody tr:nth-child(even) td {
    background: #1a2332;
}

.dark .jspreadsheet tbody tr:hover td {
    background: #374151;
}

.dark .jspreadsheet td.highlight {
    background: #065f46 !important;
}

.dark .jspreadsheet .jss_content {
    background: #111827;
}

/* Selected cell */
.dark .jspreadsheet td.selected {
    background: #10b981 !important;
    color: white;
}

/* Responsive spreadsheet */
@media (max-width: 768px) {
    .spreadsheet-wrapper {
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
    }

    .jspreadsheet {
        min-width: 600px;
    }
}

/* Formula cells */
.jspreadsheet td[data-formula] {
    font-style: italic;
}

/* Currency formatting */
.jspreadsheet td.currency {
    text-align: right;
}

/* Error state */
.spreadsheet-wrapper .error {
    color: #ef4444;
    padding: 1rem;
    font-style: italic;
}
