:root {
  --ocean-deep: #001021;
  --ocean-mid: #022c46;
  --ocean-wave: #0466c8;
  --ocean-light: #5ec2d1;
  --ocean-glow: rgba(94, 194, 209, 0.45);
  --sand: #f0f6ff;
  --foam: rgba(255, 255, 255, 0.72);
  --coral: #ff6f59;
  --navy: #012a4a;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: 'Poppins', 'Segoe UI', Arial, sans-serif;
  background-color: #044a62;
  color: #fcf9ec;
  min-height: 100vh;
}

a {
  color: inherit;
}

body.landing,
body.app-body {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 60px 20px;
  position: relative;
  overflow-x: hidden;
  overflow-y: auto;
  background: radial-gradient(circle at 18% 18%, #0e5b84 0%, #053053 38%, #011627 100%);
  color: #e6f7ff;
}

body.landing::before,
body.app-body::before {
  content: "";
  position: absolute;
  inset: -30% -10% -20% -10%;
  background: radial-gradient(circle at 30% 20%, rgba(94, 194, 209, 0.25) 0%, transparent 62%), radial-gradient(circle at 70% 110%, rgba(4, 102, 200, 0.2) 0%, transparent 65%);
  z-index: 0;
}

body.landing::after,
body.app-body::after {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at 55% -10%, rgba(255, 255, 255, 0.06), transparent 45%), radial-gradient(circle at -10% 100%, rgba(255, 255, 255, 0.04), transparent 50%);
  mix-blend-mode: screen;
  pointer-events: none;
  z-index: 0;
}

body.app-body {
  justify-content: center;
  align-items: flex-start;
  padding: 64px 32px;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  border: 0;
}

.required-indicator {
  color: var(--coral);
  font-weight: 600;
  font-size: 0.8rem;
}

.ocean-backdrop {
  position: absolute;
  inset: 0;
  overflow: hidden;
  z-index: 0;
}

.bubble {
  position: absolute;
  display: block;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.14);
  box-shadow: 0 0 14px rgba(255, 255, 255, 0.18);
  animation: bubbleRise linear infinite;
}

.bubble-1 {
  width: 18px;
  height: 18px;
  left: 12%;
  bottom: -40px;
  animation-duration: 14s;
  animation-delay: -2s;
}

.bubble-2 {
  width: 26px;
  height: 26px;
  left: 44%;
  bottom: -50px;
  animation-duration: 18s;
  animation-delay: -6s;
}

.bubble-3 {
  width: 14px;
  height: 14px;
  left: 72%;
  bottom: -60px;
  animation-duration: 12s;
  animation-delay: -1s;
}

.bubble-4 {
  width: 22px;
  height: 22px;
  left: 85%;
  bottom: -45px;
  animation-duration: 16s;
  animation-delay: -8s;
}

.bubble-5 {
  width: 12px;
  height: 12px;
  left: 30%;
  bottom: -70px;
  animation-duration: 11s;
  animation-delay: -4s;
}

.auth-wrapper {
  position: relative;
  z-index: 1;
  display: flex;
  flex-wrap: wrap;
  gap: 48px;
  align-items: stretch;
  justify-content: center;
  width: 100%;
  max-width: 1040px;
}

.brand-panel {
  flex: 1 1 360px;
  border-radius: 28px;
  padding: 48px 40px;
  background: linear-gradient(180deg, rgba(94, 194, 209, 0.22) 0%, rgba(2, 48, 71, 0.88) 100%);
  border: 1px solid rgba(94, 194, 209, 0.35);
  box-shadow: 0 30px 70px -28px rgba(0, 0, 0, 0.7);
  backdrop-filter: blur(18px);
  color: #e8f6ff;
  display: flex;
  flex-direction: column;
  position: relative;
  overflow: hidden;
  user-select: none;
  cursor: default;
}

.brand-panel::after {
  content: "";
  position: absolute;
  inset: 18px;
  border-radius: 22px;
  border: 1px solid rgba(94, 194, 209, 0.12);
  pointer-events: none;
  z-index: 1;
}

