:root {
    --bg: #f5f7fb;
    --fg: #1f2a44;
    --muted: #6b7280;
    --primary: #3498db;
    --primary-600: #2980b9;
    --card: #ffffff;
    --ring: rgba(52, 152, 219, 0.35);
    --danger: #e11d48;
    --radius: 14px;
    --shadow: 0 10px 30px rgba(2, 6, 23, 0.08);
  }
  
  html, body { 
    height: 100%; 
  }
  
  body {
    margin: 0;
    font-family: "Roboto", system-ui, -apple-system, Segoe UI, Arial, sans-serif;
    background: radial-gradient(1200px 600px at 10% -10%, #e6f4ff, transparent),
                radial-gradient(1200px 600px at 110% 110%, #eafaf1, transparent),
                var(--bg);
    color: var(--fg);
    display: grid;
    place-items: center;
    padding: 24px;
  }
  
  /* LOGO */
  .site-logo {
    position: fixed;
    top: 12px;
    left: 12px;
    z-index: 10;
  }
  .site-logo img {
    height: 80px;
    width: auto;
  }
  
  /* LANGUAGE SWITCH */
  .lang-switch {
    position: fixed;
    top: 12px;
    right: 12px;
    display: flex;
    gap: 8px;
    z-index: 10;
  }
  .lang-switch button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 36px; 
    height: 36px;
    border-radius: 999px;
    border: 1px solid #e5e7eb;
    background: #fff;
    cursor: pointer;
    box-shadow: 0 2px 8px rgba(0,0,0,.06);
    transition: transform .12s ease, box-shadow .12s ease;
  }
  .lang-switch button:hover { 
    transform: translateY(-1px); 
    box-shadow: 0 6px 14px rgba(0,0,0,.10); 
  }
  .lang-switch img { 
    width: 20px; 
    height: 20px; 
  }
  
  /* CARD */
  .card {
    width: min(880px, 92vw);
    background: var(--card);
    box-shadow: var(--shadow);
    border-radius: var(--radius);
    padding: clamp(20px, 3vw, 36px);
  }
  
  /* HEADER */
  .page-header {
    text-align: center;
    margin-bottom: 16px;
  }
  .page-header h1 {
    margin: 0;
    font-family: "Merriweather", serif;
    font-size: clamp(22px, 3.2vw, 28px);
    line-height: 1.2;
    letter-spacing: -0.01em;
  }
  
  header p {
    margin: 0;
    color: var(--muted);
    font-size: 16px;
    line-height: 1.6;
    text-align: justify;
  }
  
  /* FORM */
  .form {
    margin-top: 22px;
    display: grid;
    gap: 14px;
  }
  
  .field { 
    display: grid; 
    gap: 8px; 
  }
  .field label { 
    font-weight: 700; 
    font-size: 14px; 
  }
  
  .input {
    width: 100%;
    height: 44px;
    border-radius: 10px;
    border: 1px solid #d1d5db;
    padding: 0 12px;
    font-size: 16px;
    outline: none;
    transition: border-color .15s ease, box-shadow .15s ease;
  }
  .input:focus { 
    border-color: var(--primary); 
    box-shadow: 0 0 0 4px var(--ring); 
  }
  .input.invalid { 
    border-color: var(--danger); 
    box-shadow: 0 0 0 4px rgba(225, 29, 72, 0.15); 
  }
  
  /* BUTTONS */
  .actions { 
    display: flex; 
    align-items: center; 
    gap: 12px; 
    margin-top: 6px; 
  }
  
  .btn {
    appearance: none;
    border: none;
    border-radius: 12px;
    padding: 12px 18px;
    font-size: 16px;
    font-weight: 700;
    cursor: pointer;
    background: var(--primary);
    color: white;
    transition: background .15s ease, transform .06s ease;
  }
  .btn:hover { background: var(--primary-600); }
  .btn:active { transform: translateY(1px); }
  .btn[disabled] { background: #cbd5e1; cursor: not-allowed; }
  
  /* THANKS TEXT */
  .thanks {
    margin-top: 6px;
    font-weight: 700;
    text-align: center;
  }
  
  #movie-list {
    display: grid;
    gap: 10px;
  }

  #cardsFieldset {
    border: 0;
    padding: 0;
    margin: 0;
  }

  .drag-enabled #rankBody tr {
    cursor: move;
  }
  .drag-ghost {
    opacity: 0.6;
  }
  .drag-over {
    outline: 2px dashed #3498db;
  }