@import url('https://fonts.googleapis.com/css2?family=Orbitron:wght@400;700;900&family=Share+Tech+Mono&display=swap');

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  font-family: 'Share Tech Mono', monospace;
  background: #0a0a0f;
  color: #0ff;
  min-height: 100vh;
  padding: 20px;
  position: relative;
  overflow-x: hidden;
}

/* Cyber grid background */
body::before {
  content: '';
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background:
    linear-gradient(90deg, rgba(0, 255, 255, 0.03) 1px, transparent 1px),
    linear-gradient(rgba(0, 255, 255, 0.03) 1px, transparent 1px);
  background-size: 50px 50px;
  pointer-events: none;
  z-index: -1;
}

/* Scanline effect */
body::after {
  content: '';
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: repeating-linear-gradient(
    0deg,
    rgba(0, 0, 0, 0.1),
    rgba(0, 0, 0, 0.1) 1px,
    transparent 1px,
    transparent 2px
  );
  pointer-events: none;
  z-index: 1000;
}

.container {
  max-width: 500px;
  margin: 0 auto;
  position: relative;
}

header {
  text-align: center;
  margin-bottom: 40px;
  padding: 20px;
  border: 1px solid #0ff;
  background: rgba(0, 255, 255, 0.05);
  clip-path: polygon(0 0, calc(100% - 15px) 0, 100% 15px, 100% 100%, 15px 100%, 0 calc(100% - 15px));
  box-shadow:
    0 0 20px rgba(0, 255, 255, 0.3),
    inset 0 0 20px rgba(0, 255, 255, 0.1);
}

h1 {
  font-family: 'Orbitron', sans-serif;
  font-size: 2rem;
  font-weight: 900;
  margin-bottom: 8px;
  text-transform: uppercase;
  letter-spacing: 4px;
  color: #0ff;
  text-shadow:
    0 0 10px #0ff,
    0 0 20px #0ff,
    0 0 40px #0ff;
  animation: flicker 3s infinite;
}

@keyframes flicker {
  0%, 100% { opacity: 1; }
  92% { opacity: 1; }
  93% { opacity: 0.8; }
  94% { opacity: 1; }
  95% { opacity: 0.9; }
  96% { opacity: 1; }
}

.date {
  color: #ff00ff;
  font-size: 0.85rem;
  letter-spacing: 2px;
  text-shadow: 0 0 10px #ff00ff;
}

.add-form {
  display: flex;
  gap: 10px;
  margin-bottom: 25px;
}

.add-form input {
  flex: 1;
  padding: 14px 18px;
  border: 1px solid #0ff;
  border-radius: 0;
  background: rgba(0, 255, 255, 0.1);
  color: #0ff;
  font-family: 'Share Tech Mono', monospace;
  font-size: 1rem;
  clip-path: polygon(10px 0, 100% 0, 100% calc(100% - 10px), calc(100% - 10px) 100%, 0 100%, 0 10px);
  transition: all 0.3s;
}

.add-form input::placeholder {
  color: rgba(0, 255, 255, 0.4);
}

.add-form input:focus {
  outline: none;
  background: rgba(0, 255, 255, 0.15);
  box-shadow:
    0 0 15px rgba(0, 255, 255, 0.5),
    inset 0 0 15px rgba(0, 255, 255, 0.1);
}

.add-form button {
  padding: 14px 28px;
  border: 1px solid #ff00ff;
  border-radius: 0;
  background: rgba(255, 0, 255, 0.2);
  color: #ff00ff;
  font-family: 'Orbitron', sans-serif;
  font-size: 0.9rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 2px;
  cursor: pointer;
  clip-path: polygon(10px 0, 100% 0, 100% calc(100% - 10px), calc(100% - 10px) 100%, 0 100%, 0 10px);
  transition: all 0.3s;
  text-shadow: 0 0 10px #ff00ff;
}

.add-form button:hover {
  background: rgba(255, 0, 255, 0.4);
  box-shadow:
    0 0 20px rgba(255, 0, 255, 0.6),
    inset 0 0 20px rgba(255, 0, 255, 0.2);
}

.habit-list {
  list-style: none;
}

.habit-item {
  display: flex;
  align-items: center;
  gap: 15px;
  padding: 18px;
  margin-bottom: 12px;
  background: rgba(255, 0, 80, 0.1);
  border: 1px solid #ff0050;
  clip-path: polygon(0 0, calc(100% - 12px) 0, 100% 12px, 100% 100%, 12px 100%, 0 calc(100% - 12px));
  transition: all 0.3s;
  position: relative;
}

.habit-item::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 4px;
  height: 100%;
  background: #ff0050;
  box-shadow: 0 0 15px #ff0050;
}

.habit-item.completed {
  background: rgba(0, 255, 136, 0.1);
  border-color: #00ff88;
}

.habit-item.completed::before {
  background: #00ff88;
  box-shadow: 0 0 15px #00ff88;
}

.habit-item .status {
  width: 44px;
  height: 44px;
  border-radius: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.3rem;
  font-weight: bold;
  cursor: pointer;
  transition: all 0.3s;
  background: rgba(255, 0, 80, 0.3);
  border: 2px solid #ff0050;
  color: #ff0050;
  clip-path: polygon(8px 0, 100% 0, 100% calc(100% - 8px), calc(100% - 8px) 100%, 0 100%, 0 8px);
  text-shadow: 0 0 10px #ff0050;
}

