/*
 * App screen bundle
 * Contains:
 * screen-account.css
 * screen-characters.css
 * screen-games.css
 * screen-home.css
 * screen-movie.css
 * screen-tarinatuokiot.css
 * screen-trophies.css
 * screen-videos.css
 */

/* screen-account.css */
/* app/screen-account.css
   Scope: Account screen styles
   Reviewed for live use: 2026-02-05
*/

/* ==================================================
   ACCOUNT CONTAINER
   ================================================== */
.account-container {
  padding: 1.5rem;
  max-width: 500px;
  margin: auto;
  background: rgba(37, 58, 101, 0.8);
  border-radius: 6px;
}

.user-info {
  background: rgba(0, 0, 0, 0.2);
  border-radius: 10px;
  padding: 20px;
  margin: 30px 0;
  text-align: left;
}

.user-info .info-item {
  margin-bottom: 15px;
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  padding-bottom: 15px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.user-info .info-item:last-child {
  border-bottom: none;
  margin-bottom: 0;
}

.user-info .info-item .label {
  font-weight: bold;
  color: #8ac6d1;
}

.user-info .info-item .value {
  color: white;
}

.no-border {
  border: none !important;
}

#trophy-summary {
  display: flex;
  justify-content: center;
  width: 100%;
}

.all-trophies {
  margin: auto !important;
  display: block !important;
}

.action-buttons {
  display: flex;
  gap: 15px;
  margin-top: 30px;
  justify-content: center;
}

.btn-logout,
.btn-profile {
  padding: 12px 24px;
  border-radius: 8px;
  text-decoration: none;
  font-weight: bold;
  transition: all 0.2s ease;
}

.btn-logout {
  background: rgba(255, 107, 107, 0.2);
  color: #ff6b6b;
  border: 2px solid #ff6b6b;
  border: none;
  cursor: pointer;
}

.btn-logout:hover {
  background: #ff6b6b;
  color: white;
  transform: translateY(-2px);
}

.btn-profile {
  background: rgba(138, 198, 209, 0.2);
  color: #8ac6d1;
  border: 2px solid #8ac6d1;
}

.btn-profile:hover {
  background: #8ac6d1;
  color: #1a2b3c;
  transform: translateY(-2px);
}

/* ==================================================
   SETTINGS (SHARED)
   ================================================== */
.setting-item {
  display: flex;
  align-items: center;
  gap: 1rem;
  margin: 1.5rem 0;
}

.setting-label {
  font-size: 1.2rem;
  flex-grow: 1;
  color: #fff;
}

.status-text {
  margin-left: auto;
  font-size: 1rem;
  color: #85de81;
}

/* ==================================================
   LOGIN FORM
   ================================================== */
.login-form-container {
  padding: 40px 30px;
  position: relative;
  z-index: 2;
  max-width: 520px;
  width: 100%;
  text-align: center;
  background: rgba(0, 0, 0, 0.6);
  border-radius: 12px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.35);
  display: grid;
  gap: 1rem;
  border: 1px solid var(--kerho-color);
  box-shadow:
    0 8px 30px rgba(0, 0, 0, 0.45),
    0 0 0 1px rgba(43, 179, 192, 0.15),
    0 0 24px rgba(43, 179, 192, 0.25);
}

.login-form-container.is-shaking {
  animation: login-shake 0.45s ease;
}

@keyframes login-shake {
  0% { transform: translateX(0); }
  20% { transform: translateX(-6px); }
  40% { transform: translateX(6px); }
  60% { transform: translateX(-4px); }
  80% { transform: translateX(4px); }
  100% { transform: translateX(0); }
}

.login-header {
  text-align: center;
  margin-bottom: 1rem;
}

.login-character {
  max-width: 70px;
  margin: 1rem auto -1rem;
  display: block;
}

.login-header h1 {
  font-size: 2.2em;
  color: #fff;
  margin-bottom: 10px;
}

.login-subtitle {
  color: rgba(255, 255, 255, 0.7);
  font-size: 1.1em;
}

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

.form-group label {
  display: block;
  margin-bottom: 12px;
  color: rgba(255, 255, 255, 0.9);
  font-weight: 500;
}

.form-group input[type="text"],
.form-group input[type="password"],
.form-group input[type="email"] {
  width: 100%;
  padding: 14px 16px;
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 8px;
  color: var(--input-text-color);
  font-size: 1em;
  transition: all 0.2s ease;
  text-align: center;
}

.form-group input:focus {
  outline: none;
  border-color: var(--kerho-color-border);
  background: rgba(138, 198, 209, 0.1);
  box-shadow: var(--input-focus-shadow);
}

.form-group input::placeholder {
  color: var(--input-focus-color);
  opacity: 0.9;
}

.form-options {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 30px;
}

.remember-label {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  cursor: pointer;
  font-size: 0.9rem;
}

.forgot-password {
  color: #8ac6d1;
  text-decoration: none;
  font-size: 0.95em;
}

.forgot-password:hover {
  text-decoration: underline;
}

.btn-login {
  display: inline-block;
  padding: 14px 36px;
  border-radius: 12px;
  background: linear-gradient(
    135deg,
    var(--kerho-color-start),
    var(--kerho-color-mid),
    var(--kerho-color-end)
  );
  background-size: 200% 200%;
  background-position: 0% 50%;
  color: #fff;
  font-weight: 600;
  letter-spacing: 0.02em;
  box-shadow:
    0 10px 30px rgba(43, 179, 192, 0.45),
    inset 0 0 0 rgba(255, 255, 255, 0);
  transition:
    background-position 0.5s ease,
    transform 0.3s ease,
    box-shadow 0.3s ease;
  cursor: pointer;
}

.btn-login:hover:not(:disabled) {
  transform: translateY(-2px);
  box-shadow: 0 10px 20px rgba(138, 198, 209, 0.3);
}

.btn-login:disabled {
  opacity: 0.7;
  cursor: not-allowed;
}