.logo-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 68px;
  height: 68px;
  border-radius: 22px;
  background: linear-gradient(135deg, var(--ocean-light), #7fe0f1);
  color: var(--navy);
  font-weight: 700;
  letter-spacing: 0.12em;
  box-shadow: 0 16px 28px -12px rgba(94, 194, 209, 0.7);
  margin-bottom: 24px;
}

.brand-panel h1 {
  margin: 0 0 16px;
  font-size: 2.5rem;
  letter-spacing: 0.04em;
}

.brand-subtitle {
  margin: 0;
  max-width: 420px;
  font-size: 1.05rem;
  line-height: 1.7;
  color: rgba(232, 246, 255, 0.75);
}

.github-link {
	text-decoration: none;
	box-shadow: inset 0 0 0 0;
	transition: color .5s ease-in-out, box-shadow .5s ease-in-out;
}

.github-link:hover {
	box-shadow: inset 0 60px 0 0 #5ec2d1;
	color: #012a4a;
}

.reef {
  position: relative;
  margin-top: 36px;
  height: 220px;
}

.reef__floor {
  position: absolute;
  bottom: -6px;
  left: -40px;
  width: 360px;
  height: 60px;
  background: linear-gradient(180deg, rgba(4, 102, 200, 0.4), rgba(1, 20, 33, 0.85));
  filter: blur(16px);
  z-index: 1;
}

.reef__ridge {
  position: absolute;
  bottom: 40px;
  left: -10px;
  width: 320px;
  height: 120px;
  background: radial-gradient(circle at 50% 100%, rgba(5, 70, 110, 0.45), transparent 72%);
  filter: blur(18px);
  z-index: 1;
}

.reef__coral {
  position: absolute;
  bottom: -10px;
  width: 86px;
  height: 130px;
  border-radius: 54px 54px 0 0;
  background: linear-gradient(180deg, rgba(255, 111, 89, 0.92) 0%, rgba(255, 111, 89, 0.2) 100%);
  filter: drop-shadow(0 12px 28px rgba(255, 111, 89, 0.45));
  z-index: 2;
}

.reef__coral--left {
  left: -26px;
  transform: rotate(-8deg) scale(0.86);
}

.reef__coral--center {
  left: 96px;
  width: 74px;
  height: 120px;
  transform: rotate(5deg) scale(1.02);
  background: linear-gradient(180deg, rgba(255, 181, 114, 0.95), rgba(255, 181, 114, 0.25));
}

.reef__coral--right {
  right: -18px;
  width: 72px;
  height: 122px;
  transform: rotate(6deg);
  background: linear-gradient(180deg, rgba(255, 181, 114, 0.95), rgba(255, 181, 114, 0.25));
}

.reef__kelp {
  position: absolute;
  bottom: 0;
  width: 22px;
  height: 130px;
  border-radius: 40px 40px 0 0;
  background: linear-gradient(180deg, rgba(94, 194, 209, 0.5) 0%, rgba(4, 102, 200, 0.25) 100%);
  filter: blur(0.2px);
  animation: sway 4.5s ease-in-out infinite;
  z-index: 2;
}

.reef__kelp::after,
.reef__kelp::before {
  content: "";
  position: absolute;
  bottom: 0;
  width: 10px;
  border-radius: 40px 40px 0 0;
  background: inherit;
  opacity: 0.7;
}

.reef__kelp::after {
  left: -12px;
  height: 96px;
}

.reef__kelp::before {
  right: -12px;
  height: 78px;
}

.reef__kelp--one {
  left: 208px;
  animation-delay: -1.1s;
}

.reef__kelp--two {
  left: 285px;
  animation-delay: -2.4s;
}

.reef__fish {
  position: absolute;
  width: 140px;
  height: 82px;
  border-radius: 60% 40% 50% 50%;
  background: linear-gradient(120deg, rgba(94, 194, 209, 0.95) 0%, rgba(4, 102, 200, 0.75) 100%);
  box-shadow: 0 16px 32px rgba(4, 102, 200, 0.35);
  animation: swim 10s ease-in-out infinite;
  z-index: 3;
}

