/*!*******************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************!*\
  !*** css ./node_modules/next/dist/build/webpack/loaders/css-loader/src/index.js??ruleSet[1].rules[14].oneOf[2].use[1]!./node_modules/next/dist/build/webpack/loaders/next-font-loader/index.js??ruleSet[1].rules[14].oneOf[2].use[2]!./node_modules/next/font/google/target.css?{"path":"src/app/layout.tsx","import":"Inter","arguments":[{"subsets":["latin","cyrillic"]}],"variableName":"inter"} ***!
  \*******************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************/
/* cyrillic-ext */
@font-face {
  font-family: 'Inter';
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
  src: url(/_next/static/media/ba9851c3c22cd980-s.woff2) format('woff2');
  unicode-range: U+0460-052F, U+1C80-1C8A, U+20B4, U+2DE0-2DFF, U+A640-A69F, U+FE2E-FE2F;
}
/* cyrillic */
@font-face {
  font-family: 'Inter';
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
  src: url(/_next/static/media/21350d82a1f187e9-s.p.woff2) format('woff2');
  unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116;
}
/* greek-ext */
@font-face {
  font-family: 'Inter';
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
  src: url(/_next/static/media/c5fe6dc8356a8c31-s.woff2) format('woff2');
  unicode-range: U+1F00-1FFF;
}
/* greek */
@font-face {
  font-family: 'Inter';
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
  src: url(/_next/static/media/19cfc7226ec3afaa-s.woff2) format('woff2');
  unicode-range: U+0370-0377, U+037A-037F, U+0384-038A, U+038C, U+038E-03A1, U+03A3-03FF;
}
/* vietnamese */
@font-face {
  font-family: 'Inter';
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
  src: url(/_next/static/media/df0a9ae256c0569c-s.woff2) format('woff2');
  unicode-range: U+0102-0103, U+0110-0111, U+0128-0129, U+0168-0169, U+01A0-01A1, U+01AF-01B0, U+0300-0301, U+0303-0304, U+0308-0309, U+0323, U+0329, U+1EA0-1EF9, U+20AB;
}
/* latin-ext */
@font-face {
  font-family: 'Inter';
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
  src: url(/_next/static/media/8e9860b6e62d6359-s.woff2) format('woff2');
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
/* latin */
@font-face {
  font-family: 'Inter';
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
  src: url(/_next/static/media/e4af272ccee01ff0-s.p.woff2) format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}@font-face {font-family: 'Inter Fallback';src: local("Arial");ascent-override: 90.44%;descent-override: 22.52%;line-gap-override: 0.00%;size-adjust: 107.12%
}.__className_fcbcbf {font-family: 'Inter', 'Inter Fallback';font-style: normal
}

/*!*****************************************************************************************************************************************************************************************************************************************************************!*\
  !*** css ./node_modules/next/dist/build/webpack/loaders/css-loader/src/index.js??ruleSet[1].rules[14].oneOf[10].use[2]!./node_modules/next/dist/build/webpack/loaders/postcss-loader/src/index.js??ruleSet[1].rules[14].oneOf[10].use[3]!./src/app/globals.css ***!
  \*****************************************************************************************************************************************************************************************************************************************************************/
/* ═══════════════════════════════════════════════════════
   РЕПЕТИТОР — Design System (Archivist's Desk)
   Warm palette, purpose-built for tutor-student product
   ═══════════════════════════════════════════════════════ */

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

:root {
  /* Colors — Warm Archivist */
  --c-primary: #1a1a2e;
  --c-primary-hover: #2d2d44;
  --c-accent: #c9a96e;
  --c-accent-hover: #b89555;
  --c-accent-bg: #faf5eb;
  --c-secondary: #8b8680;
  --c-success: #4a7c59;
  --c-success-bg: #f0f7f2;
  --c-warning: #b8860b;
  --c-warning-bg: #fef9ee;
  --c-danger: #b44a4a;
  --c-danger-bg: #fdf2f2;
  --c-info: #5a7fa5;
  --c-info-bg: #f0f5fa;

  /* Surfaces */
  --c-bg: #f8f6f0;
  --c-surface: #ffffff;
  --c-border: #e8e4dc;
  --c-border-hover: #d5d0c8;
  --c-hover: #f0ece4;

  /* Text */
  --c-text: #1a1a2e;
  --c-text-secondary: #8b8680;
  --c-text-tertiary: #a8a29e;
  --c-text-inverse: #ffffff;

  /* Typography */
  --font: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --text-xs: 0.75rem;
  --text-sm: 0.8125rem;
  --text-base: 0.9375rem;
  --text-lg: 1rem;
  --text-xl: 1.125rem;
  --text-2xl: 1.5rem;
  --text-3xl: 1.875rem;

  /* Spacing */
  --sp-1: 0.25rem;
  --sp-2: 0.5rem;
  --sp-3: 0.75rem;
  --sp-4: 1rem;
  --sp-5: 1.25rem;
  --sp-6: 1.5rem;
  --sp-8: 2rem;
  --sp-10: 2.5rem;
  --sp-12: 3rem;

  /* Radius */
  --r-sm: 6px;
  --r-md: 8px;
  --r-lg: 12px;
  --r-xl: 16px;
  --r-full: 9999px;

  /* Shadows — warmer, softer */
  --shadow-sm: 0 1px 3px rgba(26, 26, 46, 0.04);
  --shadow-md: 0 2px 8px rgba(26, 26, 46, 0.08), 0 1px 2px rgba(26, 26, 46, 0.04);
  --shadow-lg: 0 8px 24px rgba(26, 26, 46, 0.1), 0 2px 8px rgba(26, 26, 46, 0.06);

  /* Layout */
  --sidebar-w: 240px;
  --header-h: 56px;

  /* Transitions — slightly slower for calmer feel */
  --t-fast: 180ms ease;
  --t-normal: 250ms ease;
}

/* ═══════════════════════════════════════════════════════
   BASE
   ═══════════════════════════════════════════════════════ */

html {
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body {
  font-family: var(--font);
  font-size: var(--text-base);
  line-height: 1.5;
  color: var(--c-text);
  background: var(--c-bg);
}

a {
  color: var(--c-primary);
  text-decoration: none;
}

a:hover {
  text-decoration: underline;
}

/* ═══════════════════════════════════════════════════════
   LAYOUT
   ═══════════════════════════════════════════════════════ */

.layout {
  display: flex;
  min-height: 100vh;
}

.layout-content {
  flex: 1 1;
  margin-left: var(--sidebar-w);
  padding: var(--sp-8);
  max-width: 1200px;
}

.layout-content-full {
  flex: 1 1;
  margin-left: var(--sidebar-w);
}

/* Auth pages (no sidebar) */
.layout-auth {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 100vh;
  padding: var(--sp-4);
  background: var(--c-bg);
}

/* ═══════════════════════════════════════════════════════
   SIDEBAR
   ═══════════════════════════════════════════════════════ */

.sidebar {
  position: fixed;
  top: 0;
  left: 0;
  bottom: 0;
  width: var(--sidebar-w);
  background: var(--c-surface);
  border-right: 1px solid var(--c-border);
  display: flex;
  flex-direction: column;
  z-index: 40;
}

.sidebar-logo {
  padding: var(--sp-5) var(--sp-5);
  font-size: var(--text-lg);
  font-weight: 700;
  color: var(--c-text);
  border-bottom: 1px solid var(--c-border);
  display: flex;
  align-items: center;
  gap: var(--sp-2);
}

.sidebar-nav {
  flex: 1 1;
  padding: var(--sp-3) var(--sp-2);
  display: flex;
  flex-direction: column;
  gap: var(--sp-1);
}

.sidebar-link {
  display: flex;
  align-items: center;
  gap: var(--sp-3);
  padding: var(--sp-2) var(--sp-3);
  border-radius: var(--r-md);
  font-size: var(--text-base);
  font-weight: 500;
  color: var(--c-text-secondary);
  text-decoration: none;
  transition: all var(--t-fast);
  cursor: pointer;
}

.sidebar-link:hover {
  background: var(--c-hover);
  color: var(--c-text);
  text-decoration: none;
}

.sidebar-link.active {
  background: var(--c-primary);
  color: var(--c-text-inverse);
}

.sidebar-link .icon {
  width: 20px;
  text-align: center;
  font-size: 16px;
}

.sidebar-footer {
  padding: var(--sp-4) var(--sp-5);
  border-top: 1px solid var(--c-border);
}

.sidebar-user {
  display: flex;
  align-items: center;
  gap: var(--sp-3);
  margin-bottom: var(--sp-3);
}

.sidebar-user-name {
  font-weight: 600;
  font-size: var(--text-sm);
  line-height: 1.2;
}

.sidebar-user-email {
  font-size: var(--text-xs);
  color: var(--c-text-secondary);
}

/* ═══════════════════════════════════════════════════════
   CARD
   ═══════════════════════════════════════════════════════ */

.card {
  background: var(--c-surface);
  border: 1px solid var(--c-border);
  border-radius: var(--r-lg);
  padding: var(--sp-6);
  transition: box-shadow var(--t-fast);
}

.card-hover:hover {
  box-shadow: var(--shadow-md);
}

.card-clickable {
  cursor: pointer;
}

.card-clickable:hover {
  border-color: var(--c-border-hover);
}

/* ═══════════════════════════════════════════════════════
   BUTTON
   ═══════════════════════════════════════════════════════ */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--sp-2);
  padding: var(--sp-2) var(--sp-4);
  border: 1px solid transparent;
  border-radius: var(--r-md);
  font-family: var(--font);
  font-size: var(--text-base);
  font-weight: 500;
  cursor: pointer;
  transition: all var(--t-fast);
  white-space: nowrap;
  line-height: 1.5;
}

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