.btn-loader .spinner {
  display: inline-block;
  width: 20px;
  height: 20px;
  border: 3px solid rgba(255, 255, 255, 0.3);
  border-radius: 50%;
  border-top-color: white;
  animation: spin 1s ease-in-out infinite;
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

.form-footer {
  margin-top: 25px;
  text-align: center;
  padding-top: 25px;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.form-footer a,
.form-footer p {
  color: rgba(255, 255, 255, 0.7);
  margin-bottom: 15px;
}

.btn-register {
  display: inline-block;
  padding: 10px 20px;
  background: rgba(255, 255, 255, 0.1);
  color: white;
  text-decoration: none;
  border-radius: 8px;
  border: 1px solid rgba(255, 255, 255, 0.2);
  transition: all 0.2s ease;
}

.btn-register:hover {
  background: rgba(255, 255, 255, 0.2);
  transform: translateY(-2px);
}

/* Error message */
.login-error {
  background: rgba(255, 107, 107, 0.1);
  border: 1px solid rgba(255, 107, 107, 0.3);
  border-radius: 8px;
  padding: 15px;
  margin-bottom: 25px;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 8px;
  animation: fadeIn 0.3s ease;
}

@keyframes fadeIn {
  from { opacity: 0; transform: translateY(-10px); }
  to { opacity: 1; transform: translateY(0); }
}

.error-icon {
  font-size: 1.2em;
  color: #ff6b6b;
}

.error-text {
  color: rgba(255, 255, 255, 0.9);
}

/* Success messages */
.login-success,
.logout-success {
  text-align: center;
  padding: 40px;
  background: rgba(76, 175, 80, 0.1);
  border: 1px solid rgba(76, 175, 80, 0.3);
  border-radius: 16px;
}

.success-icon {
  font-size: 4em;
  color: #4caf50;
  margin-bottom: 20px;
}

/* Responsive */
@media (max-width: 600px) {
  .login-screen-container {
    padding: 20px 15px;
  }

  .login-form-container {
    padding: 30px 20px;
  }

  .action-buttons {
    flex-direction: column;
  }

  .form-options {
    flex-direction: column;
    align-items: flex-start;
    gap: 15px;
  }
}

/* ==================================================
   LOGIN OVERLAY
   ================================================== */
#login-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 9999;
  display: flex;
  justify-content: center;
  align-items: center;
  color: #fff;
}

.overlay-background {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.6);
}

.overlay-content {
  position: relative;
  background-color: var(--background-color);
  background:
    radial-gradient(
      ellipse at center,
      rgba(37, 58, 101, 1) 0%,
      rgba(20, 35, 70, 1) 40%,
      rgba(5, 10, 20, 1) 100%
    ),
    rgba(37, 58, 101, 0.3);
  padding: 2rem;
  border-radius: 1rem;
  width: 90%;
  max-width: 900px;
  text-align: center;
  box-shadow: 0 0 20px rgba(0, 0, 0, 0.3);
}

.close-btn {
  position: absolute;
  top: 10px;
  right: 10px;
  background: none;
  border: none;
  font-size: 1.2rem;
  cursor: pointer;
  color: #fff;
}

.submit-btn {
  background: var(--primary-blue);
  color: white;
  border: none;
  padding: 1rem 2rem;
  border-radius: 1rem;
  cursor: pointer;
  margin-top: 1rem;
  width: 100%;
}

/* ==================================================
   LOST PASSWORD
   ================================================== */
.forgot-password-screen {
  max-width: 420px;
  margin: 0 auto;
  padding: 20px;
  box-sizing: border-box;
  text-align: center;
}

#forgot-password-content {
  background: rgba(0, 0, 0, 0.25);
  border-radius: 12px;
  padding: 0;
}

.forgot-password-screen h1,
.forgot-password-success h2 {
  margin-bottom: 15px;
}

.forgot-password-screen p {
  margin-bottom: 12px;
  line-height: 1.4;
}

#forgot-password-form {
  display: flex;
  flex-direction: column;
  gap: 15px;
}

#forgot-password-form input[type="email"] {
  width: 100%;
  max-width: 100%;
  padding: 12px;
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 8px;
  color: var(--input-text-color);
  font-size: 16px;
  box-sizing: border-box;
}

#forgot-password-form input[type="email"]:focus {
  outline: none;
  border-color: var(--kerho-color-border);
  background: rgba(138, 198, 209, 0.1);
  box-shadow: var(--input-focus-shadow);
}

#forgot-password-form input[type="email"]::placeholder {
  color: var(--input-focus-color);
  opacity: 0.9;
}

.forgot-password-screen .btn-login {
  display: inline-block;
  padding: 14px 36px;
  border-radius: 12px;
  background: linear-gradient(
    135deg,
    var(--kerho-color-start),
    var(--kerho-color-mid),
    var(--kerho-color-end)
  );
  background-size: 200% 200%;
  background-position: 0% 50%;
  color: #fff;
  font-weight: 600;
  letter-spacing: 0.02em;
  box-shadow:
    0 10px 30px rgba(43, 179, 192, 0.45),
    inset 0 0 0 rgba(255, 255, 255, 0);
  transition:
    background-position 0.5s ease,
    transform 0.3s ease,
    box-shadow 0.3s ease;
}

.forgot-password-success {
  text-align: center;
}

.forgot-password-success a {
  color: rgba(255, 255, 255, 0.7);
}

.forgot-password-screen .form-footer {
  margin-top: 20px;
  font-size: 14px;
}

.forgot-password-screen a {
  text-decoration: underline;
}

/* ==================================================
   PROFILE SWITCH
   ================================================== */
.profile-switch-btn {
  background: transparent;
  color: #fff;
  border: 2px solid var(--kerho-color-end);
  border-radius: 9px;
  padding: 8px 14px;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  display: inline-flex;
  justify-content: center;
  align-items: center;
  gap: 6px;
  transition: background 0.2s ease, transform 0.1s ease, box-shadow 0.2s ease;
}

.profile-switch-btn:hover {
  background: var(--kerho-color-end);
  color: #111;
}

.profile-switch-btn:active {
  transform: scale(0.96);
}

.profile-switch-btn .ui-icon-inline {
  width: 18px;
  height: 18px;
  vertical-align: middle;
  margin-right: 6px;
}


/* screen-characters.css */
/* app/screen-characters.css
   Scope: Character screen styles
   Reviewed for live use: 2026-02-05
*/

/* ==================================================
   CHARACTER SCREEN
   ================================================== */

.characters {
  display: inline-flex;
  flex-direction: column;
  gap: 3rem;
  max-width: 1200px;
  padding: 2rem;
  background: rgba(37, 58, 101, 0.8);
  margin-left: 20px;
  margin-right: 20px;
  border-radius: 9px;
}

.character-row {
  display: flex;
  align-items: center;
  gap: 2rem;
  max-width: 900px;
  margin: 3rem auto;
}

.character-row.reverse {
  flex-direction: row-reverse;
}

.character-image img {
  width: 250px;
  height: auto;
  border-radius: 12px;
  object-fit: cover;
}

.character-subtitle {
  font-size: 1.2rem;
  color: var(--accent-color-2);
  margin: 0.3rem 0 1rem;
  font-weight: 600;
  font-family: 'Arial', sans-serif; /* vaihtoehtoinen fontti, jos halutaan */
}

.character-text {
  flex: 1;
  font-size: 1rem;
  max-width: 560px;
  margin: auto;
  text-align: left;
}

.character-text h2 {
  margin-top: 0;
}

.character-text p {
  font-size: 1.2rem;
  margin-top: 0;
}