.reef__fish--tang {
  top: 24px;
  left: 78px;
}

.reef__fish::before {
  content: "";
  position: absolute;
  right: -30px;
  top: 26px;
  width: 40px;
  height: 30px;
  background: inherit;
  border-radius: 0 80% 20% 80%;
  transform: rotate(18deg);
}

.reef__fish::after {
  content: "";
  position: absolute;
  left: 26px;
  top: 26px;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: #012a4a;
  box-shadow: 8px -2px 0 2px rgba(255, 255, 255, 0.65);
}

.reef__fish--clown {
  top: 138px;
  left: -2px;
  width: 110px;
  height: 66px;
  animation-duration: 12s;
  animation-delay: -3s;
  background: linear-gradient(120deg, rgba(255, 111, 89, 0.92) 0%, rgba(255, 161, 86, 0.85) 55%, rgba(255, 255, 255, 0.9) 56%, rgba(255, 158, 67, 0.8) 100%);
}

.reef__fish--clown::before {
  right: -26px;
  width: 30px;
  height: 24px;
  background: linear-gradient(120deg, rgba(255, 111, 89, 0.92) 0%, rgba(255, 155, 79, 0.85) 100%);
  transform: rotate(12deg);
}

.reef__fish--clown::after {
  left: 22px;
  top: 22px;
}

.reef__fish--butterfly {
  top: 58px;
  right: 12px;
  width: 120px;
  height: 70px;
  background: linear-gradient(120deg, rgba(255, 215, 125, 0.92) 0%, rgba(255, 145, 120, 0.82) 70%, rgba(220, 84, 70, 0.75) 100%);
  animation-duration: 11s;
  animation-delay: -5s;
}

.reef__fish--butterfly::before {
  right: -26px;
  width: 36px;
  height: 28px;
  background: inherit;
  transform: rotate(16deg);
}

.reef__fish--butterfly::after {
  left: 26px;
  top: 24px;
  width: 10px;
  height: 10px;
}

.reef__bubble {
  position: absolute;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.18);
  box-shadow: 0 0 12px rgba(255, 255, 255, 0.22);
  animation: rise 6s ease-in infinite;
  z-index: 4;
}

.reef__bubble--small {
  width: 12px;
  height: 12px;
  left: 172px;
  bottom: 46px;
  animation-delay: -1.4s;
  animation-duration: 5.5s;
}

.reef__bubble--medium {
  width: 16px;
  height: 16px;
  left: 212px;
  bottom: 40px;
  animation-delay: -3s;
}

.reef__bubble--large {
  width: 20px;
  height: 20px;
  left: 268px;
  bottom: 42px;
  animation-delay: -2s;
  animation-duration: 7s;
}

.reef__school {
  position: absolute;
  bottom: 80px;
  left: 124px;
  width: 120px;
  display: flex;
  justify-content: space-between;
  z-index: 3;
}

.reef__glow {
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.22);
  filter: blur(1.5px);
  animation: shimmer 3.6s ease-in-out infinite;
}

.reef__glow--one {
  animation-delay: -1.4s;
}

.reef__glow--two {
  animation-delay: -2.1s;
}

.reef__glow--three {
  animation-delay: -2.7s;
}

.reef__mobile {
  display: none;
  position: absolute;
  inset: 0;
  pointer-events: none;
}

.reef__mini-fish {
  position: absolute;
  display: block;
  width: 64px;
  height: 24px;
  border-radius: 22px;
  background: linear-gradient(135deg, rgba(94, 194, 209, 0.9), rgba(4, 102, 200, 0.72));
  filter: drop-shadow(0 10px 18px rgba(4, 102, 200, 0.45));
  opacity: 0.92;
  animation: mobileSwim 11s ease-in-out infinite;
}

