/* =========================================================
   INTENDENTE POR UN DÍA — estilos (se suma a styles.css + brujula.css)
   ========================================================= */

/* ---------- Inicio ---------- */
.int-palacio { position: relative; width: 170px; height: 150px; margin-bottom: 14px; animation: floaty 5s ease-in-out infinite; }
@keyframes floaty { 50% { transform: translateY(-8px); } }
.int-palacio__flag { position: absolute; left: 50%; top: 0; width: 4px; height: 34px; background: var(--dark); }
.int-palacio__flag::after { content: ""; position: absolute; left: 4px; top: 0; width: 30px; height: 18px; background: linear-gradient(#74ACDF 33%, #fff 33% 66%, #74ACDF 66%); border: 1px solid var(--line); animation: flag 1.6s ease-in-out infinite; transform-origin: left center; }
@keyframes flag { 50% { transform: skewY(6deg) scaleX(.92); } }
.int-palacio__dome { position: absolute; left: 50%; top: 30px; width: 70px; height: 38px; margin-left: -35px; border-radius: 70px 70px 0 0; background: var(--purple); border: 1px solid var(--line); }
.int-palacio__body { position: absolute; left: 10px; right: 10px; top: 64px; height: 64px; background: #fff; border: 1px solid var(--line); border-radius: 6px; display: flex; justify-content: space-around; align-items: flex-end; padding: 0 10px 0; box-shadow: var(--shadow-soft); }
.int-palacio__body::before { content: ""; position: absolute; left: -14px; right: -14px; top: -14px; height: 14px; background: var(--orange); border: 1px solid var(--line); clip-path: polygon(0 100%, 50% 0, 100% 100%); border-width: 0; background: linear-gradient(var(--orange), var(--orange)); }
.int-palacio__body i { width: 12px; height: 46px; background: var(--light); border: 1px solid var(--line); border-bottom: 0; border-radius: 3px 3px 0 0; }
.int-palacio__base { position: absolute; left: 0; right: 0; bottom: 8px; height: 14px; background: var(--dark); border-radius: 4px; }

.int-ind-preview { display: flex; flex-wrap: wrap; gap: 8px; justify-content: center; margin-top: 20px; }
.int-chip { font-weight: 800; padding: 8px 14px; border-radius: 99px; background: #fff; border: 2.5px solid var(--c); box-shadow: var(--shadow-soft); font-size: .9rem; }
.int-modes { grid-template-columns: repeat(2, minmax(0, 260px)); }
.int-modes .bru-mode__n { font-size: 3rem; background: none; -webkit-background-clip: initial; background-clip: initial; color: initial; }
.int-toggle { display: inline-flex; align-items: center; gap: 10px; margin-top: 26px; font-weight: 700; background: rgba(255,255,255,.8); padding: 10px 18px; border-radius: 99px; border: 1px solid var(--line); cursor: pointer; }
.int-toggle input { width: 20px; height: 20px; accent-color: var(--purple); }

.int-how { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 16px; margin-bottom: 30px; }
.int-how > div { position: relative; padding: 22px 20px 20px; border-radius: 22px; background: #fff; border: 1px solid var(--line); box-shadow: var(--shadow-soft); }
.int-how > div > b { display: grid; place-items: center; width: 44px; height: 44px; border-radius: 50%; background: var(--grad-main); color: #fff; font-family: var(--font-display); font-size: 1.2rem; margin-bottom: 10px; border: 1px solid var(--line); }
.int-how p { font-weight: 500; }

.int-estilos { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 12px; margin-bottom: 20px; }
.int-estilo { display: flex; flex-direction: column; gap: 4px; padding: 16px; border-radius: 18px; background: #fff; border: 1px solid var(--line); box-shadow: var(--shadow-soft); transition: transform .2s var(--ease); }
.int-estilo:hover { transform: translateY(-3px) rotate(-.5deg); }
.int-estilo__ico { font-size: 1.8rem; line-height: 1; }
.int-estilo b { font-size: 1.05rem; }
.int-estilo small { color: var(--gray); font-weight: 600; }
.int-estilo__bar { height: 10px; border-radius: 10px; background: var(--light); overflow: hidden; margin-top: 6px; }
.int-estilo__bar span { display: block; height: 100%; background: var(--grad-main); transition: width 1s var(--ease); }
.int-estilo__n { font-weight: 800; font-size: .82rem; color: var(--purple); }
.int-estilo.is-top { background: var(--dark); color: #fff; box-shadow: var(--shadow-soft); transform: scale(1.03); }
.int-estilo.is-top small { color: rgba(255,255,255,.75); }
.int-estilo.is-top .int-estilo__n { color: var(--yellow); }
.int-estilo.is-off { opacity: .5; box-shadow: none; border-style: dashed; }

/* ---------- Juego ---------- */
.int-hud { position: sticky; top: 58px; z-index: 20; background: rgba(51,51,51,.96); backdrop-filter: blur(6px); border-bottom: 4px solid var(--yellow); padding: 10px 0; }
.int-hud__in { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 12px; }
.int-ind { --c: var(--yellow); position: relative; display: flex; align-items: center; gap: 8px; color: #fff; padding: 6px 10px; border-radius: 14px; background: rgba(255,255,255,.06); transition: background .3s; }
.int-ind__ico { font-size: 1.4rem; }
.int-ind__body { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 4px; }
.int-ind__name { font-weight: 800; font-size: .72rem; text-transform: uppercase; letter-spacing: .08em; opacity: .8; }
.int-ind__bar { display: block; height: 10px; border-radius: 10px; background: rgba(255,255,255,.15); overflow: hidden; }
.int-ind__bar span { display: block; height: 100%; background: var(--c); border-radius: 10px; transition: width .8s var(--ease); }
.int-ind:not(.is-danger) .int-ind__bar span { box-shadow: 0 0 10px var(--c); }
.int-ind__v { font-family: var(--font-display); font-size: 1rem; min-width: 30px; text-align: right; }
.int-ind__d { position: absolute; right: 6px; top: -6px; font: 900 .78rem var(--font-display); padding: 2px 7px; border-radius: 99px; animation: popD 1.4s var(--ease) forwards; }
.int-ind.is-up .int-ind__d { background: #1fa855; }
.int-ind.is-down .int-ind__d { background: #d0233f; }
.int-ind.is-up { animation: flashUp .9s; }
.int-ind.is-down { animation: flashDown .9s; }
@keyframes flashUp { 30% { background: rgba(31,168,85,.45); } }
@keyframes flashDown { 30% { background: rgba(208,35,63,.5); } 20%, 40% { transform: translateX(-3px); } 30% { transform: translateX(3px); } }
@keyframes popD { 0% { opacity: 0; transform: translateY(8px) scale(.6); } 15% { opacity: 1; transform: none; } 80% { opacity: 1; } 100% { opacity: 0; transform: translateY(-8px); } }
.int-ind.is-danger .int-ind__bar span { background: #ff3355; animation: blink .8s infinite; }
.int-ind.is-danger .int-ind__v { color: #ff6b81; }
@keyframes blink { 50% { opacity: .35; } }

.int-game { max-width: 860px; padding: 34px 0 80px; }
.int-clockrow { display: flex; align-items: center; gap: 20px; margin-bottom: 22px; }
.int-clock { display: flex; flex-direction: column; align-items: center; padding: 10px 18px; border-radius: 18px; background: var(--dark); color: var(--yellow); border: 1px solid var(--line); box-shadow: var(--shadow-soft); }
.int-clock span { font-family: var(--font-display); font-weight: 900; font-size: 1.8rem; line-height: 1; text-shadow: 0 0 12px rgba(244,217,105,.6); }
.int-clock small { color: #fff; font-weight: 700; font-size: .78rem; margin-top: 4px; }
.int-day { flex: 1; }

.int-card { position: relative; overflow: hidden; display: flex; flex-direction: column; gap: 14px; padding: 34px 38px; border-radius: 30px; background: #fff; border: 1px solid var(--line); box-shadow: var(--shadow-soft); min-height: 200px; justify-content: center; }
.int-card::after { content: "🏛"; position: absolute; right: -10px; bottom: -30px; font-size: 9rem; opacity: .06; }
.int-card.is-urg { background: #fff4f0; box-shadow: var(--shadow-soft); border-color: #d0233f; }
.int-card.is-in { animation: qIn .45s var(--ease); }
.int-card__urg { align-self: flex-start; font-weight: 900; font-size: .78rem; text-transform: uppercase; letter-spacing: .1em; color: #fff; background: #d0233f; padding: 5px 12px; border-radius: 99px; animation: blink 1.2s infinite; }
.int-card__quien { align-self: flex-start; font-weight: 800; font-size: .9rem; padding: 6px 14px; border-radius: 99px; background: var(--dark); color: var(--yellow); }
.int-card__txt { font-weight: 800; font-size: clamp(1.2rem, 2.8vw, 1.7rem); line-height: 1.32; }

.int-ops { display: grid; gap: 12px; margin-top: 24px; }
.int-op { display: flex; align-items: center; gap: 14px; width: 100%; text-align: left; cursor: pointer; font: 800 1.05rem var(--font); color: var(--dark); padding: 16px 20px; border-radius: 20px; background: #fff; border: 1px solid var(--line); box-shadow: var(--shadow-soft); transition: transform .15s var(--ease), box-shadow .15s, background .15s; }
.int-op:hover { transform: translate(-3px, -3px); box-shadow: var(--shadow-soft); background: #fffbe6; }
.int-op:active { transform: translate(2px, 2px); box-shadow: var(--shadow-soft); }
.int-op kbd { display: grid; place-items: center; flex: 0 0 auto; width: 34px; height: 34px; border-radius: 10px; background: var(--grad-main); color: #fff; font: 900 .95rem var(--font-display); border: 1px solid var(--line); }
.int-op__t { flex: 1; }
.int-op__fx { display: flex; gap: 4px; flex-wrap: wrap; justify-content: flex-end; max-width: 45%; }
.int-op__fx i { font-style: normal; font-size: .82rem; font-weight: 900; padding: 3px 7px; border-radius: 8px; background: var(--light); white-space: nowrap; }
.int-op__fx i.up { background: #d8f5e2; color: #12753a; }
.int-op__fx i.down { background: #fde0e5; color: #b0123f; }

.int-cons { margin-top: 24px; padding: 24px 26px; border-radius: 24px; background: var(--dark); color: #fff; box-shadow: var(--shadow-soft); display: flex; flex-direction: column; gap: 14px; align-items: flex-start; }
.int-cons.is-in { animation: qIn .4s var(--ease); }
.int-cons__txt { font-weight: 700; font-size: 1.15rem; line-height: 1.4; }
.int-cons__txt::before { content: "📣 "; }
.int-cons__fx { display: flex; flex-wrap: wrap; gap: 8px; }
.int-fx { font-weight: 800; font-size: .9rem; padding: 6px 12px; border-radius: 99px; background: rgba(255,255,255,.12); }
.int-fx.up { background: #1fa855; }
.int-fx.down { background: #d0233f; }
.int-tip { font-size: .8rem; font-weight: 600; color: var(--gray); align-self: center; }

/* ---------- Resultado ---------- */
.int-verdict { display: flex; align-items: center; gap: 30px; flex-wrap: wrap; }
.int-score { display: grid; place-items: center; width: 170px; height: 170px; border-radius: 50%; background: var(--dark); color: var(--yellow); border: 6px solid #fff; box-shadow: var(--shadow-soft), 0 0 40px rgba(244,217,105,.6); font-family: var(--font-display); font-weight: 900; text-align: center; line-height: 1; animation: pulseScore 2.4s ease-in-out infinite; }
.int-score span { font-size: 3.8rem; }
.int-score small { font-size: 1rem; color: #fff; opacity: .7; margin-top: -30px; }
@keyframes pulseScore { 50% { transform: scale(1.04) rotate(-2deg); } }
.int-verdict__estilo { font-weight: 700; font-size: 1.2rem; margin-top: 8px; }
.int-verdict__estilo b { background: var(--dark); color: var(--yellow); padding: 3px 12px; border-radius: 99px; }
.int-verdict__estilo span { font-weight: 600; opacity: .8; font-size: 1rem; }

.int-final { display: grid; gap: 12px; }
.int-fin { --c: var(--yellow); display: flex; align-items: center; gap: 14px; padding: 14px 18px; border-radius: 18px; background: #fff; border: 1px solid var(--line); box-shadow: var(--shadow-soft); }
.int-fin__ico { font-size: 1.8rem; width: 44px; text-align: center; }
.int-fin__body { flex: 1; display: flex; flex-direction: column; gap: 6px; }
.int-fin .int-ind__bar { height: 16px; background: var(--light); border: 1px solid var(--line); }
.int-fin__v { font-family: var(--font-display); font-weight: 900; font-size: 1.5rem; min-width: 50px; text-align: right; }
.int-fin.is-danger { box-shadow: var(--shadow-soft); }
.int-fin.is-danger .int-ind__bar span { background: #d0233f; }

.int-agenda { list-style: none; padding: 0 0 0 22px; margin: 0; border-left: 1px dashed var(--line); display: grid; gap: 12px; }
.int-agenda li { position: relative; display: flex; gap: 14px; align-items: flex-start; padding: 12px 16px; border-radius: 16px; background: #fff; border: 2px solid #e2e2e2; }
.int-agenda li::before { content: ""; position: absolute; left: -33px; top: 18px; width: 16px; height: 16px; border-radius: 50%; background: var(--yellow); border: 1px solid var(--line); }
.int-agenda li.is-urg { border-color: #d0233f; }
.int-agenda li.is-urg::before { background: #d0233f; }
.int-agenda li.is-fin { background: var(--dark); color: #fff; border-color: var(--dark); }
.int-agenda li.is-fin::before { background: #d0233f; }
.int-agenda li.is-ok::before { background: #1fa855; }
.int-agenda time { font-family: var(--font-display); font-weight: 900; font-size: .95rem; color: var(--purple); min-width: 56px; }
.int-agenda li.is-fin time { color: var(--yellow); }
.int-agenda div { display: flex; flex-direction: column; gap: 3px; flex: 1; }
.int-agenda small { color: var(--gray); font-weight: 700; }
.int-agenda__fx { display: flex; flex-wrap: wrap; gap: 6px; }
.int-agenda__fx i { font-style: normal; font-weight: 800; font-size: .8rem; padding: 2px 8px; border-radius: 8px; }
.int-agenda__fx i.up { background: #d8f5e2; color: #12753a; }
.int-agenda__fx i.down { background: #fde0e5; color: #b0123f; }

@media (max-width: 900px) {
  .int-how { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .int-hud__in { gap: 6px; }
  .int-ind { flex-direction: column; gap: 2px; padding: 6px 4px; text-align: center; }
  .int-ind__ico { font-size: 1.1rem; }
  .int-ind__name { font-size: .6rem; letter-spacing: .02em; }
  .int-ind__body { width: 100%; }
  .int-ind__v { font-size: .85rem; text-align: center; min-width: 0; }
}
@media (max-width: 760px) {
  .int-modes { grid-template-columns: 1fr; }
  .int-how { grid-template-columns: 1fr; }
  .int-card { padding: 24px 22px; min-height: 170px; }
  .int-op { flex-wrap: wrap; padding: 14px 16px; font-size: .98rem; }
  .int-op__fx { max-width: 100%; width: 100%; justify-content: flex-start; padding-left: 48px; }
  .int-op__fx:empty { display: none; }
  .int-tip { display: none; }
  .int-clock span { font-size: 1.4rem; }
  .int-score { width: 130px; height: 130px; }
  .int-score span { font-size: 2.8rem; }
  .int-hud { top: 56px; }
}
@media (prefers-reduced-motion: reduce) {
  .int-palacio, .int-score, .int-card__urg, .int-palacio__flag::after { animation: none; }
}
