    :root {
      /* Dark mode (default) */
      --bg-color: #121212;
      --primary-color: #ED1A3B; /* Crimson */
      --link-color: #ED1A3B;
      --link-hover-color: #F1536C; /* Crimson hover */
      --text-color: #F5F5F5; /* Light Grey */
      --secondary-text-color: rgba(255, 255, 255, 0.7); /* Lighter white for secondary text */
      --input-bg: rgba(255, 255, 255, 0.1);
      --input-border: rgba(255, 255, 255, 0.2);
      --input-text: #1A237E; /* Dark Blue (Indigo) */
      --input-placeholder: #424242; /* Darker grey for better contrast */
      --card-bg: rgba(255, 255, 255, 0.05);

      /* Message colors (Bootstrap defaults) */
      --message-success: #4CAF50; /* Green */
      --message-error: #F44336;   /* Red */
      --message-info: #2196F3;    /* Blue */
      --message-warning: #FFC107; /* Amber */

      /* Separator line color */
      --separator-line-color: rgba(255, 255, 255, 0.4);

      /* New signup button colors */
      --signup-button-bg: rgba(255, 255, 255, 0.15);
      --signup-button-border: rgba(255, 255, 255, 0.4);
      --signup-button-text: #F5F5F5;
      --signup-button-hover-bg: rgba(255, 255, 255, 0.25);
      --signup-button-hover-border: var(--primary-color);
      --signup-button-hover-text: var(--primary-color);

      /* Password toggle icon color (though not used in signup, kept for consistency if used elsewhere) */
      --password-toggle-color: #aaa;
      --password-toggle-hover-color: #fff;
    }

    /* Light mode */
    .light-mode {
      --bg-color: #f4f5f7;
      --text-color: #323232;
      --secondary-text-color: rgba(50, 50, 50, 0.7);
      --input-bg: rgba(0, 0, 0, 0.05);
      --input-border: rgba(0, 0, 0, 0.12);
      --input-text: #323232;
      --input-placeholder: #5a5a5a;
      --card-bg: rgba(255, 255, 255, 0.82);
      --separator-line-color: rgba(0, 0, 0, 0.18);
      --signup-button-bg: rgba(0, 0, 0, 0.05);
      --signup-button-border: rgba(0, 0, 0, 0.2);
      --signup-button-text: #323232;
      --signup-button-hover-bg: rgba(0, 0, 0, 0.1);
      --password-toggle-color: #666;
      --password-toggle-hover-color: #000;
    }

    /* Base Styles */
    @font-face {
      font-family: "cambria";
      src: local("cambria"), url("../fonts/cambria.ttf") format("truetype");
      font-display: swap;
    }

    html, body { /* Make html and body take full height for scrollability */
      height: 100%;
    }


    body {
      font-family: cambria, "Segoe UI", Tahoma, Geneva, Verdana, sans-serif;
      background-color: var(--bg-color);
      color: var(--text-color);
      animation: fadeIn 1s ease-in-out;
      margin: 0;
      padding: 20px 0; /* Add some padding top/bottom for content if it scrolls */
      transition: background-color 0.3s ease, color 0.3s ease;
      min-height: 100vh;
      overflow-x: hidden;
      position: relative;
    }








    @keyframes fadeIn {
      from { opacity: 0; transform: translateY(30px); }
      to { opacity: 1; transform: translateY(0); }
    }

    /* Split-screen wrapper */
    .auth-page-wrapper {
      min-height: 100vh;
      display: flex;
      flex-direction: row;
      box-sizing: border-box;
    }

    /* Left panel - branding/image */
    .auth-left-panel {
      flex: 1;
      display: flex;
      align-items: center;
      justify-content: center;
      background: linear-gradient(135deg, #1a1a2e 0%, #16213e 50%, #0f3460 100%);
      position: relative;
      overflow: hidden;
    }

    .auth-left-panel::before {
      content: '';
      position: absolute;
      top: -50%;
      left: -50%;
      width: 200%;
      height: 200%;
      background: radial-gradient(circle, rgba(237, 26, 59, 0.08) 0%, transparent 60%);
      animation: leftPanelGlow 8s ease-in-out infinite;
    }

    @keyframes leftPanelGlow {
      0%, 100% { transform: translate(0, 0); }
      50% { transform: translate(5%, 5%); }
    }

    .auth-left-content {
      text-align: center;
      z-index: 1;
      padding: 2rem;
    }

    .auth-left-logo {
      width: 160px;
      height: auto;
      margin-bottom: 2rem;
      filter: drop-shadow(0 4px 12px rgba(0, 0, 0, 0.3));
      animation: logoFloat 3s ease-in-out infinite;
    }

    .auth-left-title {
      font-size: 2.8rem;
      font-weight: 700;
      color: #fff;
      text-transform: uppercase;
      margin-bottom: 0.5rem;
      letter-spacing: 2px;
    }

    .auth-left-tagline {
      font-size: 1.1rem;
      color: rgba(255, 255, 255, 0.6);
      font-weight: 400;
    }

    /* Right panel - form */
    .auth-right-panel {
      flex: 1;
      display: flex;
      align-items: center;
      justify-content: center;
      padding: 20px;
      overflow-y: auto;
      background-color: var(--bg-color);
    }

    .auth-card {
      backdrop-filter: blur(10px);
      -webkit-backdrop-filter: blur(10px);
      background-color: var(--card-bg);
      border: none;
      border-radius: 16px;
      padding: 2.5rem;
      box-shadow: 0 20px 40px rgba(0, 0, 0, 0.4);
      width: 100%;
      max-width: 420px;
      animation: slideUp 1s ease-in-out;
      flex-shrink: 0;
      margin: auto;
    }

    /* Hide left panel on mobile, show stacked */
    @media (max-width: 768px) {
      .auth-page-wrapper {
        flex-direction: column;
      }

      .auth-left-panel {
        flex: none;
        padding: 2rem 1rem;
        min-height: auto;
      }

      .auth-left-logo {
        width: 80px;
        margin-bottom: 1rem;
      }

      .auth-left-title {
        font-size: 1.8rem;
      }

      .auth-left-tagline {
        font-size: 0.9rem;
      }

      .auth-right-panel {
        flex: 1;
      }
    }

    @keyframes slideUp {
      from { transform: translateY(40px); opacity: 0; }
      to { transform: translateY(0); opacity: 1; }
    }

    .logo-container {
      text-align: center;
      margin-bottom: 2rem;
    }

    .logo-icon {
      width: 20px;
      height: 80px;
      display: flex;
      align-items: center;
      justify-content: center;
      margin: 0 auto 1rem;
      animation: logoFloat 3s ease-in-out infinite;
    }

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

    .logo-icon img {
      height: 70px;
      width: auto;
      object-fit: contain;
      display: block;
      margin: 0 auto;
      filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.2));
      transition: transform 0.3s ease-in-out;
    }

    .logo-icon img:hover {
      transform: scale(1.05);
    }

    .company-name {
      font-size: 2.2rem;
      font-weight: 700;
      text-align: center;
      margin-bottom: 0.5rem;
      color: var(--primary-color);
      text-transform: uppercase;
    }

    .auth-page-title {
      font-size: 1.5rem;
      font-weight: 600;
      color: var(--text-color);
      text-align: center;
      margin-bottom: 1.5rem;
      margin-top: 1rem;
    }

    .form-label {
      font-weight: 600;
      color: #fff;
      margin-bottom: 0.5rem;
      font-size: 0.95rem;
    }

    .form-check-label {
      color: #fff;
      font-size: 0.9rem;
      font-weight: 500;
    }

    /* Light mode form text */
    .light-mode .form-label {
      color: #212121;
    }

    .light-mode .form-check-label {
      color: #212121;
    }

    .form-control {
      background-color: var(--input-bg);
      border: 1px solid var(--input-border);
      color: #fff !important; /* White text for dark mode */
      border-radius: 10px;
      transition: all 0.2s ease-in-out; /* Smooth transition for focus */
    }

    /* Light mode input text */
    .light-mode .form-control {
      color: #212121 !important; /* Dark text for light mode */
    }

    .form-control::placeholder {
      color: transparent;
    }
    .form-control::-webkit-input-placeholder { color: transparent; }
    .form-control:-moz-placeholder { color: transparent; opacity: 0; }
    .form-control::-moz-placeholder { color: transparent; opacity: 0; }
    .form-control:-ms-input-placeholder { color: transparent; }
    .form-control::-ms-input-placeholder { color: transparent; }


    .form-control:focus {
      border-color: var(--primary-color);
      box-shadow: 0 0 0 0.2rem rgba(237, 26, 59, 0.2);
      background-color: rgba(255, 255, 255, 0.2); /* Slightly lighter on focus */
      outline: none;
    }

    /* Autocomplete/Autofill styling - Dark mode */
    .form-control:-webkit-autofill,
    .form-control:-webkit-autofill:hover,
    .form-control:-webkit-autofill:focus,
    .form-control:-webkit-autofill:active {
      -webkit-box-shadow: 0 0 0 30px rgba(255, 255, 255, 0.1) inset !important;
      -webkit-text-fill-color: #fff !important;
      caret-color: #fff !important;
      border: 1px solid var(--input-border) !important;
      transition: background-color 5000s ease-in-out 0s;
    }

    /* Autocomplete/Autofill styling - Light mode */
    .light-mode .form-control:-webkit-autofill,
    .light-mode .form-control:-webkit-autofill:hover,
    .light-mode .form-control:-webkit-autofill:focus,
    .light-mode .form-control:-webkit-autofill:active {
      -webkit-box-shadow: 0 0 0 30px rgba(0, 0, 0, 0.05) inset !important;
      -webkit-text-fill-color: #212121 !important;
      caret-color: #212121 !important;
      border: 1px solid var(--input-border) !important;
    }

    /* Important for inline password eye icon if used (not on signup.html currently) */
    .input-group .form-control {
        flex-grow: 1;
        width: auto;
        min-width: 0; /* Ensures it can shrink on smaller screens */
    }

    .input-group .input-group-text {
        flex-shrink: 0;
        /* Specific styles for the eye toggle button */
        background-color: var(--input-bg);
        border: 1px solid var(--input-border);
        border-left: none; /* Blend with the input field */
        border-top-right-radius: 10px;
        border-bottom-right-radius: 10px;
        color: var(--password-toggle-color);
        cursor: pointer;
        padding: 0.375rem 0.75rem;
        transition: color 0.2s ease, background-color 0.2s ease;
    }

    .input-group .input-group-text:hover {
      color: var(--password-toggle-hover-color);
      background-color: rgba(255, 255, 255, 0.25); /* Slightly lighter on hover */
    }

    /* Adjust rounded corners for input-group elements */
    .input-group > .form-control:not(:last-child) {
        border-top-right-radius: 0;
        border-bottom-right-radius: 0;
    }


    .main-submit-btn {
      width: 100%;
      background: #ED1A3B !important;
      border: none;
      color: #fff;
      padding: 0.5rem 1rem;
      font-weight: 600;
      font-size: 0.9rem;
      border-radius: 8px;
      transition: all 0.3s ease;
      position: relative; /* For ripple effect */
      overflow: hidden; /* For ripple effect */
    }

    .main-submit-btn:hover {
      transform: translateY(-2px);
      box-shadow: 0 6px 20px rgba(237, 26, 59, 0.4);
      background: #F1536C !important; /* Darker red on hover */
    }

    .main-submit-btn:disabled {
      background: #ED1A3B !important;
      opacity: 0.7;
    }

    .auth-links {
      color: var(--link-color);
      font-size: 0.85rem;
      text-decoration: none;
      transition: color 0.3s ease;
    }

    .auth-links:hover {
      color: var(--link-hover-color);
      text-decoration: underline;
    }

    .social-login-btn {
      display: inline-flex;
      align-items: center;
      justify-content: center;
      gap: 0.6rem;
      width: 100%;
      padding: 0.75rem 1.25rem;
      background-color: transparent;
      border: 2px solid rgba(255, 255, 255, 0.3);
      color: #fff;
      text-decoration: none;
      border-radius: 10px;
      font-weight: 600;
      font-size: 0.95rem;
      transition: all 0.3s ease;
      position: relative;
      overflow: hidden;
    }

    .social-login-btn:hover {
      border-color: var(--primary-color);
      color: var(--primary-color);
      background-color: rgba(255, 255, 255, 0.05);
      transform: translateY(-1px);
    }

    /* Light mode social login button */
    .light-mode .social-login-btn {
      border: 2px solid rgba(0, 0, 0, 0.2);
      color: #212121;
      background-color: rgba(255, 255, 255, 0.8);
    }

    .light-mode .social-login-btn:hover {
      border-color: var(--primary-color);
      color: var(--primary-color);
      background-color: rgba(0, 0, 0, 0.05);
    }

    .social-login-btn i {
      font-size: 1.2rem;
    }

    /* Styles for general Django messages */
    .messages-container {
      margin-bottom: 1.5rem;
      text-align: center;
    }

    .alert {
      padding: 0.75rem 1.25rem;
      margin-bottom: 1rem;
      border: 1px solid transparent;
      border-radius: 0.5rem;
      animation: slideInFromTop 0.5s ease-out;
      opacity: 0;
      animation-fill-mode: forwards;
      box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
    }

    @keyframes slideInFromTop {
      0% { transform: translateY(-20px); opacity: 0; }
      100% { transform: translateY(0); opacity: 1; }
    }

    .alert-success {
      color: #0F5132;
      background-color: #D1E7DD;
      border-color: #BADBCC;
    }

    .alert-error { /* Allauth errors often use 'error' tag */
      color: #842029;
      background-color: #F8D7DA;
      border-color: #F5C2C7;
    }

    .alert-info {
        color: #055160;
        background-color: #CCEEF7;
        border-color: #B6D4FE;
    }

    .alert-warning {
        color: #664D03;
        background-color: #FFF3CD;
        border-color: #FFECB5;
    }

    /* Styling for Django form field errors (e.g., specific validation error) */
    .form-error-message {
        color: var(--message-error); /* Uses the general error color */
        font-size: 0.875rem;
        margin-top: 0.25rem;
        margin-bottom: 0.5rem;
        text-align: left;
    }

    /* Custom class for secondary informational text */
    .secondary-text {
      color: var(--secondary-text-color);
      font-size: 0.95rem;
      line-height: 1.5;
    }

    /* Original Separator Line for "OR ACCESS WITH" (as requested, no changes) */
    .separator {
      display: flex;
      align-items: center;
      text-align: center;
      margin: 1.5rem 0;
      color: var(--text-color);
    }

    .separator::before,
    .separator::after {
      content: '';
      flex: 1;
      height: 1px;
      background: linear-gradient(to right, rgba(255, 255, 255, 0) 0%, var(--separator-line-color) 50%, rgba(255, 255, 255, 0) 100%);
      background-color: var(--separator-line-color);
    }

    .separator::before {
      margin-right: 0.75rem;
      background: linear-gradient(to right, rgba(255, 255, 255, 0) 0%, var(--separator-line-color) 100%);
    }

    .separator::after {
      margin-left: 0.75rem;
      background: linear-gradient(to left, rgba(255, 255, 255, 0) 0%, var(--separator-line-color) 100%);
    }

    /* Restyled Signup/Auth toggle section */
    .auth-toggle-section {
      margin-top: 2rem;
      text-align: center;
    }

    .auth-toggle-text {
      color: var(--text-color);
      font-size: 0.95rem;
      margin-bottom: 0.8rem;
    }

    .auth-toggle-button {
      display: inline-block;
      padding: 0.8rem 1.5rem;
      background-color: var(--signup-button-bg);
      border: 1px solid var(--signup-button-border);
      color: var(--signup-button-text);
      text-decoration: none;
      border-radius: 10px;
      font-weight: 600;
      font-size: 0.95rem;
      transition: all 0.3s ease;
      box-shadow: 0 4px 10px rgba(0, 0, 0, 0.2);
    }

    .auth-toggle-button:hover {
      background-color: var(--signup-button-hover-bg);
      border-color: var(--signup-button-hover-border);
      color: var(--signup-button-hover-text);
      transform: translateY(-2px);
      box-shadow: 0 6px 15px rgba(0, 0, 0, 0.3);
    }

    /* Theme Toggle */
    .theme-toggle {
      position: fixed;
      top: 2rem;
      right: 2rem;
      z-index: 1000;
      background: var(--card-bg);
      border: 1px solid var(--input-border);
      border-radius: 50%;
      width: 50px;
      height: 50px;
      display: flex;
      align-items: center;
      justify-content: center;
      cursor: pointer;
      transition: all 0.3s ease;
      box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
      backdrop-filter: blur(10px);
      -webkit-backdrop-filter: blur(10px);
    }

    .theme-toggle:hover {
      transform: scale(1.1);
      box-shadow: 0 4px 16px rgba(0, 0, 0, 0.3);
    }

    .theme-icon {
      font-size: 1.2rem;
      color: var(--text-color);
      transition: transform 0.5s ease;
    }

    /* Ripple effect for buttons (now global in base.html) */
    .ripple {
      position: absolute;
      border-radius: 50%;
      transform: scale(0);
      animation: ripple 0.6s linear;
      background-color: rgba(255, 255, 255, 0.7);
      opacity: 0;
      pointer-events: none; /* Allow clicks to pass through */
    }
    @keyframes ripple {
      to {
        transform: scale(4);
        opacity: 0;
      }
    }


    @media (max-width: 480px) {
      .auth-card {
        padding: 1.5rem;
      }

      .company-name {
        font-size: 1.5rem;
      }

      .auth-toggle-button {
          padding: 0.7rem 1.2rem;
          font-size: 0.9rem;
      }

      .auth-left-panel {
        padding: 1.5rem 1rem;
      }

      .auth-left-logo {
        width: 60px;
        margin-bottom: 0.75rem;
      }

      .auth-left-title {
        font-size: 1.5rem;
      }

      .theme-toggle {
        top: 1rem;
        right: 1rem;
        width: 45px;
        height: 45px;
      }

      .theme-icon {
        font-size: 1rem;
      }
    }