.reef__mini-fish::after {
  content: "";
  position: absolute;
  top: 50%;
  right: -18px;
  width: 22px;
  height: 14px;
  border-radius: 60% 0 0 60%;
  background: inherit;
  transform: translateY(-50%) rotate(14deg);
  filter: brightness(0.92);
}

.reef__mini-fish--two,
.reef__mini-fish--four {
  background: linear-gradient(135deg, rgba(255, 174, 120, 0.92), rgba(255, 111, 89, 0.75));
  filter: drop-shadow(0 10px 18px rgba(255, 111, 89, 0.45));
}

.reef__mini-fish--one {
  top: 34px;
  left: 26px;
  animation-duration: 12s;
}

.reef__mini-fish--two {
  top: 74px;
  right: 34px;
  width: 58px;
  height: 24px;
  animation-duration: 9s;
  animation-delay: -2s;
}

.reef__mini-fish--three {
  bottom: 36px;
  left: 44px;
  width: 54px;
  height: 22px;
  animation-duration: 10s;
  animation-delay: -4s;
}

.reef__mini-fish--four {
  bottom: 56px;
  right: 60px;
  width: 60px;
  height: 24px;
  animation-duration: 13s;
  animation-delay: -6s;
}


.form-panel {
  flex: 1 1 340px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.auth-card {
  width: 100%;
  max-width: 400px;
  border-radius: 28px;
  padding: 42px 38px;
  background: rgba(2, 17, 30, 0.62);
  border: 1px solid rgba(94, 194, 209, 0.35);
  box-shadow: 0 24px 60px -26px rgba(0, 0, 0, 0.85);
  backdrop-filter: blur(26px);
  color: #f1fbff;
  display: flex;
  flex-direction: column;
  gap: 18px;
  user-select: none;
  cursor: default;
}

.auth-card h2 {
  margin: 0;
  font-size: 2rem;
  letter-spacing: 0.05em;
}

.card-subtitle {
  margin: -6px 0 12px;
  font-size: 0.98rem;
  color: rgba(241, 251, 255, 0.75);
  letter-spacing: 0.02em;
}

.form-field {
  display: flex;
  flex-direction: column;
  gap: 8px;
  text-align: left;
}

.field-label {
  font-size: 0.82rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: rgba(241, 251, 255, 0.65);
}

.auth-input {
  width: 100%;
  padding: 14px 18px;
  border-radius: 16px;
  border: 1px solid rgba(94, 194, 209, 0.45);
  background: rgba(8, 36, 58, 0.78);
  color: #f1fbff;
  font-size: 1rem;
  transition: border 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
  text-align: left;
  user-select: text;
}

.auth-input:focus {
  outline: none;
  border-color: var(--sand);
  box-shadow: 0 0 0 4px rgba(94, 194, 209, 0.25);
  background: rgba(10, 45, 75, 0.95);
}

.auth-input::placeholder {
  color: rgba(241, 251, 255, 0.45);
}

.auth-input.input-error {
  border-color: var(--coral);
  box-shadow: 0 0 0 4px rgba(255, 111, 89, 0.25);
}

.auth-card .primary {
  margin-top: 18px;
}

#register-div .primary {
  margin-top: 24px;
}

.auth-feedback {
  min-height: 20px;
  font-size: 0.88rem;
  letter-spacing: 0.03em;
  color: var(--coral);
}

button {
  cursor: pointer;
  border: none;
  border-radius: 16px;
  padding: 14px 18px;
  font-size: 1rem;
  font-weight: 600;
  font-family: inherit;
  transition: transform 0.2s ease, box-shadow 0.25s ease, background 0.25s ease, opacity 0.15s ease;
}

button.primary {
  background: linear-gradient(135deg, var(--ocean-light), #4f9fd9);
  color: var(--navy);
  box-shadow: 0 18px 35px -16px rgba(94, 194, 209, 0.9);
}

button.primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 22px 40px -16px rgba(94, 194, 209, 0.9);
}

button.primary:active {
  transform: translateY(0);
  box-shadow: 0 12px 24px -14px rgba(94, 194, 209, 0.75);
}