.btn-sm {
  padding: var(--sp-1) var(--sp-3);
  font-size: var(--text-sm);
}

.btn-lg {
  padding: var(--sp-3) var(--sp-6);
  font-size: var(--text-lg);
}

.btn-primary {
  background: var(--c-primary);
  color: var(--c-text-inverse);
  border-color: var(--c-primary);
}

.btn-primary:hover:not(:disabled) {
  background: var(--c-primary-hover);
}

.btn-secondary {
  background: var(--c-surface);
  color: var(--c-text);
  border-color: var(--c-border);
}

.btn-secondary:hover:not(:disabled) {
  background: var(--c-hover);
  border-color: var(--c-border-hover);
}

.btn-ghost {
  background: transparent;
  color: var(--c-text-secondary);
}

.btn-ghost:hover:not(:disabled) {
  background: var(--c-hover);
  color: var(--c-text);
}

.btn-danger {
  background: var(--c-danger);
  color: var(--c-text-inverse);
}

.btn-danger:hover:not(:disabled) {
  background: #9a3a3a;
}

.btn-success {
  background: var(--c-success);
  color: var(--c-text-inverse);
}

.btn-accent {
  background: var(--c-accent);
  color: var(--c-text-inverse);
}

.btn-accent:hover:not(:disabled) {
  background: var(--c-accent-hover);
}

