

/* SIGQUIZ — VERSION 5.8 — CSS 18/3/2026 */

:root {
  /* Felt (table) [#008001; is the green that matches the BG of the easel] */
  --felt: #234626;
  --felt-light: #2f5a32;
  --felt-dark: #1b3620;

  /* Paper (cartons / cards / panels) */
  --paper: #e8dbc3;
  --paper-dark: #cabfa9;
  --paper-light: #f6efdf;
  --ink:  #0a0a0a;

  /* Guilt */
  --gilt: #d4a83a;
  --gilt-shadow: #a3842d;

  /* Feedback tonal (M/m) */
  --major: #f8f2e2;
  --minor: #e7e0ce;
}

body {
  background-color: #008001;
  color: #ffffff; /* global default */
}


*{box-sizing:border-box}
html,body{height:100%}

body {
  margin: 0;
  font-family: system-ui, -apple-system, "Segoe UI", Roboto, Arial;
  background: linear-gradient(180deg,#eef3f8 0%, #fdfefe 100%);
  color: var(--text);
  display: flex;
  justify-content: center;
  padding: 18px;
   background-color: var(--sigwizz-green);
  background-image:
    radial-gradient(rgba(255,255,255,0.04) 1px, transparent 1px);
  background-size: 4px 4px;
  }
  
  html, body { overflow-x: hidden; }

/* container of both left & right panels*/
.sigquiz-container{
  width: min(1180px, 96vw);
  background: var(--felt-green); /* was card-cream */
  border-radius: 12px;

/* table lift */
  box-shadow:
    0 18px 36px rgba(0,0,0,0.25),   
   inset 0 0 0 1px #d4a83a; /* was grey i.e. inset 0 0 0 1px rgba(255,255,255,0.6); */
}


/* topbar */
#topbar{
  padding: 12px 18px;
  display:flex;
  flex-direction:column;
  gap:10px;
  align-items:center;
  border-bottom: 1px solid rgba(20,30,40,0.04);
}

h1#main-title {
  margin: 0;
  padding: 0;
  font-size: 2.6rem; /* 1.9 */
  font-weight: 600;
  color: #d4a83a;
  line-height: 1.1;
  text-align: center;
}

/* graphic control bar */
#graphic-bar {
  display: flex;
  gap: 6px;
  align-items: center;
}

/* === SOUND BUTTON POSITIONING IN CONTROL BAR === */
#sound-btn {
  margin-left: auto;
  cursor: pointer;
  user-select: none;
}

/* controls row */
.controls-row{
  width:100%;
  display:flex;
  justify-content:center;
  align-items:center;
  gap:12px;
  flex-wrap:wrap;
}