button.secondary {
  background: rgba(241, 251, 255, 0.08);
  color: #f1fbff;
}

button.secondary:hover {
  background: rgba(241, 251, 255, 0.14);
}

button.secondary.link {
  background: none;
  padding: 0;
  color: rgba(241, 251, 255, 0.85);
  font-weight: 500;
  text-decoration: underline;
  text-decoration-thickness: 2px;
  text-underline-offset: 6px;
  box-shadow: none;
}

button.secondary.link:hover {
  color: #ffffff;
  transform: none;
}

button.secondary.link:active {
  opacity: 0.7;
}

.form-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  font-size: 0.9rem;
  margin-top: 6px;
  color: rgba(241, 251, 255, 0.75);
}

@media (max-width: 980px) {
  .auth-wrapper {
    flex-direction: column;
    gap: 32px;
  }

  .brand-panel {
    text-align: center;
    align-items: center;
    padding: 42px 34px;
  }

  .brand-panel h1 {
    font-size: 2.2rem;
  }

  .brand-subtitle {
    max-width: 520px;
  }

  .reef {
    margin-top: 36px;
  }
}

@media (max-width: 640px) {
  body.landing {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-start;
    padding: clamp(28px, 8vh, 48px) clamp(18px, 7vw, 28px);
  }

  .auth-wrapper {
    width: min(100%, 360px);
    margin: 0 auto;
    gap: 24px;
  }

  .brand-panel,
  .form-panel,
  .auth-card {
    width: 100%;
    margin-inline: auto;
  }

  .brand-panel {
    align-items: center;
    text-align: center;
    padding: clamp(28px, 9vw, 36px) clamp(20px, 8vw, 28px);
    gap: 16px;
  }

  .brand-panel h1 {
    font-size: clamp(2.1rem, 7.8vw, 2.6rem);
  }

  .brand-subtitle {
    max-width: 28ch;
    font-size: clamp(1rem, 4.2vw, 1.15rem);
    line-height: 1.6;
  }

  .brand-panel::before {
    content: "";
    position: absolute;
    inset: 18px;
    border-radius: 22px;
    background:
      radial-gradient(circle at 18% 28%, rgba(94, 194, 209, 0.24) 0%, transparent 58%),
      radial-gradient(circle at 82% 24%, rgba(255, 161, 120, 0.22) 0%, transparent 55%),
      radial-gradient(circle at 32% 72%, rgba(4, 102, 200, 0.18) 0%, transparent 60%),
      radial-gradient(circle at 68% 78%, rgba(255, 255, 255, 0.08) 0%, transparent 70%);
    opacity: 0.8;
    filter: blur(0.8px);
    z-index: 0;
  }

  .brand-panel::after {
    border: 1px solid rgba(94, 194, 209, 0.18);
  }

  .brand-panel > * {
    position: relative;
    z-index: 2;
  }

  .auth-card {
    padding: clamp(26px, 7.5vw, 32px) clamp(20px, 7vw, 26px);
  }

  .form-footer {
    flex-direction: column;
    align-items: center;
    gap: 6px;
    text-align: center;
  }

  .reef {
    width: 100%;
    margin: 12px auto 0;
    height: clamp(160px, 45vw, 190px);
    border-radius: 30px;
    background:
      linear-gradient(180deg, rgba(0, 38, 59, 0.88) 0%, rgba(0, 16, 28, 0.96) 100%);
    box-shadow:
      inset 0 0 0 1px rgba(94, 194, 209, 0.26),
      inset 0 -26px 48px rgba(1, 12, 24, 0.64);
    position: relative;
    overflow: hidden;
  }

  .reef::before,
  .reef::after {
    content: "";
    position: absolute;
    width: 72px;
    height: 28px;
    border-radius: 70% 40% 55% 50%;
    opacity: 0.92;
  }

  .reef::before {
    top: 32px;
    left: 26px;
    background: linear-gradient(135deg, rgba(94, 194, 209, 0.92), rgba(4, 115, 214, 0.74));
    box-shadow:
      46px 18px 0 -6px rgba(255, 255, 255, 0.2),
      24px 46px 0 -8px rgba(94, 194, 209, 0.25);
  }

  .reef::after {
    right: 28px;
    bottom: 40px;
    background: linear-gradient(135deg, rgba(255, 175, 120, 0.94), rgba(255, 111, 89, 0.8));
    box-shadow:
      -42px -14px 0 -6px rgba(4, 102, 200, 0.2),
      -18px 40px 0 -10px rgba(255, 111, 89, 0.25);
  }

  .reef__floor,
  .reef__ridge,
  .reef__coral,
  .reef__kelp,
  .reef__fish,
  .reef__bubble,
  .reef__school {
    display: none;
  }

  .reef__mobile {
    display: block;
    inset: 8px 12px;
  }

  .reef__mini-fish {
    will-change: transform;
    border-radius: 22px;
    opacity: 1;
    mix-blend-mode: screen;
  }

  .form-panel {
    justify-content: center;
  }
}