/* ═══════════════════════════════════════════════════════
   INPUT / SELECT
   ═══════════════════════════════════════════════════════ */

.input-group {
  display: flex;
  flex-direction: column;
  gap: var(--sp-1);
}

.input-group label {
  font-size: var(--text-sm);
  font-weight: 500;
  color: var(--c-text);
}

.input,
.select {
  width: 100%;
  padding: var(--sp-2) var(--sp-3);
  border: 1px solid var(--c-border);
  border-radius: var(--r-md);
  font-family: var(--font);
  font-size: var(--text-base);
  color: var(--c-text);
  background: var(--c-surface);
  transition: border-color var(--t-fast);
  outline: none;
}

.input:focus,
.select:focus {
  border-color: var(--c-accent);
  box-shadow: 0 0 0 3px rgba(201, 169, 110, 0.12);
}

.input::placeholder {
  color: var(--c-text-tertiary);
}

.input-error {
  border-color: var(--c-danger);
}

.error-text {
  font-size: var(--text-xs);
  color: var(--c-danger);
  margin-top: var(--sp-1);
}

/* ═══════════════════════════════════════════════════════
   BADGE
   ═══════════════════════════════════════════════════════ */

.badge {
  display: inline-flex;
  align-items: center;
  padding: 2px var(--sp-2);
  border-radius: var(--r-full);
  font-size: var(--text-xs);
  font-weight: 600;
  line-height: 1.5;
}