.habit-item .status:hover {
  transform: scale(1.1);
  box-shadow:
    0 0 20px rgba(255, 0, 80, 0.6),
    inset 0 0 10px rgba(255, 0, 80, 0.3);
}

.habit-item.completed .status {
  background: rgba(0, 255, 136, 0.3);
  border-color: #00ff88;
  color: #00ff88;
  text-shadow: 0 0 10px #00ff88;
  box-shadow: 0 0 15px rgba(0, 255, 136, 0.4);
}

.habit-item.completed .status:hover {
  box-shadow:
    0 0 25px rgba(0, 255, 136, 0.7),
    inset 0 0 10px rgba(0, 255, 136, 0.3);
}

.habit-item .name {
  flex: 1;
  font-size: 1.1rem;
  color: #eee;
  letter-spacing: 1px;
}

.habit-item.completed .name {
  color: #00ff88;
  text-shadow: 0 0 8px rgba(0, 255, 136, 0.5);
}

.habit-item .delete-btn {
  background: none;
  border: 1px solid transparent;
  color: #666;
  font-size: 1.4rem;
  cursor: pointer;
  padding: 5px 12px;
  transition: all 0.3s;
}

.habit-item .delete-btn:hover {
  color: #ff0050;
  border-color: #ff0050;
  text-shadow: 0 0 10px #ff0050;
  box-shadow: 0 0 15px rgba(255, 0, 80, 0.3);
}

.empty-message {
  text-align: center;
  color: #666;
  padding: 50px 20px;
  border: 1px dashed #333;
  font-style: italic;
  letter-spacing: 1px;
}

.empty-message.hidden {
  display: none;
}

/* Mobile responsiveness */
@media (max-width: 480px) {
  body {
    padding: 15px;
  }

  h1 {
    font-size: 1.4rem;
    letter-spacing: 2px;
  }

  .add-form {
    flex-direction: column;
  }

  .add-form button {
    width: 100%;
  }

  .habit-item {
    padding: 14px;
  }

  .habit-item .status {
    width: 38px;
    height: 38px;
    font-size: 1.1rem;
  }

  .habit-item .name {
    font-size: 0.95rem;
  }
}

/* Glow animation for completed items */
@keyframes pulse-glow {
  0%, 100% { box-shadow: 0 0 15px rgba(0, 255, 136, 0.4); }
  50% { box-shadow: 0 0 25px rgba(0, 255, 136, 0.7); }
}

.habit-item.completed {
  animation: pulse-glow 2s ease-in-out infinite;
}

/* Date Navigation */
.date-nav {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 15px;
  margin-top: 10px;
}

.nav-btn {
  width: 40px;
  height: 40px;
  border: 1px solid #0ff;
  background: rgba(0, 255, 255, 0.1);
  color: #0ff;
  font-family: 'Orbitron', sans-serif;
  font-size: 1.2rem;
  font-weight: bold;
  cursor: pointer;
  clip-path: polygon(6px 0, 100% 0, 100% calc(100% - 6px), calc(100% - 6px) 100%, 0 100%, 0 6px);
  transition: all 0.3s;
  text-shadow: 0 0 8px #0ff;
}

.nav-btn:hover:not(:disabled) {
  background: rgba(0, 255, 255, 0.25);
  box-shadow:
    0 0 15px rgba(0, 255, 255, 0.5),
    inset 0 0 10px rgba(0, 255, 255, 0.2);
}

.nav-btn:disabled {
  opacity: 0.3;
  cursor: not-allowed;
}

.date-nav .date {
  min-width: 180px;
  text-align: center;
}

/* View Toggle Buttons */
.view-toggle {
  display: flex;
  justify-content: center;
  gap: 8px;
  margin-bottom: 20px;
  flex-wrap: wrap;
}

.view-btn {
  padding: 10px 16px;
  border: 1px solid rgba(0, 255, 255, 0.4);
  background: rgba(0, 0, 0, 0.3);
  color: rgba(0, 255, 255, 0.6);
  font-family: 'Share Tech Mono', monospace;
  font-size: 0.75rem;
  letter-spacing: 1px;
  cursor: pointer;
  transition: all 0.3s;
  clip-path: polygon(8px 0, 100% 0, 100% calc(100% - 8px), calc(100% - 8px) 100%, 0 100%, 0 8px);
}

.view-btn:hover {
  border-color: #0ff;
  color: #0ff;
  background: rgba(0, 255, 255, 0.1);
}

.view-btn.active {
  border-color: #0ff;
  background: rgba(0, 255, 255, 0.2);
  color: #0ff;
  text-shadow: 0 0 10px #0ff;
  box-shadow: 0 0 15px rgba(0, 255, 255, 0.3), inset 0 0 10px rgba(0, 255, 255, 0.1);
}

@media (max-width: 480px) {
  .view-toggle {
    gap: 5px;
  }

  .view-btn {
    padding: 8px 12px;
    font-size: 0.65rem;
  }
}

/* Analog 30-Day Tracker - James Clear Style */
.analog-section {
  margin-top: 40px;
  padding: 25px;
  border: 2px solid #0ff;
  background: rgba(0, 255, 255, 0.03);
  clip-path: polygon(0 15px, 15px 0, 100% 0, 100% calc(100% - 15px), calc(100% - 15px) 100%, 0 100%);
  box-shadow:
    0 0 30px rgba(0, 255, 255, 0.2),
    inset 0 0 30px rgba(0, 255, 255, 0.05);
}

