/* =========================
   FONT FACES (PROJECT FONTS)
   ========================= */
@font-face {
  font-family: Inter;
  src: url("assets/fonts/Inter-Regular.ttf");
  font-weight: 400;
}
@font-face {
  font-family: Inter;
  src: url("assets/fonts/Inter-Medium.ttf");
  font-weight: 500;
}
@font-face {
  font-family: Inter;
  src: url("assets/fonts/Inter-Bold.ttf");
  font-weight: 700;
}
@font-face {
  font-family: Montserrat;
  src: url("assets/fonts/Montserrat-Bold.ttf");
  font-weight: 700;
}

/* =========================
   DESIGN TOKENS
   ========================= */
:root {
  /* Colors */
  --color-bg-app: #f7f7f9;
  --color-bg-card: #ffffff;
  --color-text-primary: #111;
  --color-text-secondary: #666;
  --color-text-muted: #444;
  --color-border-light: #e6e6e6;
  --color-divider: #eee;

  --color-brand-primary: #6b3cff;
  --color-cta-primary: #4285f4;
  --color-rating-star: #f4b400;

  /* Typography */
  --font-primary: Inter, system-ui, -apple-system, BlinkMacSystemFont,
                  "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  --font-accent: Montserrat, Inter, system-ui, sans-serif;

  --font-size-h1: 22px;
  --font-size-body: 15px;
  --font-size-input: 15px;
  --font-size-button: 16px;

  /* Spacing */
  --space-xs: 4px;
  --space-sm: 12px;
  --space-md: 20px;
  --space-lg: 28px;
  --space-xl: 32px;

  /* Radius */
  --radius-sm: 8px;
  --radius-md: 14px;
  --radius-lg: 16px;

  /* Shadows */
  --shadow-card: 0 12px 30px rgba(0,0,0,0.08);

  /* Heights */
  --height-control: 52px;
}

/* =========================
   RESET / BASE
   ========================= */
* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100vh;
  font-family: var(--font-primary);
  background: var(--color-bg-app);
  color: var(--color-text-primary);
}

/* =========================
   SCREEN LAYOUT
   ========================= */
.screen {
  min-height: 100dvh;
  background: #f7f7f9;
  display: flex;
  justify-content: center;
}

@media (max-width: 360px) {
  .screen {
    padding: 12px;
  }
}

/* =========================
   CARD
   ========================= */
.card {
  width: 100%;
  max-width: 420px;
  min-height: 100dvh;
  background: #ffffff;
  padding: 32px 24px;
  display: flex;
  flex-direction: column;
  padding-top: calc(32px + env(safe-area-inset-top));
}

@media (min-width: 768px) {
  .card {
    height: auto;
  }
}
/* =========================
   CARD CONTENT
   ========================= */
.card-content {
  display: flex;
  flex-direction: column;
  text-align: center;
  overflow-y: auto;
  max-height: calc(100vh - 120px);
  scroll-behavior: smooth;
  
}

/* Push CTA to bottom */
.card-cta {
  margin-top: auto;
  display: flex;
  flex-direction: column;
  gap: var(--space-sm);
  padding-top: var(--space-md);
}

/* =========================
   BRAND
   ========================= */
.brand {
  display: flex;
  justify-content: center;
  margin-bottom: var(--space-xs);
}

.brand img {
  height: 20px;
  width: auto;
  opacity: 0.9;
}

.brand-subtitle {
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 1.2px;
  text-transform: uppercase;
  color: var(--color-text-secondary);
  opacity: 0.75;
  margin-top: 6px;
  margin-bottom: 18px;
}

/* =========================
   VISUAL SEPARATION: PLATFORM vs STORE
========================= */

/* PLATFORM ZONE */
.platform-zone {
  text-align: center;
  padding-bottom: 18px;
  margin-bottom: 32px;
}

/* STORE ZONE */
.store-zone {
  
  border-radius: 14px;
  padding: 18px 16px;
  margin-bottom: 48px;
  
}

/* Stronger store identity */
.store-name {
  font-size: 26px;
  font-weight: 600;
  letter-spacing: -0.5px;
  margin: 0 0 12px 0;
}

.store-address {
  font-size: 14px;
  color: #8A8A8A;
  margin-bottom: 16px;
  line-height: 1.4;
  max-width: 90%;
  margin-left: auto;
  margin-right: auto;

  display: -webkit-box;
  -webkit-box-orient: vertical;
  overflow: hidden;

  line-clamp: 2;
  -webkit-line-clamp: 2;
}
.rating-text {
  font-size: 15px;
  color: #4A4A4A;
  margin-top: 4px;
  padding-top: 10px;
  line-height: 1.5;
  border-top: 1px solid rgba(0,0,0,0.05); /* subtle separator */
  align-items: baseline;

}