.badge-default {
  background: var(--c-hover);
  color: var(--c-text-secondary);
}

.badge-success {
  background: var(--c-success-bg);
  color: #2d5a3a;
}

.badge-warning {
  background: var(--c-warning-bg);
  color: #7a5a0a;
}

.badge-danger {
  background: var(--c-danger-bg);
  color: #8a3a3a;
}

.badge-info {
  background: var(--c-info-bg);
  color: #3a5a7a;
}

.badge-accent {
  background: var(--c-accent-bg);
  color: #8a7040;
}

/* ═══════════════════════════════════════════════════════
   SOURCE CARD — Signature element
   For displaying inherited source text in essay tasks
   ═══════════════════════════════════════════════════════ */

.source-card {
  background: var(--c-hover);
  border-left: 3px solid var(--c-accent);
  border-radius: 0 var(--r-md) var(--r-md) 0;
  padding: var(--sp-4) var(--sp-5);
  margin-bottom: var(--sp-4);
}

.source-card-label {
  font-size: var(--text-xs);
  font-weight: 600;
  color: var(--c-accent);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-bottom: var(--sp-2);
}

.source-card-text {
  font-size: var(--text-base);
  line-height: 1.7;
  color: var(--c-text);
  white-space: pre-wrap;
}

.source-card-text em {
  font-style: italic;
  color: var(--c-text-secondary);
}

/* ═══════════════════════════════════════════════════════
   MODAL
   ═══════════════════════════════════════════════════════ */

.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(26, 26, 46, 0.35);
  -webkit-backdrop-filter: blur(4px);
          backdrop-filter: blur(4px);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 50;
  padding: var(--sp-4);
}

.modal {
  background: var(--c-surface);
  border-radius: var(--r-xl);
  box-shadow: var(--shadow-lg);
  width: 100%;
  max-width: 480px;
  max-height: 90vh;
  overflow-y: auto;
}

.modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: var(--sp-5) var(--sp-6);
  border-bottom: 1px solid var(--c-border);
}

.modal-header h3 {
  font-size: var(--text-lg);
  font-weight: 600;
}

.modal-body {
  padding: var(--sp-6);
}

.modal-footer {
  display: flex;
  justify-content: flex-end;
  gap: var(--sp-3);
  padding: var(--sp-4) var(--sp-6);
  border-top: 1px solid var(--c-border);
}

/* ═══════════════════════════════════════════════════════
   TABLE
   ═══════════════════════════════════════════════════════ */

.table-wrap {
  overflow-x: auto;
}

.table {
  width: 100%;
  border-collapse: collapse;
}

.table th,
.table td {
  padding: var(--sp-3) var(--sp-4);
  text-align: left;
  border-bottom: 1px solid var(--c-border);
  font-size: var(--text-base);
}

.table th {
  font-weight: 600;
  font-size: var(--text-sm);
  color: var(--c-text-secondary);
  background: var(--c-bg);
}

.table tr:hover td {
  background: var(--c-hover);
}

/* ═══════════════════════════════════════════════════════
   GRID
   ═══════════════════════════════════════════════════════ */

.grid {
  display: grid;
  grid-gap: var(--sp-4);
  gap: var(--sp-4);
}

.grid-2 { grid-template-columns: repeat(2, 1fr); }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.grid-4 { grid-template-columns: repeat(4, 1fr); }

@media (max-width: 768px) {
  .grid-2, .grid-3, .grid-4 {
    grid-template-columns: 1fr;
  }
  .layout-content {
    margin-left: 0;
    padding: var(--sp-4);
  }
  .sidebar {
    display: none;
  }
}