.analog-section h2 {
  font-family: 'Orbitron', sans-serif;
  font-size: 1.2rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 4px;
  color: #0ff;
  text-shadow: 0 0 15px #0ff;
  margin-bottom: 5px;
  text-align: center;
}

.analog-subtitle {
  font-size: 0.75rem;
  color: #ff00ff;
  text-align: center;
  letter-spacing: 2px;
  text-shadow: 0 0 8px #ff00ff;
  margin-bottom: 25px;
  font-style: italic;
}

.analog-tracker {
  display: flex;
  flex-direction: column;
  gap: 25px;
}

.analog-habit {
  padding: 20px;
  background: rgba(0, 0, 0, 0.3);
  border: 1px solid rgba(0, 255, 255, 0.3);
  border-radius: 4px;
}

.analog-habit-name {
  font-family: 'Orbitron', sans-serif;
  font-size: 1rem;
  font-weight: 700;
  color: #fff;
  letter-spacing: 2px;
  margin-bottom: 5px;
  text-shadow: 0 0 5px rgba(255, 255, 255, 0.3);
}

.analog-streak {
  font-size: 0.8rem;
  color: #888;
  margin-bottom: 15px;
}

.analog-streak .streak-count {
  font-family: 'Orbitron', sans-serif;
  font-size: 1.2rem;
  font-weight: 700;
  color: #00ff88;
  text-shadow: 0 0 10px #00ff88;
}

.analog-circles {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: center;
  margin-bottom: 15px;
}

.analog-circle {
  width: 32px;
  height: 32px;
  border: 2px solid rgba(255, 255, 255, 0.2);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.3s;
  cursor: default;
  position: relative;
  background: rgba(0, 0, 0, 0.3);
}

.analog-circle .circle-day {
  font-size: 0.65rem;
  color: rgba(255, 255, 255, 0.3);
  font-family: 'Orbitron', sans-serif;
}

.analog-circle.filled {
  background: #00ff88;
  border-color: #00ff88;
  box-shadow: 0 0 15px #00ff88, inset 0 0 10px rgba(255, 255, 255, 0.3);
}

.analog-circle.filled .circle-day {
  color: #0a0a0f;
  font-weight: 700;
}

.analog-circle:hover {
  transform: scale(1.15);
  border-color: #0ff;
  box-shadow: 0 0 10px #0ff;
}

.analog-circle.filled:hover {
  box-shadow: 0 0 20px #00ff88;
}

.analog-circle.today {
  border-color: #ff00ff;
  box-shadow: 0 0 10px #ff00ff;
}

.analog-circle.today .circle-day {
  color: #ff00ff;
}

.analog-circle.today.filled {
  box-shadow: 0 0 15px #00ff88, 0 0 20px #ff00ff;
}

.analog-progress {
  display: flex;
  align-items: center;
  gap: 12px;
}

.progress-bar {
  flex: 1;
  height: 6px;
  background: rgba(255, 255, 255, 0.1);
  border-radius: 3px;
  overflow: hidden;
}

