/* ─── CSS Variables ─── */
:root {
  --phi: 1.618;
  --bg: #0f0f14;
  --bg-card: #1a1a24;
  --bg-card-hover: #22222e;
  --bg-input: #12121a;
  --border: #2a2a3a;
  --border-focus: #6366f1;
  --text: #e2e2ea;
  --text-muted: #8888a0;
  --text-dim: #55556a;
  --accent: #6366f1;
  --accent-glow: rgba(99, 102, 241, 0.15);
  --accent-soft: #818cf8;
  --success: #22c55e;
  --warning: #f59e0b;
  --danger: #ef4444;
  --radius: 8px;
  --radius-lg: 12px;
  --sidebar-width: 320px;
  --navbar-h: 52px;
  --transition: 0.2s ease;
  --font-sans: 'Inter', system-ui, -apple-system, sans-serif;
  --font-mono: 'JetBrains Mono', monospace;
  --font-display: 'Playfair Display', Georgia, serif;
}

/* ─── Reset ─── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { font-size: 14px; }
body {
  font-family: var(--font-sans);
  background: var(--bg);
  color: var(--text);
  overflow: hidden;
  height: 100vh;
}

/* ─── Scrollbar ─── */
::-webkit-scrollbar { width: 6px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: var(--border); border-radius: 3px; }
::-webkit-scrollbar-thumb:hover { background: var(--text-dim); }

/* ─── NAVBAR ─── */
#navbar {
  height: var(--navbar-h);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 16px;
  background: var(--bg-card);
  border-bottom: 1px solid var(--border);
  position: relative;
  z-index: 100;
  gap: 16px;
}
.nav-left, .nav-right { display: flex; align-items: center; gap: 8px; }
.logo {
  display: flex;
  align-items: center;
  gap: 8px;
  font-weight: 700;
  font-size: 1.1rem;
  color: var(--accent-soft);
  letter-spacing: -0.3px;
}
.logo svg { stroke: var(--accent-soft); }

.nav-center {
  display: flex;
  gap: 4px;
  background: var(--bg);
  border-radius: var(--radius);
  padding: 3px;
}
.nav-tab {
  background: none;
  border: none;
  color: var(--text-muted);
  font-family: var(--font-sans);
  font-size: 0.85rem;
  font-weight: 500;
  padding: 6px 14px;
  border-radius: 6px;
  cursor: pointer;
  transition: var(--transition);
  white-space: nowrap;
}
.nav-tab:hover { color: var(--text); background: var(--bg-card); }
.nav-tab.active { color: #fff; background: var(--accent); }

#zen-toggle {
  display: flex;
  align-items: center;
  gap: 6px;
  background: none;
  border: 1px solid var(--border);
  color: var(--text-muted);
  font-family: var(--font-sans);
  font-size: 0.85rem;
  padding: 6px 14px;
  border-radius: var(--radius);
  cursor: pointer;
  transition: var(--transition);
}
#zen-toggle:hover { color: var(--text); border-color: var(--text-dim); }

/* ─── APP LAYOUT ─── */
.app-layout {
  display: grid;
  grid-template-columns: var(--sidebar-width) 1fr;
  grid-template-rows: 1fr auto;
  height: calc(100vh - var(--navbar-h));
}
.app-layout .sidebar { grid-row: 1; }
.app-layout #canvas-area { grid-row: 1; }
.app-layout .footer { grid-row: 2; }

/* ─── SIDEBAR ─── */
.sidebar {
  width: var(--sidebar-width);
  min-width: var(--sidebar-width);
  background: var(--bg-card);
  border-right: 1px solid var(--border);
  overflow-y: auto;
  transition: transform 0.3s ease, opacity 0.3s ease;
}
.sidebar.hidden {
  transform: translateX(-100%);
  opacity: 0;
  width: 0;
  min-width: 0;
  overflow: hidden;
  border: none;
  pointer-events: none;
}

/* ─── PANELS ─── */
.panel { display: none; padding: 16px; }
.panel.active { display: block; }