/* Mobiili */
@media (max-width: 768px) {
  .character-row,
  .character-row.reverse {
    flex-direction: column;
    text-align: center;
  }

  .character-image img {
    width: 80%;
    max-width: 300px;
    margin: 0 auto;
  }
}


/* screen-games.css */
/* app/screen-games.css
   Scope: Games screen styles
   Reviewed for live use: 2026-02-05
*/

/* ==================================================
   GAME SCREEN
   ================================================== */

/* --- Peliruudukko --- */
.game-grid {
  --game-card-radius: 22px;
  --game-card-shadow: 0 16px 40px rgba(0, 0, 0, 0.35);
  --game-card-glow: 0 0 0 1px rgba(255, 255, 255, 0.18);
  display: grid;
  grid-template-columns: repeat(2, 200px);
  gap: 3rem;
  justify-content: center;
  padding: 2rem;
  max-width: 100%;
  margin: 0 auto;
}

/* Iso peli bannereissa */
.game-card.banner {
  grid-column: 1 / -1;
  max-width: 100%;
  width: calc(2 * 200px + 3rem);
  height: 200px;
  aspect-ratio: unset;
  justify-self: center;
}

/* Pienet pelit */
.game-card {
  position: relative;
  width: 200px;
  height: 200px;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.35);
  border-radius: var(--game-card-radius);
  background: linear-gradient(180deg, rgba(12, 18, 38, 0.72), rgba(7, 10, 22, 0.8));
  box-shadow: var(--game-card-shadow), var(--game-card-glow);
  text-decoration: none;
  color: #fff;
  cursor: pointer;
  transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
}

.game-card::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image: var(--game-card-bg);
  background-size: cover;
  background-position: center;
  filter: saturate(1.1) contrast(1.05);
  transform: scale(1.02);
  transition: transform 0.35s ease, filter 0.35s ease;
  z-index: 0;
}

.game-card::after {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(
      120% 120% at 0% 0%,
      rgba(255, 255, 255, 0.18) 0%,
      rgba(0, 0, 0, 0) 45%
    ),
    linear-gradient(
      180deg,
      rgba(7, 10, 22, 0.15) 0%,
      rgba(7, 10, 22, 0.65) 70%,
      rgba(7, 10, 22, 0.85) 100%
    );
  z-index: 1;
}

.game-card img,
.game-card span {
  position: relative;
  z-index: 2;
}

.game-card img {
  position: absolute;
  left: 18px;
  bottom: 18px;
  width: min(42%, 96px);
  height: auto;
  margin: 0;
  object-fit: contain;
  filter: drop-shadow(0 8px 16px rgba(0, 0, 0, 0.35));
  transition: transform 0.3s ease;
}

.game-card span {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  font-size: 1.25rem;
  font-weight: bold;
  letter-spacing: 0.2px;
  text-align: center;
  text-shadow: 0 2px 10px rgba(0, 0, 0, 0.6);
}

.game-card:hover {
  transform: translateY(-4px) scale(1.02);
  border-color: rgba(255, 255, 255, 0.55);
  box-shadow: 0 24px 50px rgba(0, 0, 0, 0.45), 0 0 0 1px rgba(255, 255, 255, 0.25);
}

.game-card:hover::before {
  transform: scale(1.08);
  filter: saturate(1.2) contrast(1.1);
}

.game-card:hover img {
  transform: scale(1.05);
}

.game-card:active {
  transform: translateY(-2px) scale(1.01);
}

.game-card[data-game="game_memory_game"] {
  --game-card-bg: url("../../../assets/games/memory-game/bg-memory-game.jpg");
}

.game-card[data-game="game_five_errors"] {
  --game-card-bg: url("../../../assets/games/five-errors/bg-five-errors.jpg");
}

.game-card[data-game="game_sanapeli"] {
  --game-card-bg: url("../../../bg/seasonal/games/sanapeli-game.jpg");
}

/* --- Otsikko --- */
.content-title {
  font-size: 2rem;
  color: #fff;
  text-align: center;
  margin: 1rem 0;
}

/* Videos screen: make top title distinct from section titles */
.videos-main-title {
  font-family: 'Fredoka', sans-serif;
  font-size: 2.45rem;
  letter-spacing: 0.01em;
  margin-top: 0.5rem;
  margin-bottom: 0.75rem;
}

@media (max-width: 768px) {
  .videos-main-title {
    font-size: 2.15rem;
  }
}

/* --- Iframe-kääre --- */
.game-container {
  position: relative;
  max-width: 1200px;
  width: 100%;
  margin: 2rem auto;
  border-radius: 20px;
  overflow: auto;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
}

.game-container iframe {
  position: absolute;
  top: 0;
  left: 0;
  border: none;
  width: 100%;
  height: 100%;
}

/* --- New game badge (Games screen) --- */
.new-game-badge {
  position: absolute;
  top: 10px;
  left: 10px;
  background: #ff3b30;
  color: #fff;
  font-size: 12px;
  font-weight: 700;
  padding: 4px 8px;
  border-radius: 4px;
  z-index: 3;
  letter-spacing: 0.2px;
  text-transform: uppercase;
  box-shadow: 0 6px 14px rgba(0, 0, 0, 0.25);
}

@media screen and (max-width: 768px) {
  .game-grid {
    grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
    gap: 1.5rem;
    padding: 4rem;
  }

  .game-card {
    width: 100%;
    height: 150px;
    max-width: 150px;
    aspect-ratio: 1 / 1;
    justify-self: center;
    border-radius: 18px;
  }

  .game-card.banner {
    grid-column: 1 / -1;
    width: 100%;
    aspect-ratio: 2.5 / 1;
    max-width: 100%;
    justify-self: center;
  }

  .game-card img {
    left: 14px;
    bottom: 14px;
    width: min(48%, 88px);
  }

  .game-card span {
    font-size: 1.1rem;
  }
}


/* screen-home.css */
/* app/screen-home.css
   Scope: Home screen styles
   Reviewed for live use: 2026-02-05
*/

/* HOME WELCOME HEADER */
.bombo-home-screen {
  margin-top: 3rem;
}

.bombo-home-header {
  max-width: 800px;
  margin-top: 12rem;
  margin-bottom: 3rem;
  margin-left: auto;
  margin-right: auto;
}

.bombo-home-header-logo {
  text-align: center;
}

.bombo-home-header-logo img {
  max-width: 150px;
  margin: auto;
  height: auto;
  margin-bottom: -9px;
}

.bombo-home-header-welcome-text h3 {
  margin: 0.5rem !important;
  font-size: 2.1rem;
  font-family: var(--font-display);
}

.bombo-home-header-welcome-text {
  font-size: 1.3rem;
  color: #fff;
  text-align: center;
}

