@import url('https://fonts.googleapis.com/css2?family=Manrope:wght@500;600;700;800&family=Montserrat:wght@400;500;600;700;800&display=swap');

:root {
    --bg: #eaf0f8;
    --panel: rgba(255, 255, 255, 0.92);
    --panel-strong: #ffffff;
    --panel-soft: #f3f7ff;
    --line: #d8e0ef;
    --text: #24304a;
    --muted: #66708a;
    --blue: #202682;
    --blue-2: #3140bd;
    --blue-3: #4f61e6;
    --red: #d32f2f;
    --red-2: #f04c4c;
    --green: #2e9d62;
    --gold: #f0b429;
    --shadow: 0 22px 46px rgba(32, 38, 130, 0.14);
    --shadow-soft: 0 12px 28px rgba(32, 38, 130, 0.1);
    --glow-blue: 0 18px 38px rgba(49, 64, 189, 0.18);
    --glow-red: 0 18px 34px rgba(211, 47, 47, 0.18);
    --radius-xl: 34px;
    --radius-lg: 26px;
    --radius-md: 18px;
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
    font-family: 'Montserrat', sans-serif;
}

h1,
h2,
h3,
h4,
.panel-badge,
.table-badge,
.auth-badge,
.auth-mini,
.stat-card strong {
    font-family: 'Manrope', 'Montserrat', sans-serif;
}

html {
    scroll-behavior: smooth;
}

body {
    min-height: 100vh;
    color: var(--text);
    background:
        radial-gradient(circle at top left, rgba(49, 64, 189, 0.16), transparent 24%),
        radial-gradient(circle at 85% 15%, rgba(79, 97, 230, 0.1), transparent 18%),
        radial-gradient(circle at bottom right, rgba(211, 47, 47, 0.12), transparent 22%),
        linear-gradient(180deg, #eef3fb 0%, #e2eaf7 100%);
    position: relative;
}

body::before {
    content: "";
    position: fixed;
    inset: 0;
    pointer-events: none;
    background-image:
        linear-gradient(rgba(255, 255, 255, 0.12) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255, 255, 255, 0.12) 1px, transparent 1px);
    background-size: 28px 28px;
    mask-image: radial-gradient(circle at center, black 35%, transparent 95%);
    opacity: 0.25;
}

body.modal-open {
    overflow: hidden;
}

button,
input,
select,
textarea {
    font: inherit;
}

.auth-body {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 32px 20px;
}

.auth-shell {
    width: 100%;
    max-width: 1520px;
    min-height: 86vh;
    display: grid;
    grid-template-columns: 1.18fr 0.82fr;
    background: rgba(255, 255, 255, 0.55);
    border: 1px solid rgba(255, 255, 255, 0.72);
    border-radius: 40px;
    overflow: hidden;
    box-shadow: 0 28px 64px rgba(32, 38, 130, 0.15);
    backdrop-filter: blur(12px);
    position: relative;
    animation: shellReveal 0.85s ease;
}

.auth-hero {
    position: relative;
    padding: 78px 72px;
    background:
        radial-gradient(circle at top right, rgba(255, 255, 255, 0.12), transparent 24%),
        linear-gradient(135deg, rgba(32, 38, 130, 0.98), rgba(49, 64, 189, 0.92));
    color: white;
    overflow: hidden;
}

.auth-hero > * {
    position: relative;
    z-index: 2;
}

.auth-hero::before,
.auth-hero::after {
    content: "";
    position: absolute;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.08);
    animation: floatBlob 8s ease-in-out infinite;
}

.auth-hero::before {
    width: 220px;
    height: 220px;
    top: -40px;
    right: -50px;
}

.auth-hero::after {
    width: 160px;
    height: 160px;
    bottom: 40px;
    left: -50px;
    animation-delay: 1.5s;
}

.auth-hero::selection,
.auth-card::selection {
    background: rgba(255, 255, 255, 0.22);
}

.auth-hero-pattern {
    position: absolute;
    inset: 0;
    pointer-events: none;
    opacity: 0.45;
    z-index: 1;
    background:
        radial-gradient(circle at 18% 18%, rgba(255, 255, 255, 0.14) 0, rgba(255, 255, 255, 0.14) 2px, transparent 3px),
        radial-gradient(circle at 70% 28%, rgba(255, 255, 255, 0.08) 0, rgba(255, 255, 255, 0.08) 3px, transparent 4px),
        radial-gradient(circle at 35% 82%, rgba(255, 255, 255, 0.12) 0, rgba(255, 255, 255, 0.12) 2px, transparent 3px);
    background-size: 180px 180px, 260px 260px, 220px 220px;
    animation: shimmerField 12s linear infinite;
}