.panel-title {
  font-size: 1rem;
  font-weight: 700;
  margin-bottom: 16px;
  color: var(--accent-soft);
  letter-spacing: -0.3px;
}

.panel-section {
  margin-bottom: 20px;
  padding-bottom: 16px;
  border-bottom: 1px solid var(--border);
}
.panel-section:last-child { border-bottom: none; }
.panel-section h4 {
  font-size: 0.8rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  color: var(--text-muted);
  margin-bottom: 10px;
}

/* ─── Section Header with Tooltip ─── */
.section-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 10px;
}
.section-header h4 {
  margin-bottom: 0;
}
.tip {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: var(--bg);
  border: 1px solid var(--border);
  color: var(--text-dim);
  font-size: 0.65rem;
  cursor: help;
  position: relative;
  flex-shrink: 0;
  transition: var(--transition);
}
.tip:hover {
  border-color: var(--accent);
  color: var(--accent-soft);
}
.tip::after {
  content: attr(data-tip);
  position: absolute;
  bottom: calc(100% + 8px);
  left: 50%;
  transform: translateX(-50%);
  width: 240px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 10px 12px;
  font-size: 0.78rem;
  font-weight: 400;
  line-height: 1.5;
  color: var(--text);
  text-transform: none;
  letter-spacing: 0;
  box-shadow: 0 8px 24px rgba(0,0,0,0.3);
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.2s ease, visibility 0.2s ease;
  z-index: 500;
  pointer-events: none;
}
.tip:hover::after {
  opacity: 1;
  visibility: visible;
}
/* Flip tooltip if near top */
.tip.flip::after {
  bottom: auto;
  top: calc(100% + 8px);
}

/* ─── Recommendation Box ─── */
.reco-box {
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 10px;
  margin-top: 6px;
}
.reco-placeholder {
  font-size: 0.82rem;
  color: var(--text-dim);
  text-align: center;
  padding: 8px 0;
}
.reco-item {
  display: flex;
  gap: 10px;
  padding: 8px 0;
  border-bottom: 1px solid var(--border);
  align-items: flex-start;
}
.reco-item:last-child { border-bottom: none; }
.reco-icon {
  font-size: 1rem;
  flex-shrink: 0;
  line-height: 1.4;
}
.reco-text {
  font-size: 0.8rem;
  line-height: 1.5;
  color: var(--text-muted);
}
.reco-text strong {
  color: var(--text);
}
.reco-text .reco-highlight {
  color: var(--accent-soft);
  font-weight: 600;
}
.reco-tag {
  display: inline-block;
  font-size: 0.65rem;
  font-weight: 600;
  padding: 1px 6px;
  border-radius: 3px;
  text-transform: uppercase;
  letter-spacing: 0.3px;
  margin-left: 4px;
  vertical-align: middle;
}
.reco-tag.good { background: rgba(34,197,94,0.15); color: var(--success); }
.reco-tag.warn { background: rgba(245,158,11,0.15); color: var(--warning); }
.reco-tag.bad { background: rgba(239,68,68,0.15); color: var(--danger); }

/* Calc rows with tooltips */
.calc-row[data-tip] {
  position: relative;
  cursor: help;
}
.calc-row[data-tip]::after {
  content: attr(data-tip);
  position: absolute;
  right: 0;
  bottom: calc(100% + 4px);
  width: 200px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 8px 10px;
  font-size: 0.72rem;
  font-weight: 400;
  line-height: 1.4;
  color: var(--text);
  box-shadow: 0 4px 16px rgba(0,0,0,0.3);
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.2s ease, visibility 0.2s ease;
  z-index: 500;
  pointer-events: none;
}
.calc-row[data-tip]:hover::after {
  opacity: 1;
  visibility: visible;
}