.bombo-home-header-welcome-text .welcome-icon {
  margin-bottom: -0.5rem;
  height: 60px;
}

@media (max-width: 768px) {
  .bombo-home-header-welcome-text {
    font-size: 1rem;
    margin: 15px;
  }
}

/* HOME APP GRID */
.bombo-home-grid {
  width: 100%;
  max-width: 640px;
  margin: 0 auto;
  padding: 1rem;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, max-content));
  justify-content: center;
  gap: 2rem;
  justify-items: center;
  min-height: 150px;
}

.bombo-home-grid .app-icon {
  background: radial-gradient(
      ellipse at center,
      rgba(37, 58, 101, 1) 10%,
      rgba(20, 35, 70, 1) 90%,
      rgba(5, 10, 20, 1) 100%
    ),
    rgba(37, 58, 101, 0.3);
  border: 2px solid var(--app-color-2);
  opacity: 1;
  border-radius: 20px;
  max-width: 170px;
  aspect-ratio: 1 / 1;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  padding: 0.5rem;
  cursor: pointer;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.25);
  transition: transform 0.2s ease;
}

.app-icon:hover {
  transform: scale(1.05);
  transition: transform 0.2s ease;
  background: radial-gradient(
      ellipse at center,
      rgba(37, 58, 101, 1) 30%,
      rgba(20, 35, 70, 1) 90%,
      rgba(5, 10, 20, 1) 100%
    ),
    rgba(37, 58, 101, 0.3);
}

.app-icon img {
  width: 30%;
  height: auto;
  object-fit: contain;
}

.app-icon span {
  margin-top: 1rem;
  font-size: 1.2rem;
  color: white;
  font-weight: bold;
  text-align: center;
}

@media screen and (max-width: 768px) {
  .bombo-home-grid {
    grid-template-columns: repeat(auto-fit, minmax(105px, 2fr));
    gap: 2rem;
    padding-left: 3rem;
    padding-right: 3rem;
  }

  .bombo-home-grid .app-icon {
    aspect-ratio: 1 / 1;
    width: 100%;
    padding: 0.2rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
  }

  .bombo-home-grid .app-icon img {
    width: 40%;
    height: auto;
    margin-bottom: 0.1rem;
  }

  .bombo-home-grid .app-icon span,
  .bombo-home-grid .app-icon p {
    font-size: 0.85rem;
    text-transform: uppercase;
  }

  .bombo-home-header {
    margin-top: 6rem;
    margin-bottom: 1rem;
  }
}


/* screen-movie.css */
/* app/screen-movie.css
   Scope: Movie screen styles
   Reviewed for live use: 2026-02-05
*/

/* ==================================================
   MOVIE PLAYER (SINGLE)
   ================================================== */

.movie-poster {
  position: relative;
  display: inline-block;
  width: 100%;
  max-width: 500px;
  margin-bottom: 1rem;
}

.movie-poster img {
  width: 100%;
  height: auto;
  border-radius: 8px;
}

/* ==================================================
   MOVIE SCREEN
   ================================================== */

.movie-screen-container {
  max-width: 1200px;
  margin: 0 auto;
  background: radial-gradient(
      ellipse at center,
      rgba(37, 58, 101, 0.85) 0%,
      rgba(20, 35, 70, 0.8) 40%,
      rgba(5, 10, 20, 0.9) 100%
    ),
    rgba(37, 58, 101, 0.3);
  text-align: left;
  padding: 20px 30px;
  color: white;
}

.movie-layout {
  display: grid;
  grid-template-columns: 320px 1fr;
  gap: 32px;
  align-items: start;
}

