@import url('https://fonts.googleapis.com/css2?family=Mulish:wght@400;500;600;700&family=Playfair+Display:wght@500;600;700&display=swap');

:root {
  --bg: #050302;
  --bg-2: #0f0b08;
  --card-bg: rgba(5, 3, 2, 0.85);
  --text: #ffffff;
  --text-muted: #b8a99a;
  --border: rgba(212, 175, 55, 0.35);
  --input-bg: rgba(8, 5, 4, 0.9);
  --input-border: rgba(212, 175, 55, 0.4);
  --primary: #d4af37;
  --primary-2: #b8960c;
  --accent: #f5e7a3;
  --primary-disabled: #3a3530;
  --social-size: 48px;
  --icon-size: 32px;
  --error: #ff6b6b;
  --error-bg: rgba(255, 107, 107, 0.14);
  --recaptcha-bg: #1a1714;
  --recaptcha-text: #b8a99a;
  --cookie-bg: rgba(5, 3, 2, 0.98);
  --cookie-gold: #ffc400;
  --cookie-orange: #ffc400;
  --cookie-text: #e8e0d0;
  --cookie-link: #f5e7a3;
  --glow: 0 0 15px rgba(212, 175, 55, 0.25);
}

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

body {
  background: radial-gradient(1200px 600px at 10% 5%, rgba(212, 175, 55, 0.08), transparent 60%),
    radial-gradient(1000px 600px at 90% 15%, rgba(245, 231, 163, 0.06), transparent 55%),
    linear-gradient(135deg, var(--bg), var(--bg-2) 55%, #0d0907 100%);
  color: var(--text);
  font-family: 'Mulish', sans-serif;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 20px;
  line-height: 1.5;
  position: relative;
}

body::before {
  content: '';
  position: fixed;
  inset: 0;
  background: linear-gradient(120deg, rgba(212, 175, 55, 0.06), transparent 35%),
    linear-gradient(300deg, rgba(245, 231, 163, 0.05), transparent 40%);
  mix-blend-mode: screen;
  pointer-events: none;
  z-index: -1;
}

body::after {
  content: '';
  position: fixed;
  inset: 0;
  background-image: radial-gradient(circle at 10% 20%, rgba(212, 175, 55, 0.05), transparent 35%),
    radial-gradient(circle at 80% 15%, rgba(245, 231, 163, 0.04), transparent 40%),
    radial-gradient(circle at 40% 80%, rgba(255, 255, 255, 0.03), transparent 35%);
  opacity: 0.25;
  pointer-events: none;
  z-index: -1;
}

video {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: -1;
  filter: brightness(0.3) contrast(1.1) saturate(0.8);
}

.login-container {
  width: 100%;
  max-width: 420px;
  background: var(--card-bg);
  border-radius: 12px;
  box-shadow: 0 12px 30px rgba(1, 14, 22, 0.7), inset 0 0 0 1px rgba(255, 255, 255, 0.03);
  border: 1px solid var(--border);
  backdrop-filter: blur(14px);
  position: relative;
  padding: 24px;
  margin-bottom: 40px;
  opacity: 0;
  animation: fadeIn 0.8s ease-in-out forwards;
  transition: box-shadow 0.3s ease;
}

.login-container::before {
  content: '';
  position: absolute;
  inset: -1px;
  border-radius: 12px;
  padding: 1px;
  background: linear-gradient(130deg, rgba(212, 175, 55, 0.5), rgba(245, 231, 163, 0.35), rgba(184, 150, 12, 0.45));
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  -webkit-mask-composite: xor;
  mask-composite: exclude;
  pointer-events: none;
}

.login-container:hover {
  box-shadow: 0 16px 36px rgba(1, 14, 22, 0.7), 0 0 20px rgba(212, 175, 55, 0.2);
}

@keyframes fadeIn {
  to { opacity: 1; }
}

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

@keyframes blinkCursor {
  0%, 100% { border-color: transparent; }
  50% { border-color: #d4af37; }
}

.login-header {
  text-align: center;
  margin-bottom: 24px;
}

.promo-text {
  font-size: 12px;
  color: #d4af37;
  text-align: center;
  margin-bottom: 20px;
  font-weight: 500;
  line-height: 1.5;
  border-left: 2px solid #d4af37;
  padding-left: 12px;
  min-height: 55px;
  white-space: normal;
  word-spacing: normal;
  letter-spacing: normal;
}

.promo-text.typing {
  border-right: 2px solid #d4af37;
  animation: blinkCursor 0.8s step-end infinite;
}

.logo {
  width: 220px;
  height: auto;
  margin: 0 auto 24px;
  display: block;
  transition: transform 0.2s ease;
  filter: brightness(1.05) contrast(1.1) drop-shadow(0 0 8px rgba(212, 175, 55, 0.3));
}

.logo:hover {
  transform: scale(1.02);
}

.title {
  font-family: 'Playfair Display', serif;
  font-size: 24px;
  font-weight: 700;
  letter-spacing: 0.6px;
  color: var(--text);
  margin-bottom: 8px;
  position: relative;
  line-height: 1.2;
}

.title::after {
  content: '';
  position: absolute;
  bottom: -6px;
  left: 0;
  width: 100%;
  height: 2px;
  background: linear-gradient(90deg, var(--primary), var(--accent), transparent 80%);
}

.form-group {
  margin-bottom: 16px;
}

label {
  display: block;
  font-size: 13px;
  font-weight: 600;
  color: var(--text-muted);
  margin-bottom: 6px;
  letter-spacing: 0.7px;
}

.input-wrapper {
  position: relative;
}

input {
  width: 100%;
  padding: 12px 12px;
  background: var(--input-bg);
  border: 1px solid var(--input-border);
  border-radius: 8px;
  color: var(--text);
  font-size: 15px;
  transition: all 0.3s ease;
}

input:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 2px rgba(212, 175, 55, 0.2), 0 0 12px rgba(212, 175, 55, 0.2);
  transform: translateY(-1px);
}

input.error {
  border-color: var(--error);
  box-shadow: 0 0 0 2px var(--error-bg);
}

input::placeholder {
  color: #6a5a4a;
}

.password-toggle {
  position: absolute;
  right: 12px;
  top: 50%;
  transform: translateY(-50%);
  cursor: pointer;
  width: 20px;
  height: 20px;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='20' height='20' viewBox='0 0 24 24' fill='none' stroke='%23b8a99a' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M1 12s4-8 11-8 11 8 11 8-4 8-11 8-11-8-11-8z'%3E%3C/path%3E%3Ccircle cx='12' cy='12' r='3'%3E%3C/circle%3E%3C/svg%3E");
  background-size: contain;
  background-repeat: no-repeat;
  transition: opacity 0.2s ease;
  filter: drop-shadow(0 0 4px rgba(212, 175, 55, 0.2));
}

.password-toggle:hover {
  opacity: 0.7;
}

.password-toggle.hide {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='20' height='20' viewBox='0 0 24 24' fill='none' stroke='%23b8a99a' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M17.94 17.94A10.07 10.07 0 0 1 12 20c-7 0-11-8-11-8a18.45 18.45 0 0 1 5.06-5.94M9.9 4.24A9.12 9.12 0 0 1 12 4c7 0 11 8 11 8a18.5 18.5 0 0 1-2.16 3.19m-6.72-1.07a3 3 0 1 1-4.24-4.24'%3E%3C/path%3E%3Cline x1='1' y1='1' x2='23' y2='23'%3E%3C/line%3E%3C/svg%3E");
}

.error-message {
  display: none;
  color: var(--error);
  font-size: 12px;
  margin-top: 4px;
  padding: 4px 8px;
  background: var(--error-bg);
  border-radius: 4px;
  border-left: 3px solid var(--error);
  transition: opacity 0.2s ease;
}

.error-message.show {
  display: block;
}

.need-help {
  text-align: center;
  margin-top: 12px;
  font-size: 13px;
  color: var(--text-muted);
}

.need-help a {
  color: var(--primary);
  text-decoration: none;
}

.need-help a:hover {
  text-decoration: underline;
}

.account-error {
  text-align: center;
  background: var(--error-bg);
  border: 1px solid var(--error);
  border-radius: 4px;
  padding: 16px;
  margin: 16px 0;
  color: var(--error);
  font-size: 14px;
  display: none;
  transition: opacity 0.3s ease;
}

.account-error.show {
  display: block;
}

.signin-btn {
  width: 100%;
  padding: 16px;
  background: linear-gradient(135deg, #2a2520, #1f1b18);
  color: #a09080;
  border: none;
  border-radius: 8px;
  font-size: 16px;
  font-weight: 600;
  cursor: not-allowed;
  transition: all 0.3s ease;
  line-height: 1.2;
  letter-spacing: 0.7px;
}

.signin-btn.enabled {
  background: linear-gradient(120deg, var(--primary), var(--primary-2));
  color: #0a0806;
  cursor: pointer;
  box-shadow: 0 10px 20px rgba(184, 150, 12, 0.25), 0 0 14px rgba(212, 175, 55, 0.3);
}

.signin-btn.enabled:hover {
  background: linear-gradient(120deg, #e8c84a, #c9a520);
  transform: translateY(-1px);
}

.signin-btn.loading {
  background: var(--primary);
  color: #0a0806;
  cursor: wait;
  position: relative;
}

.signin-btn.loading::after {
  content: ' . . .';
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  animation: none;
}

.divider {
  position: relative;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(212, 175, 55, 0.35), transparent);
  margin: 24px 0;
}

.divider::after {
  content: 'Or sign in with';
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  background: var(--card-bg);
  padding: 0 20px;
  font-size: 12px;
  font-weight: 500;
  color: var(--text-muted);
  line-height: 1;
}

.social-buttons {
  display: flex;
  justify-content: space-around;
  gap: 12px;
  margin-bottom: 32px;
  flex-wrap: wrap;
  opacity: 0;
  animation: fadeInUp 0.6s ease-out 0.3s forwards;
}

.social-btn {
  width: var(--social-size);
  height: var(--social-size);
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1px solid rgba(212, 175, 55, 0.25);
  border-radius: 6px;
  transition: all 0.3s ease;
  flex-shrink: 0;
  background: rgba(8, 5, 4, 0.7);
}

.social-btn:hover {
  border-color: var(--primary);
  background: rgba(212, 175, 55, 0.1);
  transform: scale(1.05);
  box-shadow: 0 0 12px rgba(212, 175, 55, 0.3);
}

.social-btn .icon {
  width: var(--icon-size);
  height: var(--icon-size);
  background-size: contain;
  background-repeat: no-repeat;
  background-position: center;
  filter: brightness(0.9) sepia(1) saturate(3) hue-rotate(-5deg);
}

.social-btn.playstation .icon { background-image: url('https://www.callofduty.com/content/dam/atvi/callofduty/sso/platforms/icon_psn.png?imwidth=32'); }
.social-btn.xbox .icon { background-image: url('https://www.callofduty.com/content/dam/atvi/callofduty/sso/platforms/icon_xbl.png?imwidth=32'); }
.social-btn.battlenet .icon { background-image: url('https://www.callofduty.com/content/dam/atvi/callofduty/sso/platforms/icon_battle.png?imwidth=32'); }
.social-btn.steam .icon { background-image: url('https://www.callofduty.com/content/dam/atvi/callofduty/sso/platforms/icon_steam.png?imwidth=32'); }

.signup-section {
  text-align: center;
  margin-bottom: 32px;
  font-size: 14px;
  font-weight: 400;
  color: var(--text-muted);
  line-height: 1.4;
  opacity: 0;
  animation: fadeInUp 0.6s ease-out 0.5s forwards;
  letter-spacing: 0.4px;
}

.signup-link {
  color: var(--primary);
  text-decoration: none;
  transition: color 0.2s ease;
  margin-left: 0.5em;
}

.signup-link:hover {
  color: #f5e7a3;
  text-decoration: underline;
}

.footer {
  text-align: center;
  width: 100%;
  max-width: 420px;
  padding: 0 20px;
  opacity: 0;
  animation: fadeInUp 0.6s ease-out 0.7s forwards;
}

.lang-selector {
  margin-bottom: 16px;
  position: relative;
}

.lang-btn {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  background: none;
  border: none;
  color: var(--primary);
  font-size: 14px;
  cursor: pointer;
  transition: color 0.2s ease;
}

.lang-btn:hover {
  color: #f5e7a3;
}

.flag {
  width: 16px;
  height: 12px;
  border-radius: 2px;
}

.lang-dropdown {
  display: none;
  position: absolute;
  bottom: 100%;
  left: 0;
  background: rgba(8, 5, 4, 0.96);
  border: 1px solid rgba(212, 175, 55, 0.2);
  border-radius: 8px;
  padding: 12px;
  min-width: 200px;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.3);
  z-index: 10;
  text-align: left;
}

.lang-dropdown.active {
  display: block;
}

.dropdown-item {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 12px;
  color: var(--text);
  font-size: 14px;
  cursor: pointer;
  border-radius: 6px;
  transition: background 0.2s ease;
}

.dropdown-item:hover {
  background: rgba(212, 175, 55, 0.12);
}

.small-logo {
  width: 80px;
  height: auto;
  filter: brightness(0) invert(1);
}

.legal-links {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  gap: 0;
  margin-bottom: 16px;
  font-family: 'Mulish', sans-serif;
  font-size: 12px;
  font-weight: 400;
  line-height: 1.2;
  letter-spacing: 0.5px;
}

.legal-links span {
  color: var(--text-muted);
  padding: 0 4px;
  font-size: 12px;
}

.legal-links a {
  color: var(--text-muted);
  text-decoration: none;
  transition: color 0.2s ease;
  font-size: 12px;
}

.legal-links a:hover {
  color: var(--primary);
}

.footer-logo {
  width: 256px;
  height: auto;
  margin: 16px auto;
  filter: brightness(0) invert(1);
  opacity: 0.6;
}

.copyright {
  font-size: 11px;
  line-height: 1.4;
  color: var(--text-muted);
  max-width: 100%;
  text-align: center;
  font-family: 'Mulish', sans-serif;
  font-weight: 400;
}

.recaptcha-branding {
  font-size: 11px;
  color: var(--text-muted);
  margin-top: 8px;
  text-align: center;
  line-height: 1.3;
  font-family: 'Mulish', sans-serif;
  font-weight: 400;
}

.recaptcha-branding a {
  color: var(--primary);
  text-decoration: none;
  transition: color 0.2s ease;
}

.recaptcha-branding a:hover {
  text-decoration: underline;
}

.cookie-banner {
  position: fixed;
  bottom: 0;
  left: 0;
  width: 100%;
  background: var(--cookie-bg);
  color: var(--cookie-text);
  padding: 16px 24px;
  text-align: left;
  z-index: 1001;
  display: none;
  box-shadow: 0 -6px 20px rgba(2, 10, 16, 0.45);
  font-family: 'Mulish', sans-serif;
  font-size: 12px;
  line-height: 1.3;
  font-weight: 400;
  border-top: 1px solid rgba(212, 175, 55, 0.2);
}

.cookie-banner.show {
  display: block;
}

.cookie-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 8px;
}

