:root {
  --bg-1: #0b0f14;
  --bg-2: #0f1720;
  --accent: #7c5cff;
  --muted: #9aa4b2;
  --glass: rgba(255,255,255,0.03);
  --radius: 14px;
  --valid: #34c759; /* Green for valid input */
  --invalid: #ff3b30; /* Red for invalid input */
  font-family: 'Inter', system-ui, -apple-system, "Segoe UI", Roboto, 'Helvetica Neue', Arial;
}
* { box-sizing: border-box; }
html, body { height: 100%; }
body {
  margin: 0;
  background: radial-gradient(1200px 600px at 10% 10%, rgba(124,92,255,0.08), transparent),
              linear-gradient(180deg, var(--bg-1), var(--bg-2));
  color: #e6eef8;
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

/* Header */
header {
  width: 100%;
  padding: 18px 40px;
  background: rgba(0,0,0,0.4);
  border-bottom: 1px solid rgba(255,255,255,0.05);
  display: flex;
  justify-content: space-between;
  align-items: center;
  position: sticky;
  top: 0;
  z-index: 100;
}
header .logo {
  width: 46px;
  height: 46px;
  border-radius: 10px;
  background: linear-gradient(135deg, var(--accent), #3dd4ff);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  color: #071022;
  font-size: 18px;
}
header nav a {
  margin-left: 20px;
  color: var(--muted);
  text-decoration: none;
  font-weight: 500;
}
header nav a:hover { color: #fff; }

/* Main */
main {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 40px;
}
.container {
  width: 100%;
  max-width: 1100px;
  display: grid;
  grid-template-columns: 1fr 420px;
  gap: 28px;
  align-items: start;
}

/* Hero section */
.hero {
  background: linear-gradient(180deg, rgba(255,255,255,0.02), transparent);
  padding: 34px;
  border-radius: var(--radius);
  box-shadow: 0 6px 30px rgba(2,6,23,0.6);
  border: 1px solid rgba(255,255,255,0.03);
  min-height: 420px;
}
.brand {
  display: flex;
  gap: 16px;
  align-items: center;
}
.brand .logo {
  width: 68px;
  height: 68px;
  font-size: 22px;
}
h1 { margin: 12px 0 6px; font-size: 28px; }
p.lead { color: var(--muted); margin: 0 0 18px; max-width: 70%; }

/* Mission and Why-auth */
.mission, .why-auth {
  margin-top: 18px;
  padding: 18px;
  border-radius: 10px;
}
.mission {
  background: var(--glass);
  border: 1px solid rgba(255,255,255,0.02);
}
.mission p { color: var(--muted); line-height: 1.5; }
.why-auth {
  background: linear-gradient(180deg, rgba(124,92,255,0.04), rgba(255,255,255,0.01));
  border: 1px solid rgba(124,92,255,0.06);
}
.why-auth ul { color: var(--muted); }

/* Auth form */
.auth {
  background: linear-gradient(180deg, rgba(255,255,255,0.03), rgba(255,255,255,0.01));
  padding: 22px;
  border-radius: var(--radius);
  border: 1px solid rgba(255,255,255,0.03);
  box-shadow: 0 8px 30px rgba(2,6,23,0.7);
  position: sticky;
  top: 100px;
}
label { 
  display: block; 
  font-size: 13px; 
  color: var(--muted); 
  margin-bottom: 6px; 
  font-weight: 500;
  letter-spacing: 0.3px;
}

/* Updated input styles for modern design */
input[type="text"], input[type="password"], input[type="file"], input[type="email"] {
  width: 100%;
  padding: 14px 16px;
  border-radius: 12px;
  border: 1px solid rgba(255,255,255,0.1);
  background: rgba(255,255,255,0.05);
  color: #e6eef8;
  font-family: inherit;
  font-size: 16px;
  transition: all 0.3s ease;
  box-shadow: inset 0 2px 4px rgba(0,0,0,0.2);
  appearance: none;
  -webkit-appearance: none;
  -moz-appearance: none;
}

/* Validation styles */
input.valid {
  border-color: var(--valid);
  box-shadow: 0 0 8px rgba(52, 199, 89, 0.3);
}
input.invalid {
  border-color: var(--invalid);
  box-shadow: 0 0 8px rgba(255, 59, 48, 0.3);
}

/* Error message styles */
.error-message {
  display: none;
  color: var(--invalid);
  font-size: 12px;
  margin-top: 4px;
  margin-bottom: 8px;
  font-style: italic;
}
.error-message.active {
  display: block;
}

/* Hover and focus effects */
input[type="text"]:hover, 
input[type="password"]:hover, 
input[type="file"]:hover, 
input[type="email"]:hover,
input[type="text"]:focus, 
input[type="password"]:focus, 
input[type="file"]:focus, 
input[type="email"]:focus {
  border-color: var(--accent);
  background: rgba(255,255,255,0.08);
  box-shadow: 0 0 8px rgba(124,92,255,0.3);
  outline: none;
}

/* Placeholder styling */
input[type="text"]::placeholder,
input[type="password"]::placeholder,
input[type="email"]::placeholder,
input[type="file"]::placeholder {
  color: var(--muted);
  opacity: 0.6;
  font-style: italic;
}

/* Custom file input styling to match other inputs */
input[type="file"] {
  padding: 14px 16px;
  line-height: 1.5;
}

/* Hide default file input button and style the entire input */
input[type="file"]::-webkit-file-upload-button,
input[type="file"]::file-selector-button {
  display: none;
}

/* Checkbox styles */
.checkbox-label {
  display: flex;
  align-items: center;
  font-size: 14px;
  color: var(--muted);
}
.checkbox-label input[type="checkbox"] {
  margin-right: 8px;
  width: 18px;
  height: 18px;
  border: 1px solid rgba(255,255,255,0.1);
  border-radius: 6px;
  background: rgba(255,255,255,0.05);
  cursor: pointer;
  transition: all 0.3s ease;
}
.checkbox-label input[type="checkbox"]:checked {
  background: var(--accent);
  border-color: var(--accent);
  box-shadow: 0 0 6px rgba(124,92,255,0.4);
}
.checkbox-label input[type="checkbox"].valid {
  border-color: var(--valid);
  box-shadow: 0 0 6px rgba(52, 199, 89, 0.4);
}
.checkbox-label input[type="checkbox"].invalid {
  border-color: var(--invalid);
  box-shadow: 0 0 6px rgba(255, 59, 48, 0.4);
}
.btn {
  display: inline-block;
  padding: 10px 14px;
  border-radius: 10px;
  border: 0;
  background: linear-gradient(90deg, var(--accent), #3dd4ff);
  color: #071022;
  font-weight: 700;
  cursor: pointer;
}
.link-muted { color: var(--muted); font-size: 14px; text-decoration: none; }
.aux { 
  display: flex; 
  justify-content: space-between; 
  align-items: center;
  margin-top: 6px; 
  flex-wrap: wrap;
  gap: 10px;
}

/* Contacts */
.contacts {
  margin-top: 22px;
  padding: 14px;
  border-radius: 10px;
  background: rgba(255,255,255,0.02);
  border: 1px solid rgba(255,255,255,0.02);
}
.contacts p { margin: 6px 0; color: var(--muted); font-size: 14px; }
.socials { display: flex; gap: 10px; margin-top: 8px; }
.socials a {
  width: 36px; height: 36px;
  display: flex; align-items: center; justify-content: center;
  border-radius: 8px;
  background: rgba(255,255,255,0.02);
  color: var(--muted);
  text-decoration: none;
}

/* Footer */
.local-footer {
  padding: 20px 40px;
  background: rgba(0,0,0,0.4);
  border-top: 1px solid rgba(255,255,255,0.05);
  text-align: center;
  color: var(--muted);
  font-size: 13px;
}

/* Mobile */
@media (max-width:980px) {
  .container { grid-template-columns: 1fr; }
  .hero p.lead { max-width: 100%; }
}

.cookie-warning {
  padding: 12px;
  background: rgba(255,255,255,0.05);
  border: 1px solid rgba(255,255,255,0.1);
  border-radius: 8px;
  margin-bottom: 20px;
  text-align: center;
  color: var(--muted);
  font-size: 14px;
}
.cookie-warning a {
  color: var(--accent);
  text-decoration: none;
}
.cookie-warning a:hover {
  text-decoration: underline;
}

.cookie-popup {
  padding: 12px;
  background: rgba(35, 41, 46, 0.8);
  border: 1px solid rgba(255,255,255,0.1);
  border-radius: 8px;
  margin-bottom: 20px;
  text-align: center;
  color: var(--muted);
  font-size: 14px;

  position: fixed;
  bottom: 20px;
  left: 50%;
  transform: translateX(-50%);
  width: 90%;
  max-width: 1000px;

  display: none;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  z-index: 1000;
}
.cookie-popup p {
  margin: 0;
  color: var(--muted);
  font-size: 14px;
  flex: 1;
}
.cookie-popup a {
  
  color: var(--accent);
  text-decoration: none;
}
.cookie-popup a:hover {
  text-decoration: underline;
}
.cookie-popup .btn {
  padding: 8px 16px;
  font-size: 14px;
}
@media (max-width: 600px) {
  .cookie-popup {
    flex-direction: column;
    text-align: center;
  }
  .cookie-popup .btn {
    width: 100%;
  }
}