.movie-aside {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.movie-main {
  min-width: 0;
}

.trailer-button-container {
  display: flex;
  justify-content: center;
}

.movie-back-button {
  margin-bottom: 30px;
}

.movie-back-button a {
  color: #8ac6d1;
  text-decoration: none;
  font-size: 1.1em;
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.movie-back-button a:hover {
  color: #b8e0e6;
}

.movie-header {
  margin-bottom: 30px;
}

.movie-title {
  font-size: 2.5em;
  margin-bottom: 10px;
  color: white;
}

.movie-meta {
  display: flex;
  gap: 20px;
  color: #b8e0e6;
  font-size: 1.1em;
}

.movie-meta-item.ikaraja {
  background: #ff6b6b;
  padding: 2px 10px;
  border-radius: 4px;
  font-weight: bold;
}

.movie-player-container {
  border-radius: 12px;
  overflow: hidden;
  max-width: 100%;
  margin: 0 auto 2rem auto;
}

.movie-player {
  position: relative;
  padding-bottom: 56.25%;
  height: 0;
}

.movie-player iframe {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  border: none;
}

.movie-details {
  display: grid;
  grid-template-columns: 2fr 1fr;
  gap: 40px;
}

.movie-synopsis h3 {
  font-size: 1.5em;
  margin-bottom: 15px;
  color: #8ac6d1;
}

.synopsis-content {
  line-height: 1.8;
  font-size: 1rem;
}

.movie-info-sidebar {
  background: rgba(255, 255, 255, 0.1);
  padding: 25px;
  border-radius: 10px;
  border: 1px solid rgba(255, 255, 255, 0.2);
}

.elokuva-meta-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px 24px;
  font-size: 0.98rem;
}

.elokuva-meta-grid strong {
  color: #8ac6d1;
}

.elokuva-meta-grid .span-2 {
  grid-column: 1 / -1;
}

.movie-age {
  line-height: 1.5;
}

.info-item {
  margin-bottom: 15px;
  padding-bottom: 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.info-item:last-child {
  border-bottom: none;
  margin-bottom: 0;
}

.info-label {
  display: block;
  font-weight: bold;
  color: #8ac6d1;
  margin-bottom: 5px;
}

.info-value {
  display: block;
  color: white;
}

/* Responsiivisuus */
@media (max-width: 768px) {
  .movie-layout {
    grid-template-columns: 1fr;
  }

  .movie-details {
    grid-template-columns: 1fr;
  }

  .movie-title {
    font-size: 2em;
  }

  .movie-synopsis {
    font-size: 0.95rem;
  }

  .movie-meta {
    flex-direction: column;
    gap: 10px;
  }
}

hr {
  border-width: 1px !important;
  color: var(--accent-color) !important;
  width: 100% !important;
  margin-left: 0 !important;
  border: none;
  border-top: 1px solid var(--accent-color);
  margin: 1rem auto;
  opacity: 0.5;
}


/* screen-tarinatuokiot.css */
/* app/screen-tarinatuokiot.css
   Scope: Tarinatuokiot screen styles
   Reviewed for live use: 2026-02-05
*/

/* ==================================================
   TARINATUOKIOT – SCREEN
   ================================================== */

.tarinatuokio-screen {
  max-width: 1200px;
  margin: 0 auto;
  padding: 2rem 1.5rem 4rem;
  color: #fff;
}

/* ==================================================
   COVER / HEADER
   ================================================== */

.tarinatuokio-cover {
  position: relative;
  background-size: cover;
  background-position: center;
  padding: 4rem 1.5rem;
  color: #fff;
  height: 300px;
  border-radius: 9px;
  align-content: center;
}

.tarinatuokio-cover-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(rgba(0, 0, 0, 0.15), rgba(0, 0, 0, 0.65));
}

.tarinatuokio-cover-content {
  position: relative;
  max-width: 900px;
  margin: 0 auto;
  text-align: center;
}

.tarinatuokio-cover h1 {
  font-size: 2.2rem;
  margin-bottom: 1rem;
}

.tarinatuokio-cover h1 span {
  color: rgba(0, 150, 190, 1);
}

.tarinatuokio-description {
  max-width: 640px;
  margin: 0 auto;
  font-size: 1.1rem;
  line-height: 1.7;
  opacity: 0.9;
}

/* ==================================================
   TAB BUTTONS (JAKSOLISTA)
   ================================================== */
.tarinatuokio-tabs {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 1.2rem;
  margin: 2rem auto;
  max-width: 1000px;
}

.tarinatuokio-tab-button {
  display: flex;
  align-items: center;
  gap: 12px;
  cursor: pointer;
  transition: all 0.25s ease;
  text-align: left;
  background: var(--gradient-bg);
  text-shadow: 1px 1px 3px rgba(0, 0, 0, 0.3);
  padding: 0.5rem 1rem;
  border-radius: 6px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
  border: 1px solid transparent;
}

.tarinatuokio-tab-button img {
  width: 33px;
  height: 33px;
  object-fit: cover;
  border-radius: 99px;
  flex-shrink: 0;
}

.tarinatuokio-tab-button .tab-title {
  flex-grow: 1;
  font-weight: 600;
  color: #fff;
  font-size: 1.1rem;
}

.tarinatuokio-tab-button .tab-ikaraja {
  background: #333;
  color: #ffd700;
  font-weight: bold;
  padding: 4px 8px;
  border-radius: 6px;
  font-size: 0.85rem;
}

.tarinatuokio-tab-button:hover,
.tarinatuokio-tab-button.active {
  border: 1px solid var(--tarinatuokiot-color);
}

.tarinatuokio-tab-button button {
  background: rgba(255, 255, 255, 0.08);
  color: #fff;
  border: none;
  border-radius: 14px;
  padding: 1rem 1.25rem;
  text-align: left;
  font-size: 1.1rem;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.25s ease, transform 0.15s ease;
}

.tarinatuokio-tab-button button:hover {
  background: rgba(255, 255, 255, 0.14);
  transform: translateY(-1px);
}

.tarinatuokio-tab-button button.active {
  background: linear-gradient(135deg, #4aa3df, #1f6fa3);
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.35);
}

/* ==================================================
   TAB CONTENT (JAKSO)
   ================================================== */

.bombo-tab-content {
  display: none;
  margin-bottom: 3rem;
}

.tarinatuokio-episode {
  background: var(--gradient-bg);
  border-radius: 24px;
  padding: 2rem;
  border: 1px solid rgba(255, 255, 255, 0.08);
}

/* ==================================================
   EPISODE LAYOUT
   ================================================== */

.episode-layout {
  display: grid;
  grid-template-columns: 2fr 1fr;
  gap: 2.5rem;
}

/* ==================================================
   VASEN SARAA – SISÄLTÖ
   ================================================== */

.episode-main h2 {
  font-size: 1.8rem;
  margin-bottom: 1rem;
}

.episode-synopsis {
  font-size: 1.05rem;
  line-height: 1.8;
  margin-bottom: 1.5rem;
  opacity: 0.95;
}

/* ==================================================
   VIDEO
   ================================================== */

.episode-video {
  position: relative;
  padding-bottom: 56.25%;
  height: 0;
  border-radius: 16px;
  overflow: hidden;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.45);
}

.episode-video iframe {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: none;
}

/* ==================================================
   LUKITTU SISÄLTÖ
   ================================================== */

.episode-locked {
  background: rgba(0, 0, 0, 0.55);
  border-radius: 16px;
  padding: 2rem;
  text-align: center;
  border: 1px solid rgba(255, 255, 255, 0.15);
}

.episode-locked p {
  font-size: 1.1rem;
  margin-bottom: 1.5rem;
  color: #f0f0f0;
}

.episode-locked .button {
  margin: 0.25rem;
}

/* ==================================================
   OIKEA SARAA – META
   ================================================== */

.episode-meta {
  background: rgba(255, 255, 255, 0.05);
  border-radius: 20px;
  padding: 1.25rem;
  border: 1px solid rgba(255, 255, 255, 0.1);
  text-align: left;
}

.episode-meta img {
  width: 100%;
  border-radius: 14px;
  margin-bottom: 1rem;
  display: block;
  aspect-ratio: 16 / 9;
}

.episode-meta div {
  font-size: 1rem;
  margin-bottom: 0.5rem;
}

.episode-meta strong {
  color: #9bd3ff;
  font-weight: 600;
}

.tarinatuokio-age-hint {
  display: flex;
  gap: 10px;
  margin-top: 0.75rem;
  font-size: 0.95rem;
  color: #e6e6e6;
  opacity: 0.95;
}

.tarinatuokio-age-hint img {
  width: 39px;
  height: 39px;
  flex-shrink: 0;
  border-radius: 99px;
  border: 0;
}

.tab-thumb {
  position: relative;
  width: 56px;
  height: 56px;
  flex-shrink: 0;
}

.tab-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 8px;
}

.tab-new-dot {
  position: absolute;
  top: -3px;
  left: -3px;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: #ff3b30;
  box-shadow: 0 0 0 2px rgba(0, 0, 0, 0.6);
}

/* ==================================================
   RESPONSIVE
   ================================================== */

@media (max-width: 900px) {
  .episode-layout {
    grid-template-columns: 1fr;
  }

  .episode-meta {
    order: -1;
  }

  .tarinatuokio-cover h1 {
    font-size: 2rem;
  }
}

@media (max-width: 600px) {
  .tarinatuokio-screen {
    padding: 1.5rem 1rem 3rem;
  }

  .tarinatuokio-cover {
    padding: 2.5rem 1.5rem;
  }

  .episode-main h2 {
    font-size: 1.5rem;
  }

  .episode-synopsis {
    font-size: 1rem;
  }
}


/* screen-trophies.css */
/* app/screen-trophies.css
   Scope: Trophies screen styles
   Reviewed for live use: 2026-02-05
*/

