/* =================================================================
   PAES Practice · Job Intro
   Boss character hands the student today's job at the start.
   ================================================================= */

.intro-overlay {
  position: fixed;
  inset: 0;
  z-index: 1500;
  background:
    radial-gradient(ellipse at 30% 20%, rgba(217,164,65,0.18) 0%, transparent 55%),
    radial-gradient(ellipse at 70% 80%, rgba(29,139,139,0.15) 0%, transparent 55%),
    linear-gradient(180deg, #0a1f33 0%, #050d18 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 40px 24px;
  animation: intro-fade-in 0.5s ease forwards;
}

@keyframes intro-fade-in {
  from { opacity: 0; }
  to   { opacity: 1; }
}

.intro-overlay.exiting {
  animation: intro-fade-out 0.45s ease forwards;
  pointer-events: none;
}

@keyframes intro-fade-out {
  from { opacity: 1; transform: scale(1); }
  to   { opacity: 0; transform: scale(1.05); }
}

.intro-stage {
  display: grid;
  grid-template-columns: 280px 1fr;
  gap: 40px;
  max-width: 980px;
  width: 100%;
  align-items: center;
}

/* ----- The boss ----- */

.intro-boss {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  animation: boss-slide 0.7s cubic-bezier(0.34, 1.56, 0.64, 1) 0.1s both;
}

@keyframes boss-slide {
  from { transform: translateX(-60px); opacity: 0; }
  to   { transform: translateX(0); opacity: 1; }
}

.boss-avatar {
  width: 220px;
  height: 220px;
  border-radius: 50%;
  background: linear-gradient(180deg, var(--boss-color, #2C5F9A) 0%, var(--boss-color-dark, #0F2E4C) 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 130px;
  box-shadow:
    0 24px 60px rgba(0,0,0,0.5),
    inset 0 -8px 20px rgba(0,0,0,0.25),
    inset 0 4px 10px rgba(255,255,255,0.18),
    0 0 0 8px rgba(255,255,255,0.05);
  position: relative;
  animation: boss-bob 3s ease-in-out infinite;
}

@keyframes boss-bob {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-6px); }
}

.boss-avatar:before {
  content: '';
  position: absolute;
  bottom: -16px;
  left: 50%;
  transform: translateX(-50%);
  width: 200px;
  height: 18px;
  background: radial-gradient(ellipse, rgba(0,0,0,0.4) 0%, transparent 70%);
  border-radius: 50%;
  z-index: -1;
}

.boss-name {
  margin-top: 20px;
  text-align: center;
}

.boss-name .role {
  font-size: 10px;
  letter-spacing: 2.4px;
  text-transform: uppercase;
  color: var(--paes-gold);
  font-weight: 700;
  margin-bottom: 4px;
}

.boss-name .full {
  font-size: 22px;
  color: #fff;
  font-weight: 800;
  letter-spacing: -0.3px;
}

.boss-name .note {
  font-size: 12px;
  color: rgba(255,255,255,0.55);
  margin-top: 4px;
  font-style: italic;
}

/* ----- Speech + clipboard ----- */

.intro-content {
  position: relative;
  animation: content-slide 0.7s cubic-bezier(0.34, 1.56, 0.64, 1) 0.3s both;
}

@keyframes content-slide {
  from { transform: translateX(60px); opacity: 0; }
  to   { transform: translateX(0); opacity: 1; }
}

.speech-bubble {
  position: relative;
  background: linear-gradient(180deg, #fff 0%, #f4f0e0 100%);
  color: var(--paes-navy);
  border-radius: 18px;
  padding: 22px 28px;
  font-size: 17px;
  line-height: 1.5;
  font-weight: 600;
  margin-bottom: 22px;
  box-shadow: 0 12px 36px rgba(0,0,0,0.4);
  max-width: 540px;
}

.speech-bubble:before {
  content: '';
  position: absolute;
  left: -14px;
  top: 30px;
  width: 0; height: 0;
  border-top: 14px solid transparent;
  border-bottom: 14px solid transparent;
  border-right: 16px solid #fff;
}

.speech-bubble .name-tag {
  display: inline-block;
  font-size: 10px;
  letter-spacing: 1.6px;
  text-transform: uppercase;
  color: var(--paes-gold);
  font-weight: 800;
  margin-bottom: 8px;
}

.speech-bubble .line {
  font-style: italic;
}

/* ----- Clipboard with the job details ----- */

.clipboard {
  position: relative;
  background: #c8a868;
  border-radius: 6px;
  padding: 10px;
  box-shadow: 0 16px 40px rgba(0,0,0,0.5);
  max-width: 540px;
}

.clipboard:before {
  content: '';
  position: absolute;
  top: -10px;
  left: 50%;
  transform: translateX(-50%);
  width: 80px;
  height: 22px;
  background: linear-gradient(180deg, #888 0%, #555 100%);
  border-radius: 4px;
  border-bottom: 3px solid #2a2a2a;
}

.clipboard-paper {
  background: #fffaf0;
  border-radius: 3px;
  padding: 26px 28px 22px;
  position: relative;
}

.clipboard-paper:before {
  content: '';
  position: absolute;
  left: 24px;
  top: 0;
  bottom: 0;
  width: 1.5px;
  background: rgba(220,60,60,0.4);
}

.cb-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  border-bottom: 2px solid var(--paes-navy);
  padding-bottom: 10px;
  margin-bottom: 14px;
}

.cb-header .label {
  font-size: 9px;
  letter-spacing: 1.6px;
  text-transform: uppercase;
  color: #4A5878;
  font-weight: 700;
  margin-bottom: 2px;
}

.cb-header .job-title {
  font-size: 18px;
  color: var(--paes-navy);
  font-weight: 800;
  letter-spacing: -0.3px;
  margin-bottom: 2px;
}

.cb-header .unit-tag {
  font-size: 11px;
  color: var(--paes-gold);
  font-weight: 700;
  letter-spacing: 1px;
}

.cb-header .pts {
  background: var(--paes-navy);
  color: #fff;
  padding: 5px 11px;
  border-radius: 100px;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.4px;
}

.cb-body {
  font-size: 12.5px;
  line-height: 1.5;
  color: #1a1a1a;
}

.cb-row {
  display: grid;
  grid-template-columns: 80px 1fr;
  gap: 10px;
  padding: 4px 0;
  border-bottom: 1px dashed rgba(0,0,0,0.08);
}

.cb-row:last-child { border-bottom: none; }

.cb-row .key {
  font-size: 10px;
  letter-spacing: 1.2px;
  text-transform: uppercase;
  color: #4A5878;
  font-weight: 700;
}

.cb-row .val { font-weight: 600; }

/* ----- Action row ----- */

.intro-actions {
  display: flex;
  gap: 12px;
  margin-top: 28px;
  align-items: center;
}

.btn-clock-in {
  background: linear-gradient(135deg, var(--paes-gold) 0%, #C68F2F 100%);
  color: var(--paes-navy);
  border: none;
  padding: 16px 32px;
  border-radius: 14px;
  font-weight: 800;
  font-size: 16px;
  cursor: pointer;
  letter-spacing: 0.4px;
  box-shadow: 0 12px 32px rgba(217,164,65,0.4), inset 0 1px 0 rgba(255,255,255,0.5);
  transition: all 0.18s ease;
  display: inline-flex;
  align-items: center;
  gap: 10px;
}

.btn-clock-in:hover { transform: translateY(-2px); box-shadow: 0 16px 40px rgba(217,164,65,0.5), inset 0 1px 0 rgba(255,255,255,0.5); }
.btn-clock-in:active { transform: translateY(0); }

.btn-skip-intro {
  background: transparent;
  border: 1px solid rgba(255,255,255,0.2);
  color: rgba(255,255,255,0.55);
  font-size: 13px;
  padding: 10px 18px;
  border-radius: 100px;
  cursor: pointer;
  font-weight: 600;
  transition: all 0.15s ease;
}

.btn-skip-intro:hover {
  background: rgba(255,255,255,0.06);
  color: #fff;
}

/* ----- Streak / day pill ----- */

.intro-pill {
  position: absolute;
  top: 24px;
  right: 24px;
  display: flex;
  gap: 8px;
}

.intro-pill .stat {
  background: rgba(255,255,255,0.07);
  border: 1px solid rgba(255,255,255,0.12);
  color: rgba(255,255,255,0.85);
  padding: 7px 14px;
  border-radius: 100px;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.4px;
}

.intro-pill .stat .icon { margin-right: 4px; }
.intro-pill .stat.streak {
  background: linear-gradient(135deg, rgba(217,164,65,0.25), rgba(220,80,40,0.15));
  border-color: rgba(217,164,65,0.4);
  color: var(--paes-gold);
}

@media (max-width: 800px) {
  .intro-stage { grid-template-columns: 1fr; gap: 20px; }
  .boss-avatar { width: 140px; height: 140px; font-size: 90px; }
  .speech-bubble { font-size: 15px; padding: 18px 22px; }
  .speech-bubble:before { left: 30px; top: -14px; transform: rotate(90deg); }
  .clipboard-paper { padding: 22px 18px 16px; }
}