/* ─── Inputs ─── */
.input-group {
  display: flex;
  flex-direction: column;
  gap: 4px;
  margin-bottom: 10px;
}
.input-group label {
  font-size: 0.78rem;
  color: var(--text-muted);
  font-weight: 500;
}
input[type="number"],
input[type="text"],
select {
  background: var(--bg-input);
  border: 1px solid var(--border);
  color: var(--text);
  font-family: var(--font-sans);
  font-size: 0.9rem;
  padding: 8px 10px;
  border-radius: var(--radius);
  outline: none;
  transition: var(--transition);
  width: 100%;
}
input:focus, select:focus {
  border-color: var(--border-focus);
  box-shadow: 0 0 0 3px var(--accent-glow);
}
input[type="color"] {
  -webkit-appearance: none;
  border: none;
  width: 36px;
  height: 36px;
  border-radius: 6px;
  cursor: pointer;
  background: none;
  padding: 0;
}
input[type="color"]::-webkit-color-swatch-wrapper { padding: 2px; }
input[type="color"]::-webkit-color-swatch { border-radius: 4px; border: 1px solid var(--border); }

/* ─── Toggle Row ─── */
.toggle-row {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 0;
  cursor: pointer;
  font-size: 0.9rem;
  color: var(--text);
}
.toggle-row input[type="checkbox"] {
  appearance: none;
  width: 36px;
  height: 20px;
  background: var(--bg-input);
  border: 1px solid var(--border);
  border-radius: 10px;
  position: relative;
  cursor: pointer;
  transition: var(--transition);
  flex-shrink: 0;
}
.toggle-row input[type="checkbox"]::after {
  content: '';
  position: absolute;
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: var(--text-muted);
  top: 2px;
  left: 2px;
  transition: var(--transition);
}
.toggle-row input[type="checkbox"]:checked {
  background: var(--accent);
  border-color: var(--accent);
}
.toggle-row input[type="checkbox"]:checked::after {
  background: #fff;
  left: 18px;
}

/* ─── Buttons ─── */
.btn-row { display: flex; gap: 8px; }
.btn-sm {
  background: var(--bg);
  border: 1px solid var(--border);
  color: var(--text-muted);
  font-family: var(--font-sans);
  font-size: 0.8rem;
  font-weight: 500;
  padding: 6px 12px;
  border-radius: 6px;
  cursor: pointer;
  transition: var(--transition);
  flex: 1;
}
.btn-sm:hover { color: var(--text); border-color: var(--text-dim); }
.btn-sm:active { transform: scale(0.97); }

/* ─── CALC RESULTS ─── */
.calc-results {
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  margin-top: 8px;
}
.calc-row {
  display: flex;
  justify-content: space-between;
  padding: 8px 12px;
  font-size: 0.85rem;
  border-bottom: 1px solid var(--border);
}
.calc-row:last-child { border-bottom: none; }
.calc-row span:first-child { color: var(--text-muted); }
.calc-row span:last-child { font-family: var(--font-mono); font-weight: 500; color: var(--accent-soft); }
.calc-row.highlight { background: var(--accent-glow); }
.calc-row.highlight span { color: var(--accent-soft); }

/* ─── TYPE PREVIEW ─── */
.type-preview {
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 16px;
  margin-top: 8px;
}
.prev-headline {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.8rem;
  line-height: 1.2;
  margin-bottom: 8px;
  color: var(--text);
}
.prev-sub {
  font-weight: 600;
  font-size: 1.15rem;
  margin-bottom: 8px;
  color: var(--text-muted);
}
.prev-body {
  font-size: 0.95rem;
  color: var(--text-muted);
}

/* ─── CONTRAST ─── */
.color-input-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 12px;
}
.color-input-row label { font-size: 0.85rem; color: var(--text-muted); }
.color-pick { display: flex; align-items: center; gap: 8px; }
.color-pick input[type="text"] { width: 80px; font-family: var(--font-mono); font-size: 0.8rem; }