.auth-badge,
.auth-mini,
.panel-badge,
.table-badge {
    display: inline-flex;
    align-items: center;
    width: fit-content;
    padding: 9px 15px;
    border-radius: 999px;
    font-size: 0.8rem;
    font-weight: 800;
    letter-spacing: 0.4px;
    text-transform: uppercase;
}

.auth-badge {
    background: rgba(255, 255, 255, 0.18);
    margin-bottom: 18px;
    box-shadow: 0 10px 22px rgba(0, 0, 0, 0.12);
    animation: slideUp 0.55s ease;
}

.auth-hero h1 {
    font-family: 'Montserrat', sans-serif;
    font-size: 4rem;
    line-height: 0.95;
    margin-bottom: 20px;
    animation: slideUp 0.7s ease;
    font-weight: 800;
    letter-spacing: -0.03em;
    text-wrap: balance;
    text-transform: uppercase;
    text-shadow: 0 8px 18px rgba(0, 0, 0, 0.12);
}

.auth-hero p {
    max-width: 640px;
    line-height: 1.85;
    color: rgba(255, 255, 255, 0.93);
    font-size: 1.04rem;
    animation: slideUp 0.9s ease;
}

.demo-box {
    position: relative;
    margin-top: 38px;
    padding: 26px;
    border-radius: var(--radius-lg);
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.16);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.15);
    animation: slideUp 1.05s ease;
    overflow: hidden;
}

.demo-box::after {
    content: "";
    position: absolute;
    inset: 0;
    pointer-events: none;
    background: linear-gradient(120deg, transparent 15%, rgba(255, 255, 255, 0.12) 35%, transparent 55%);
    transform: translateX(-120%);
    animation: cardSweep 5.8s ease-in-out infinite;
}

.demo-box h2 {
    font-size: 1.2rem;
    margin-bottom: 14px;
}

.demo-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 14px;
}