.progress-fill {
  height: 100%;
  background: linear-gradient(90deg, #00ff88, #0ff);
  box-shadow: 0 0 10px #00ff88;
  transition: width 0.5s ease;
}

.progress-text {
  font-size: 0.75rem;
  color: #888;
  white-space: nowrap;
}

.analog-empty {
  text-align: center;
  color: #666;
  font-size: 0.9rem;
  padding: 30px;
  font-style: italic;
}

/* Mobile responsiveness for analog tracker */
@media (max-width: 480px) {
  .analog-section {
    padding: 15px;
  }

  .analog-section h2 {
    font-size: 1rem;
    letter-spacing: 2px;
  }

  .analog-habit {
    padding: 15px;
  }

  .analog-habit-name {
    font-size: 0.9rem;
  }

  .analog-circles {
    gap: 5px;
  }

  .analog-circle {
    width: 26px;
    height: 26px;
  }

  .analog-circle .circle-day {
    font-size: 0.55rem;
  }
}

/* History Section */
.history-section {
  margin-top: 40px;
  padding: 20px;
  border: 1px solid #ff00ff;
  background: rgba(255, 0, 255, 0.05);
  clip-path: polygon(0 15px, 15px 0, 100% 0, 100% calc(100% - 15px), calc(100% - 15px) 100%, 0 100%);
  overflow: hidden;
}

.history-section h2 {
  font-family: 'Orbitron', sans-serif;
  font-size: 1rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 3px;
  color: #ff00ff;
  text-shadow: 0 0 10px #ff00ff;
  margin-bottom: 20px;
  text-align: center;
}

.history-grid {
  display: flex;
  flex-direction: column;
  gap: 8px;
  overflow-x: auto;
}

.history-row {
  display: flex;
  align-items: center;
  gap: 10px;
}

.history-label {
  width: 100px;
  font-size: 0.75rem;
  color: #aaa;
  text-overflow: ellipsis;
  overflow: hidden;
  white-space: nowrap;
  flex-shrink: 0;
}

.history-cells {
  display: flex;
  gap: 2px;
  flex: 1;
  justify-content: flex-start;
  min-width: 0;
}

.history-cell {
  width: 9px;
  height: 9px;
  flex-shrink: 0;
  border-radius: 2px;
  transition: all 0.2s;
  cursor: default;
}

.history-cell.completed {
  background: #00ff88;
  box-shadow: 0 0 6px #00ff88;
}

.history-cell.missed {
  background: rgba(255, 0, 80, 0.4);
  border: 1px solid rgba(255, 0, 80, 0.6);
}

.history-cell:hover {
  transform: scale(1.5);
}

.history-row.date-labels {
  margin-top: 5px;
}

.history-date-label {
  width: 10px;
  font-size: 0.6rem;
  color: #666;
  text-align: center;
}

.history-empty {
  text-align: center;
  color: #666;
  font-size: 0.85rem;
  padding: 20px;
}

/* Mobile responsiveness for history */
@media (max-width: 480px) {
  .history-section {
    padding: 15px;
    margin-top: 30px;
  }

  .history-label {
    width: 60px;
    font-size: 0.6rem;
  }

  .history-cell {
    width: 6px;
    height: 6px;
  }

  .history-cells {
    gap: 1px;
  }

  .history-date-label {
    width: 6px;
    font-size: 0.45rem;
  }

  .date-nav .date {
    min-width: 140px;
    font-size: 0.75rem;
  }

  .nav-btn {
    width: 35px;
    height: 35px;
    font-size: 1rem;
  }
}

/* Theme Toggle Button */
.theme-toggle {
  position: fixed;
  top: 20px;
  right: 20px;
  width: 44px;
  height: 44px;
  border: 1px solid #0ff;
  background: rgba(0, 255, 255, 0.1);
  border-radius: 50%;
  cursor: pointer;
  z-index: 1001;
  transition: all 0.3s;
  display: flex;
  align-items: center;
  justify-content: center;
}

.theme-toggle:hover {
  background: rgba(0, 255, 255, 0.2);
  box-shadow: 0 0 15px rgba(0, 255, 255, 0.5);
}

.theme-icon {
  font-size: 1.2rem;
  position: absolute;
  transition: opacity 0.3s, transform 0.3s;
}

.cyber-icon {
  opacity: 1;
  color: #0ff;
  text-shadow: 0 0 10px #0ff;
}

.minimal-icon {
  opacity: 0;
  color: #333;
}

/* Notification Toggle Button */
.notification-toggle {
  position: fixed;
  top: 20px;
  right: 74px;
  width: 44px;
  height: 44px;
  border: 1px solid #0ff;
  background: rgba(0, 255, 255, 0.1);
  border-radius: 50%;
  cursor: pointer;
  z-index: 1001;
  transition: all 0.3s;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-direction: column;
}

.notification-toggle:hover {
  background: rgba(0, 255, 255, 0.2);
  box-shadow: 0 0 15px rgba(0, 255, 255, 0.5);
}

.notification-toggle.enabled {
  border-color: #00ff88;
  background: rgba(0, 255, 136, 0.2);
}

.notification-toggle.denied {
  border-color: #ff4444;
  opacity: 0.5;
  cursor: not-allowed;
}

.notif-icon {
  font-size: 1.1rem;
}

.notif-status {
  font-size: 0.5rem;
  position: absolute;
  bottom: 4px;
  color: #0ff;
}

.notification-toggle.enabled .notif-status::after {
  content: 'ON';
  color: #00ff88;
}

.notification-toggle.denied .notif-status::after {
  content: 'OFF';
  color: #ff4444;
}

/* iOS Install Banner */
.ios-install-banner {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  background: linear-gradient(135deg, #1a1a2e 0%, #0a0a15 100%);
  border-top: 1px solid #0ff;
  padding: 16px;
  z-index: 1002;
  animation: slideUp 0.3s ease-out;
}

@keyframes slideUp {
  from { transform: translateY(100%); }
  to { transform: translateY(0); }
}

.ios-install-content {
  display: flex;
  align-items: center;
  gap: 12px;
  max-width: 500px;
  margin: 0 auto;
}

.ios-install-icon {
  font-size: 2rem;
}

.ios-install-text {
  flex: 1;
}

.ios-install-text strong {
  display: block;
  color: #0ff;
  margin-bottom: 4px;
}

.ios-install-text p {
  font-size: 0.85rem;
  color: #888;
  margin: 0;
}

.ios-share-icon {
  display: inline-block;
  background: #0ff;
  color: #000;
  padding: 2px 4px;
  border-radius: 3px;
  font-size: 0.75rem;
}

.ios-install-dismiss {
  background: none;
  border: 1px solid #444;
  color: #888;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  cursor: pointer;
  font-size: 1.2rem;
  transition: all 0.2s;
}

.ios-install-dismiss:hover {
  border-color: #0ff;
  color: #0ff;
}

.ios-install-banner.hidden {
  display: none;
}

/* ========================================
   MINIMALIST THEME
   ======================================== */

body.minimal {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  background: #fafafa;
  color: #333;
}

body.minimal::before,
body.minimal::after {
  display: none;
}

body.minimal .theme-toggle {
  border: 1px solid #ddd;
  background: #fff;
  box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}

body.minimal .theme-toggle:hover {
  background: #f5f5f5;
  box-shadow: 0 4px 12px rgba(0,0,0,0.15);
}

body.minimal .cyber-icon {
  opacity: 0;
}

body.minimal .minimal-icon {
  opacity: 1;
}

body.minimal .notification-toggle {
  border: 1px solid #ddd;
  background: #fff;
  box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}

body.minimal .notification-toggle:hover {
  background: #f5f5f5;
  box-shadow: 0 4px 12px rgba(0,0,0,0.15);
}

body.minimal .notification-toggle.enabled {
  border-color: #22c55e;
  background: rgba(34, 197, 94, 0.1);
}

body.minimal .notification-toggle.enabled .notif-status::after {
  color: #22c55e;
}

body.minimal .ios-install-banner {
  background: #fff;
  border-top: 1px solid #ddd;
  box-shadow: 0 -4px 12px rgba(0,0,0,0.1);
}

body.minimal .ios-install-text strong {
  color: #333;
}

body.minimal .ios-share-icon {
  background: #007aff;
  color: #fff;
}

body.minimal .container {
  max-width: 480px;
}

body.minimal header {
  border: none;
  background: #fff;
  clip-path: none;
  box-shadow: 0 2px 8px rgba(0,0,0,0.08);
  border-radius: 12px;
  padding: 24px;
}

body.minimal h1 {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  font-size: 1.5rem;
  font-weight: 600;
  color: #333;
  text-shadow: none;
  animation: none;
  letter-spacing: 0;
  text-transform: none;
}

body.minimal .date {
  color: #666;
  text-shadow: none;
  font-size: 0.9rem;
}

body.minimal .nav-btn {
  border: 1px solid #ddd;
  background: #fff;
  color: #333;
  border-radius: 8px;
  clip-path: none;
  text-shadow: none;
}

body.minimal .nav-btn:hover:not(:disabled) {
  background: #f0f0f0;
  box-shadow: none;
}

body.minimal .nav-btn:disabled {
  opacity: 0.4;
}

body.minimal .add-form input {
  border: 1px solid #ddd;
  background: #fff;
  color: #333;
  clip-path: none;
  border-radius: 8px;
  font-family: inherit;
}

body.minimal .add-form input::placeholder {
  color: #999;
}

body.minimal .add-form input:focus {
  outline: none;
  border-color: #333;
  box-shadow: none;
  background: #fff;
}

body.minimal .add-form button {
  border: none;
  background: #333;
  color: #fff;
  font-family: inherit;
  font-weight: 500;
  text-transform: none;
  letter-spacing: 0;
  clip-path: none;
  border-radius: 8px;
  text-shadow: none;
}

body.minimal .add-form button:hover {
  background: #555;
  box-shadow: none;
}

body.minimal .habit-item {
  background: #fff;
  border: 1px solid #eee;
  clip-path: none;
  border-radius: 10px;
  box-shadow: 0 2px 4px rgba(0,0,0,0.04);
  animation: none;
}

body.minimal .habit-item::before {
  display: none;
}

body.minimal .habit-item.completed {
  background: #f0fdf4;
  border-color: #86efac;
}

body.minimal .habit-item .status {
  background: #f5f5f5;
  border: 2px solid #ddd;
  color: #999;
  clip-path: none;
  border-radius: 8px;
  text-shadow: none;
}

body.minimal .habit-item .status:hover {
  transform: scale(1.05);
  box-shadow: none;
}

body.minimal .habit-item.completed .status {
  background: #22c55e;
  border-color: #22c55e;
  color: #fff;
  box-shadow: none;
}

body.minimal .habit-item .name {
  color: #333;
  font-size: 1rem;
  letter-spacing: 0;
}

body.minimal .habit-item.completed .name {
  color: #166534;
  text-shadow: none;
}

body.minimal .habit-item .delete-btn {
  color: #ccc;
}

body.minimal .habit-item .delete-btn:hover {
  color: #ef4444;
  border-color: transparent;
  text-shadow: none;
  box-shadow: none;
}

body.minimal .empty-message {
  color: #999;
  border: 1px dashed #ddd;
}

/* Minimal View Toggle */
body.minimal .view-toggle {
  gap: 6px;
}

body.minimal .view-btn {
  border: 1px solid #ddd;
  background: #fff;
  color: #666;
  font-family: inherit;
  clip-path: none;
  border-radius: 6px;
}

body.minimal .view-btn:hover {
  border-color: #333;
  color: #333;
  background: #fff;
}

body.minimal .view-btn.active {
  border-color: #333;
  background: #333;
  color: #fff;
  text-shadow: none;
  box-shadow: none;
}

/* Minimal Analog Section */
body.minimal .analog-section {
  border: 1px solid #eee;
  background: #fff;
  clip-path: none;
  border-radius: 12px;
  box-shadow: 0 2px 8px rgba(0,0,0,0.08);
  padding: 24px;
}

body.minimal .analog-section h2 {
  font-family: inherit;
  font-size: 1.1rem;
  font-weight: 600;
  color: #333;
  text-shadow: none;
  letter-spacing: 0;
  text-transform: none;
}

body.minimal .analog-subtitle {
  color: #999;
  text-shadow: none;
  font-style: normal;
  font-size: 0.85rem;
}

body.minimal .analog-habit {
  background: #fafafa;
  border: 1px solid #eee;
  border-radius: 8px;
}

body.minimal .analog-habit-name {
  font-family: inherit;
  font-weight: 600;
  color: #333;
  text-shadow: none;
  letter-spacing: 0;
}

body.minimal .analog-streak {
  color: #666;
}

body.minimal .analog-streak .streak-count {
  font-family: inherit;
  font-weight: 700;
  color: #22c55e;
  text-shadow: none;
}

body.minimal .analog-circle {
  border: 2px solid #ddd;
  background: #fff;
}

body.minimal .analog-circle .circle-day {
  font-family: inherit;
  color: #ccc;
}

body.minimal .analog-circle.filled {
  background: #22c55e;
  border-color: #22c55e;
  box-shadow: none;
}

body.minimal .analog-circle.filled .circle-day {
  color: #fff;
}

body.minimal .analog-circle:hover {
  border-color: #333;
  box-shadow: none;
  transform: scale(1.1);
}

body.minimal .analog-circle.filled:hover {
  box-shadow: none;
}

body.minimal .analog-circle.today {
  border-color: #333;
  box-shadow: 0 0 0 2px rgba(0,0,0,0.1);
}

body.minimal .analog-circle.today .circle-day {
  color: #333;
  font-weight: 700;
}

body.minimal .analog-circle.today.filled {
  box-shadow: none;
  border-color: #22c55e;
}

body.minimal .progress-bar {
  background: #eee;
  border-radius: 4px;
}

body.minimal .progress-fill {
  background: linear-gradient(90deg, #22c55e, #4ade80);
  box-shadow: none;
}

body.minimal .progress-text {
  color: #666;
}

/* Minimal History Section */
body.minimal .history-section {
  border: 1px solid #eee;
  background: #fff;
  clip-path: none;
  border-radius: 12px;
  box-shadow: 0 2px 8px rgba(0,0,0,0.08);
}

body.minimal .history-section h2 {
  font-family: inherit;
  font-weight: 600;
  color: #333;
  text-shadow: none;
  letter-spacing: 0;
  text-transform: none;
}

body.minimal .history-label {
  color: #666;
}

body.minimal .history-cell.completed {
  background: #22c55e;
  box-shadow: none;
  border-radius: 2px;
}

body.minimal .history-cell.missed {
  background: #f5f5f5;
  border: 1px solid #eee;
}

body.minimal .history-cell:hover {
  transform: scale(1.3);
}

body.minimal .history-date-label {
  color: #999;
}

/* ========================================
   NEW ATOMIC HABITS FEATURES
   ======================================== */

/* Confetti Canvas */
#confetti-canvas {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 9999;
}

/* Modals */
.modal {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.85);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 2000;
  padding: 20px;
}

.modal.hidden {
  display: none;
}

.modal-content {
  background: #0a0a0f;
  border: 2px solid #0ff;
  padding: 30px;
  max-width: 450px;
  width: 100%;
  max-height: 90vh;
  overflow-y: auto;
  clip-path: polygon(0 15px, 15px 0, 100% 0, 100% calc(100% - 15px), calc(100% - 15px) 100%, 0 100%);
  box-shadow: 0 0 40px rgba(0, 255, 255, 0.3);
}

.modal-content h2 {
  font-family: 'Orbitron', sans-serif;
  color: #0ff;
  text-shadow: 0 0 10px #0ff;
  margin-bottom: 20px;
  text-align: center;
}

/* Form Styles */
.form-group {
  margin-bottom: 18px;
}

.form-group label {
  display: block;
  color: #0ff;
  font-size: 0.85rem;
  margin-bottom: 6px;
  letter-spacing: 1px;
}

.form-group input,
.form-group select,
.form-group textarea {
  width: 100%;
  padding: 12px;
  border: 1px solid #0ff;
  background: rgba(0, 255, 255, 0.1);
  color: #fff;
  font-family: 'Share Tech Mono', monospace;
  font-size: 0.95rem;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
  outline: none;
  box-shadow: 0 0 15px rgba(0, 255, 255, 0.4);
}

.form-group textarea {
  resize: vertical;
  min-height: 80px;
}

.form-hint {
  display: block;
  color: #666;
  font-size: 0.75rem;
  margin-top: 4px;
  font-style: italic;
}

.form-row {
  display: flex;
  gap: 15px;
}

.form-row .form-group {
  flex: 1;
}

.form-actions {
  display: flex;
  gap: 12px;
  margin-top: 25px;
}

.btn-primary,
.btn-secondary {
  flex: 1;
  padding: 12px 20px;
  border: none;
  font-family: 'Orbitron', sans-serif;
  font-size: 0.85rem;
  cursor: pointer;
  transition: all 0.3s;
}

.btn-primary {
  background: #0ff;
  color: #0a0a0f;
  text-shadow: none;
}

.btn-primary:hover {
  box-shadow: 0 0 20px #0ff;
}

.btn-secondary {
  background: transparent;
  border: 1px solid #666;
  color: #666;
}

.btn-secondary:hover {
  border-color: #ff00ff;
  color: #ff00ff;
}

/* Difficulty Buttons */
.difficulty-buttons {
  display: flex;
  gap: 10px;
}

.diff-btn {
  flex: 1;
  padding: 12px;
  border: 1px solid #444;
  background: transparent;
  color: #888;
  cursor: pointer;
  transition: all 0.3s;
  font-size: 0.9rem;
}

.diff-btn:hover {
  border-color: #0ff;
  color: #0ff;
}

.diff-btn.selected {
  border-color: #00ff88;
  background: rgba(0, 255, 136, 0.2);
  color: #00ff88;
}

/* Milestone Modal */
.milestone-content {
  text-align: center;
  border-color: #ffff00;
  box-shadow: 0 0 60px rgba(255, 255, 0, 0.4);
}

.milestone-icon {
  font-size: 4rem;
  margin-bottom: 15px;
  animation: bounce 0.5s ease infinite alternate;
}

@keyframes bounce {
  from { transform: translateY(0); }
  to { transform: translateY(-10px); }
}

.milestone-content h2 {
  color: #ffff00;
  text-shadow: 0 0 20px #ffff00;
}

#milestone-message {
  color: #fff;
  font-size: 1.1rem;
  margin-bottom: 20px;
}