.contrast-box {
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 16px;
  text-align: center;
}
.ratio-display {
  font-size: 2.5rem;
  font-weight: 700;
  font-family: var(--font-mono);
  margin-bottom: 8px;
  color: var(--accent-soft);
}
.contrast-preview {
  padding: 14px;
  border-radius: 6px;
  font-size: 1rem;
  font-weight: 600;
  margin-bottom: 12px;
}
.wcag-badges {
  display: flex;
  gap: 8px;
  justify-content: center;
  flex-wrap: wrap;
}
.wcag-badge {
  font-size: 0.72rem;
  font-weight: 600;
  padding: 3px 10px;
  border-radius: 20px;
  text-transform: uppercase;
  letter-spacing: 0.3px;
}
.wcag-badge.pass { background: rgba(34,197,94,0.15); color: var(--success); }
.wcag-badge.fail { background: rgba(239,68,68,0.15); color: var(--danger); }

/* ─── LINTER ─── */
.font-tracker { display: flex; gap: 8px; margin-bottom: 8px; }
.font-tracker input { flex: 1; }
.font-list {
  display: flex;
  flex-direction: column;
  gap: 4px;
  margin-bottom: 8px;
}
.font-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: var(--bg);
  border: 1px solid var(--border);
  padding: 6px 10px;
  border-radius: 6px;
  font-size: 0.85rem;
}
.font-item .remove-font {
  background: none;
  border: none;
  color: var(--danger);
  cursor: pointer;
  font-size: 1rem;
  padding: 0 4px;
}

.lint-warning {
  background: rgba(245,158,11,0.1);
  border: 1px solid rgba(245,158,11,0.3);
  color: var(--warning);
  font-size: 0.82rem;
  padding: 10px 12px;
  border-radius: var(--radius);
  line-height: 1.5;
}
.lint-warning.hidden { display: none; }

.pairing-box {
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 12px;
  margin-top: 8px;
  font-size: 0.85rem;
  line-height: 1.6;
}
.pairing-box .pair-label { color: var(--text-muted); font-size: 0.75rem; }
.pairing-box .pair-font { color: var(--accent-soft); font-weight: 600; }

/* ─── COLORS ─── */
.mood-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 6px;
}
.mood-btn {
  background: var(--bg);
  border: 1px solid var(--border);
  color: var(--text);
  font-family: var(--font-sans);
  font-size: 0.8rem;
  padding: 10px 8px;
  border-radius: var(--radius);
  cursor: pointer;
  transition: var(--transition);
  text-align: left;
}
.mood-btn:hover { border-color: var(--accent); background: var(--accent-glow); }
.mood-btn.active { border-color: var(--accent); background: var(--accent-glow); color: var(--accent-soft); }

.palette-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}
.palette-swatch {
  width: 42px;
  height: 42px;
  border-radius: 8px;
  border: 2px solid transparent;
  cursor: pointer;
  transition: var(--transition);
  position: relative;
}
.palette-swatch:hover {
  border-color: #fff;
  transform: scale(1.1);
  z-index: 2;
}
.palette-swatch .swatch-label {
  display: none;
  position: absolute;
  bottom: -22px;
  left: 50%;
  transform: translateX(-50%);
  font-size: 0.65rem;
  font-family: var(--font-mono);
  color: var(--text-muted);
  white-space: nowrap;
  background: var(--bg-card);
  padding: 2px 5px;
  border-radius: 3px;
}
.palette-swatch:hover .swatch-label { display: block; }

.mood-description {
  margin-top: 12px;
  font-size: 0.82rem;
  color: var(--text-muted);
  line-height: 1.6;
  font-style: italic;
}

.color-tooltip-box {
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 12px;
  margin-top: 8px;
  font-size: 0.85rem;
  line-height: 1.6;
  min-height: 60px;
}
.color-tooltip-box .ct-name { font-weight: 700; color: var(--accent-soft); }
.color-tooltip-box .ct-meaning { color: var(--text-muted); }
.color-tooltip-box .ct-detail { font-family: var(--font-mono); font-size: 0.75rem; color: var(--text-dim); margin-top: 4px; }

