:root {
  --troogg-black: #08090b;
  --troogg-white: #ffffff;
  --troogg-blue: #2675ff;
  --troogg-muted: #747b88;
  --troogg-line: #e5e7eb;
}

html,
body {
  min-height: 100%;
  margin: 0;
  background: var(--troogg-white);
}

body {
  font-family: Inter, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

.login-page {
  display: grid;
  min-height: 100vh;
  grid-template-columns: minmax(0, 1.08fr) minmax(420px, 0.92fr);
  background: var(--troogg-white);
}

.login-page:not(.is-login) {
  display: block;
}

.login-page:not(.is-login) .kinetic-panel {
  min-height: 100vh;
}

.login-page:not(.is-login) .login-panel {
  display: none !important;
}

.login-page.is-login {
  display: block;
}

.login-page.is-login .kinetic-panel {
  display: grid;
}

.login-page.is-login .login-panel {
  position: absolute;
  inset: 0;
  z-index: 2;
  display: grid;
  min-height: 100vh;
  place-items: center;
  padding: 32px 24px;
  background: rgba(8, 9, 11, 0.34);
}

.login-page.is-signup {
  display: block;
  position: relative;
  min-height: 100vh;
}

.login-page.is-signup .kinetic-panel {
  display: grid;
}

.login-page.is-signup .login-panel {
  display: none !important;
}

.login-page.is-signup .signup-panel {
  position: absolute;
  inset: 0;
  z-index: 2;
  display: grid;
  min-height: 100vh;
  place-items: center;
  padding: 32px 24px;
  background: rgba(8, 9, 11, 0.34);
}

.signup-panel[hidden] {
  display: none !important;
}

.signup-content {
  width: min(100%, 400px);
  padding: 34px 30px 30px;
  border-radius: 18px;
  background: #fff;
  box-shadow: 0 24px 70px rgba(0, 0, 0, 0.28);
}

.signup-back {
  display: inline-flex;
  min-height: 30px;
  align-items: center;
  color: #626872;
  font-size: 13px;
  font-weight: 700;
}

.signup-content h1 {
  margin: 28px 0 0;
  color: #111318;
  font-size: clamp(28px, 4vw, 42px);
  letter-spacing: -0.07em;
  line-height: 1.12;
}

.signup-form {
  display: grid;
  gap: 10px;
  margin-top: 30px;
}

.signup-form > label {
  margin-top: 10px;
  color: #22252b;
  font-size: 14px;
  font-weight: 700;
}

.signup-form input {
  box-sizing: border-box;
  width: 100%;
  min-height: 54px;
  padding: 0 16px;
  border: 1px solid var(--troogg-line);
  border-radius: 12px;
  outline: 0;
  background: #fff;
  color: #111318;
  font: inherit;
  font-size: 16px;
}

.signup-form input:focus {
  border-color: var(--troogg-blue);
  box-shadow: 0 0 0 4px rgba(38, 117, 255, 0.12);
}

.login-page.is-guest {
  display: block;
  min-height: 100vh;
  background: #f5f6f8;
}

.login-page.is-guest .kinetic-panel,
.login-page.is-guest .login-panel {
  display: none;
}

.social-home {
  display: block;
  min-height: 100vh;
  padding-top: 64px;
  color: #17191d;
}

.social-home[hidden] {
  display: none !important;
}

.social-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 5;
  display: flex;
  align-items: center;
  gap: 28px;
  height: 64px;
  width: 100%;
  margin: 0;
  padding: 0 clamp(20px, 5vw, 72px);
  border-bottom: 1px solid #e7e9ed;
  background: rgba(255, 255, 255, 0.86);
  backdrop-filter: blur(18px);
}

.social-brand {
  display: inline-flex;
  align-items: center;
  width: 74px;
  height: 40px;
  color: #1d1f21;
}

.social-brand img {
  display: block;
  width: 58px;
  height: 58px;
  object-fit: contain;
}

.social-search {
  display: flex;
  align-items: center;
  gap: 8px;
  width: min(100%, 360px);
  min-height: 42px;
  padding: 0 14px;
  border-radius: 12px;
  background: #f1f3f6;
  color: #7d8490;
}

.social-search input {
  width: 100%;
  border: 0;
  outline: 0;
  background: transparent;
  color: #17191d;
  font: inherit;
}