.demo-user-btn {
    border: none;
    border-radius: 20px;
    padding: 20px 16px;
    text-align: left;
    font-weight: 800;
    color: var(--blue);
    background: linear-gradient(180deg, #ffffff 0%, #f7f9fe 100%);
    cursor: pointer;
    box-shadow: 0 12px 22px rgba(0, 0, 0, 0.12);
    transition: transform 0.28s ease, box-shadow 0.28s ease, background 0.28s ease, border-color 0.28s ease;
    animation: demoCardEnter 0.75s ease both, demoFloat 4.6s ease-in-out infinite;
    border: 1px solid rgba(255, 255, 255, 0.8);
    position: relative;
    overflow: hidden;
}

.demo-user-btn:nth-child(1) {
    animation-delay: 0.12s, 0s;
}

.demo-user-btn:nth-child(2) {
    animation-delay: 0.22s, 0.35s;
}

.demo-user-btn:nth-child(3) {
    animation-delay: 0.32s, 0.7s;
}

.demo-user-btn:hover {
    transform: translateY(-8px) scale(1.03) rotate(-0.4deg);
    box-shadow: 0 24px 36px rgba(32, 38, 130, 0.24);
    background: linear-gradient(180deg, #ffffff 0%, #eef3ff 100%);
    border-color: rgba(49, 64, 189, 0.22);
}

.demo-user-btn::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(120deg, transparent 18%, rgba(255, 255, 255, 0.55) 42%, transparent 62%);
    transform: translateX(-140%);
    transition: transform 0.8s ease;
    pointer-events: none;
}

.demo-user-btn:hover::after {
    transform: translateX(140%);
}

.demo-user-btn small {
    display: block;
    margin-top: 8px;
    color: var(--muted);
    font-weight: 600;
}

.auth-card {
    padding: 78px 60px;
    background:
        radial-gradient(circle at top right, rgba(211, 47, 47, 0.05), transparent 28%),
        rgba(255, 255, 255, 0.92);
    display: flex;
    flex-direction: column;
    justify-content: center;
    position: relative;
}

.auth-card::before {
    content: "";
    position: absolute;
    top: 28px;
    right: 28px;
    width: 120px;
    height: 120px;
    border-radius: 28px;
    background: radial-gradient(circle, rgba(211, 47, 47, 0.08), transparent 70%);
    pointer-events: none;
    animation: pulseGlow 4.8s ease-in-out infinite;
}

.auth-card-head {
    margin-bottom: 28px;
    animation: slideUp 0.8s ease;
}

.auth-mini {
    background: rgba(32, 38, 130, 0.08);
    color: var(--blue);
    margin-bottom: 14px;
}

.auth-card-head h2 {
    font-size: 2.9rem;
    color: var(--blue);
    margin-bottom: 10px;
    font-weight: 800;
    letter-spacing: -0.045em;
    text-wrap: balance;
}

.auth-card-head p {
    color: var(--muted);
    line-height: 1.8;
}

.auth-form,
.upload-form {
    display: grid;
    gap: 16px;
}

.auth-form label,
.upload-form label {
    display: grid;
    gap: 8px;
    font-weight: 700;
    color: var(--text);
    transition: transform 0.25s ease, color 0.25s ease;
}

.auth-form input,
.upload-form input,
.upload-form textarea,
.upload-form select {
    width: 100%;
    border: 1px solid var(--line);
    border-radius: 16px;
    padding: 15px 16px;
    background: linear-gradient(180deg, #ffffff 0%, #fbfcff 100%);
    color: var(--text);
    outline: none;
    transition: border-color 0.25s ease, box-shadow 0.25s ease, transform 0.25s ease;
}

.auth-form input:hover,
.upload-form input:hover,
.upload-form textarea:hover,
.upload-form select:hover {
    border-color: rgba(49, 64, 189, 0.3);
}

.auth-form input:focus,
.upload-form input:focus,
.upload-form textarea:focus,
.upload-form select:focus {
    border-color: rgba(49, 64, 189, 0.5);
    box-shadow: 0 0 0 4px rgba(49, 64, 189, 0.08), 0 12px 24px rgba(49, 64, 189, 0.08);
    transform: translateY(-1px);
}

.auth-form label:focus-within,
.upload-form label:focus-within {
    color: var(--blue);
    transform: translateX(2px);
}

.upload-form textarea {
    min-height: 120px;
    resize: vertical;
}

.primary-btn,
.secondary-btn,
.outline-btn,
.link-btn,
.file-btn,
.review-btn {
    border: none;
    cursor: pointer;
    border-radius: 14px;
    padding: 13px 18px;
    font-weight: 800;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    transition: transform 0.25s ease, box-shadow 0.25s ease, opacity 0.25s ease, background 0.25s ease, color 0.25s ease;
}

.primary-btn:hover,
.secondary-btn:hover,
.outline-btn:hover,
.link-btn:hover,
.review-btn:hover {
    transform: translateY(-2px) scale(1.01);
}

.primary-btn {
    background: linear-gradient(135deg, var(--red), var(--red-2));
    color: white;
    box-shadow: 0 12px 24px rgba(211, 47, 47, 0.24);
}

.primary-btn:hover {
    box-shadow: 0 18px 30px rgba(211, 47, 47, 0.32);
}

.secondary-btn {
    background: linear-gradient(180deg, #f0f4ff 0%, #e7edfb 100%);
    color: var(--blue);
    box-shadow: 0 10px 20px rgba(32, 38, 130, 0.08);
}

.secondary-btn:hover {
    box-shadow: 0 16px 26px rgba(32, 38, 130, 0.14);
    color: var(--blue-2);
}

.outline-btn {
    background: rgba(255, 255, 255, 0.65);
    border: 2px solid rgba(32, 38, 130, 0.18);
    color: var(--blue);
    box-shadow: 0 10px 20px rgba(32, 38, 130, 0.06);
}

.outline-btn:hover {
    background: linear-gradient(180deg, #ffffff 0%, #f3f6ff 100%);
    box-shadow: 0 16px 26px rgba(32, 38, 130, 0.12);
}

.link-btn,
.review-btn {
    background: linear-gradient(135deg, var(--blue), var(--blue-2));
    color: white;
    padding: 10px 14px;
    border-radius: 12px;
    font-size: 0.9rem;
    box-shadow: 0 12px 22px rgba(32, 38, 130, 0.2);
}

.link-btn:hover,
.review-btn:hover {
    box-shadow: 0 18px 28px rgba(32, 38, 130, 0.28);
}

.file-btn {
    background: linear-gradient(180deg, rgba(46, 157, 98, 0.12), rgba(46, 157, 98, 0.18));
    color: var(--green);
    padding: 10px 14px;
    border-radius: 12px;
    font-size: 0.9rem;
    box-shadow: 0 10px 18px rgba(46, 157, 98, 0.08);
}

.form-message {
    min-height: 24px;
    font-size: 0.95rem;
    font-weight: 700;
}

.auth-form {
    animation: slideUp 0.95s ease;
}

.app-shell {
    width: 100%;
    max-width: 1640px;
    margin: 0 auto;
    padding: 30px 28px 36px;
    position: relative;
    z-index: 1;
}

.topbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 18px;
    margin-bottom: 24px;
    padding: 24px 28px;
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.94) 0%, rgba(247, 250, 255, 0.9) 100%);
    border-radius: 28px;
    box-shadow: var(--shadow);
    animation: fadePop 0.5s ease;
    border: 1px solid rgba(255, 255, 255, 0.7);
}

.brand-block h1 {
    color: var(--blue);
    font-size: 2.25rem;
    margin-bottom: 4px;
    letter-spacing: -0.045em;
    font-weight: 800;
    text-wrap: balance;
}

.brand-block p {
    color: var(--muted);
    line-height: 1.7;
}

.topbar-actions {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
}

.dashboard-grid {
    display: grid;
    grid-template-columns: 0.98fr 1.42fr;
    gap: 24px;
    align-items: start;
}

.panel,
.table-panel,
.stats-panel {
    background:
        radial-gradient(circle at top right, rgba(79, 97, 230, 0.05), transparent 24%),
        linear-gradient(180deg, rgba(255, 255, 255, 0.96) 0%, rgba(247, 250, 255, 0.94) 100%);
    border-radius: 28px;
    box-shadow: var(--shadow);
    animation: fadePop 0.6s ease;
    position: relative;
    overflow: hidden;
}

.panel::before,
.table-panel::before,
.stats-panel::before {
    content: "";
    position: absolute;
    inset: 0 0 auto 0;
    height: 4px;
    background: linear-gradient(90deg, var(--blue), var(--red));
    opacity: 0.9;
}

.panel::after,
.table-panel::after,
.stats-panel::after {
    content: "";
    position: absolute;
    top: 14px;
    right: 18px;
    width: 110px;
    height: 110px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(79, 97, 230, 0.08), transparent 70%);
    pointer-events: none;
}