/* ─── Analysis Boxes ─── */
.analysis-box {
  margin-top: 6px;
  margin-bottom: 8px;
}
.analysis-title {
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  color: var(--text-muted);
  margin-bottom: 6px;
}
.analysis-row {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 4px 0;
  font-size: 0.82rem;
}
.analysis-swatch {
  width: 18px;
  height: 18px;
  border-radius: 4px;
  flex-shrink: 0;
}
.analysis-label { color: var(--text-muted); min-width: 70px; }
.analysis-hex { font-family: var(--font-mono); color: var(--accent-soft); font-size: 0.78rem; }
.analysis-detail { font-family: var(--font-mono); font-size: 0.72rem; color: var(--text-dim); }
.analysis-insight {
  margin-top: 8px;
  font-size: 0.8rem;
  line-height: 1.5;
  color: var(--text-muted);
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 8px 10px;
}
.analysis-insight strong { color: var(--accent-soft); }

/* ─── Stats Box ─── */
.stats-box {
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 12px;
}
.stats-placeholder {
  font-size: 0.82rem;
  color: var(--text-dim);
  text-align: center;
  padding: 8px 0;
}
.stat-row {
  display: flex;
  justify-content: space-between;
  padding: 5px 0;
  font-size: 0.82rem;
  border-bottom: 1px solid var(--border);
}
.stat-row:last-child { border-bottom: none; }
.stat-label { color: var(--text-muted); }
.stat-val { font-family: var(--font-mono); color: var(--accent-soft); font-weight: 500; }

/* Hue distribution bar */
.hue-bar {
  display: flex;
  gap: 2px;
  height: 40px;
  align-items: flex-end;
  margin: 10px 0;
  padding: 0 2px;
}
.hue-segment {
  flex: 1;
  border-radius: 2px 2px 0 0;
  min-height: 2px;
  transition: height 0.3s ease;
}

/* ─── Palette Box ─── */
.palette-box {
  min-height: 40px;
}

/* ─── Contrast Suggestion ─── */
.contrast-suggestion {
  margin-top: 10px;
  font-size: 0.82rem;
  line-height: 1.5;
  color: var(--text-muted);
  text-align: left;
}
.contrast-suggestion strong { color: var(--text); }

/* ─── CANVAS AREA ─── */
#canvas-area {
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--bg);
  overflow: auto;
  position: relative;
  padding: 24px;
  min-height: 0;
  flex-direction: column;
  gap: 16px;
}
#canvas-wrapper { position: relative; display: inline-block; }
#canvas-image {
  display: none;
  position: absolute;
  top: 0; left: 0;
  width: 100%; height: 100%;
  object-fit: contain;
  pointer-events: none;
}

/* Dropzone */
.dropzone {
  border: 2px dashed var(--border);
  border-radius: var(--radius-lg);
  padding: 40px 32px;
  text-align: center;
  cursor: pointer;
  transition: var(--transition);
  background: var(--bg-card);
  max-width: 420px;
  width: 100%;
}
.dropzone.hidden { display: none; }
.dropzone:hover, .dropzone.dragover {
  border-color: var(--accent);
  background: var(--accent-glow);
}
.dropzone-icon { font-size: 2.5rem; margin-bottom: 8px; }
.dropzone-title { font-size: 0.95rem; font-weight: 600; color: var(--text); margin-bottom: 4px; }
.dropzone-sub { font-size: 0.78rem; color: var(--text-muted); }

/* Image info bar */
.img-info {
  margin-top: 8px;
  font-size: 0.78rem;
  color: var(--text-muted);
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 6px 10px;
  display: flex;
  align-items: center;
  gap: 6px;
}
.img-info.hidden { display: none; }
.img-info .img-name { color: var(--accent-soft); font-weight: 500; }
.img-info .img-dims { font-family: var(--font-mono); }
#main-canvas {
  background: #ffffff;
  border-radius: 4px;
  box-shadow: 0 4px 40px rgba(0,0,0,0.4);
  max-width: 100%;
  max-height: 100%;
}