/* mode buttons */
.mode-group { display:flex; gap:8px; }
.mode-btn{
  padding:10px 14px;
  border-radius:10px; border:none; color:#fff; cursor:pointer; font-weight:600;
  box-shadow: 0 6px 18px rgba(12,18,26,0.06);
  white-space:nowrap;
}
.mode-btn:focus{ outline:3px solid rgba(0,0,0,0.06); }
.mode-btn.blue{ background: linear-gradient(180deg,#2b7fe6,#0f5fcf); }
.mode-btn.red{ background: linear-gradient(180deg,#e24d4a,#b83332); }
.mode-btn.green{ background: linear-gradient(180deg,#2ec07c,#1e8f5a); }

/* menu buttons */
.menu-btn{ padding:8px 12px; border-radius:8px; border:1px solid rgba(20,30,40,0.06); background:#fff; cursor:pointer; font-weight:600; }
.menu-btn.gold{ background: linear-gradient(180deg,#f8e6c1,#f2d08a); border-color: rgba(120,90,40,0.12); }

/* floating dropdowns */
.menu-wrapper{ position:relative; display:inline-block; }
.menu-panel{
  position:absolute; top:calc(100% + 8px); left:0; width:320px;
  background: rgba(8,10,12,0.96); color:#fff; border-radius:10px; padding:8px;
  box-shadow: 0 16px 40px rgba(2,6,12,0.45); z-index:900;
  transform: translateY(-6px) scaleY(0.98); opacity:0; pointer-events:none;
  transition: transform .22s ease, opacity .22s ease;
}
.menu-panel.show{ transform: translateY(0) scaleY(1); opacity:1; pointer-events:auto; }
.menu-item{ padding:8px 10px; margin-bottom:6px; border-radius:6px; cursor:pointer; font-size:0.95rem; }
.menu-item:hover{ background: rgba(255,255,255,0.04); color:var(--gold); }
.menu-panel.multi{
  column-count: 2;
  column-gap: 12px;
  width: 420px; /* gives breathing room */
}

.menu-panel.multi .menu-item{
  break-inside: avoid;
}
.module-status{
  margin-top:10px;
  padding:6px 12px;
  font-size:0.9rem;
  font-weight:600;
  text-align:center;

  color:#ffffff;
  background: linear-gradient(180deg, #d4af37, #b8962e); /* gold look */
  border-radius:10px;

  display:inline-block;
}
/* =======================================================
   MULTI-COLUMN DROPDOWNS (for long category lists)
   Safe: layout only, no logic impact
   ======================================================= */

/* activate column layout when .multi is present */
.menu-panel.multi{
  width: 460px;          /* wider panel for columns */
  column-count: 2;       /* default: 2 columns */
  column-gap: 24px;
}

/* prevent items splitting across columns */
.menu-panel.multi .menu-item{
  break-inside: avoid;
  -webkit-column-break-inside: avoid;
  page-break-inside: avoid;
}

/* three-column variant (All tonalities) */
.menu-panel.multi.three{
  column-count: 3;
  width: 680px; // 680
}

/* four-column variant (optional, future-proof) */
.menu-panel.multi.four{
  column-count: 4;
  width: 880px; // 880
}

/* Start of new edited portion by GPT /*
/* main area */
#quiz-area{
  display:flex;
  gap:18px;
  padding:18px;
  align-items:flex-start;
  position:relative;
}

.quiz-container{
  display:flex;
  width:100%;
  gap:18px;
}

.left-stack{
  display:flex;
  flex-direction:column;
  align-items:center;
  gap:36px; /* spacing between card, prompt, counter, button */
}

/* Prompt text */
#left-caption{
  font-size:0.95rem;
  color:var(--muted);
  margin-top:8px;
  width:100%;
  max-width:170px;
  text-align:center;
  line-height:1.3;
}

/* LEFT FLASH CARD (container) */
.left-card{
  width:104px;
  height:152px;
  display:flex;
  align-items:center;
  justify-content:center;
}

/* LEFT IMAGE (clean + stable) */
#left-card img{
  width:100%;
  height:100%;
  object-fit:contain;
  opacity:0;
  transition: opacity 0.2s ease;
}

/* Show image only when it has a real source */
#left-card img[src]:not([src=""]){
  opacity:1;
}

/* RIGHT PANEL */
.quiz-right{
  flex:1;
  min-height:300px;
  padding-top:22px;
}

/* RIGHT PANEL CARDS ONLY */
.quiz-right .signature-card{
  width:85px;
  height:123px; // 123
}
/* End of edited portion by GPT */

#left-card img{
  width:100% !important;
  height:100% !important;
}

/* answer area */
.answer-area {
  width: 90%; /* 100% */
  min-height: 200px;
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  justify-content: center;
  align-content: flex-start; 
  padding-top: 8px; // 10px 
}

.hint {
  color: var(--muted);
  width: 100%;
  text-align: center;
}

/* New horizontal wrapping layout */
.signature-grid {
  width: 100%;
  display: flex;
  flex-wrap: wrap;
  gap: 20px; /* 10px */
  justify-content: center;
}

.signature-row {
  display: contents;
}

/* Larger answer cards (right panel) */
.signature-card{
  width:85px;        /* card width was 85, 122 */
  height:123px;       /* card height was 176(your requested size) */
  border-radius:12px; /* rounded corners */
  overflow:hidden;
  background:#fff;
  display:flex;
  align-items:center;
  justify-content:center;
  cursor:pointer;
  border:1px solid rgba(20,30,40,0.06);
  box-shadow: 0 6px 14px rgba(0,0,0,0.12);
}
.signature-card img{
  width:100%;
  height:100%;
  object-fit:cover; /* preserves aspect, fills card nicely */
  display:block;
}

/* tone list */
.tone-list{
  display:flex;
  flex-direction:column;
  gap:1px;                 /* 4 tighter vertical spacing */
  width:25%;				/* was 100%.  This reduces the width of the list of tonalities'names */
  max-width:520px;
  align-items:center;
}



/* Hover — subtle lift */
.tone-item:hover {
  transform: translateY(-2px);
  box-shadow: 0 3px 6px rgba(0,0,0,0.22);
  border-color: rgba(0,0,0,0.25);
}

/* Press — tactile dip */
.tone-item:active {
  transform: translateY(0);
  box-shadow: 0 1px 2px rgba(0,0,0,0.30);
}

/* ========== TONE TILE — REFINED ========== */

/* Base */
.tone-item {
  width: 75%;
  padding: 5px 8px;
  background: #ffffff;
  color: #17202a;
  border-radius: 6px;
  border: 1px solid rgba(0,0,0,0.15);
  cursor: pointer;
  text-align: center;
  font-size: .8rem; // 0.8 This is the optimal font size for the tiles.
  line-height: 1.0;
  .tone-item {
  position: relative;
  z-index: 2;
}

  transition:
    background .12s ease,
    transform .10s ease,
    box-shadow .10s ease,
    border-color .10s ease;
	opacity .2s ease;
}

/* Hover — subtle lift */
.tone-item:hover {
  transform: translateY(-2px);
  box-shadow: 0 3px 6px rgba(0,0,0,0.22);
  border-color: rgba(0,0,0,0.25);
}

/* Press — tactile dip */
.tone-item:active {
  transform: translateY(0);
  box-shadow: 0 1px 2px rgba(0,0,0,0.30);
}

/* Keyboard focus */
.tone-item:focus {
  outline: none;
}
/* End of swap 27 Feb 2026 11_26 */
/* Start insert 27 Feb 2026 11:31 */
/* Selected (before answer validation) */
.tone-item.selected {
  border-color: rgba(0,0,0,0.15);
  box-shadow: none;
}
/* === Fade others === */
.tone-item.dimmed {
  background: #f4f4f4;   /* light grey instead of transparency */
  color: rgba(0,0,0,0.5);
  border-color: rgba(0,0,0,0.1);
}


/* === Pulse animation === */
@keyframes tilePulse {
  0%   { transform: scale(1); }
  50%  { transform: scale(1.03); }
  100% { transform: scale(1); }
}

.tone-item.pulse {
  animation: tilePulse 0.15s ease;
}
.tone-item.correct,
.tone-item.incorrect {
  background: inherit;
  border-color: inherit;
}

/* question counter small */
.question-counter{ margin-top:6px; font-size:0.9rem; color:var(--muted); }

/* feedback */
.feedback {
  display: none;
  position: fixed;
  bottom: 250px;
  right: 160px;

  background: transparent;   /* no box */
  padding: 0;
  border: none;
  box-shadow: none;

  font-size: 1.8rem;
  font-weight: bold;

  pointer-events: none; /* does not interfere with UI */
  z-index: 1000; /* ensure it floats above everything */
}

.feedback.show {
  display: block;
}

.feedback.correct {
  color: gold;
  text-shadow: 1px 1px 0 rgba(0,0,0,0.6);
}

.feedback.incorrect {
  color: #d00000;
  text-shadow: 1px 1px 0 rgba(0,0,0,0.6);
}

/* sponsor */
.sponsor {
  position: fixed;
  top: 18px;
  right: 34px;
}

.quiz-left{
  width:180px;
}
/* responsive */
@media (max-width:900px){
  .controls-row{ gap:8px; justify-content:center; }
  .mode-btn{ padding:8px 10px; font-size:0.95rem; }
  .quiz-left{ width:200px; }
  .signature-card{ width:74px; height:52px; }
}

.menu-panel {
  display: none;
  position: absolute;
}

/* === SIGQUIZ TOP BUTTON BASE STYLE === */
.gfx-btn {
  cursor: pointer;
  padding: 2px;               /* light, so that they can breathe */
  border-radius: 4px;         /* rounded modern */
  user-select: none;          /* prevents text selection */
  -webkit-user-drag: none;    /* prevents button's dragging */
  transition: 
    filter 120ms ease,
    box-shadow 120ms ease;    /* soft transition */
}
/* hover = éclairage */
.gfx-btn:hover {
  filter: brightness(1.20);
}
/* état actif (ex: bouton sélectionné) */
.gfx-btn.active {
  filter: brightness(1.35) drop-shadow(0 0 4px rgba(255,255,200,0.45));
}
/* option d'accent feutrine */
.gfx-btn:hover {
  background: rgba(255,255,255,0.10); /* subtile — papier translucide */
  border-radius: 6px;
}
.gfx-btn.active:hover {
  filter: brightness(1.35);
  background: none;
}

/* Choreography start */
.gfx-btn.disabled {
  opacity: 0.5;
  pointer-events: none;
}
.gfx-btn {
  transition: opacity 0.5s ease;
}
/* Choreography ends */

.menu-panel.show {
  display: block !important;
}

/* === Prompt visibility on green background === */

#left-caption,
#hint,
.hint,
.status-text,
.quiz-panel,
.menu-panel,
.menu-btn {
  color: #ffffff;
}

#reshuffle-btn {
  background-color: #d4af37; /* gold */
  color: #ffffff;
  border: 2px solid #b8962e;
  font-weight: bold;
}

#reshuffle-btn:hover {
  background-color: #e6c65a;
}


/* A — A darker outer world that is not too dark */
body {
  background-color: #228822; // Controls the edges of the sreen and the large area containing menu buttons.   
}
/* shades of green: #002000; #001a00; #001400 */
/* B — The ONLY framed surface */
.quiz-container {
  background-color: #008001;
  border: 0px solid gold;
  border-radius: 14px;

  box-shadow: 0 20px 50px rgba(0,0,0,0.65); /* was 0 20px 50px rgba(0,0,0,0.65); */
}

/* Stabilise question & answer stage */
#sigquiz-app {
  min-height:455px;   /* adjust to your 15-tile layout.  Controls inner pannel's height (question & answer stage).*/
}

/* Start of addition 3 March 2026 08:45 */
.signature-card.selected {
    outline: 2px solid #d4a83a;
    outline-offset: 2px;
}
/* End of addition 3 March 2026 */

.module-indicator{
  text-align:center;
  font-weight:600;
  color:#ffe08a;
  font-size:14px;
  line-height:1.4;
}

@keyframes tilePulse {
  0%   { transform: scale(1); }
  50%  { transform: scale(1.05); }
  100% { transform: scale(1); }
}

.tone-item.pulse {
  animation: tilePulse 0.25s ease;
  }
  

.feedback {
  z-index: 1;
}

.signature-card {
  cursor: pointer;
  transition: transform 0.1s ease, box-shadow 0.1s ease;
}

.signature-card:hover {
  transform: scale(1.05);
  box-shadow: 0 0 8px gold;
}

.signature-card.selected {
  box-shadow: 0 0 12px gold;
  border: 2px solid gold;
}