.milestone-streak {
  font-family: 'Orbitron', sans-serif;
  font-size: 3rem;
  font-weight: 900;
  color: #00ff88;
  text-shadow: 0 0 30px #00ff88;
  margin-bottom: 25px;
}

.modal-close {
  padding: 15px 40px;
  background: #ffff00;
  border: none;
  color: #0a0a0f;
  font-family: 'Orbitron', sans-serif;
  font-size: 1rem;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.3s;
}

.modal-close:hover {
  box-shadow: 0 0 30px #ffff00;
}

/* Add Habit Button */
.add-habit-btn {
  width: 100%;
  padding: 15px;
  margin-bottom: 20px;
  border: 2px dashed #0ff;
  background: transparent;
  color: #0ff;
  font-family: 'Orbitron', sans-serif;
  font-size: 0.9rem;
  cursor: pointer;
  transition: all 0.3s;
}

.add-habit-btn:hover {
  background: rgba(0, 255, 255, 0.1);
  box-shadow: 0 0 20px rgba(0, 255, 255, 0.3);
}

/* Weekly Stats */
.weekly-stats {
  margin-bottom: 25px;
  padding: 18px;
  border: 1px solid #ff00ff;
  background: rgba(255, 0, 255, 0.05);
}

.stats-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 12px;
}