.rating-text strong {
  font-weight: 600;
  color: var(--color-text-primary);
}


@keyframes screenEnter {
  from {
    opacity: 0;
    transform: translateY(12px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.card {
  animation: screenEnter 0.35s ease-out;
}

.platform-zone {
  animation: screenEnter 0.35s ease-out;
}

.store-zone {
  animation: screenEnter 0.45s ease-out;
}

.experience-block {
  animation: screenEnter 0.55s ease-out;
}
/* =========================
   UNIVERSAL EXPERIENCE BLOCK
========================= */

.experience-block {
  margin-top: auto;
  text-align: center;
}

.experience-title {
  font-size: 20px;
  font-weight: 600;
  margin-bottom: 28px;
  letter-spacing: -0.3px;
  color: var(--color-text-primary);
}

/* Layout */
.emotion-row {
  display: flex;
  justify-content: center;
  gap: 28px;
  padding: 0;
}

/* Base Button */
.emotion-btn {
  width: 92px;               /* fixed instead of flex */
  height: 92px;
  border-radius: 50%;
  background: #ffffff;
  border: 2px solid #e5e7eb; /* softer but clearer */
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;

  box-shadow: 0 4px 14px rgba(0,0,0,0.05);

  transition:
    transform 0.12s ease,
    box-shadow 0.18s ease,
    border-color 0.18s ease,
    background 0.18s ease;
}

/* Bigger icon for recognition */
.emotion-icon {
  width: 44px;
  height: 44px;
  stroke-width: 1.8;
  transition: transform 0.12s ease, color 0.18s ease;
}

/* Position-based semantic colors */
.emotion-btn.negative .emotion-icon {
  color: #D64545;
}

.emotion-btn.neutral .emotion-icon {
  color: #6B7280;
}

.emotion-btn.positive .emotion-icon {
  color: #2E7D32 ;
}

/* Touch Feedback (critical for mobile) */
.emotion-btn:active {
  transform: scale(0.95);
  box-shadow: 0 2px 8px rgba(0,0,0,0.12);
}

/* Selected States (Very Clear) */

.emotion-btn.negative.selected {
  background: rgba(214,69,69,0.08);
  border-color: #D64545;
  box-shadow: 0 4px 16px rgba(214,69,69,0.20);
}

.emotion-btn.neutral.selected {
  background: rgba(107,114,128,0.08);
  border-color: #6B7280;
  box-shadow: 0 4px 16px rgba(107,114,128,0.20);
}

.emotion-btn.positive.selected {
  background: rgba(46,125,50,0.10);
  border-color: #2E7D32;
  box-shadow: 0 4px 16px rgba(46,125,50,0.25);
}

/* Selected icon emphasis */
.emotion-btn.selected .emotion-icon {
  transform: scale(1.1);
}

.emotion-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;   /* was 10px */
}

.emotion-label {
  font-size: 16px;     /* 🔥 from 15px */
  font-weight: 600;
  letter-spacing: -0.2px;
}

.emotion-btn.negative + .emotion-label {
  color: #D64545;
}

.emotion-btn.neutral + .emotion-label {
  color: #6B7280;
}

.emotion-btn.positive + .emotion-label {
  color: #2E7D32;
}
/* =========================
   TYPOGRAPHY
   ========================= */
h1 {
  font-family: var(--font-accent);
  font-size: var(--font-size-h1);
  margin: 0 0 10px 0;   /* 🔑 real spacing */
  padding: 0;
}

.note {
  font-size: var(--font-size-body);
  color: var(--color-text-muted);
}

.rating {
  display: flex;
  align-items: center;        /* vertical alignment */
  justify-content: center;
  gap: 6px;
  margin-top: 14px;
  font-size: var(--font-size-body);
  white-space: nowrap;
  min-height: 20px;       /* 🔑 prevents jump */
  line-height: 1;
}

.star {
  color: var(--color-rating-star);
}

.divider {
  height: 1px;
  background: rgba(0,0,0,0.06);
  margin: 16px 0;
}

/* =========================
   BUTTONS
   ========================= */
.primary {
  height: var(--height-control);
  border-radius: var(--radius-md);
  border: none;
  background: var(--color-cta-primary);
  color: #ffffff;
  font-size: var(--font-size-button);
  font-weight: 600;
  font-family: var(--font-primary);
  cursor: pointer;
}

.secondary {
  background: none;
  border: none;
  font-size: var(--font-size-body);
  color: var(--color-text-secondary);
  font-family: var(--font-primary);
  cursor: pointer;
}

/* =========================
   FLOW SCREENS
   ========================= */
.flow {
  display: none;
  height: 100%;
}

.flow.active {
  display: block;
}

/* =========================
   FORMS / INPUTS
   ========================= */
.form {
  margin-top: var(--space-lg);
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.input {
  height: var(--height-control);
  padding: 0 16px;
  font-size: var(--font-size-input);
  font-family: var(--font-primary);
  color: var(--color-text-primary);

  background: #fafafa;
  border-radius: var(--radius-md);
  border: 1px solid var(--color-border-light);

  transition: border-color 0.2s ease,
              box-shadow 0.2s ease,
              background 0.2s ease;
}

.input::placeholder {
  color: #888;
}

.input:focus {
  outline: none;
  background: #ffffff;
  border-color: var(--color-cta-primary);
  box-shadow: 0 0 0 3px rgba(66,133,244,0.15);
}

input:-webkit-autofill {
  -webkit-box-shadow: 0 0 0 1000px #ffffff inset;
}

/* ------------------------------
   LOADING SKELETON
--------------------------------*/

.skeleton {
  position: relative;
  overflow: hidden;
  background-color: #e5e7eb;
  border-radius: 6px;
}

.skeleton::after {
  content: "";
  position: absolute;
  inset: 0;
  transform: translateX(-100%);
  background: linear-gradient(
    90deg,
    transparent,
    rgba(255, 255, 255, 0.6),
    transparent
  );
  animation: skeleton-shimmer 1.2s infinite;
}

@keyframes skeleton-shimmer {
  100% {
    transform: translateX(100%);
  }
}

.skeleton-text {
  height: 22px;
  width: 80%;
  margin: 12px auto;
}

.skeleton-line {
  height: 16px;
  width: 60%;
  margin: 8px auto;
}

.skeleton-btn {
  height: 48px;
  width: 100%;
  margin-top: 16px;
  border-radius: 8px;
}

/* =========================
   FINAL FIX: RATING ROW
   ========================= */



.rating .star {
  font-size: 14px;
  line-height: 1;
  color: var(--color-rating-star);
}

.rating .score {
  min-width: 24px;
  text-align: center;
  line-height: 1;
}

.rating .count {
  line-height: 1;
  color: var(--color-text-secondary);
}

/* Skeleton override ONLY inside rating */
.rating .skeleton-text {
  height: 14px;
  width: 24px;
  margin: 0;
  display: inline-block;
  vertical-align: middle;
  border-radius: 4px;
  align-items: baseline;
}
/* Skeleton text wrapper (inline-safe) */
.text-placeholder {
  display: inline-block;
  min-width: 24px;
  min-height: 14px;
  align-items: baseline;
}

/* When real data loads */
.text-placeholder:not(.skeleton) {
  min-width: 0;
  min-height: 0;
}




/* Screen 2a css */

.review-cta-block {
  margin-top: 30px;
  text-align: center;
}

.review-title {
  font-size: 20px;
  font-weight: 600;
  margin-bottom: 14px;
}

.review-subtext {
  font-size: 15px;
  color: #555;
  line-height: 1.6;
  max-width: 90%;
  margin: 0 auto;
}

/* =====================================
   EXPERIENCE INDICATOR (SMILEY)
   ===================================== */

.experience-indicator {
  display: flex;
  justify-content: center;
  margin: 24px 0 12px 0;
}

.smiley-icon {
  width: 38px;
  height: 38px;
  color: #08875B; /* Replace with your brand green if needed */
  opacity: 0.9;
}


/* =========================
   FEEDBACK CATEGORY PILLS
   ========================= */

.feedback-categories {
  display: flex;
  gap: 12px;
  margin: 20px 0;
}

.feedback-pill {
  flex: 1;
  padding: 14px 0;
  border-radius: 14px;
  border: 1px solid #e5e7eb;
  background: #fff;
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  min-height: 48px;
  transition: all 0.2s ease;
}

.feedback-pill:active {
  transform: scale(0.97);
}

.feedback-pill.selected {
  background: #111827;
  color: #fff;
  border-color: #111827;
}

/* =========================
   TEXT AREA
   ========================= */

.feedback-text {
  width: 100%;
  min-height: 100px;
  padding: 14px;
  border-radius: 14px;
  border: 1px solid #e5e7eb;
  resize: none;
  font-size: 14px;
  margin-bottom: 16px;
}

.feedback-text:focus {
  outline: none;
  border-color: #111827;
}

/* =========================
   MOBILE INPUT
   ========================= */

.mobile-wrapper {
  margin-bottom: 10px;
}

.mobile-input {
  width: 100%;
  padding: 14px;
  border-radius: 14px;
  border: 1px solid #e5e7eb;
  font-size: 14px;
}

.mobile-input:focus {
  outline: none;
  border-color: #111827;
}

.helper-text {
  font-size: 11px;
  color: #6b7280;
  margin-top: 6px;
}

/* Disable primary until selected */
#feedback-submit:disabled {
  opacity: 0.4;
  cursor: not-allowed;
}

.feedback-text-wrapper {
  display: none;
}