.panel,
.stats-panel {
    padding: 30px;
}

.table-panel {
    overflow: hidden;
}

.panel-head {
    margin-bottom: 20px;
}

.panel-badge {
    background: rgba(32, 38, 130, 0.08);
    color: var(--blue);
    margin-bottom: 12px;
}

.panel-head h2 {
    color: var(--blue);
    font-size: 2.05rem;
    margin-bottom: 8px;
    letter-spacing: -0.045em;
    font-weight: 800;
    text-wrap: balance;
}

.panel-head p {
    color: var(--muted);
    line-height: 1.75;
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 18px;
}

.stat-card {
    padding: 24px 22px;
    border-radius: 22px;
    background:
        radial-gradient(circle at top right, rgba(49, 64, 189, 0.05), transparent 26%),
        linear-gradient(180deg, #ffffff 0%, #f3f7ff 100%);
    border: 1px solid #edf1f8;
    box-shadow: var(--shadow-soft);
    transition: transform 0.25s ease, box-shadow 0.25s ease;
    animation: slideUp 0.7s ease both;
    position: relative;
    overflow: hidden;
}

.stat-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 16px 28px rgba(32, 38, 130, 0.12);
}

.stat-card::after {
    content: "";
    position: absolute;
    inset: auto -20px -30px auto;
    width: 90px;
    height: 90px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(79, 97, 230, 0.08), transparent 72%);
}

.stat-card h3 {
    font-size: 0.88rem;
    text-transform: uppercase;
    color: var(--muted);
    margin-bottom: 10px;
    letter-spacing: 0.03em;
}

.stat-card strong {
    font-size: 2.1rem;
    color: var(--blue);
    letter-spacing: -0.05em;
    font-weight: 800;
}

.table-head {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 12px;
    padding: 28px 28px 16px;
}

.table-badge {
    background: rgba(211, 47, 47, 0.1);
    color: var(--red);
    margin-bottom: 10px;
}

.table-head h2 {
    color: var(--blue);
    font-size: 2rem;
    letter-spacing: -0.045em;
    font-weight: 800;
    text-wrap: balance;
}

.table-wrap {
    overflow: auto;
    padding: 0 28px 28px;
}

table {
    width: 100%;
    border-collapse: collapse;
    min-width: 1120px;
}

th,
td {
    text-align: left;
    padding: 18px 16px;
    border-bottom: 1px solid #edf1f8;
    vertical-align: top;
}

th {
    color: var(--muted);
    text-transform: uppercase;
    font-size: 0.82rem;
    letter-spacing: 0.06em;
    font-weight: 800;
}

td {
    color: var(--text);
    line-height: 1.55;
}

tbody tr {
    transition: background-color 0.22s ease, transform 0.22s ease;
}

tbody tr:hover {
    background: linear-gradient(90deg, rgba(32, 38, 130, 0.03), rgba(79, 97, 230, 0.035));
    box-shadow: inset 4px 0 0 rgba(32, 38, 130, 0.18);
}

tbody tr.row-pending {
    background: linear-gradient(90deg, rgba(240, 180, 41, 0.05), rgba(240, 180, 41, 0.015));
}

tbody tr.row-reviewed {
    background: linear-gradient(90deg, rgba(46, 157, 98, 0.06), rgba(46, 157, 98, 0.015));
}

tbody tr td:first-child {
    font-weight: 700;
}

