:root {
    --background: #ffffff;
    --foreground: #020817;
    --muted: #f1f5f9;
    --muted-foreground: #64748b;
    --border: #e2e8f0;
    --radius: 0.5rem;
    --shadow: 0 1px 2px 0 rgb(0 0 0 / 0.05);
    --shadow-md: 0 4px 6px -1px rgb(0 0 0 / 0.1), 0 2px 4px -2px rgb(0 0 0 / 0.1);
}

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

body {
    font-family: system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    background: var(--background);
    color: var(--foreground);
    height: 100vh;
    overflow: hidden;
}

.app-container {
    display: grid;
    grid-template-columns: 300px 1fr;
    height: 100vh;
    gap: 1rem;
    padding: 1rem;
}

.file-panel {
    background: var(--background);
    border-radius: var(--radius);
    border: 1px solid var(--border);
    box-shadow: var(--shadow);
    padding: 1rem;
    height: calc(100vh - 2rem);
    overflow-y: auto;
}

.platform-section {
    margin-top: 1rem;
}

.platform-section h3 {
    font-size: 0.875rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
}

.file-list {
    background: var(--muted);
    border-radius: var(--radius);
    padding: 0.5rem;
    min-height: 80px;
}

.file-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0.5rem 0.75rem;
    margin: 0.25rem 0;
    background: var(--background);
    border: 1px solid var(--border);
    border-radius: calc(var(--radius) - 0.25rem);
    cursor: move;
    font-size: 0.875rem;
    box-shadow: var(--shadow);
}

.file-item.is-scheduled {
    background-color: #f0f8ff;
}

.file-item.hidden {
    display: none;
}

.file-name {
    flex: 1;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.file-actions {
    display: flex;
    gap: 0.25rem;
    flex-shrink: 0;
}

.file-action-button {
    padding: 0.25rem;
    border: none;
    background: none;
    cursor: pointer;
    color: var(--muted-foreground);
    opacity: 0.7;
    transition: opacity 0.2s;
}

.file-action-button:hover {
    opacity: 1;
}

.file-action-button.calendar {
    color: #3b82f6;
}

.file-action-button.delete {
    color: #ef4444;
}

.calendar-container {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    height: calc(100vh - 2rem);
}

.calendar-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.5rem;
}

.calendar-header button {
    background: var(--background);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 0.5rem 1rem;
    cursor: pointer;
    box-shadow: var(--shadow);
}

.calendar-grid {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 0.5rem;
    flex: 1;
    min-height: 0;
}

.weekday {
    text-align: center;
    font-size: 0.75rem;
    font-weight: 600;
    color: var(--muted-foreground);
    padding: 0.5rem;
}

.calendar-day {
    background: var(--background);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 0.5rem;
    font-size: 0.875rem;
    box-shadow: var(--shadow);
    height: 100%;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.calendar-day.different-month {
    background: var(--muted);
    border-color: transparent;
}

.scheduled-file {
    display: flex;
    align-items: center;
    padding: 0.5rem 0.2rem;
    cursor: pointer;
    background: var(--background);
    border: 1px solid var(--border);
    border-radius: calc(var(--radius) - 0.25rem);
    box-shadow: var(--shadow);
    gap: 0.5rem;
}

.delete-button {
    position: static;
    transform: none;
    border: none;
    background: none;
    cursor: pointer;
    padding: 0.15rem;
    color: #ef4444;
    font-size: 0.875rem;
    opacity: 0.7;
    transition: opacity 0.2s;
    line-height: 1;
    height: 1.25rem;
    width: 1.25rem;
    display: flex;
    align-items: center;
    justify-content: center;
}

.delete-button:hover {
    opacity: 1;
}

.publish-toggle {
    position: static;
    transform: none;
    border: none;
    background: none;
    cursor: pointer;
    padding: 0.15rem;
    border-radius: var(--radius);
    color: var(--muted-foreground);
    line-height: 1;
    height: 1.25rem;
    width: 1.25rem;
    display: flex;
    align-items: center;
    justify-content: center;
}

.scheduled-file.published {
    background: #f0fdf4;
    border-color: #86efac;
}

.file-input {
    font-size: 0.875rem;
    margin: 0.5rem 0;
}

.file-path {
    font-size: 0.75rem;
    color: var(--muted-foreground);
    margin-bottom: 0.5rem;
}

/* Responsive adjustments */
@media (max-width: 1024px) {
    .app-container {
        grid-template-columns: 250px 1fr;
    }
}

@media (max-width: 768px) {
    .app-container {
        grid-template-columns: 1fr;
    }
    
    .file-panel {
        display: none;
    }
    
    .calendar-container {
        height: 100vh;
    }
}

/* Custom scrollbar */
::-webkit-scrollbar {
    width: 6px;
    height: 6px;
}

::-webkit-scrollbar-track {
    background: var(--muted);
    border-radius: var(--radius);
}

::-webkit-scrollbar-thumb {
    background: var(--muted-foreground);
    border-radius: var(--radius);
}

/* Add these new styles */
.content-details {
    flex: 1;
    min-width: 0;
    margin-right: 0.5rem;
}

.content-display {
    font-weight: 500;
    white-space: nowrap;
    overflow-x: scroll; 
    max-width: calc(100%);
    font-size: 0.8rem;
    line-height: 1.2;
}

.content-edit-fields {
    display: none;
    margin-top: 0.5rem;
}

.scheduled-file.editing .content-edit-fields {
    display: block;
}

.content-title,
.content-caption {
    width: 100%;
    border: 1px solid var(--border);
    border-radius: calc(var(--radius) - 0.25rem);
    padding: 0.25rem;
    margin: 0.25rem 0;
    font-size: 0.75rem;
    background: var(--background);
}

.content-caption {
    resize: vertical;
    min-height: 2.5rem;
    max-height: 5rem;
}

.content-buttons {
    
    gap: 0.15rem;
    margin-left: auto;
    flex-shrink: 0;
}

/* Add these styles for the detail panel */
.detail-panel {
    position: fixed;
    top: 0;
    right: -400px; /* Start off-screen */
    width: 400px;
    height: 100vh;
    background: var(--background);
    border-left: 1px solid var(--border);
    box-shadow: var(--shadow-md);
    transition: right 0.3s ease;
    z-index: 1000;
}

.detail-panel.open {
    right: 0;
}

.detail-panel-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem;
    border-bottom: 1px solid var(--border);
}