body.app-body {
  min-height: 100vh;
}

.app-shell {
  position: relative;
  z-index: 1;
  width: 100%;
  max-width: 1200px;
  display: flex;
  flex-direction: column;
  gap: 32px;
  margin: 0 auto;
}

.app-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 28px 32px;
  border-radius: 32px;
  background: rgba(2, 17, 30, 0.62);
  border: 1px solid rgba(94, 194, 209, 0.35);
  box-shadow: 0 30px 70px -28px rgba(0, 0, 0, 0.7);
  backdrop-filter: blur(22px);
  user-select: none;
  cursor: default;
}

.app-brand {
  display: flex;
  align-items: center;
  gap: 18px;
}

.brand-copy h1 {
  margin: 0;
  font-size: 2rem;
  letter-spacing: 0.05em;
}

.brand-copy p {
  margin: 4px 0 0;
  color: rgba(232, 246, 255, 0.7);
  letter-spacing: 0.03em;
}

.app-user {
  display: flex;
  align-items: center;
  gap: 18px;
}

.user-avatar {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 54px;
  height: 54px;
  border-radius: 18px;
  background: linear-gradient(135deg, rgba(94, 194, 209, 0.55), rgba(4, 102, 200, 0.7));
  color: var(--navy);
  font-weight: 700;
  letter-spacing: 0.08em;
  box-shadow: 0 18px 36px -18px rgba(94, 194, 209, 0.8);
}

.user-meta {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 8px;
  color: rgba(232, 246, 255, 0.85);
}

.user-greeting {
  font-size: 1rem;
  letter-spacing: 0.04em;
}

button.secondary.ghost {
  background: rgba(241, 251, 255, 0.08);
  color: #f1fbff;
  border: 1px solid rgba(241, 251, 255, 0.18);
  padding: 10px 18px;
  border-radius: 14px;
}

button.secondary.ghost:hover {
  background: rgba(241, 251, 255, 0.18);
}

.app-content {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(340px, 1fr));
  gap: 32px;
}

.panel {
  position: relative;
  padding: 32px;
  border-radius: 28px;
  background: rgba(2, 17, 30, 0.58);
  border: 1px solid rgba(94, 194, 209, 0.32);
  box-shadow: 0 24px 60px -26px rgba(0, 0, 0, 0.8);
  backdrop-filter: blur(22px);
  display: flex;
  flex-direction: column;
  gap: 24px;
  user-select: none;
  cursor: default;
}

.panel-header h2 {
  margin: 0;
  font-size: 1.6rem;
  letter-spacing: 0.05em;
}

.panel-header p {
  margin: 8px 0 0;
  color: rgba(232, 246, 255, 0.65);
  line-height: 1.6;
}

.search-form {
  margin: 0;
}

.search-input {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 16px 20px;
  border-radius: 18px;
  border: 1px solid rgba(94, 194, 209, 0.35);
  background: rgba(8, 36, 58, 0.78);
  box-shadow: inset 0 0 0 1px rgba(4, 102, 200, 0.18);
}

