:root {
  --bg-primary: #09131e;
  --bg-card: rgba(22, 36, 54, 0.75);
  --bg-card-hover: rgba(30, 48, 71, 0.85);
  --accent-cyan: #38bdf8;
  --accent-blue: #0284c7;
  --text-main: #f8fafc;
  --text-muted: #94a3b8;
  --border-color: rgba(255, 255, 255, 0.08);
  
  --shadow-glow: 0 8px 32px 0 rgba(0, 0, 0, 0.37);
  --radius-lg: 24px;
  --radius-md: 16px;
  --radius-sm: 12px;

  /* Colores de Bebidas */
  --softdrinks-color: #38bdf8;
  --softdrinks-bg: rgba(56, 189, 248, 0.12);
  --beer-color: #f59e0b;
  --beer-bg: rgba(245, 158, 11, 0.12);
  --water-color: #06b6d4;
  --water-bg: rgba(6, 182, 212, 0.12);
  --coffee-color: #a855f7;
  --coffee-bg: rgba(168, 85, 247, 0.12);
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  font-family: 'Outfit', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  -webkit-tap-highlight-color: transparent;
  user-select: none;
}

body {
  background: var(--bg-primary);
  background-image: 
    radial-gradient(at 0% 0%, rgba(2, 132, 199, 0.25) 0px, transparent 50%),
    radial-gradient(at 100% 100%, rgba(14, 165, 233, 0.15) 0px, transparent 50%),
    radial-gradient(at 50% 50%, rgba(15, 23, 42, 0.8) 0px, transparent 100%);
  background-attachment: fixed;
  color: var(--text-main);
  min-height: 100vh;
  display: flex;
  justify-content: center;
  align-items: flex-start;
  padding: 16px;
}

.app-container {
  width: 100%;
  max-width: 480px;
  display: flex;
  flex-direction: column;
  gap: 20px;
  padding-bottom: 30px;
}

/* Header */
.header {
  display: flex;
  flex-direction: column;
  gap: 16px;
  margin-top: 10px;
}

.header-content {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.header-title-box {
  display: flex;
  align-items: center;
  gap: 14px;
}

.header-logo {
  width: 52px;
  height: 52px;
  border-radius: 16px;
  box-shadow: 0 4px 20px rgba(56, 189, 248, 0.3);
  border: 2px solid rgba(255, 255, 255, 0.15);
  object-fit: cover;
}

h1 {
  font-size: 1.5rem;
  font-weight: 800;
  letter-spacing: -0.02em;
  background: linear-gradient(135deg, #ffffff 0%, #cbd5e1 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.subtitle {
  font-size: 0.85rem;
  color: var(--text-muted);
  font-weight: 500;
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 8px;
}

.install-btn {
  background: linear-gradient(135deg, #0284c7, #0369a1);
  color: #ffffff;
  border: 1px solid rgba(255, 255, 255, 0.2);
  padding: 8px 14px;
  border-radius: 12px;
  font-weight: 700;
  font-size: 0.85rem;
  cursor: pointer;
  box-shadow: 0 4px 14px rgba(2, 132, 199, 0.4);
  transition: transform 0.15s ease;
}

.install-btn.hidden {
  display: none;
}

.install-btn:active {
  transform: scale(0.95);
}

.reset-btn {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--border-color);
  color: var(--text-muted);
  width: 44px;
  height: 44px;
  border-radius: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.2s ease;
}

.reset-btn:active {
  transform: scale(0.92);
  background: rgba(255, 255, 255, 0.12);
  color: var(--text-main);
}

/* Total Card */
.total-summary-card {
  background: linear-gradient(135deg, rgba(2, 132, 199, 0.3) 0%, rgba(14, 165, 233, 0.1) 100%);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1px solid rgba(56, 189, 248, 0.25);
  border-radius: var(--radius-md);
  padding: 16px 20px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.2);
}

.total-label {
  font-size: 0.95rem;
  font-weight: 600;
  color: #e0f2fe;
  letter-spacing: 0.01em;
}

.total-value {
  font-size: 1.8rem;
  font-weight: 800;
  color: #38bdf8;
  text-shadow: 0 0 12px rgba(56, 189, 248, 0.4);
}

/* Grid de Bebidas */
.drinks-grid {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.drink-card {
  background: var(--bg-card);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  padding: 18px 20px;
  display: flex;
  flex-direction: column;
  gap: 14px;
  box-shadow: var(--shadow-glow);
  transition: transform 0.2s ease, border-color 0.2s ease;
  position: relative;
  overflow: hidden;
}

.drink-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 6px;
  height: 100%;
  background: var(--card-theme-color);
  border-radius: 4px 0 0 4px;
}

.drink-header {
  display: flex;
  align-items: center;
  gap: 12px;
}

.drink-icon-box {
  width: 48px;
  height: 48px;
  border-radius: 14px;
  background: var(--card-theme-bg);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.6rem;
  border: 1px solid rgba(255, 255, 255, 0.05);
}

.drink-info {
  flex: 1;
}

.drink-name {
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--text-main);
}