/* ==================================================
   SCREEN TROPHIES
   ================================================== */

/* APP – TROPHIES GRID */
/* Grid styles are shared in app/core.css (scoped to .trophies-container-app) */

.trophies-scroll-area {
  max-height: 100%;
  overflow-y: auto;
}

/* GAME TROPHIES (ALT LIST) */
.game-trophies {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 15px;
  margin-bottom: 20px;
}

.game-trophies .trophy-card.earned {
  border-color: #ffd700;
  background-color: transparent;
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
  color: #fff;
  border: 1px solid #fff;
}

.game-trophies .trophy-icon {
  font-size: 2.5rem;
  margin-right: 15px;
  color: #ffd700;
}

.profile-trophy-list .trophy-info h3 {
  margin: 0 0 5px 0;
  color: #333;
  font-size: 1.1rem;
}

.profile-trophy-list .earned-date {
  margin: 0;
  font-size: 0.9rem;
  color: #666;
  font-style: italic;
}

.game-trophies .trophy-card.not-earned {
  color: #888;
  font-style: italic;
  background: transparent;
  border: 1px solid #555;
}

/* Grouped app trophies */
.trophies-group {
  margin-bottom: 26px;
}

.trophies-group-title {
    margin: 1rem;
    color: #fff;
    font-size: 1.5rem;
    text-align: center;
}

.trophies-empty {
  margin: 0 0 12px;
  color: rgba(255, 255, 255, 0.85);
  text-align: center;
  font-style: italic;
}

/* PROFILE TROPHIES LAYOUT */
.profile-trophies-layout {
  display: flex;
  flex-direction: row;
  gap: 20px;
  margin-top: 20px;
}

.profile-user-info {
  width: 250px;
  flex-shrink: 0;
  background: #f5f5f5;
  padding: 15px;
  border-radius: 10px;
}

.profile-trophy-list {
  flex: 1;
  max-height: 500px;
  overflow-y: auto;
  padding-right: 10px;
}

.profile-trophy-list .trophy-card {
  display: flex;
  flex-direction: row;
  align-items: center;
  gap: 10px;
  background: #fff;
  border-radius: 8px;
  padding: 10px 15px;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
  min-width: 330px;
}

.profile-trophy-list .trophy-icon i {
  font-size: 28px;
}

/* Tier-värit */
.profile-trophy-list .tier-bronze i {
  color: #cd7f32;
}

.profile-trophy-list .tier-silver i {
  color: #c0c0c0;
}

.profile-trophy-list .tier-gold i {
  color: #ffd700;
}

.profile-trophy-list .tier-platinum i {
  color: #e5e4e2;
  text-shadow: 0 0 4px #bbb;
}

/* Status-tekstit */
.profile-trophy-list .earned-date {
  color: green;
  font-weight: bold;
}

/* Trophy toast styles come from bombo-trophies plugin CSS. */

/* liukukytkin */
.switch {
  position: relative;
  display: inline-block;
  width: 50px;
  height: 28px;
}

.switch input {
  opacity: 0;
  width: 0;
  height: 0;
}

.slider {
  position: absolute;
  cursor: pointer;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-color: #ccc;
  transition: 0.4s;
  border-radius: 34px;
}

.slider:before {
  position: absolute;
  content: "";
  height: 20px;
  width: 20px;
  left: 4px;
  bottom: 4px;
  background-color: white;
  transition: 0.4s;
  border-radius: 50%;
}

input:checked + .slider {
  background-color: #85de81;
}

input:checked + .slider:before {
  transform: translateX(22px);
}


/* screen-videos.css */
/* app/screen-videos.css
   Scope: Videos screen styles
   Reviewed for live use: 2026-02-05
*/

/* ==================================================
   VIDEO SCREEN
   ================================================== */

/* --- Otsikot --- */
.video-section,
.video-section h3 {
  text-align: center;
  color: #fff;
}

.content-description {
  max-width: 520px;
  margin: 0 auto;
  font-size: 1.1rem;
  line-height: 1.6;
  padding-left: 2rem;
  padding-right: 2rem;
}

@media (min-width: 1024px) {
  .content-description {
    max-width: 670px;
    margin: auto;
    margin-bottom: 1rem;
  }
}

.content-note {
  display: block;
  margin-top: 12px;
  font-size: 1.4rem;
  opacity: 0.7;
  color: var(--accent-color-2);
}

/* --- LUONTOJAKSOT --- */
.luontojaksot-section {
  position: relative;
  padding: 2rem 0;
  z-index: 1;
}

/* --- Kausikortit Grid --- */
.video-grid-seasons {
  display: grid;
  grid-template-columns: repeat(2, 400px);
  gap: 6rem;
  padding: 2rem;
  max-width: 1200px;
  margin: 0 auto;
  padding-bottom: 6rem;
  justify-content: center;
}

.video-grid-seasons .video-card .video-thumb .video-overlay {
  font-size: 1.2rem;
}

/* Tablet (esim. 768px-900px) */
@media (max-width: 900px) and (min-width: 600px) {
  .video-grid-seasons {
    grid-template-columns: repeat(2, 1fr);
    gap: 4rem;
    padding: 1.2rem;
    padding-bottom: 4rem;
  }

  .video-grid-seasons .video-card .video-thumb .video-overlay {
    font-size: 1.2rem;
  }
}

/* Mobiili */
@media (max-width: 599px) {
  .video-grid-seasons {
    grid-template-columns: repeat(1, 1fr);
    gap: 2rem;
    padding: 1rem;
    padding-bottom: 3rem;
    margin-left: 2rem;
    margin-right: 2rem;
  }

  .video-grid-seasons .video-card .video-thumb .video-overlay {
    font-size: 1rem;
  }
}

.new-episode-badge {
  position: absolute;
  top: 10px;
  left: 10px;
  background: #ff3b30;
  color: #fff;
  font-size: 12px;
  font-weight: 700;
  padding: 4px 8px;
  border-radius: 4px;
  z-index: 5;
}

/* --- Jaksot Grid --- */
.video-grid-episodes {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 6rem;
  padding: 2rem;
  max-width: 1200px;
  margin: 0 auto;
}

@media (max-width: 900px) {
  .video-grid-episodes {
    grid-template-columns: repeat(2, 1fr);
    gap: 4rem;
    padding-top: 10px;
    padding-left: 60px;
    padding-right: 60px;
    padding-bottom: 10px;
  }
}

/* Mobiili pysty: 1 sarake */
@media (max-width: 600px) {
  .video-grid-episodes {
    grid-template-columns: 1fr;
    gap: 2rem;
    padding-top: 10px;
    padding-left: 60px;
    padding-right: 60px;
    padding-bottom: 10px;
  }
}