.search-input .material-icons {
  font-size: 22px;
  color: rgba(232, 246, 255, 0.65);
}

.search-input input {
  border: none;
  background: transparent;
  color: #f1fbff;
  font-size: 1rem;
  width: 100%;
  outline: none;
}

.search-feedback {
  font-size: 0.9rem;
  letter-spacing: 0.03em;
  color: rgba(232, 246, 255, 0.7);
  display: none;
}

.search-feedback-error {
  color: var(--coral);
}

.panel-toolbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 18px;
  flex-wrap: wrap;
}

.panel-toolbar h3 {
  margin: 0;
  font-size: 1.1rem;
  letter-spacing: 0.06em;
}

.panel-toolbar p {
  margin: 4px 0 0;
  color: rgba(232, 246, 255, 0.6);
  font-size: 0.95rem;
}

button.primary.halo {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 12px 20px;
  background: linear-gradient(135deg, rgba(94, 194, 209, 0.92), rgba(79, 159, 217, 0.92));
  color: var(--navy);
  box-shadow: 0 22px 48px -20px rgba(94, 194, 209, 0.9);
}

button.primary.halo .material-icons {
  font-size: 22px;
}

button.primary.halo:hover {
  transform: translateY(-1px);
}

.contacts-wrapper {
  border-radius: 22px;
  background: rgba(8, 36, 58, 0.72);
  border: 1px solid rgba(94, 194, 209, 0.28);
  padding: 24px;
  min-height: 320px;
  box-shadow: inset 0 0 0 1px rgba(4, 102, 200, 0.15);
}