.stats-header h3 {
  font-family: 'Orbitron', sans-serif;
  font-size: 0.9rem;
  color: #ff00ff;
  text-shadow: 0 0 10px #ff00ff;
}

.stats-percentage {
  font-family: 'Orbitron', sans-serif;
  font-size: 1.5rem;
  font-weight: 900;
  color: #00ff88;
  text-shadow: 0 0 15px #00ff88;
}

.stats-bar {
  height: 8px;
  background: rgba(255, 255, 255, 0.1);
  border-radius: 4px;
  overflow: hidden;
  margin-bottom: 15px;
}

.stats-fill {
  height: 100%;
  transition: width 0.5s ease;
  border-radius: 4px;
}

.stats-fill.excellent {
  background: linear-gradient(90deg, #00ff88, #0ff);
  box-shadow: 0 0 10px #00ff88;
}

.stats-fill.good {
  background: linear-gradient(90deg, #ffff00, #ff9900);
  box-shadow: 0 0 10px #ffff00;
}

.stats-fill.needs-work {
  background: linear-gradient(90deg, #ff0050, #ff00ff);
  box-shadow: 0 0 10px #ff0050;
}

.stats-details {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.stat-habit {
  display: flex;
  justify-content: space-between;
  padding: 6px 10px;
  background: rgba(0, 0, 0, 0.3);
  border-radius: 4px;
  font-size: 0.75rem;
  flex: 1 1 calc(50% - 4px);
  min-width: 120px;
}

.stat-name {
  color: #aaa;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  max-width: 70%;
}

.stat-score {
  color: #0ff;
  font-weight: bold;
}

/* Updated Habit Item */
.habit-item {
  margin-bottom: 10px;
  background: rgba(255, 0, 80, 0.1);
  border: 1px solid #ff0050;
  clip-path: polygon(0 0, calc(100% - 10px) 0, 100% 10px, 100% 100%, 10px 100%, 0 calc(100% - 10px));
  transition: all 0.3s;
  position: relative;
  overflow: hidden;
}

.habit-item.warning {
  border-color: #ffff00;
  background: rgba(255, 255, 0, 0.1);
}

.habit-item.warning::before {
  background: #ffff00;
  box-shadow: 0 0 15px #ffff00;
}

.never-miss-twice {
  color: #ffff00;
  font-size: 0.8rem;
  margin-left: 8px;
}

.habit-main {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 12px;
}

.habit-info {
  flex: 1;
  min-width: 0;
}

.habit-name-row {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 2px;
}

.habit-info .name {
  font-size: 0.95rem;
  color: #eee;
}

.habit-name-row .current-streak {
  font-size: 0.85rem;
  color: #ff9900;
}

.habit-identity {
  font-size: 0.75rem;
  color: #0ff;
  font-style: italic;
  margin-bottom: 3px;
}

.habit-when {
  font-size: 0.7rem;
  color: #888;
}

.habit-2min {
  font-size: 0.7rem;
  color: #00ff88;
  margin-top: 4px;
}

.habit-actions {
  display: flex;
  gap: 5px;
}

.edit-btn {
  background: none;
  border: 1px solid transparent;
  color: #666;
  font-size: 1.1rem;
  cursor: pointer;
  padding: 5px 8px;
  transition: all 0.3s;
}

.edit-btn:hover {
  color: #0ff;
  border-color: #0ff;
}

/* Analog Identity */
.analog-identity {
  font-size: 0.75rem;
  color: #0ff;
  font-style: italic;
  font-weight: normal;
  margin-top: 3px;
}

.best-streak-badge {
  font-size: 0.7rem;
  color: #888;
  margin-left: 10px;
  padding: 2px 8px;
  background: rgba(255, 255, 255, 0.1);
  border-radius: 10px;
}

/* ========================================
   MINIMAL THEME - NEW FEATURES
   ======================================== */

body.minimal .modal-content {
  background: #fff;
  border: 1px solid #ddd;
  border-radius: 16px;
  clip-path: none;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.2);
}

body.minimal .modal-content h2 {
  font-family: inherit;
  color: #333;
  text-shadow: none;
}

body.minimal .form-group label {
  color: #333;
}

body.minimal .form-group input,
body.minimal .form-group select,
body.minimal .form-group textarea {
  border: 1px solid #ddd;
  background: #fff;
  color: #333;
  border-radius: 8px;
}

body.minimal .form-group input:focus,
body.minimal .form-group select:focus,
body.minimal .form-group textarea:focus {
  border-color: #333;
  box-shadow: none;
}

body.minimal .btn-primary {
  background: #333;
  color: #fff;
  border-radius: 8px;
}

body.minimal .btn-primary:hover {
  background: #555;
  box-shadow: none;
}

body.minimal .btn-secondary {
  border: 1px solid #ddd;
  color: #666;
  border-radius: 8px;
}

body.minimal .btn-secondary:hover {
  border-color: #333;
  color: #333;
}

body.minimal .diff-btn {
  border: 1px solid #ddd;
  border-radius: 8px;
}

body.minimal .diff-btn:hover {
  border-color: #333;
  color: #333;
}

body.minimal .diff-btn.selected {
  border-color: #22c55e;
  background: rgba(34, 197, 94, 0.1);
  color: #22c55e;
}

body.minimal .milestone-content {
  border-color: #fbbf24;
  box-shadow: 0 10px 40px rgba(251, 191, 36, 0.3);
}

body.minimal .milestone-content h2 {
  color: #f59e0b;
  text-shadow: none;
}

body.minimal .milestone-streak {
  color: #22c55e;
  text-shadow: none;
}

body.minimal .modal-close {
  background: #f59e0b;
  border-radius: 8px;
}

body.minimal .modal-close:hover {
  box-shadow: 0 4px 15px rgba(245, 158, 11, 0.4);
}

body.minimal .add-habit-btn {
  border: 2px dashed #ddd;
  color: #666;
  border-radius: 12px;
}

body.minimal .add-habit-btn:hover {
  border-color: #333;
  color: #333;
  background: #f9f9f9;
  box-shadow: none;
}

body.minimal .weekly-stats {
  border: 1px solid #eee;
  background: #fff;
  border-radius: 12px;
  box-shadow: 0 2px 8px rgba(0,0,0,0.08);
}

body.minimal .stats-header h3 {
  font-family: inherit;
  color: #333;
  text-shadow: none;
}

body.minimal .stats-percentage {
  font-family: inherit;
  color: #22c55e;
  text-shadow: none;
}

body.minimal .stats-fill.excellent {
  background: linear-gradient(90deg, #22c55e, #4ade80);
  box-shadow: none;
}

body.minimal .stats-fill.good {
  background: linear-gradient(90deg, #f59e0b, #fbbf24);
  box-shadow: none;
}

body.minimal .stats-fill.needs-work {
  background: linear-gradient(90deg, #ef4444, #f87171);
  box-shadow: none;
}

body.minimal .stat-habit {
  background: #f9f9f9;
}

body.minimal .stat-name {
  color: #666;
}

body.minimal .stat-score {
  color: #333;
}

body.minimal .habit-item {
  border: 1px solid #eee;
  background: #fff;
  clip-path: none;
  border-radius: 12px;
}

body.minimal .habit-item.warning {
  border-color: #fbbf24;
  border-left: 4px solid #fbbf24;
  background: #fffbeb;
}

body.minimal .never-miss-twice {
  color: #92400e;
}

body.minimal .habit-info .name {
  color: #333;
}

body.minimal .habit-identity {
  color: #666;
}

body.minimal .habit-when {
  color: #999;
}

body.minimal .habit-2min {
  color: #22c55e;
}

body.minimal .current-streak {
  color: #f59e0b;
}

body.minimal .edit-btn:hover {
  color: #333;
  border-color: #333;
}

body.minimal .analog-identity {
  color: #666;
}

body.minimal .best-streak-badge {
  background: #f3f4f6;
  color: #666;
}

/* Mobile Adjustments for New Features */
@media (max-width: 480px) {
  .modal-content {
    padding: 20px;
  }

  .form-row {
    flex-direction: column;
    gap: 0;
  }

  .difficulty-buttons {
    flex-direction: column;
  }

  .habit-main {
    flex-wrap: wrap;
  }

  .habit-streaks {
    flex-direction: row;
    width: 100%;
    justify-content: center;
    padding: 10px 0 0;
    gap: 15px;
  }

  .habit-actions {
    position: absolute;
    top: 10px;
    right: 10px;
  }

  .stats-details {
    flex-direction: column;
  }

  .stat-habit {
    flex: 1 1 100%;
  }

  .milestone-streak {
    font-size: 2.5rem;
  }
}