/* --- Kortti --- */
.video-card {
  position: relative;
  cursor: pointer;
  border-radius: 20px;
  overflow: hidden;
  aspect-ratio: 16 / 9;
  opacity: 0.9;
  transform: scale(1.06);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
  transition: transform 0.2s ease;
}

.video-card:hover {
  transform: scale(1.1);
  opacity: 1;
}

/* --- Thumbnail --- */
.video-thumb {
  width: 100%;
  height: 100%;
  background-size: cover;
  background-position: center center;
  display: flex;
  align-items: flex-end;
  justify-content: center;
}

.video-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

/* --- Otsikkopalkki kortissa --- */
.video-overlay {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  background: rgba(0, 0, 0, 0.6);
  color: #fff;
  font-size: 1rem;
  font-weight: bold;
  text-align: center;
  padding: 0.5rem 0.75rem;
  border-bottom-left-radius: 20px;
  border-bottom-right-radius: 20px;
  text-shadow: 0 1px 3px rgba(0, 0, 0, 0.8);
}

/* ALA-NAVIGAATIO */
.back-to-videos {
  margin-top: 2rem;
  text-align: left;
  padding-left: 1rem;
  text-align: center;
}

.back-to-videos .back-link {
  display: inline-block;
  margin: 0.5rem;
  padding: 0.75rem 1.5rem;
  background-color: var(--primary-blue);
  color: white;
  border-radius: 0.5rem;
  text-decoration: none;
  font-weight: bold;
  transition: background 0.3s;
}

.back-to-videos .back-link:hover {
  background-color: #fff;
  color: #253a65;
  box-shadow: 0 0 5px rgba(0, 0, 0, 0.1);
}

.season-switch-link {
  margin-top: 1rem;
  text-align: center;
  padding-bottom: 2rem;
}

.season-switch-button {
  display: inline-block;
  margin: 0.5rem;
  padding: 0.5rem 1rem;
  color: white;
  border: 2px solid transparent;
  border-radius: 0.5rem;
  text-decoration: none;
  font-weight: bold;
  transition: background 0.3s, transform 0.2s, box-shadow 0.2s;
  font-size: 0.8rem;
}

.season-switch-button:hover {
  transform: translateY(-2px) scale(1.02);
  box-shadow: 0 10px 18px rgba(0, 0, 0, 0.22);
  filter: brightness(1.05);
}

/* Season color accents */
.season-switch-button.winter {
  border-color: #007bff;
}

.season-switch-button.spring {
  border-color: #4caf50;
}

.season-switch-button.summer {
  border-color: #ffc107;
}

.season-switch-button.autumn {
  border-color: #ff5722;
}

/* Current state */
.season-switch-button.current.winter {
  background: linear-gradient(135deg, #1e90ff, #00bfff);
  border-color: #007bff;
}

.season-switch-button.current.spring {
  background: linear-gradient(135deg, #32cd32, #90ee90);
  border-color: #4caf50;
}

.season-switch-button.current.summer {
  background: linear-gradient(135deg, #ff8c00, #ffd700);
  border-color: #ffc107;
}

.season-switch-button.current.autumn {
  background: linear-gradient(135deg, #8b4513, #d2691e);
  border-color: #ff5722;
}

.season-switch-button.current {
  transform: scale(1.05);
  pointer-events: none;
  transition: transform 0.2s ease;
}

/* --- Tarinatuokiot -section --- */
.tarinatuokiot-section {
  position: relative;
  padding: 2rem 0;
  z-index: 1;
}

.tarinatuokiot-section::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 50, 90, 0.5);
  z-index: -1;
}

/* --- Tarinatuokkioiden Grid --- */
.video-grid-collections {
  display: grid;
  grid-template-columns: repeat(auto-fit, 250px);
  justify-content: center;
  gap: 2rem;
  padding: 2rem;
  max-width: 1200px;
  margin: 0 auto;
  padding-bottom: 6rem;
}

.video-grid-collections .video-card .video-thumb .video-overlay {
  font-size: 1.2rem;
}

/* Tablet */
@media (max-width: 900px) and (min-width: 600px) {
  .video-grid-collections {
    grid-template-columns: repeat(2, 1fr);
    gap: 4rem;
    padding: 1.2rem;
    padding-bottom: 4rem;
  }

  .video-grid-collections .video-card .video-thumb .video-overlay {
    font-size: 1.2rem;
  }
}

/* Mobiili */
@media (max-width: 599px) {
  .video-grid-collections {
    grid-template-columns: repeat(1, 1fr);
    gap: 2rem;
    padding: 1rem;
    padding-bottom: 3rem;
    margin-left: 2rem;
    margin-right: 2rem;
  }

  .video-grid-collections .video-card .video-thumb .video-overlay {
    font-size: 1rem;
  }
}

/* --- Elokuvaosio mustalla taustalla --- */
.movies-section {
  position: relative;
  padding: 4rem 0;
  z-index: 1;
}

.movies-section::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0);
  z-index: -1;
}

.movies-section h2 {
  text-align: center;
  color: #fff;
}

/* --- Elokuvien grid pienempi ja yhtenäinen --- */
.video-grid-movies {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 220px));
  justify-content: center;
  gap: 3rem;
  max-width: 1200px;
  margin: 0 auto;
  padding: 2rem;
}

@media (max-width: 900px) {
  .video-grid-movies {
    grid-template-columns: repeat(auto-fit, minmax(180px, 260px));
    justify-content: center;
    gap: 2rem;
    padding: 1.25rem;
  }
}

/* --- "Tulossa" teksti --- */
.no-movies {
  text-align: center;
  color: #ccc;
  font-style: italic;
  margin-top: 2rem;
}

/* --- Elokuvien kortit julistekuvasuhteella --- */
.video-grid-movies .video-card {
  transform: scale(1.02);
  overflow: hidden;
  border-radius: 12px;
  display: flex;
  flex-direction: column;
  background: rgba(255, 255, 255, 0.03);
  transition: all 0.3s ease;
  cursor: pointer;
  width: 100%;
  max-width: 260px;
  margin: 0 auto;
}

.video-grid-movies .video-card:not(.coming-soon):hover {
  transform: scale(1.05);
  box-shadow: 0 15px 35px rgba(0, 0, 0, 0.4);
  background: rgba(255, 255, 255, 0.05);
}

/* Julistekuva täyttää kehyksen */
.video-grid-movies .video-thumb {
  aspect-ratio: 2 / 3;
  position: relative;
  background-size: cover;
  background-position: center;
  width: 100%;
  flex-grow: 1;
}

