:root {
    --bg-color: #F5F3EB;
    --text-color: #1a1a1a;
    --card-bg: #FFFFFF;
    --upload-bg: #F3ECCA;
    --border-color: #000000;
    --accent: #E5D588;
    --shadow: 8px 8px 0px #000000;
    --border-radius: 12px;
}

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

body {
    font-family: 'Inter', sans-serif;
    background-color: var(--bg-color);
    color: var(--text-color);
    min-height: 100vh;
    padding: 2rem;
    overflow-x: hidden;
}

.page-wrapper {
    max-width: 1100px;
    margin: 0 auto;
}

/* Header */
.header {
    margin-bottom: 2.5rem;
}

.header h1 {
    font-family: 'Space Grotesk', sans-serif;
    font-size: 3rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
    letter-spacing: -0.05em;
    color: #000;
}

.header p {
    font-size: 1.1rem;
    color: #444;
    font-weight: 400;
}

/* Layout */
.main-content {
    display: grid;
    grid-template-columns: 1fr 1.5fr;
    gap: 3rem;
    align-items: start;
}

/* Cards */
.card {
    background: var(--card-bg);
    border: 4px solid var(--border-color);
    border-radius: var(--border-radius);
    box-shadow: var(--shadow);
    padding: 2rem;
}

/* Student Details Left Card */
.details-card h2 {
    font-family: 'Space Grotesk', sans-serif;
    font-size: 1.5rem;
    margin-bottom: 1.5rem;
}