.status-pill {
    display: inline-flex;
    padding: 8px 12px;
    border-radius: 999px;
    font-size: 0.82rem;
    font-weight: 800;
}

.status-entregado {
    background: rgba(240, 180, 41, 0.18);
    color: #8b6500;
}

.status-revisado {
    background: rgba(46, 157, 98, 0.16);
    color: #1f7d4a;
}

.empty-box {
    padding: 18px;
    border-radius: 18px;
    background: linear-gradient(180deg, #f8faff 0%, #eef4ff 100%);
    border: 1px dashed #cfd8ea;
    color: var(--muted);
    line-height: 1.7;
}

.file-input {
    border: 2px dashed #cfd8ea !important;
    background:
        radial-gradient(circle at top right, rgba(79, 97, 230, 0.08), transparent 26%),
        linear-gradient(180deg, #fbfcff 0%, #eef4ff 100%) !important;
    padding: 18px !important;
    border-radius: 20px !important;
    min-height: 78px;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.85), 0 14px 24px rgba(32, 38, 130, 0.06);
    cursor: pointer;
    position: relative;
}

.file-input:hover {
    border-color: rgba(49, 64, 189, 0.36) !important;
    box-shadow: var(--glow-blue), 0 18px 30px rgba(32, 38, 130, 0.08);
    transform: translateY(-1px);
}

.file-input::file-selector-button {
    border: none;
    margin-right: 14px;
    padding: 12px 16px;
    border-radius: 14px;
    background: linear-gradient(135deg, var(--blue), var(--blue-2));
    color: white;
    font-weight: 800;
    box-shadow: 0 12px 20px rgba(32, 38, 130, 0.18);
    cursor: pointer;
    transition: transform 0.22s ease, box-shadow 0.22s ease, background 0.22s ease;
}

.file-input:hover::file-selector-button {
    transform: translateY(-1px);
    box-shadow: 0 16px 24px rgba(32, 38, 130, 0.24);
}

.file-helper {
    margin-top: -4px;
    padding: 10px 14px 0;
    color: var(--muted);
    font-size: 0.9rem;
    line-height: 1.6;
}

.preview-box {
    margin-top: 14px;
    padding: 18px;
    border-radius: 20px;
    background:
        radial-gradient(circle at top right, rgba(46, 157, 98, 0.06), transparent 28%),
        linear-gradient(180deg, #fafdff 0%, #eef4ff 100%);
    border: 1px solid #dbe4f2;
    line-height: 1.7;
    color: var(--muted);
    animation: fadePop 0.55s ease;
    box-shadow: 0 14px 24px rgba(32, 38, 130, 0.08);
    position: relative;
    overflow: hidden;
}

.preview-box::before {
    content: "";
    position: absolute;
    inset: 0 0 auto 0;
    height: 4px;
    background: linear-gradient(90deg, var(--blue), var(--red));
    opacity: 0.9;
}

.preview-box strong {
    color: var(--blue);
}

.teacher-actions {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

.review-legend {
    display: flex;
    align-items: center;
    gap: 12px;
    flex-wrap: wrap;
    padding: 0 28px 18px;
}

.legend-pill {
    display: inline-flex;
    align-items: center;
    padding: 9px 14px;
    border-radius: 999px;
    font-size: 0.83rem;
    font-weight: 800;
    box-shadow: 0 10px 18px rgba(32, 38, 130, 0.08);
}

.legend-pending {
    background: rgba(240, 180, 41, 0.18);
    color: #8b6500;
}

.legend-reviewed {
    background: rgba(46, 157, 98, 0.16);
    color: #1f7d4a;
}

.legend-note {
    color: var(--muted);
    font-size: 0.92rem;
    line-height: 1.6;
}

.rating-modal {
    position: fixed;
    inset: 0;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 24px;
    z-index: 3000;
}

.rating-modal.active {
    display: flex;
}

.rating-modal-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(18, 24, 52, 0.48);
    backdrop-filter: blur(6px);
    animation: modalFade 0.22s ease;
}

.rating-modal-card {
    position: relative;
    z-index: 1;
    width: min(100%, 520px);
    padding: 28px 26px;
    border-radius: 26px;
    background:
        radial-gradient(circle at top right, rgba(79, 97, 230, 0.08), transparent 28%),
        linear-gradient(180deg, #ffffff 0%, #f6f9ff 100%);
    box-shadow: 0 28px 60px rgba(18, 24, 52, 0.26);
    border: 1px solid rgba(255, 255, 255, 0.82);
    animation: modalPop 0.26s ease;
}

.rating-modal-badge {
    display: inline-flex;
    align-items: center;
    padding: 8px 13px;
    border-radius: 999px;
    background: rgba(32, 38, 130, 0.08);
    color: var(--blue);
    font-size: 0.78rem;
    font-weight: 800;
    letter-spacing: 0.05em;
    text-transform: uppercase;
    margin-bottom: 14px;
}

.rating-modal-card h2 {
    color: var(--blue);
    font-size: 1.95rem;
    letter-spacing: -0.04em;
    margin-bottom: 10px;
}

.rating-modal-text {
    color: var(--muted);
    line-height: 1.7;
    margin-bottom: 18px;
}

.rating-modal-preview {
    display: grid;
    gap: 10px;
    padding: 18px;
    border-radius: 20px;
    background: linear-gradient(180deg, #ffffff 0%, #eef4ff 100%);
    border: 1px solid rgba(32, 38, 130, 0.1);
    box-shadow: 0 14px 24px rgba(32, 38, 130, 0.08);
    margin-bottom: 20px;
}

.rating-modal-level {
    display: inline-flex;
    width: fit-content;
    padding: 9px 14px;
    border-radius: 999px;
    background: linear-gradient(135deg, rgba(32, 38, 130, 0.12), rgba(79, 97, 230, 0.16));
    color: var(--blue);
    font-weight: 800;
    font-size: 0.92rem;
}

.rating-modal-work {
    color: var(--text);
    font-weight: 700;
    line-height: 1.5;
}

.rating-modal-actions {
    display: flex;
    gap: 12px;
    justify-content: flex-end;
}

.rating-review {
    display: flex;
    gap: 8px;
    flex-wrap: nowrap;
}

.comment-review {
    display: grid;
    gap: 8px;
    min-width: 240px;
}

.comment-input {
    width: 100%;
    min-height: 82px;
    padding: 12px 12px;
    border-radius: 14px;
    border: 1px solid rgba(32, 38, 130, 0.14);
    background: linear-gradient(180deg, #ffffff 0%, #f8faff 100%);
    color: var(--text);
    resize: vertical;
    line-height: 1.55;
    transition: border-color 0.22s ease, box-shadow 0.22s ease, transform 0.22s ease;
}

.comment-input:focus {
    outline: none;
    border-color: rgba(49, 64, 189, 0.34);
    box-shadow: 0 0 0 4px rgba(49, 64, 189, 0.08);
    transform: translateY(-1px);
}

.comment-save-btn {
    border: none;
    cursor: pointer;
    border-radius: 12px;
    padding: 10px 14px;
    font-weight: 800;
    color: white;
    background: linear-gradient(135deg, var(--blue), var(--blue-2));
    box-shadow: 0 12px 20px rgba(32, 38, 130, 0.16);
    transition: transform 0.22s ease, box-shadow 0.22s ease;
}

.comment-save-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 18px 28px rgba(32, 38, 130, 0.24);
}

.row-reviewed .comment-save-btn {
    background: linear-gradient(135deg, #278a54, #39ab71);
    box-shadow: 0 12px 20px rgba(46, 157, 98, 0.18);
}

.row-reviewed .comment-save-btn:hover {
    box-shadow: 0 18px 28px rgba(46, 157, 98, 0.24);
}

.rating-chip {
    border: 1px solid rgba(32, 38, 130, 0.14);
    background: linear-gradient(180deg, #ffffff 0%, #f3f6ff 100%);
    color: var(--blue);
    min-width: 62px;
    padding: 10px 10px 8px;
    border-radius: 14px;
    cursor: pointer;
    box-shadow: 0 8px 16px rgba(32, 38, 130, 0.08);
    transition: transform 0.22s ease, box-shadow 0.22s ease, border-color 0.22s ease, background 0.22s ease;
}

.rating-chip:hover {
    transform: translateY(-2px);
    box-shadow: 0 14px 24px rgba(32, 38, 130, 0.14);
    border-color: rgba(32, 38, 130, 0.28);
}

.rating-chip.active {
    background: linear-gradient(135deg, rgba(32, 38, 130, 0.12), rgba(79, 97, 230, 0.18));
    border-color: rgba(32, 38, 130, 0.34);
    box-shadow: 0 16px 26px rgba(32, 38, 130, 0.16);
}

.rating-chip strong {
    display: block;
    margin-top: 6px;
    font-size: 0.88rem;
    font-family: 'Manrope', 'Montserrat', sans-serif;
}

.rating-chip-dots,
.rating-display {
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

.rating-mini-dot,
.rating-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: rgba(32, 38, 130, 0.16);
    box-shadow: inset 0 1px 1px rgba(255, 255, 255, 0.55);
}

.rating-mini-dot.active,
.rating-dot.active {
    background: linear-gradient(135deg, var(--blue), var(--red));
}

.rating-display {
    padding: 9px 12px;
    border-radius: 999px;
    background: linear-gradient(180deg, #ffffff 0%, #f2f6ff 100%);
    border: 1px solid rgba(32, 38, 130, 0.12);
    box-shadow: 0 10px 18px rgba(32, 38, 130, 0.08);
    white-space: nowrap;
}

.rating-display strong {
    margin-left: 2px;
    color: var(--blue);
    font-size: 0.86rem;
    font-family: 'Manrope', 'Montserrat', sans-serif;
}

.rating-display-1 {
    border-color: rgba(211, 47, 47, 0.14);
}

.rating-display-2 {
    border-color: rgba(79, 97, 230, 0.18);
}

.rating-display-3 {
    border-color: rgba(46, 157, 98, 0.2);
}

.rating-pending {
    display: inline-flex;
    padding: 8px 12px;
    border-radius: 999px;
    background: rgba(240, 180, 41, 0.18);
    color: #8b6500;
    font-weight: 700;
    font-size: 0.84rem;
}

.comment-student {
    max-width: 250px;
    padding: 10px 12px;
    border-radius: 14px;
    background: linear-gradient(180deg, #ffffff 0%, #f3f7ff 100%);
    border: 1px solid rgba(32, 38, 130, 0.12);
    color: var(--text);
    line-height: 1.55;
    box-shadow: 0 10px 18px rgba(32, 38, 130, 0.06);
}

.preview-link {
    background: rgba(240, 180, 41, 0.16);
    color: #8b6500;
}

.page-student .dashboard-grid {
    grid-template-columns: 1.02fr 1.48fr;
}

.page-student .panel {
    box-shadow: 0 20px 42px rgba(32, 38, 130, 0.12);
}

.page-student .table-panel {
    box-shadow: 0 22px 44px rgba(32, 38, 130, 0.12);
}

.page-teacher .table-panel {
    box-shadow: 0 24px 48px rgba(32, 38, 130, 0.14);
}

.page-teacher .table-wrap {
    min-height: 430px;
}

.page-teacher .stats-panel::before {
    background: linear-gradient(90deg, var(--blue), var(--blue-3), var(--red));
}

.page-student .stats-panel::before {
    background: linear-gradient(90deg, var(--blue), var(--red));
}

.panel-badge,
.table-badge,
.auth-badge,
.auth-mini {
    transition: transform 0.25s ease, box-shadow 0.25s ease, background 0.25s ease;
    letter-spacing: 0.06em;
}

.panel-badge:hover,
.table-badge:hover,
.auth-badge:hover,
.auth-mini:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 20px rgba(32, 38, 130, 0.12);
}

label:hover {
    transform: translateX(2px);
}

select:hover,
input:hover,
textarea:hover {
    box-shadow: 0 10px 20px rgba(32, 38, 130, 0.06);
}

@keyframes slideUp {
    from {
        opacity: 0;
        transform: translateY(18px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadePop {
    from {
        opacity: 0;
        transform: translateY(16px) scale(0.985);
    }

    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

@keyframes floatBlob {
    0%, 100% {
        transform: translateY(0px);
    }

    50% {
        transform: translateY(-16px);
    }
}

@keyframes pulseGlow {
    0%, 100% {
        transform: scale(1);
        opacity: 0.7;
    }

    50% {
        transform: scale(1.08);
        opacity: 1;
    }
}

@keyframes shimmerField {
    from {
        transform: translate3d(0, 0, 0);
    }

    50% {
        transform: translate3d(8px, -10px, 0);
    }

    to {
        transform: translate3d(0, 0, 0);
    }
}

@keyframes cardSweep {
    0%, 100% {
        transform: translateX(-120%);
        opacity: 0;
    }

    20% {
        opacity: 1;
    }

    55% {
        transform: translateX(120%);
        opacity: 0.75;
    }

    100% {
        transform: translateX(120%);
        opacity: 0;
    }
}

@keyframes shellReveal {
    from {
        opacity: 0;
        transform: translateY(18px) scale(0.985);
        box-shadow: 0 10px 18px rgba(32, 38, 130, 0.06);
    }

    to {
        opacity: 1;
        transform: translateY(0) scale(1);
        box-shadow: 0 28px 64px rgba(32, 38, 130, 0.15);
    }
}

@keyframes modalFade {
    from {
        opacity: 0;
    }

    to {
        opacity: 1;
    }
}

@keyframes modalPop {
    from {
        opacity: 0;
        transform: translateY(10px) scale(0.97);
    }

    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

@keyframes demoFloat {
    0%, 100% {
        transform: translateY(0px);
    }

    50% {
        transform: translateY(-4px);
    }
}

@keyframes demoCardEnter {
    from {
        opacity: 0;
        transform: translateY(18px) scale(0.96);
    }

    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

@media (max-width: 1180px) {
    .auth-shell,
    .dashboard-grid {
        grid-template-columns: 1fr;
    }

    .demo-grid,
    .stats-grid {
        grid-template-columns: 1fr;
    }

    .auth-shell {
        max-width: 1040px;
        min-height: auto;
    }

    .auth-hero,
    .auth-card {
        padding: 54px 44px;
    }

    .app-shell {
        max-width: 1120px;
        padding: 24px;
    }

    .dashboard-grid,
    .page-student .dashboard-grid {
        grid-template-columns: 1fr;
    }

    .panel,
    .stats-panel {
        padding: 24px;
    }

    .table-wrap {
        padding: 0 22px 22px;
    }

    table {
        min-width: 980px;
    }
}

@media (max-width: 768px) {
    .auth-hero,
    .auth-card,
    .app-shell {
        padding: 20px;
    }

    .auth-hero h1,
    .auth-card-head h2,
    .brand-block h1 {
        font-size: 2rem;
    }

    .panel-head h2,
    .table-head h2 {
        font-size: 1.7rem;
    }

    .auth-hero p,
    .auth-card-head p,
    .panel-head p,
    .brand-block p {
        font-size: 0.96rem;
        line-height: 1.65;
    }

    .auth-shell {
        border-radius: 26px;
    }

    .topbar {
        padding: 18px;
        flex-direction: column;
        align-items: flex-start;
        border-radius: 22px;
    }

    .topbar-actions {
        width: 100%;
    }

    .topbar-actions .outline-btn,
    .topbar-actions .primary-btn {
        flex: 1 1 180px;
    }

    .rating-modal-actions {
        flex-direction: column;
    }

    .table-head {
        padding: 18px 18px 10px;
    }

    .review-legend {
        padding: 0 18px 14px;
    }

    .table-wrap {
        padding: 0 18px 18px;
    }

    .auth-shell {
        min-height: auto;
    }

    table {
        min-width: 920px;
    }

    .stats-grid {
        gap: 14px;
    }

    .stat-card {
        padding: 18px 16px;
        border-radius: 18px;
    }

    .stat-card strong {
        font-size: 1.8rem;
    }

    .panel,
    .stats-panel,
    .table-panel {
        border-radius: 22px;
    }

    .panel,
    .stats-panel {
        padding: 20px;
    }

    .auth-form input,
    .upload-form input,
    .upload-form textarea,
    .upload-form select {
        padding: 14px 14px;
        font-size: 0.95rem;
    }

    .primary-btn,
    .secondary-btn,
    .outline-btn,
    .link-btn,
    .file-btn,
    .review-btn {
        width: 100%;
        min-height: 48px;
    }

    .teacher-actions {
        flex-direction: column;
        align-items: stretch;
    }

    .rating-review {
        flex-wrap: wrap;
    }

    .comment-review {
        min-width: 210px;
    }
}

@media (max-width: 560px) {
    .auth-body {
        padding: 14px;
    }

    .auth-hero,
    .auth-card,
    .app-shell {
        padding: 16px;
    }

    .auth-shell,
    .topbar,
    .panel,
    .stats-panel,
    .table-panel {
        border-radius: 18px;
    }

    .auth-hero h1,
    .auth-card-head h2,
    .brand-block h1 {
        font-size: 1.72rem;
    }

    .panel-head h2,
    .table-head h2 {
        font-size: 1.42rem;
    }

    .auth-badge,
    .auth-mini,
    .panel-badge,
    .table-badge {
        font-size: 0.72rem;
        padding: 7px 12px;
    }

    .demo-box {
        padding: 18px;
    }

    .demo-user-btn {
        padding: 16px 14px;
        border-radius: 16px;
    }

    .stats-grid {
        grid-template-columns: 1fr;
    }

    .table-head {
        padding: 16px 16px 8px;
    }

    .review-legend {
        padding: 0 16px 12px;
    }

    .table-wrap {
        padding: 0 16px 16px;
    }

    .rating-modal {
        padding: 16px;
    }

    .rating-modal-card {
        padding: 22px 18px;
        border-radius: 20px;
    }

    table {
        min-width: 780px;
    }

    th,
    td {
        padding: 14px 12px;
        font-size: 0.92rem;
    }

    .empty-box,
    .preview-box {
        padding: 14px;
        font-size: 0.92rem;
    }
}

@media (max-width: 400px) {
    .auth-hero h1,
    .auth-card-head h2,
    .brand-block h1 {
        font-size: 1.56rem;
    }

    .panel-head h2,
    .table-head h2 {
        font-size: 1.28rem;
    }

    .brand-block p,
    .panel-head p,
    .auth-hero p,
    .auth-card-head p {
        font-size: 0.9rem;
    }

    .topbar {
        gap: 12px;
    }

    .topbar-actions {
        gap: 10px;
    }
}