/* --- VUOSILUKU BADGE OIKEALLA YLHÄÄLLÄ --- */
.movie-year-badge {
  position: absolute;
  top: 10px;
  left: 10px;
  font-size: 0.8rem;
  font-weight: 700;
  background: linear-gradient(135deg, #ffcc00, #ff9900);
  color: #000;
  padding: 0.4rem 0.8rem;
  border-radius: 6px;
  z-index: 2;
  box-shadow: 0 3px 10px rgba(0, 0, 0, 0.3);
  font-family: sans-serif;
}

/* --- TULOSSA-BADGE KESKELLÄ --- */
.coming-badge-center {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  z-index: 10;
  text-align: center;
  width: 80%;
}

.coming-badge-center .coming-text {
  display: inline-block;
  background: rgba(0, 0, 0, 0.9);
  color: #ffd700;
  padding: 12px 24px;
  border-radius: 8px;
  font-weight: bold;
  font-size: 1.2em;
  border: 3px solid rgba(255, 215, 0, 0.4);
  text-transform: uppercase;
  letter-spacing: 2px;
  box-shadow: 0 5px 20px rgba(0, 0, 0, 0.8);
  backdrop-filter: blur(5px);
  font-family: 'Arial Rounded MT Bold', 'Arial', sans-serif;
}

/* --- ELOKUVAN NIMI JULISTEEN ALHAALLA --- */
.movie-title-bottom {
  padding: 1rem;
  background: rgba(0, 0, 0, 0.6);
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  text-align: center;
  flex-shrink: 0;
}

.movie-title-bottom h3 {
  font-size: 0.9rem;
  font-weight: 700;
  color: #fff;
  margin: 0;
  line-height: 1.3;
  font-family: 'Arial Rounded MT Bold', 'Arial', sans-serif;
}

.video-grid-movies .video-card:not(.coming-soon):hover .movie-title-bottom h3 {
  color: #ffcc00;
}

.video-card.movie-card {
  aspect-ratio: auto;
  transform: none;
  display: flex;
  flex-direction: column;
}

/* --- MOVIE CARD (hover CTA) --- */
.movie-card {
  position: relative;
  cursor: pointer;
  transition: transform 0.3s ease;
  border-radius: 12px;
  overflow: hidden;
  background: #1a2b3c;
}

.movie-card:hover {
  transform: translateY(-5px);
}

.movie-card:hover .movie-watch-button {
  opacity: 1;
  transform: translateY(0);
}

.movie-watch-button {
  position: absolute;
  bottom: 70px;
  left: 0;
  right: 0;
  background: #111;
  color: #ffcc00;
  padding: 12px;
  text-align: center;
  font-weight: bold;
  opacity: 0;
  transform: translateY(10px);
  transition: all 0.3s ease;
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 8px;
}

.watch-arrow {
  font-size: 1.2em;
}

/* --- TULOSSA OVERLAY (estää klikkauksen) --- */
.video-card.coming-soon {
  pointer-events: none;
  opacity: 0.85;
}

.video-card.coming-soon .movie-title-bottom h3 {
  color: rgba(255,  255,  255, 0.9);
}

/* --- Mobile tyylit --- */
@media (max-width: 768px) {
  .coming-badge-center .coming-text {
    padding: 10px 18px;
    font-size: 1em;
    letter-spacing: 1px;
  }

  .movie-year-badge {
    font-size: 0.8rem;
    padding: 0.3rem 0.6rem;
    top: 8px;
  }

  .movie-title-bottom h3 {
    font-size: 1rem;
  }
}

/* Ikärajasymboli yläkulmaan */
.ikaraja-symbol {
  position: absolute;
  top: 6px;
  right: 6px;
  width: 26px;
  height: 26px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: bold;
  font-size: 16px;
  z-index: 10;
  font-family: sans-serif;
}

.ikaraja-s {
  background-color: #3e3e3e;
  color: #97d64e;
}

.ikaraja-k7 {
  background-color: #3e3e3e;
  color: #ffff00;
}

.ikaraja-k12 { background: #c62828; }

.ikaraja-default {
  background-color: #3e3e3e;
}

.video-overlay .ikaraja-symbol {
  margin-left: 8px;
  padding: 2px 6px;
  border-radius: 4px;
  font-size: 12px;
  font-weight: bold;
}

.collection-hint-icon {
  position: absolute;
  top: 3px;
  right: 8px;
  opacity: 0.9;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.collection-hint-icon img {
  width: 39px;
  height: 39px;
  display: block;
}

.video-card.is-locked {
  cursor: default;
  pointer-events: none;
}

.video-lock-overlay {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.6);
  color: #fff;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  font-size: 0.85rem;
  font-weight: 600;
  padding: 1rem;
  z-index: 2;
}

.video-card.is-missing-video {
  cursor: default;
  pointer-events: none;
}

.video-missing-overlay {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.65);
  color: #fff;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  font-size: 0.9rem;
  font-weight: 600;
  padding: 1rem;
  z-index: 2;
}

/* =========================
   IKÄRAJALEGENDA
   ========================= */
.ikaraja-legend {
  width: 100%;
  margin: 3rem 0 1.5rem;
  padding: 0 1rem;
}

.ikaraja-legend ul {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 1.5rem;
  list-style: none;
  margin: 0;
  padding: 0;
  flex-wrap: wrap;
}

.ikaraja-item {
  display: flex;
  align-items: center;
  gap: 8px;
  color: #ffffff;
  font-size: 0.8rem;
  white-space: nowrap;
  opacity: 0.8;
}

.ikaraja-text {
  opacity: 0.9;
}

/* =========================
   IKÄRAJAPALLUKKA (YHTEINEN)
   ========================= */
.ikaraja-symbol {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 26px;
  height: 26px;
  border-radius: 50%;
  font-weight: bold;
  font-size: 16px;
  font-family: sans-serif;
}

/* =========================
   RESET: EI ABSOLUTE LEGENDASSA
   ========================= */
.ikaraja-legend .ikaraja-symbol {
  position: static !important;
}

/* =========================
   MOBIILI
   ========================= */
@media (max-width: 600px) {
  .ikaraja-item {
    white-space: normal;
    align-items: flex-start;
  }
}

.video-badges {
  position: absolute;
  top: 8px;
  left: 8px;
  display: flex;
  flex-direction: column;
  gap: 6px;
  z-index: 6;
}

.video-badges > span {
  align-self: flex-start;
}

/* Uusi */
.badge-new {
  background: linear-gradient(
    135deg,
    #ff6a6a,
    #ff3b30
  );
  color: #fff;
  padding: 4px 10px;
  border-radius: 6px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.04em;
}

/* Ennakkokatselu */
.corner-badge {
  position: static;
  background: linear-gradient(
    135deg,
    var(--kerho-color-start),
    var(--kerho-color-mid),
    var(--kerho-color-end)
  );
  color: #fff;
  padding: 4px 10px;
  border-radius: 6px;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.04em;
  opacity: 0.95;
}