.drink-subtitle {
  font-size: 0.78rem;
  color: var(--text-muted);
  font-weight: 500;
}

/* Controls */
.drink-controls {
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: rgba(0, 0, 0, 0.25);
  border: 1px solid rgba(255, 255, 255, 0.05);
  border-radius: var(--radius-md);
  padding: 6px 8px;
}

.action-btn {
  width: 52px;
  height: 52px;
  border-radius: 14px;
  border: none;
  font-size: 1.5rem;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.15s ease;
  outline: none;
}

.btn-minus {
  background: rgba(239, 68, 68, 0.15);
  color: #f87171;
  border: 1px solid rgba(239, 68, 68, 0.3);
}

.btn-minus:active {
  transform: scale(0.9);
  background: rgba(239, 68, 68, 0.35);
}

.btn-minus:disabled {
  opacity: 0.3;
  cursor: not-allowed;
  transform: none !important;
}

.btn-plus {
  background: rgba(34, 197, 94, 0.15);
  color: #4ade80;
  border: 1px solid rgba(34, 197, 94, 0.3);
}

.btn-plus:active {
  transform: scale(0.9);
  background: rgba(34, 197, 94, 0.35);
}

.drink-count-display {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-width: 80px;
}

.count-number {
  font-size: 2.2rem;
  font-weight: 800;
  line-height: 1;
  color: var(--text-main);
  transition: transform 0.15s ease;
}

.count-label {
  font-size: 0.7rem;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-top: 4px;
  font-weight: 600;
}

.count-bump {
  animation: bump 0.2s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

@keyframes bump {
  0% { transform: scale(1); }
  50% { transform: scale(1.25); }
  100% { transform: scale(1); }
}

/* Modal */
.modal-backdrop {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.7);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 100;
  padding: 20px;
  opacity: 1;
  transition: opacity 0.2s ease;
}

.modal-backdrop.hidden {
  opacity: 0;
  pointer-events: none;
}

.modal-card {
  background: #0f172a;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  padding: 24px;
  width: 100%;
  max-width: 360px;
  box-shadow: var(--shadow-glow);
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.modal-card h3 {
  font-size: 1.2rem;
  color: var(--text-main);
}

.modal-card p {
  font-size: 0.9rem;
  color: var(--text-muted);
  line-height: 1.4;
}

.modal-defaults-list {
  background: rgba(255, 255, 255, 0.04);
  padding: 12px 16px;
  border-radius: var(--radius-sm);
  font-size: 0.88rem;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}

.modal-actions {
  display: flex;
  gap: 10px;
  margin-top: 8px;
}

.btn {
  flex: 1;
  padding: 12px;
  border-radius: var(--radius-sm);
  border: none;
  font-weight: 700;
  font-size: 0.9rem;
  cursor: pointer;
  transition: all 0.15s ease;
}

.btn-secondary {
  background: rgba(255, 255, 255, 0.08);
  color: var(--text-main);
}

.btn-secondary:active {
  background: rgba(255, 255, 255, 0.15);
}

.btn-danger {
  background: #e11d48;
  color: white;
}

.btn-danger:active {
  background: #be123c;
}