.social-actions { display: flex; align-items: center; gap: 10px; margin-left: auto; }
.social-actions button { border: 0; background: transparent; color: #555c67; font: inherit; cursor: pointer; }
.social-avatar { display: grid; width: 40px; height: 40px; place-items: center; flex: none; border-radius: 50%; background: #1d1f21; color: #fff; font-weight: 800; }
.social-layout { display: grid; grid-template-columns: 180px minmax(0, 620px); justify-content: center; gap: 42px; width: min(100% - 40px, 900px); margin: 0 auto; padding: 24px 0 80px; }
.social-sidebar { padding-top: 4px; }
.social-sidebar nav { display: grid; gap: 8px; }
.social-sidebar a { display: flex; align-items: center; gap: 14px; min-height: 46px; padding: 0 14px; border-radius: 12px; color: #69717d; font-weight: 700; }
.social-sidebar a span { width: 22px; color: #1d1f21; font-size: 21px; text-align: center; }
.social-menu-icon { width: 22px; height: 22px; flex: none; object-fit: contain; }
.social-sidebar a.is-active, .social-sidebar a:hover { background: #fff; color: #1d1f21; }
.sidebar-note { display: grid; gap: 4px; margin-top: 40px; padding: 16px; border-radius: 14px; background: #eaedf2; color: #30353d; font-size: 13px; }
.sidebar-note span { color: #7a828e; line-height: 1.4; }
.social-feed { display: grid; gap: 16px; }
.social-composer, .social-post, .social-widget { border: 1px solid #e3e6eb; border-radius: 16px; background: #fff; }
.social-composer { display: flex; gap: 14px; padding: 20px; }
.composer-body { min-width: 0; flex: 1; }
.composer-body textarea { width: 100%; min-height: 66px; resize: vertical; border: 0; outline: 0; color: #17191d; font: inherit; line-height: 1.5; }
.composer-footer { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding-top: 14px; border-top: 1px solid #eef0f3; }
.composer-tools { display: flex; gap: 8px; }
.composer-tools button, .post-actions button { border: 0; background: transparent; color: #737b87; font: inherit; font-size: 13px; cursor: pointer; }
.post-button { min-height: 38px; padding: 0 16px; border: 0; border-radius: 10px; background: #1d1f21; color: #fff; font: inherit; font-size: 13px; font-weight: 750; cursor: pointer; }
.social-post { padding: 20px; }
.post-head { display: flex; align-items: center; gap: 12px; }
.post-head > div:nth-child(2) { display: grid; gap: 2px; }
.post-head span { color: #9299a4; font-size: 12px; }
.post-more { margin-left: auto; border: 0; background: transparent; color: #9299a4; font-size: 18px; cursor: pointer; }
.social-post > p { margin: 20px 0; color: #363b43; line-height: 1.7; }
.post-image-placeholder { display: grid; min-height: 220px; place-items: center; border-radius: 12px; background: linear-gradient(135deg, #dce8ff, #f4d9d1); color: #39404b; font-size: 18px; font-weight: 750; }
.post-actions { display: flex; gap: 20px; padding-top: 16px; border-top: 1px solid #eef0f3; }
.social-widget { display: grid; gap: 12px; padding: 18px; }
.social-widget + .social-widget { margin-top: 16px; }
.social-widget h2 { margin: 0 0 4px; font-size: 15px; }
.social-widget a { display: grid; gap: 3px; color: #343a43; font-size: 14px; font-weight: 700; }
.social-widget small, .online-person small { display: block; color: #949ba5; font-size: 12px; font-weight: 400; }
.online-person { display: flex; align-items: center; gap: 10px; font-size: 14px; font-weight: 700; }
.online-person i { display: grid; width: 32px; height: 32px; place-items: center; border-radius: 50%; color: #fff; font-size: 12px; font-style: normal; }
.avatar-blue { background: #3974d8; } .avatar-coral { background: #d77c68; } .avatar-green { background: #4f9b78; } .avatar-purple { background: #8975ba; }

.kinetic-panel {
  position: relative;
  display: grid;
  min-height: 100vh;
  overflow: hidden;
  place-items: center;
  background: var(--troogg-black);
  color: var(--troogg-white);
}

.kinetic-grid {
  display: grid;
  gap: clamp(8px, 1.25vw, 18px);
  width: max-content;
  transform-origin: center;
  animation: kinetic-zoom 5.8s ease-in-out infinite;
}

.kinetic-row {
  display: flex;
  gap: clamp(14px, 2vw, 30px);
  white-space: nowrap;
  animation: kinetic-drift 4.8s ease-in-out infinite;
}

.kinetic-row:nth-child(even) {
  animation-direction: reverse;
  animation-duration: 5.4s;
}

.kinetic-word {
  display: inline-block;
  color: rgba(255, 255, 255, 0.16);
  font-size: clamp(32px, 5vw, 78px);
  font-weight: 750;
  letter-spacing: -0.08em;
  line-height: 0.92;
  animation: kinetic-fade 5.8s ease-in-out infinite;
}

.kinetic-word.is-center {
  color: var(--troogg-white);
  font-size: clamp(54px, 8vw, 124px);
  font-weight: 800;
  cursor: pointer;
  transition: color 160ms ease, transform 160ms ease;
}

.kinetic-word.is-center:hover,
.kinetic-word.is-center:focus-visible {
  color: #1d1f21;
  outline: none;
  transform: scale(1.04);
}

.login-panel {
  display: grid;
  align-items: center;
  padding: clamp(32px, 8vw, 120px);
}

.login-content {
  width: min(100%, 400px);
  margin: 0 auto;
  padding: 34px 30px 30px;
  border-radius: 18px;
  background: #fff;
  box-shadow: 0 24px 70px rgba(0, 0, 0, 0.28);
}

.login-eyebrow {
  margin: 0 0 22px;
  color: var(--troogg-blue);
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.14em;
}

.login-content h1 {
  margin: 0;
  color: #111318;
  font-size: clamp(30px, 4vw, 48px);
  letter-spacing: -0.07em;
  line-height: 1.12;
}

.login-description {
  margin: 18px 0 0;
  color: var(--troogg-muted);
  font-size: 16px;
  line-height: 1.65;
}

.login-form {
  display: grid;
  gap: 10px;
  margin-top: 42px;
}

.login-form > label {
  margin-top: 12px;
  color: #22252b;
  font-size: 14px;
  font-weight: 700;
}

.login-form input[type="email"],
.login-form input[type="password"] {
  box-sizing: border-box;
  width: 100%;
  min-height: 54px;
  padding: 0 16px;
  border: 1px solid var(--troogg-line);
  border-radius: 12px;
  outline: 0;
  background: #fff;
  color: #111318;
  font: inherit;
  font-size: 16px;
  transition: border-color 160ms ease, box-shadow 160ms ease;
}

.login-form input[type="email"]:focus,
.login-form input[type="password"]:focus {
  border-color: var(--troogg-blue);
  box-shadow: 0 0 0 4px rgba(38, 117, 255, 0.12);
}

.login-options {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-top: 10px;
  color: var(--troogg-muted);
  font-size: 13px;
}

.remember-option {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.remember-option input {
  width: 16px;
  height: 16px;
  accent-color: var(--troogg-blue);
}

.login-options a,
.signup-prompt a {
  color: #1d1f21;
  font-weight: 700;
}

.login-submit {
  min-height: 56px;
  margin-top: 18px;
  border: 0;
  border-radius: 12px;
  background: #1d1f21;
  color: #fff;
  cursor: pointer;
  font: inherit;
  font-size: 16px;
  font-weight: 750;
  transition: transform 160ms ease, background 160ms ease;
}

.login-submit:hover {
  background: #303438;
  transform: translateY(-1px);
}

.login-status {
  min-height: 22px;
  margin: 10px 0 0;
  color: #1d1f21;
  font-size: 13px;
  text-align: center;
}

.login-divider {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 18px 0 2px;
  color: #a0a6af;
  font-size: 12px;
}

.login-divider::before,
.login-divider::after {
  height: 1px;
  flex: 1;
  background: #eceef1;
  content: "";
}

.google-login {
  display: inline-flex;
  min-height: 54px;
  align-items: center;
  justify-content: center;
  gap: 10px;
  border: 1px solid #dfe2e7;
  border-radius: 12px;
  background: #fff;
  color: #1d1f21;
  cursor: pointer;
  font: inherit;
  font-size: 15px;
  font-weight: 700;
  transition: background 160ms ease, border-color 160ms ease;
}

.google-login:hover,
.google-login:focus-visible {
  border-color: #c9ced6;
  background: #f8f9fb;
  outline: none;
}

.google-login:disabled {
  cursor: wait;
  opacity: 0.62;
}

.google-login img {
  width: 20px;
  height: 20px;
}

.signup-prompt {
  margin: 28px 0 0;
  color: var(--troogg-muted);
  font-size: 14px;
  text-align: center;
}

@keyframes kinetic-drift {
  0%,
  100% { transform: translateX(-4%); }
  50% { transform: translateX(4%); }
}

@keyframes kinetic-zoom {
  0%,
  100% { transform: scale(0.94); }
  50% { transform: scale(1.04); }
}

@keyframes kinetic-fade {
  0%,
  100% { opacity: 0.62; }
  50% { opacity: 1; }
}

@media (max-width: 820px) {
  .login-page {
    grid-template-columns: 1fr;
  }

  .kinetic-panel {
    min-height: 42vh;
  }

  .login-page:not(.is-login) .kinetic-panel {
    min-height: 100vh;
  }

  .login-panel {
    min-height: 58vh;
    padding: 48px 24px 64px;
  }

  .login-page.is-login .login-panel {
    min-height: 100vh;
    padding: 24px;
  }

  .login-page.is-signup .signup-panel {
    padding: 24px;
  }

  .social-layout { grid-template-columns: 1fr; width: min(100% - 32px, 620px); padding-top: 20px; }
  .social-sidebar, .social-rightbar { display: none; }
  .social-header { gap: 14px; padding-inline: 16px; }
  .social-search { margin-left: auto; }
}

@media (prefers-reduced-motion: reduce) {
  .kinetic-grid,
  .kinetic-row,
  .kinetic-word {
    animation: none;
  }

  .login-submit {
    transition: none;
  }
}
