/* ═══════════════════════════════════════════
   SailGP Performance — Login Page
   ═══════════════════════════════════════════ */

:root {
  --sgp-dark: #061A1B;
  --sgp-surface: #0e2829;
  --sgp-surface-light: #163435;
  --sgp-red: #E23C25;
  --sgp-red-glow: rgba(226, 60, 37, 0.15);
  --sgp-white: #FFFFFF;
  --sgp-muted: rgba(255, 255, 255, 0.5);
  --sgp-border: rgba(255, 255, 255, 0.08);
  --radius: 6px;
}

/* ─── Reset & Page ─── */

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

.login-page {
  font-family: 'Barlow Condensed', sans-serif;
  background: var(--sgp-dark);
  color: var(--sgp-white);
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  overflow-x: hidden;

  /* Diagonal stripe texture — echoes the homepage cards */
  background-image:
    repeating-linear-gradient(
      -45deg,
      transparent,
      transparent 60px,
      rgba(255, 255, 255, 0.012) 60px,
      rgba(255, 255, 255, 0.012) 61px
    );
}

/* ─── Header ─── */

.login-header {
  display: flex;
  align-items: center;
  gap: 24px;
  height: 72px;
  padding: 0 32px;
  background: rgba(0, 0, 0, 0.25);
  border-bottom: 2px solid var(--sgp-red);
  flex-shrink: 0;
}

.login-header__logo {
  display: flex;
  align-items: center;
}

.login-header__logo img {
  display: block;
}

.login-header__title {
  font-weight: 700;
  font-size: 18px;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: rgba(255, 255, 255, 0.88);
}

/* ─── Main area — vertically centres the card ─── */

.login-main {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 40px 20px;
}

/* ─── Card ─── */

.login-card {
  position: relative;
  width: 100%;
  max-width: 420px;
  background: var(--sgp-surface);
  border: 1px solid var(--sgp-border);
  border-radius: var(--radius);
  overflow: hidden;

  /* Entrance animation */
  animation: card-enter 0.5s cubic-bezier(0.22, 1, 0.36, 1) both;
}

@keyframes card-enter {
  from {
    opacity: 0;
    transform: translateY(16px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Red top accent bar */
.login-card__accent {
  height: 3px;
  background: var(--sgp-red);
}

.login-card__body {
  padding: 40px 36px 36px;
}

/* ─── Heading ─── */

.login-card__heading {
  font-weight: 700;
  font-size: 32px;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  line-height: 1;
  margin-bottom: 6px;
}

.login-card__sub {
  font-size: 15px;
  font-weight: 400;
  color: var(--sgp-muted);
  letter-spacing: 0.02em;
  margin-bottom: 32px;
}

/* ─── Google Button (Primary CTA) ─── */

.google-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 14px;
  width: 100%;
  padding: 0 20px;
  height: 54px;
  background: var(--sgp-white);
  border: none;
  border-radius: var(--radius);
  text-decoration: none;
  cursor: pointer;
  transition: background 0.2s ease, box-shadow 0.2s ease, transform 0.15s ease;
}

.google-btn:hover {
  background: #f1f1f1;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
  transform: translateY(-1px);
}

.google-btn:active {
  transform: translateY(0);
}

.google-btn__icon {
  width: 36px;
  height: 36px;
  flex-shrink: 0;
}

.google-btn__label {
  font-family: 'Barlow Condensed', sans-serif;
  font-weight: 600;
  font-size: 17px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: #333;
}

/* ─── Divider ─── */

.divider {
  display: flex;
  align-items: center;
  gap: 16px;
  margin: 28px 0 24px;
}

.divider::before,
.divider::after {
  content: '';
  flex: 1;
  height: 1px;
  background: var(--sgp-border);
}

.divider__text {
  font-size: 12px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--sgp-muted);
  white-space: nowrap;
}

/* ─── Credentials Form ─── */

.credentials-form__error {
  background: rgba(226, 60, 37, 0.12);
  border-left: 3px solid var(--sgp-red);
  color: #ff8a7a;
  padding: 10px 14px;
  font-size: 14px;
  border-radius: 0 var(--radius) var(--radius) 0;
  margin-bottom: 16px;
}

.field {
  margin-bottom: 16px;
}

.field__label {
  display: block;
  font-size: 12px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: rgba(255, 255, 255, 0.65);
  margin-bottom: 6px;
}

.field__input {
  width: 100%;
  padding: 12px 14px;
  background: var(--sgp-surface-light);
  border: 1px solid var(--sgp-border);
  border-radius: var(--radius);
  color: var(--sgp-white);
  font-family: 'Barlow Condensed', sans-serif;
  font-size: 16px;
  font-weight: 400;
  letter-spacing: 0.02em;
  outline: none;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.field__input:focus {
  border-color: var(--sgp-red);
  box-shadow: 0 0 0 3px var(--sgp-red-glow);
}

.field__input::placeholder {
  color: rgba(255, 255, 255, 0.25);
}

.credentials-form__submit {
  width: 100%;
  padding: 13px 20px;
  margin-top: 8px;
  background: transparent;
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: var(--radius);
  color: var(--sgp-white);
  font-family: 'Barlow Condensed', sans-serif;
  font-weight: 600;
  font-size: 15px;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  cursor: pointer;
  transition: background 0.2s ease, border-color 0.2s ease;
}

.credentials-form__submit:hover {
  background: rgba(255, 255, 255, 0.06);
  border-color: rgba(255, 255, 255, 0.35);
}

.credentials-form__submit:active {
  background: rgba(255, 255, 255, 0.1);
}

/* ─── Responsive ─── */

@media screen and (max-width: 480px) {
  .login-header {
    padding: 0 20px;
    gap: 16px;
  }

  .login-header__logo img {
    width: 110px;
  }

  .login-header__title {
    font-size: 15px;
  }

  .login-main {
    padding: 24px 16px;
  }

  .login-card__body {
    padding: 32px 24px 28px;
  }

  .login-card__heading {
    font-size: 26px;
  }

  .google-btn {
    height: 48px;
  }

  .google-btn__icon {
    width: 30px;
    height: 30px;
  }

  .google-btn__label {
    font-size: 15px;
  }
}