/* ─── ZEN MODE ─── */
.zen-overlay {
  position: fixed;
  inset: 0;
  background: var(--bg);
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: center;
}
.zen-overlay.hidden { display: none; }
.zen-overlay canvas {
  background: #fff;
  border-radius: 4px;
  box-shadow: 0 4px 60px rgba(0,0,0,0.5);
}
.zen-exit-btn {
  position: fixed;
  top: 16px;
  right: 16px;
  z-index: 1001;
  background: rgba(255,255,255,0.1);
  border: 1px solid rgba(255,255,255,0.2);
  color: #fff;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  font-size: 1.1rem;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: var(--transition);
}
.zen-exit-btn:hover { background: rgba(255,255,255,0.2); }

/* ─── Responsive ─── */
@media (max-width: 768px) {
  :root { --sidebar-width: 260px; }
  .app-layout { grid-template-columns: var(--sidebar-width) 1fr; }
  .nav-center { display: none; }
  .nav-tab { font-size: 0.75rem; padding: 5px 10px; }
}

/* ─── Copyright Footer ─── */
.footer {
  text-align: center;
  padding: 14px 16px 10px;
  margin-top: 0;
  background: var(--bg-card);
  border-top: 1px solid var(--border);
  grid-column: 1 / -1;
}
.footer-inner {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 8px 22px;
  border-radius: 40px;
  background: var(--bg);
  border: 1px solid var(--border);
}
.footer-icon {
  font-size: 1rem;
  animation: footer-bob 3s ease-in-out infinite;
}
.footer-text {
  font-size: 0.75rem;
  color: var(--text-muted);
  letter-spacing: 0.03em;
}
@keyframes footer-bob {
  0%, 100% { transform: translateY(0) rotate(-5deg); }
  50%      { transform: translateY(-2px) rotate(5deg); }
}

/* ─── Trakteer Floating Button (compact) ─── */
.kopi-float {
  position: fixed;
  bottom: 20px;
  right: 20px;
  width: 40px;
  height: 40px;
  background: #be1e2d;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 9999;
  text-decoration: none;
  cursor: pointer;
  animation: kopi-float 3.5s ease-in-out infinite;
  transition: transform 0.25s cubic-bezier(0.34, 1.56, 0.64, 1);
}
.kopi-float:hover {
  transform: scale(1.12);
  animation: none;
}
.kopi-float:hover .kopi-ring {
  animation: none;
  opacity: 0;
}
.kopi-float img {
  width: 20px;
  height: 20px;
  object-fit: contain;
  display: block;
  pointer-events: none;
  animation: kopi-wobble 4s ease-in-out infinite;
  transform-origin: center bottom;
}
.kopi-float:hover img {
  animation: none;
  transform: rotate(0deg);
}
.kopi-ring {
  position: absolute;
  inset: 0;
  border-radius: 50%;
  border: 1.5px solid rgba(190, 30, 45, 0.5);
  animation: kopi-ripple 2.4s ease-out infinite;
  transition: opacity 0.3s ease;
}
.kopi-r2 { animation-delay: 1.2s; }

@keyframes kopi-ripple {
  0%   { transform: scale(1);   opacity: 0.7; }
  100% { transform: scale(2.0); opacity: 0; }
}
@keyframes kopi-float {
  0%, 100% { transform: translateY(0); }
  50%      { transform: translateY(-7px); }
}
@keyframes kopi-wobble {
  0%, 55%  { transform: rotate(0deg); }
  58%      { transform: rotate(-18deg); }
  61%      { transform: rotate(16deg); }
  64%      { transform: rotate(-12deg); }
  67%      { transform: rotate(10deg); }
  70%      { transform: rotate(-6deg); }
  73%      { transform: rotate(4deg); }
  76%, 100%{ transform: rotate(0deg); }
}

@media (max-width: 720px) {
  .kopi-float {
    bottom: 16px;
    right: 16px;
    width: 36px;
    height: 36px;
  }
  .kopi-float img { width: 18px; height: 18px; }
}