@media (min-width: 769px) and (max-width: 1024px) {
  .grid-3, .grid-4 {
    grid-template-columns: repeat(2, 1fr);
  }
}

/* ═══════════════════════════════════════════════════════
   EMPTY STATE
   ═══════════════════════════════════════════════════════ */

.empty-state {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: var(--sp-12) var(--sp-8);
  text-align: center;
}

.empty-state-icon {
  font-size: 48px;
  margin-bottom: var(--sp-4);
  opacity: 0.3;
}

.empty-state-title {
  font-size: var(--text-lg);
  font-weight: 600;
  margin-bottom: var(--sp-2);
}

.empty-state-text {
  color: var(--c-text-secondary);
  font-size: var(--text-sm);
  max-width: 360px;
  margin-bottom: var(--sp-6);
}

/* ═══════════════════════════════════════════════════════
   PROGRESS BAR
   ═══════════════════════════════════════════════════════ */

.progress {
  width: 100%;
  height: 6px;
  background: var(--c-hover);
  border-radius: var(--r-full);
  overflow: hidden;
}

.progress-fill {
  height: 100%;
  background: var(--c-accent);
  border-radius: var(--r-full);
  transition: width var(--t-normal);
}

.progress-success .progress-fill {
  background: var(--c-success);
}

/* ═══════════════════════════════════════════════════════
   AVATAR
   ═══════════════════════════════════════════════════════ */

.avatar {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border-radius: var(--r-full);
  background: var(--c-primary);
  color: var(--c-text-inverse);
  font-size: var(--text-sm);
  font-weight: 600;
  flex-shrink: 0;
}

.avatar-lg {
  width: 48px;
  height: 48px;
  font-size: var(--text-lg);
}

/* ═══════════════════════════════════════════════════════
   SPINNER
   ═══════════════════════════════════════════════════════ */

.spinner {
  width: 20px;
  height: 20px;
  border: 2px solid var(--c-border);
  border-top-color: var(--c-accent);
  border-radius: 50%;
  animation: spin 0.7s linear infinite;
}

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

.spinner-lg {
  width: 32px;
  height: 32px;
  border-width: 3px;
}

/* ═══════════════════════════════════════════════════════
   EXAM TIMER — calm, not alarming
   ═══════════════════════════════════════════════════════ */

.timer-pill {
  display: inline-flex;
  align-items: center;
  gap: var(--sp-1);
  padding: var(--sp-1) var(--sp-3);
  border-radius: var(--r-full);
  font-size: var(--text-sm);
  font-weight: 500;
  font-feature-settings: "tnum";
  font-variant-numeric: tabular-nums;
  transition: all var(--t-normal);
}

.timer-normal {
  background: var(--c-hover);
  color: var(--c-text-secondary);
}

.timer-warning {
  background: var(--c-accent-bg);
  color: var(--c-accent-hover);
}

.timer-critical {
  background: var(--c-danger-bg);
  color: var(--c-danger);
}

/* ═══════════════════════════════════════════════════════
   AUTOSAVE INDICATOR
   ═══════════════════════════════════════════════════════ */

.autosave-dot {
  width: 6px;
  height: 6px;
  border-radius: var(--r-full);
  background: var(--c-success);
  display: inline-block;
  transition: opacity var(--t-fast);
}

.autosave-saving {
  background: var(--c-accent);
  animation: pulse 1s ease-in-out infinite;
}

@keyframes pulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.4; }
}

/* ═══════════════════════════════════════════════════════
   UTILITY
   ═══════════════════════════════════════════════════════ */

.text-secondary { color: var(--c-text-secondary); }
.text-sm { font-size: var(--text-sm); }
.text-xs { font-size: var(--text-xs); }
.font-medium { font-weight: 500; }
.font-semibold { font-weight: 600; }
.font-bold { font-weight: 700; }
.truncate { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0,0,0,0); border: 0; }

/* ═══════════════════════════════════════════════════════
   REDUCED MOTION
   ═══════════════════════════════════════════════════════ */

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}