.input-group {
    margin-bottom: 1.5rem;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.input-group label {
    font-size: 0.75rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: #333;
}

.input-group input {
    width: 100%;
    padding: 0.875rem 1rem;
    border: 2px solid var(--border-color);
    border-radius: 6px;
    font-family: 'Inter', sans-serif;
    font-size: 1rem;
    outline: none;
    transition: all 0.2s;
}

.input-group input:focus {
    box-shadow: 4px 4px 0px rgba(0,0,0,0.2);
    transform: translate(-2px, -2px);
}

.note-box {
    background: var(--upload-bg);
    border: 2px solid var(--border-color);
    border-radius: 6px;
    padding: 1rem;
    font-size: 0.875rem;
    line-height: 1.5;
    margin-bottom: 1.5rem;
}

.brutal-btn {
    width: 100%;
    background: #000;
    color: #fff;
    border: 2px solid #000;
    padding: 1rem;
    font-size: 1.1rem;
    font-weight: 600;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.2s;
    font-family: 'Inter', sans-serif;
}

.brutal-btn:not(:disabled):hover {
    background: #222;
    transform: translate(-3px, -3px);
    box-shadow: 6px 6px 0px rgba(0,0,0,0.5);
}

.brutal-btn:disabled {
    background: #888;
    cursor: not-allowed;
    border-color: #888;
}

/* Right Column */
.right-column {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.upload-area {
    background: var(--upload-bg);
    border: 3px dashed var(--border-color);
    border-radius: var(--border-radius);
    padding: 4rem 2rem;
    text-align: center;
    cursor: pointer;
    transition: all 0.2s;
}

.upload-area.dragover {
    background: #E5D588;
    transform: scale(1.02);
}

.upload-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1rem;
}

.upload-icon {
    margin-bottom: 0.5rem;
}

.upload-content h3 {
    font-family: 'Space Grotesk', sans-serif;
    font-size: 1.25rem;
}

.upload-content p {
    font-size: 0.9rem;
    color: #444;
}

.file-pill {
    margin-top: 0.5rem;
    background: #fff;
    border: 2px solid var(--border-color);
    border-radius: 20px;
    padding: 0.4rem 1rem;
    font-size: 0.875rem;
    font-weight: 600;
}

/* File List */
.file-list {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.file-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: #fff;
    border: 2px solid var(--border-color);
    border-radius: 8px;
    padding: 0.75rem 1rem;
}

.file-name {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    font-size: 0.875rem;
    font-weight: 500;
}

.btn-remove {
    background: transparent;
    border: none;
    color: #ff3b3b;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: transform 0.2s;
}

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

/* Results section */
.hidden {
    display: none !important;
}

.results-section {
    margin-top: 4rem;
}

.results-section h2 {
    font-family: 'Space Grotesk', sans-serif;
    font-size: 2rem;
    margin-bottom: 1.5rem;
}

.processed-list {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 1.5rem;
}

.processed-item {
    background: #fff;
    border: 3px solid var(--border-color);
    border-radius: 8px;
    padding: 1.5rem;
    box-shadow: 4px 4px 0px #000;
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.processed-name {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-weight: 600;
    font-size: 0.9rem;
    word-break: break-all;
}

.action-buttons {
    display: flex;
    gap: 0.5rem;
    margin-top: auto;
}

.btn-preview {
    flex: 1;
    text-align: center;
    background: #fff;
    color: #000;
    border: 2px solid #000;
    padding: 0.5rem;
    font-weight: 600;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.2s;
}

.btn-preview:hover {
    background: #f0f0f0;
}

.btn-download {
    flex: 1;
    text-align: center;
    text-decoration: none;
    background: var(--border-color);
    color: #fff;
    border: 2px solid #000;
    padding: 0.5rem;
    font-weight: 600;
    border-radius: 6px;
    transition: all 0.2s;
}

.btn-download:hover {
    background: #333;
}

.btn-download-all {
    grid-column: 1 / -1;
    text-align: center;
    background: #10b981;
    color: #fff;
    border: 3px solid #000;
    padding: 1rem;
    font-size: 1.2rem;
    font-weight: 700;
    border-radius: 8px;
    text-decoration: none;
    box-shadow: 6px 6px 0px #000;
    transition: all 0.2s;
    margin-top: 1rem;
}

.btn-download-all:hover {
    transform: translate(-2px, -2px);
    box-shadow: 8px 8px 0px #000;
}

/* Modal */
.modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(4px);
    z-index: 1000;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 2rem;
}

.modal-content {
    width: 100%;
    max-width: 1000px;
    height: 90vh;
    display: flex;
    flex-direction: column;
    padding: 1rem;
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
    padding-bottom: 1rem;
    border-bottom: 2px solid #000;
}

.btn-close {
    background: transparent;
    border: none;
    font-size: 2rem;
    font-weight: 700;
    cursor: pointer;
}

.modal-body {
    flex: 1;
    border: 2px solid #000;
    border-radius: 4px;
}

#previewIframe {
    width: 100%;
    height: 100%;
    border: none;
}

.bug-report-btn {
    position: fixed;
    right: 1.5rem;
    bottom: 1.5rem;
    z-index: 900;
    background: #f97316;
    color: #000;
    border: 3px solid #000;
    border-radius: 999px;
    padding: 0.85rem 1.1rem;
    font-weight: 800;
    cursor: pointer;
    box-shadow: 5px 5px 0 #000;
}

.bug-report-btn:hover {
    transform: translate(-2px, -2px);
    box-shadow: 7px 7px 0 #000;
}

.bug-report-content {
    max-width: 520px;
    height: auto;
    max-height: 90vh;
    overflow-y: auto;
}

.bug-report-content select,
.bug-report-content textarea {
    width: 100%;
    padding: 0.875rem 1rem;
    border: 2px solid var(--border-color);
    border-radius: 6px;
    font: inherit;
    resize: vertical;
}

.bug-report-status {
    min-height: 1.5rem;
    margin-bottom: 0.75rem;
    font-size: 0.9rem;
    font-weight: 600;
}

@media (max-width: 768px) {
    .main-content {
        grid-template-columns: 1fr;
    }

    .bug-report-btn {
        right: 1rem;
        bottom: 1rem;
    }
}