.contacts-list {
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.contact-card {
  border-radius: 20px;
  padding: 20px 22px;
  background: rgba(1, 20, 33, 0.82);
  border: 1px solid rgba(94, 194, 209, 0.22);
  box-shadow: 0 16px 32px -20px rgba(0, 0, 0, 0.8);
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.contact-card-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.contact-name {
  margin: 0;
  font-size: 1.15rem;
  letter-spacing: 0.04em;
  color: rgba(232, 246, 255, 0.9);
}

.contact-card-actions {
  display: flex;
  gap: 10px;
}

.contact-action-btn {
  padding: 8px 14px;
  border-radius: 12px;
  border: none;
  font-size: 0.9rem;
  font-weight: 600;
  cursor: pointer;
  transition: transform 0.2s ease, box-shadow 0.25s ease, background 0.25s ease;
}

.contact-action-edit {
  background: rgba(94, 194, 209, 0.2);
  color: #f1fbff;
}

.contact-action-edit:hover {
  background: rgba(94, 194, 209, 0.32);
}

.contact-action-delete {
  background: rgba(255, 111, 89, 0.2);
  color: #ffb19f;
}

.contact-action-delete:hover {
  background: rgba(255, 111, 89, 0.32);
}

.contact-details {
  display: flex;
  flex-wrap: wrap;
  gap: 12px 18px;
  color: rgba(232, 246, 255, 0.7);
  font-size: 0.95rem;
}

.modal-backdrop {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0, 10, 22, 0.78);
  backdrop-filter: blur(20px);
  z-index: 20;
  align-items: center;
  justify-content: center;
  padding: 32px 18px;
}

.modal-card {
  position: relative;
  border-radius: 28px;
  padding: 36px 32px 30px;
  background: rgba(2, 17, 30, 0.9);
  border: 1px solid rgba(94, 194, 209, 0.4);
  box-shadow: 0 32px 64px -30px rgba(0, 0, 0, 0.85);
  max-width: 460px;
  width: 100%;
  display: flex;
  flex-direction: column;
  gap: 22px;
}

.modal-card h2 {
  margin: 0;
  font-size: 1.6rem;
  letter-spacing: 0.05em;
}

.modal-subtitle {
  margin: -10px 0 0;
  color: rgba(232, 246, 255, 0.6);
  font-size: 0.95rem;
}

.modal-body {
  display: flex;
  flex-direction: column;
  gap: 22px;
}

.modal-field {
  position: relative;
}

.modal-body .field-label {
  margin: 0 0 8px;
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.modal-body .field-label:first-of-type {
  margin-top: 16px;
}

.modal-footer {
  display: flex;
  flex-direction: column;
  gap: 16px;
  margin-top: 4px;
}

.modal-footer .primary {
  margin-top: 12px;
}

.modal-field .auth-input {
  padding-right: 44px;
}

.modal-close {
  position: absolute;
  top: 18px;
  right: 18px;
  background: rgba(241, 251, 255, 0.08);
  border: none;
  border-radius: 14px;
  padding: 8px;
  color: #f1fbff;
  cursor: pointer;
}

.modal-close:hover {
  background: rgba(241, 251, 255, 0.18);
}

.problem-icons {
  display: none;
  position: absolute;
  top: 50%;
  right: 14px;
  transform: translateY(-50%);
  color: var(--coral);
  font-size: 20px;
}

.modal-error {
  display: none;
  color: var(--coral);
  font-size: 0.9rem;
  letter-spacing: 0.03em;
}

.modal-footer .auth-feedback {
  min-height: 20px;
}

@media (max-width: 980px) {
  .app-header {
    flex-direction: column;
    gap: 20px;
    text-align: center;
  }

  .app-brand,
  .app-user {
    flex-direction: column;
  }

  .app-content {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 640px) {
  body.app-body {
    display: block;
    padding: 0;
  }

  .app-shell {
    width: 100%;
    max-width: 380px;
    margin: 0 auto;
    padding: 32px 16px 44px;
    gap: 24px;
  }

  .app-header {
    width: 100%;
    align-items: center;
    text-align: center;
    padding: 24px 20px;
  }

  .app-brand,
  .app-user {
    align-items: center;
    text-align: center;
    gap: 12px;
  }

  .user-meta {
    align-items: center;
    text-align: center;
  }

  .app-header,
  .panel {
    width: 100%;
    margin-inline: auto;
  }

  .panel {
    padding: 24px 20px;
  }

  .app-content {
    display: flex;
    flex-direction: column;
    gap: 24px;
    width: 100%;
  }

  .panel-header h2,
  .panel-header p,
  .toolbar-copy {
    text-align: center;
  }

  .panel-toolbar {
    flex-direction: column;
    align-items: center;
    text-align: center;
    gap: 16px;
  }

  .panel-toolbar .primary.halo {
    width: 100%;
    justify-content: center;
  }

  .modal-card {
    padding: 32px 24px 26px;
  }
}

@keyframes bubbleRise {
  0% {
    transform: translateY(0) scale(1);
    opacity: 0;
  }

  10% {
    opacity: 0.6;
  }

  100% {
    transform: translateY(-120vh) scale(1.2);
    opacity: 0;
  }
}

@keyframes swim {
  0%,
  100% {
    transform: translateX(0) translateY(0);
  }

  50% {
    transform: translateX(16px) translateY(-10px) scale(1.02);
  }
}

@keyframes mobileSwim {
  0%,
  100% {
    transform: translate3d(0, 0, 0) scale(1);
  }

  40% {
    transform: translate3d(12px, -6px, 0) scale(1.04);
  }

  70% {
    transform: translate3d(-8px, 4px, 0) scale(0.98);
  }
}

@keyframes sway {
  0%,
  100% {
    transform: translateX(0) rotate(0deg);
  }

  50% {
    transform: translateX(-6px) rotate(-4deg);
  }
}

@keyframes rise {
  0% {
    transform: translateY(0) scale(0.9);
    opacity: 0;
  }

  10% {
    opacity: 0.6;
  }

  100% {
    transform: translateY(-60px) scale(1);
    opacity: 0;
  }
}

@keyframes shimmer {
  0%,
  100% {
    opacity: 0.35;
    transform: scale(0.9);
  }

  50% {
    opacity: 0.75;
    transform: scale(1.1);
  }
}