.close-btn {
  background: none;
  border: none;
  color: var(--cookie-text);
  font-size: 20px;
  font-weight: bold;
  cursor: pointer;
  line-height: 1;
  padding: 0;
  margin: 0;
  opacity: 0.7;
  transition: opacity 0.2s;
}

.close-btn:hover {
  opacity: 1;
}

.cookie-content {
  max-width: 1200px;
  margin: 0 auto;
}

.cookie-text {
  margin-bottom: 8px;
  white-space: pre-wrap;
}

.cookie-text a {
  color: var(--cookie-link);
  text-decoration: underline;
  font-weight: 500;
}

.cookie-text a:hover {
  text-decoration: none;
}

.cookie-buttons-row {
  display: flex;
  justify-content: flex-end;
  gap: 8px;
  align-items: center;
}
/* دکمه قبول کوکی - طلایی برنزی شیک */
.cookie-btn {
  padding: 6px 12px;
  border: none;
  border-radius: 6px;
  cursor: pointer;
  font-size: 12px;
  font-weight: 600;
  transition: all 0.2s ease;
  color: #0a0806;
  text-decoration: none;
  display: inline-block;
  min-height: 28px;
  line-height: 1.2;
  background: linear-gradient(135deg, #c9a84c 0%, #b8962e 50%, #8b6b1a 100%);
  letter-spacing: 0.5px;
}

.cookie-btn:hover {
  background: linear-gradient(135deg, #dbb95c 0%, #c9a84c 50%, #a08028 100%);
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
}

/* دکمه رد کوکی */
.cookie-btn.reject-btn {
  background: transparent;
  border: 1px solid #c9a84c;
  color: #c9a84c;
  background: rgba(18, 16, 14, 0.5);
}

.cookie-btn.reject-btn:hover {
  background: rgba(201, 168, 76, 0.15);
  border-color: #dbb95c;
  color: #dbb95c;
}

/* دکمه تنظیمات */
.cookie-btn.settings-btn {
  margin-right: auto;
  background: none;
  border: none;
  color: #c9a84c;
  font-weight: 500;
}

.cookie-btn.settings-btn:hover {
  background: none;
  border: none;
  color: #dbb95c;
  transform: none;
  box-shadow: none;
}
@media (max-width: 768px) {
  .cookie-banner {
    padding: 12px 16px;
    font-size: 11px;
  }
  .cookie-text {
    text-align: center;
    margin-bottom: 8px;
  }
  .cookie-buttons-row {
    flex-direction: column;
    gap: 6px;
    width: 100%;
    align-items: stretch;
    justify-content: stretch;
  }
  .cookie-btn {
    width: 100%;
    text-align: center;
  }
  .cookie-btn.settings-btn {
    margin-right: 0;
  }
  .close-btn {
    position: absolute;
    top: 8px;
    right: 12px;
  }
  .cookie-header {
    justify-content: center;
    margin-bottom: 4px;
  }
}

@media (max-width: 480px) {
  .login-container {
    margin: 10px;
    padding: 20px;
  }
  .social-buttons {
    flex-direction: row;
    justify-content: space-evenly;
    gap: 8px;
    flex-wrap: wrap;
    padding: 0 10px;
  }
  .legal-links {
    flex-direction: column;
    align-items: center;
    gap: 4px;
  }
  .legal-links span {
    display: none;
  }
  .social-btn {
    width: 40px;
    height: 40px;
    --social-size: 40px;
  }
  .lang-dropdown {
    min-width: 180px;
    left: 50%;
    transform: translateX(-50%);
  }
  .promo-text {
    font-size: 10px;
    padding: 4px 10px 4px 10px;
  }
}

@media (max-width: 360px) {
  .social-buttons {
    flex-direction: column;
    gap: 8px;
    align-items: center;
  }
  .social-btn {
    width: 50px;
    height: 50px;
  }
  .promo-text {
    font-size: 9px;
  }
}