.close-panel-button {
    border: none;
    background: none;
    font-size: 1.5rem;
    cursor: pointer;
    color: var(--muted-foreground);
    padding: 0.5rem;
}

.detail-panel-content {
    padding: 1rem;
    height: calc(100vh - 4rem);
    overflow-y: auto;
}

.detail-form {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.form-group label {
    font-size: 0.875rem;
    font-weight: 500;
    color: var(--muted-foreground);
}

.filename-display {
    font-size: 0.875rem;
    padding: 0.5rem;
    background: var(--muted);
    border-radius: var(--radius);
}

#detail-title {
    padding: 0.5rem;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    font-size: 0.875rem;
}

#detail-caption {
    padding: 0.5rem;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    font-size: 0.875rem;
    min-height: 100px;
    resize: vertical;
}

.detail-publish-toggle {
    align-self: flex-start;
    padding: 0.5rem 1rem;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    background: var(--background);
    cursor: pointer;
    font-size: 0.875rem;
}

/* Add overlay when panel is open */
.panel-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.3);
    z-index: 999;
}

.panel-overlay.active {
    display: block;
}

.day-number {
    font-size: 0.75rem;
    color: var(--muted-foreground);
    margin-bottom: 0.5rem;
}

/* Add these new styles */
.panel-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
}

.toggle-scheduled {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    background: var(--background);
    cursor: pointer;
    font-size: 0.75rem;
    color: var(--muted-foreground);
}

.toggle-switch {
    width: 2rem;
    height: 1rem;
    background: var(--muted);
    border-radius: 1rem;
    position: relative;
    transition: background-color 0.2s;
}

.toggle-switch::after {
    content: '';
    position: absolute;
    width: 0.8rem;
    height: 0.8rem;
    background: var(--background);
    border-radius: 50%;
    top: 0.1rem;
    left: 0.1rem;
    transition: transform 0.2s;
}

.toggle-scheduled.active {
    color: var(--foreground);
}

.toggle-scheduled.active .toggle-switch {
    background: #22c55e;
}

.toggle-scheduled.active .toggle-switch::after {
    transform: translateX(1rem);
}

.calendar-icon {
    margin-left: 0.5rem;
    opacity: 0.7;
    display: none; /* Hidden by default */
}

/* Add these styles */
.status-row {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 2rem;
}

.status-row > div {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.detail-scheduled-toggle {
    padding: 0.5rem 1rem;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    background: var(--background);
    cursor: pointer;
    font-size: 0.875rem;
}

.detail-scheduled-toggle.scheduled {
    background: #3b82f6;
    color: white;
    border-color: #2563eb;
}

.clear-all-button {
    padding: 0.5rem 1rem;
    background: #ef4444;
    color: white;
    border: none;
    border-radius: var(--radius);
    cursor: pointer;
    font-size: 0.875rem;
    transition: background-color 0.2s;
}

.clear-all-button:hover {
    background: #dc2626;
}

.modal {
    display: none;
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: var(--background);
    padding: 2rem;
    border-radius: var(--radius);
    box-shadow: var(--shadow-md);
    z-index: 1001;
    max-width: 400px;
    width: 90%;
}

.modal-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
    z-index: 1000;
}

.modal-content {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.modal-buttons {
    display: flex;
    gap: 1rem;
    justify-content: flex-end;
}

.danger-button {
    padding: 0.5rem 1rem;
    background: #ef4444;
    color: white;
    border: none;
    border-radius: var(--radius);
    cursor: pointer;
}

.cancel-button {
    padding: 0.5rem 1rem;
    background: var(--muted);
    border: none;
    border-radius: var(--radius);
    cursor: pointer;
}

.panel-actions {
    display: flex;
    gap: 0.5rem;
}

.export-button {
    padding: 0.5rem 1rem;
    background: #22c55e;
    color: white;
    border: none;
    border-radius: var(--radius);
    cursor: pointer;
    font-size: 0.875rem;
    transition: background-color 0.2s;
}

.export-button:hover {
    background: #16a34a;
}
 