/* ===== NERDNOTES STYLES - WITH DASHBOARD ===== */

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

/* ===== BETA BANNER ===== */
.beta-banner {
  background: linear-gradient(135deg, #4a5568 0%, #2d3748 100%);
  color: white;
  padding: 10px 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1001;
  font-size: 0.9rem;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
}

.beta-banner.hidden {
  display: none;
}

.beta-content {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  justify-content: center;
  text-align: center;
}

.beta-badge {
  background: #ecc94b;
  color: #744210;
  padding: 3px 10px;
  border-radius: 12px;
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.5px;
  flex-shrink: 0;
}

.beta-message {
  opacity: 0.95;
}

.beta-dismiss {
  background: rgba(255, 255, 255, 0.2);
  border: none;
  color: white;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  cursor: pointer;
  font-size: 1.1rem;
  line-height: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.2s ease;
  position: absolute;
  right: 15px;
  flex-shrink: 0;
}

.beta-dismiss:hover {
  background: rgba(255, 255, 255, 0.3);
}

/* ===== SIDEBAR ===== */
.sidebar {
  position: fixed;
  top: 0;
  left: 0;
  width: 240px;
  height: 100vh;
  background: linear-gradient(180deg, #E07A5F 0%, #9D4EDD 100%);
  z-index: 1000;
  display: flex;
  flex-direction: column;
  transition: transform 0.3s ease;
  box-shadow: 4px 0 15px rgba(0, 0, 0, 0.15);
}

.sidebar.collapsed {
  transform: translateX(-240px);
}

.sidebar-header {
  padding: 24px 20px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.15);
}

.sidebar-logo {
  color: white;
  font-size: 1.4rem;
  font-weight: 700;
  margin: 0;
}

.sidebar-nav {
  display: flex;
  flex-direction: column;
  padding: 16px 12px;
  gap: 8px;
}

.sidebar-btn {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px 16px;
  background: transparent;
  border: none;
  border-radius: 10px;
  color: rgba(255, 255, 255, 0.85);
  font-size: 0.95rem;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s ease;
  text-decoration: none;
  text-align: left;
}

.sidebar-btn:hover {
  background: rgba(255, 255, 255, 0.15);
  color: white;
}

.sidebar-btn.active {
  background: rgba(255, 255, 255, 0.2);
  color: white;
  font-weight: 600;
}

.sidebar-icon {
  font-size: 1.2rem;
  flex-shrink: 0;
}

.sidebar-text {
  white-space: nowrap;
}

.sidebar-toggle {
  position: fixed;
  top: 55px;
  left: 250px;
  width: 40px;
  height: 40px;
  background: linear-gradient(135deg, #E07A5F 0%, #9D4EDD 100%);
  border: none;
  border-radius: 0 8px 8px 0;
  color: white;
  font-size: 1.3rem;
  cursor: pointer;
  z-index: 1001;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: left 0.3s ease, transform 0.2s ease;
  box-shadow: 2px 2px 8px rgba(0, 0, 0, 0.2);
}

.sidebar-toggle:hover {
  transform: scale(1.05);
}

.sidebar-toggle.shifted {
  left: 10px;
  border-radius: 8px;
}

.container.with-sidebar {
  margin-left: 240px;
  margin-right: auto;
  transition: margin-left 0.3s ease, margin-right 0.3s ease;
}

.container.sidebar-collapsed {
  margin-left: auto;
  margin-right: auto;
}

/* Sidebar Settings */
.sidebar-settings {
  margin-top: auto;
  padding: 16px 12px;
  border-top: 1px solid rgba(255, 255, 255, 0.15);
}

.sidebar-section-title {
  color: rgba(255, 255, 255, 0.6);
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  padding: 0 16px 10px;
}

.settings-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 16px;
  color: rgba(255, 255, 255, 0.85);
  font-size: 0.95rem;
}

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

.settings-label {
  flex: 1;
}

/* Toggle Switch */
.toggle-switch {
  position: relative;
  width: 44px;
  height: 24px;
  flex-shrink: 0;
}

.toggle-switch input {
  opacity: 0;
  width: 0;
  height: 0;
}

.toggle-slider {
  position: absolute;
  cursor: pointer;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(255, 255, 255, 0.3);
  border-radius: 24px;
  transition: 0.3s;
}

.toggle-slider:before {
  position: absolute;
  content: "";
  height: 18px;
  width: 18px;
  left: 3px;
  bottom: 3px;
  background: white;
  border-radius: 50%;
  transition: 0.3s;
}

.toggle-switch input:checked + .toggle-slider {
  background: #4ade80;
}

.toggle-switch input:checked + .toggle-slider:before {
  transform: translateX(20px);
}

/* ===== DARK MODE ===== */
body.dark-mode {
  background: linear-gradient(135deg, #1a1a2e 0%, #16213e 100%);
}

body.dark-mode .container {
  background: transparent;
}

body.dark-mode .header .logo,
body.dark-mode .header .tagline {
  color: #e0e0e0;
}

body.dark-mode .upload-section,
body.dark-mode .result-section,
body.dark-mode .search-section,
body.dark-mode .empty-state,
body.dark-mode .login-prompt-card {
  background: #1e1e2f;
  border: 1px solid #2d2d44;
}

body.dark-mode .section-title,
body.dark-mode .input-label {
  color: #e0e0e0;
}

body.dark-mode .file-input,
body.dark-mode .text-input,
body.dark-mode .search-input {
  background: #2a2a40;
  border-color: #3d3d5c;
  color: #e0e0e0;
}

body.dark-mode .file-input::placeholder,
body.dark-mode .text-input::placeholder,
body.dark-mode .search-input::placeholder {
  color: #888;
}

body.dark-mode .divider-text {
  color: #888;
  background: #1e1e2f;
}

body.dark-mode .result-card,
body.dark-mode .note-card {
  background: #252538;
  border-color: #3d3d5c;
}

body.dark-mode .card-title,
body.dark-mode .detail-title {
  color: #e0e0e0;
}

body.dark-mode .card-content,
body.dark-mode .notes-content,
body.dark-mode .transcript-content {
  color: #c0c0c0;
  background: #1e1e2f;
}

body.dark-mode .usage-section {
  background: #252538;
  border-color: #3d3d5c;
}

body.dark-mode .usage-bar {
  background: #3d3d5c;
}

body.dark-mode .notes-table {
  background: #252538;
}

body.dark-mode .notes-table th {
  background: linear-gradient(135deg, #E07A5F 0%, #9D4EDD 100%);
}

body.dark-mode .notes-table td {
  border-color: #3d3d5c;
  color: #c0c0c0;
}

body.dark-mode .notes-table td.term-cell {
  background: #2a2a40;
}

body.dark-mode .notes-table tbody tr:nth-child(even) {
  background: #2a2a40;
}

body.dark-mode .notes-table tbody tr:hover {
  background: #333350;
}

body.dark-mode .action-btn {
  background: #2a2a40;
  color: #e0e0e0;
  border-color: #3d3d5c;
}

body.dark-mode .action-btn:hover {
  background: #333350;
}

body.dark-mode .back-btn {
  background: #252538;
  color: #f472b6;
}

body.dark-mode .file-type-hint,
body.dark-mode .file-name {
  color: #888;
}

/* Dark mode - Dashboard usage section */
body.dark-mode .usage-dashboard {
  background: #1e1e2f;
  border-color: #2d2d44;
}

body.dark-mode .usage-dashboard h2,
body.dark-mode .usage-dashboard .usage-title {
  color: #e0e0e0;
}

body.dark-mode .usage-stat-card {
  background: #252538;
  border-color: #3d3d5c;
}

body.dark-mode .usage-stat-label {
  color: #a0a0a0;
}

body.dark-mode .usage-stat-value {
  color: #e0e0e0;
}

body.dark-mode .usage-progress-container {
  background: #252538;
}

body.dark-mode .usage-progress-bg {
  background: #3d3d5c;
}

body.dark-mode .usage-percent,
body.dark-mode .usage-text,
body.dark-mode .reset-date {
  color: #a0a0a0;
}

/* Dark mode - Note cards */
body.dark-mode .note-card .note-title {
  color: #f0f0f0;
}

body.dark-mode .note-card .note-date {
  color: #a0a0a0;
}

body.dark-mode .note-card .note-preview {
  color: #c0c0c0;
}

body.dark-mode .note-card {
  background: #252538;
  border-color: #3d3d5c;
}

body.dark-mode .note-card:hover {
  border-color: #E07A5F;
}

/* Dark mode - Upload section inner elements */
body.dark-mode .upload-section .divider {
  background: transparent;
}

body.dark-mode .upload-section .divider::before,
body.dark-mode .upload-section .divider::after {
  background: #2d2d44;
}

body.dark-mode .upload-section .divider span {
  background: #1e1e2f;
  color: #888;
}

body.dark-mode .generate-btn {
  background: linear-gradient(135deg, #E07A5F 0%, #9D4EDD 100%);
}

/* Dark mode - Detail view */
body.dark-mode .note-detail-view {
  background: #1e1e2f;
}

body.dark-mode .detail-header {
  color: #e0e0e0;
}

/* Dark mode - Login prompt */
body.dark-mode .login-prompt-card h3 {
  color: #e0e0e0;
}

body.dark-mode .login-prompt-card p {
  color: #a0a0a0;
}

body.dark-mode .login-benefits .benefit-item {
  color: #c0c0c0;
}

/* Dark mode - Usage tracker card */
body.dark-mode .usage-tracker-card {
  background: #1e1e2f;
  border-color: #2d2d44;
}

body.dark-mode .usage-tracker-header,
body.dark-mode .usage-tracker-title {
  color: #e0e0e0;
}

body.dark-mode .usage-stat {
  background: rgba(224, 122, 95, 0.15);
  border-color: #3d3d5c;
}

body.dark-mode .stat-label {
  color: #a0a0a0;
}

body.dark-mode .stat-value {
  color: #f0f0f0;
}

body.dark-mode .usage-progress-section {
  background: #252538;
}

body.dark-mode .progress-bar-bg {
  background: #3d3d5c;
}

body.dark-mode .progress-info,
body.dark-mode .reset-info {
  color: #a0a0a0;
}

/* Dark mode - Dashboard header */
body.dark-mode .dashboard-header h2 {
  color: #e0e0e0;
}

/* Dark mode - Notes grid cards */
body.dark-mode .history-card {
  background: #252538;
  border-color: #3d3d5c;
}

body.dark-mode .history-card:hover {
  border-color: #E07A5F;
}

body.dark-mode .history-card .card-title,
body.dark-mode .history-item .card-title {
  color: #f0f0f0;
}

body.dark-mode .history-card .card-date,
body.dark-mode .history-item .card-date {
  color: #a0a0a0;
}

body.dark-mode .history-card .card-preview,
body.dark-mode .history-item .card-preview {
  color: #c0c0c0;
}

/* ===== SETTINGS PAGE ===== */
.settings-section {
  padding: 20px 0;
}

.settings-card {
  background: white;
  border-radius: 16px;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.08);
  overflow: hidden;
  margin-bottom: 20px;
}

.settings-card-header {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 20px 24px;
  border-bottom: 1px solid #f0f0f0;
}

.settings-card-icon {
  font-size: 1.5rem;
}

.settings-card-title {
  font-size: 1.1rem;
  font-weight: 600;
  color: #333;
  margin: 0;
}

.settings-card-body {
  padding: 16px 24px;
}

.setting-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 0;
  gap: 20px;
}

.setting-row:not(:last-child) {
  border-bottom: 1px solid #f0f0f0;
}

.setting-info {
  display: flex;
  align-items: flex-start;
  gap: 16px;
  flex: 1;
}

.setting-icon {
  font-size: 1.5rem;
  flex-shrink: 0;
}

.setting-text {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.setting-name {
  font-weight: 600;
  color: #333;
  font-size: 1rem;
}

.setting-desc {
  color: #666;
  font-size: 0.9rem;
  line-height: 1.4;
}

/* Cancel Button */
.btn-cancel {
  background: #dc3545;
  color: white;
  border: none;
  padding: 10px 20px;
  border-radius: 8px;
  font-weight: 600;
  font-size: 0.9rem;
  cursor: pointer;
  transition: all 0.2s;
  flex-shrink: 0;
}

.btn-cancel:hover {
  background: #c82333;
  transform: translateY(-1px);
}

.btn-cancel:disabled {
  background: #6c757d;
  cursor: not-allowed;
  transform: none;
}

body.dark-mode .btn-cancel {
  background: #e74c3c;
}

body.dark-mode .btn-cancel:hover {
  background: #c0392b;
}

/* Large Toggle Switch */
.toggle-switch-large {
  position: relative;
  width: 56px;
  height: 30px;
  flex-shrink: 0;
}

.toggle-switch-large input {
  opacity: 0;
  width: 0;
  height: 0;
}

.toggle-slider-large {
  position: absolute;
  cursor: pointer;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: #ccc;
  border-radius: 30px;
  transition: 0.3s;
}

.toggle-slider-large:before {
  position: absolute;
  content: "";
  height: 24px;
  width: 24px;
  left: 3px;
  bottom: 3px;
  background: white;
  border-radius: 50%;
  transition: 0.3s;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

.toggle-switch-large input:checked + .toggle-slider-large {
  background: #E07A5F;
}

.toggle-switch-large input:checked + .toggle-slider-large:before {
  transform: translateX(26px);
}

/* Dark mode - Settings */
body.dark-mode .settings-card {
  background: #1e1e2f;
  border: 1px solid #2d2d44;
}

body.dark-mode .settings-card-header {
  border-color: #2d2d44;
}

body.dark-mode .settings-card-title {
  color: #e0e0e0;
}

body.dark-mode .setting-name {
  color: #e0e0e0;
}

body.dark-mode .setting-desc {
  color: #a0a0a0;
}

body.dark-mode .setting-row:not(:last-child) {
  border-color: #2d2d44;
}

body.dark-mode .toggle-slider-large {
  background: #3d3d5c;
}

@media (max-width: 600px) {
  .beta-banner {
    padding: 12px 45px 12px 15px;
    font-size: 0.8rem;
  }
  
  .beta-content {
    gap: 8px;
  }
  
  .beta-badge {
    font-size: 0.7rem;
    padding: 2px 8px;
  }
  
  .beta-dismiss {
    right: 10px;
  }
}

/* ===== OFFLINE INDICATOR ===== */
.offline-indicator {
  position: fixed;
  bottom: 20px;
  left: 50%;
  transform: translateX(-50%);
  background: linear-gradient(135deg, #f6ad55 0%, #ed8936 100%);
  color: white;
  padding: 12px 24px;
  border-radius: 25px;
  font-size: 0.9rem;
  font-weight: 500;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
  z-index: 1002;
  display: none;
  animation: slideUp 0.3s ease-out;
}

@keyframes slideUp {
  from {
    opacity: 0;
    transform: translateX(-50%) translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
  }
}

@media (max-width: 600px) {
  .offline-indicator {
    bottom: 15px;
    padding: 10px 20px;
    font-size: 0.8rem;
    max-width: 90%;
    text-align: center;
  }
}

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen,
    Ubuntu, Cantarell, sans-serif;
  background: linear-gradient(135deg, #E07A5F 0%, #9D4EDD 100%);
  min-height: 100vh;
  padding: 20px;
}

.container {
  max-width: 1200px;
  margin: 0 auto;
}

/* ===== HEADER ===== */
.header {
  margin-bottom: 25px;
}

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

.logo-section {
  text-align: left;
}

.auth-section {
  display: flex;
  align-items: center;
}

.auth-buttons {
  display: flex;
  gap: 10px;
}

.auth-btn {
  padding: 10px 20px;
  border-radius: 25px;
  text-decoration: none;
  font-weight: 600;
  font-size: 0.9rem;
  transition: all 0.3s ease;
}

.login-btn {
  background: white;
  color: #E07A5F;
  border: 2px solid white;
}

.login-btn:hover {
  background: transparent;
  color: white;
}

.logout-btn {
  background: rgba(255, 255, 255, 0.2);
  color: white;
  border: 1px solid rgba(255, 255, 255, 0.5);
  padding: 8px 16px;
  font-size: 0.85rem;
}

.logout-btn:hover {
  background: rgba(255, 255, 255, 0.3);
}

.user-profile {
  display: flex;
  align-items: center;
  gap: 12px;
  background: rgba(255, 255, 255, 0.15);
  padding: 8px 15px;
  border-radius: 30px;
}

.user-avatar {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  border: 2px solid white;
  object-fit: cover;
}

.user-info {
  display: flex;
  flex-direction: column;
}

.user-name {
  color: white;
  font-weight: 600;
  font-size: 0.9rem;
}

.plan-badge-small {
  background: rgba(255, 255, 255, 0.3);
  color: white;
  padding: 2px 8px;
  border-radius: 10px;
  font-size: 0.7rem;
  font-weight: 600;
  text-transform: uppercase;
}

.plan-badge-small.student {
  background: linear-gradient(135deg, #667eea, #764ba2);
}

.plan-badge-small.pro {
  background: linear-gradient(135deg, #f6ad55, #ed8936);
}

.login-prompt-card {
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(20px);
  border-radius: 20px;
  padding: 40px;
  margin-bottom: 25px;
  text-align: center;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.5);
}

.login-prompt-content {
  max-width: 400px;
  margin: 0 auto;
}

.login-icon {
  font-size: 3rem;
  display: block;
  margin-bottom: 15px;
}

.login-prompt-card h3 {
  font-size: 1.5rem;
  color: #333;
  margin-bottom: 10px;
}

.login-prompt-card p {
  color: #666;
  margin-bottom: 20px;
  line-height: 1.5;
}

.login-benefits {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-bottom: 25px;
}

.benefit-item {
  color: #28a745;
  font-weight: 500;
}

.login-prompt-btn {
  display: inline-block;
  background: linear-gradient(135deg, #E07A5F, #9D4EDD);
  color: white;
  padding: 15px 30px;
  border-radius: 30px;
  text-decoration: none;
  font-weight: 700;
  font-size: 1rem;
  transition: all 0.3s ease;
  box-shadow: 0 4px 15px rgba(224, 122, 95, 0.3);
}

.login-prompt-btn:hover {
  transform: translateY(-3px);
  box-shadow: 0 8px 25px rgba(224, 122, 95, 0.4);
}

@media (max-width: 600px) {
  .header-content {
    flex-direction: column;
    text-align: center;
  }
  
  .logo-section {
    text-align: center;
  }
  
  .user-profile {
    flex-wrap: wrap;
    justify-content: center;
  }
}

.logo {
  font-size: 3.5rem;
  color: white;
  margin-bottom: 10px;
  font-weight: 700;
}

.tagline {
  color: rgba(255, 255, 255, 0.9);
  font-size: 1.1rem;
}

/* ===== USAGE SECTION ===== */
.usage-section {
  background: rgba(255, 255, 255, 0.9);
  backdrop-filter: blur(20px);
  border-radius: 15px;
  padding: 15px 25px;
  margin-bottom: 20px;
  display: flex;
  align-items: center;
  gap: 20px;
  flex-wrap: wrap;
  justify-content: center;
}

.usage-info {
  display: flex;
  align-items: center;
  gap: 10px;
}

.user-email {
  color: #666;
  font-size: 0.9rem;
}

.plan-badge {
  background: linear-gradient(135deg, #E07A5F, #9D4EDD);
  color: white;
  padding: 4px 12px;
  border-radius: 20px;
  font-size: 0.8rem;
  font-weight: 600;
}

.plan-badge.student {
  background: linear-gradient(135deg, #667eea, #764ba2);
}

.plan-badge.pro {
  background: linear-gradient(135deg, #f6ad55, #ed8936);
}

.usage-bar-wrapper {
  display: flex;
  align-items: center;
  gap: 10px;
  flex: 1;
  min-width: 200px;
}

.usage-bar {
  flex: 1;
  height: 10px;
  background: #e0e0e0;
  border-radius: 5px;
  overflow: hidden;
}

.usage-bar-fill {
  height: 100%;
  background: linear-gradient(90deg, #E07A5F, #9D4EDD);
  border-radius: 5px;
  transition: width 0.5s ease;
}

.usage-label {
  font-size: 0.85rem;
  color: #666;
  white-space: nowrap;
}

.upgrade-link {
  background: linear-gradient(135deg, #E07A5F, #9D4EDD);
  color: white;
  padding: 8px 20px;
  border-radius: 20px;
  text-decoration: none;
  font-weight: 600;
  font-size: 0.9rem;
  transition: all 0.2s;
}

.upgrade-link:hover {
  transform: translateY(-2px);
  box-shadow: 0 5px 15px rgba(224, 122, 95, 0.3);
}

/* ===== DASHBOARD USAGE TRACKER CARD ===== */
.usage-tracker-card {
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(20px);
  border-radius: 20px;
  padding: 25px;
  margin-bottom: 25px;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.5);
}

.usage-tracker-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 20px;
  padding-bottom: 15px;
  border-bottom: 2px solid #f0f0f0;
}

.usage-tracker-title {
  display: flex;
  align-items: center;
  gap: 10px;
}

.usage-tracker-title h3 {
  font-size: 1.3rem;
  color: #333;
  font-weight: 700;
}

.usage-icon {
  font-size: 1.5rem;
}

.plan-badge-large {
  background: linear-gradient(135deg, #E07A5F, #9D4EDD);
  color: white;
  padding: 8px 20px;
  border-radius: 25px;
  font-size: 0.95rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.plan-badge-large.student {
  background: linear-gradient(135deg, #667eea, #764ba2);
}

.plan-badge-large.pro {
  background: linear-gradient(135deg, #f6ad55, #ed8936);
}

.usage-tracker-body {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.usage-stats {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
}

@media (max-width: 500px) {
  .usage-stats {
    grid-template-columns: 1fr;
  }
}

.usage-stat {
  display: flex;
  align-items: center;
  gap: 15px;
  background: linear-gradient(135deg, #fdf2f4, #fff5f7);
  padding: 18px;
  border-radius: 15px;
  border: 1px solid rgba(224, 122, 95, 0.1);
}

.stat-icon {
  font-size: 2rem;
}

.stat-content {
  display: flex;
  flex-direction: column;
}

.stat-label {
  font-size: 0.85rem;
  color: #888;
  margin-bottom: 3px;
}

.stat-value {
  font-size: 1.4rem;
  font-weight: 700;
  color: #333;
}

.stat-value.unlimited {
  background: linear-gradient(135deg, #f6ad55, #ed8936);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.stat-value.warning {
  color: #e53e3e;
}

.usage-progress-section {
  background: #f8f9fa;
  padding: 20px;
  border-radius: 15px;
}

.usage-progress-labels {
  display: flex;
  justify-content: space-between;
  margin-bottom: 10px;
  font-size: 0.9rem;
  color: #666;
}

.usage-progress-bar {
  height: 16px;
  background: #e0e0e0;
  border-radius: 8px;
  overflow: hidden;
  box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.1);
}

.usage-progress-fill {
  height: 100%;
  background: linear-gradient(90deg, #E07A5F, #9D4EDD);
  border-radius: 8px;
  transition: width 0.5s ease, background 0.3s ease;
  min-width: 0;
}

.usage-progress-fill.warning {
  background: linear-gradient(90deg, #ed8936, #dd6b20);
}

.usage-progress-fill.danger {
  background: linear-gradient(90deg, #e53e3e, #c53030);
}

.usage-tracker-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 15px;
}

.reset-info {
  display: flex;
  align-items: center;
  gap: 8px;
  color: #666;
  font-size: 0.95rem;
}

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

.upgrade-btn-large {
  background: linear-gradient(135deg, #E07A5F, #9D4EDD);
  color: white;
  padding: 12px 28px;
  border-radius: 25px;
  text-decoration: none;
  font-weight: 700;
  font-size: 0.95rem;
  transition: all 0.3s ease;
  box-shadow: 0 4px 15px rgba(224, 122, 95, 0.3);
}

.upgrade-btn-large:hover {
  transform: translateY(-3px);
  box-shadow: 0 8px 25px rgba(224, 122, 95, 0.4);
}

.usage-warning {
  margin-top: 20px;
  padding: 15px 20px;
  background: linear-gradient(135deg, #fff5f5, #fed7d7);
  border: 2px solid #fc8181;
  border-radius: 12px;
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}

.warning-icon {
  font-size: 1.3rem;
}

.usage-warning span {
  color: #c53030;
  font-weight: 600;
}

.warning-upgrade-link {
  margin-left: auto;
  background: #e53e3e;
  color: white;
  padding: 8px 18px;
  border-radius: 20px;
  text-decoration: none;
  font-weight: 600;
  font-size: 0.9rem;
  transition: all 0.2s;
}

.warning-upgrade-link:hover {
  background: #c53030;
  transform: translateY(-2px);
}

/* ===== TAB NAVIGATION ===== */
.tab-navigation {
  display: flex;
  gap: 10px;
  margin-bottom: 30px;
  justify-content: center;
}

.pricing-tab {
  text-decoration: none;
}

.tab-btn {
  padding: 12px 30px;
  font-size: 1rem;
  font-weight: 600;
  border: none;
  border-radius: 12px;
  cursor: pointer;
  background: rgba(255, 255, 255, 0.2);
  color: white;
  transition: all 0.3s ease;
}

.tab-btn:hover {
  background: rgba(255, 255, 255, 0.3);
  transform: translateY(-2px);
}

.tab-btn.active {
  background: white;
  color: #E07A5F;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
}

#noteCount {
  font-size: 0.9rem;
  opacity: 0.8;
}

/* ===== TAB CONTENT ===== */
.tab-content {
  display: none;
}

.tab-content.active {
  display: block;
}

/* ===== UPLOAD SECTION ===== */
.upload-section {
  background: rgba(255, 255, 255, 0.9);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-radius: 24px;
  padding: 40px;
  margin-bottom: 30px;
  border: 1px solid rgba(255, 255, 255, 0.7);
  box-shadow: 
    0 20px 60px rgba(0, 0, 0, 0.15),
    0 8px 25px rgba(0, 0, 0, 0.1),
    inset 0 1px 0 rgba(255, 255, 255, 1);
}

.section-title {
  font-size: 1.5rem;
  margin-bottom: 25px;
  color: #333;
}

.input-group {
  margin-bottom: 20px;
}

.input-label {
  display: block;
  margin-bottom: 8px;
  font-weight: 600;
  color: #555;
  font-size: 0.95rem;
}

.icon {
  margin-right: 8px;
}

.file-input,
.text-input {
  width: 100%;
  padding: 12px;
  border: 2px solid #e0e0e0;
  border-radius: 10px;
  font-size: 1rem;
  transition: border-color 0.3s;
}

.file-input:focus,
.text-input:focus {
  outline: none;
  border-color: #E07A5F;
}

.file-name {
  margin-top: 8px;
  color: #E07A5F;
  font-size: 0.9rem;
}

.file-type-hint {
  margin-top: 6px;
  color: #888;
  font-size: 0.8rem;
  font-style: italic;
}

.divider {
  text-align: center;
  margin: 20px 0;
  position: relative;
}

.divider::before,
.divider::after {
  content: "";
  position: absolute;
  top: 50%;
  width: 45%;
  height: 1px;
  background: #e0e0e0;
}

.divider::before {
  left: 0;
}

.divider::after {
  right: 0;
}

.divider-text {
  color: #999;
  font-weight: 600;
  background: white;
  padding: 0 15px;
  position: relative;
}

.upload-btn {
  width: 100%;
  padding: 15px;
  font-size: 1.1rem;
  font-weight: 600;
  border: none;
  border-radius: 12px;
  background: linear-gradient(135deg, #E07A5F 0%, #9D4EDD 100%);
  color: white;
  cursor: pointer;
  transition: transform 0.2s, box-shadow 0.2s;
  margin-top: 10px;
}

.upload-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 5px 20px rgba(224, 122, 95, 0.4);
}

.upload-btn:disabled {
  background: #ccc;
  cursor: not-allowed;
  transform: none;
}

/* ===== PROGRESS SPINNER ===== */
.progress-container {
  margin-top: 25px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
}

.spinner-wrapper {
  display: flex;
  justify-content: center;
  align-items: center;
}

.spinner {
  width: 50px;
  height: 50px;
  border: 4px solid #f0f0f0;
  border-top: 4px solid #E07A5F;
  border-radius: 50%;
  animation: spin 1s linear infinite;
}

@keyframes spin {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

.status-message {
  margin: 0;
  text-align: center;
  color: #333;
  font-weight: 600;
  font-size: 1rem;
}

.progress-percent {
  margin: 0;
  text-align: center;
  color: #E07A5F;
  font-weight: 700;
  font-size: 0.9rem;
}

.time-estimate {
  margin: 0;
  text-align: center;
  color: #666;
  font-size: 0.85rem;
  font-style: italic;
}

/* ===== RESULT SECTION ===== */
.result-section {
  background: rgba(255, 255, 255, 0.9);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-radius: 24px;
  padding: 40px;
  /* Mobile responsiveness: prevent content overflow */
  box-sizing: border-box;
  max-width: 100%;
  overflow-x: hidden;
  border: 1px solid rgba(255, 255, 255, 0.7);
  box-shadow: 
    0 20px 60px rgba(0, 0, 0, 0.15),
    0 8px 25px rgba(0, 0, 0, 0.1),
    inset 0 1px 0 rgba(255, 255, 255, 1);
}

.result-header {
  margin-bottom: 20px;
  padding-bottom: 20px;
  border-bottom: 2px solid #f0f0f0;
}

.result-title {
  font-size: 1.8rem;
  color: #333;
  margin-bottom: 10px;
}

.result-info {
  color: #999;
  font-size: 0.9rem;
}

.detail-actions {
  margin-top: 15px;
  display: flex;
  gap: 10px;
}

.action-btn {
  padding: 10px 20px;
  border: none;
  border-radius: 10px;
  cursor: pointer;
  font-weight: 600;
  display: flex;
  align-items: center;
  gap: 8px;
  transition: transform 0.2s;
}

.action-btn:hover {
  transform: translateY(-2px);
}

.export-btn {
  background: #E07A5F;
  color: white;
}

.delete-btn {
  background: #e53e3e;
  color: white;
}

.result-card {
  margin-bottom: 30px;
  background: rgba(255, 255, 255, 0.6);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border-radius: 18px;
  padding: 24px;
  border: 1px solid rgba(255, 255, 255, 0.5);
  box-shadow: 
    0 4px 24px rgba(0, 0, 0, 0.08),
    inset 0 1px 0 rgba(255, 255, 255, 0.8);
  /* Mobile responsiveness: ensure content stays within bounds */
  box-sizing: border-box;
  max-width: 100%;
  overflow-x: hidden;
  transition: all 0.3s ease;
}

.result-card:hover {
  box-shadow: 
    0 8px 32px rgba(0, 0, 0, 0.12),
    inset 0 1px 0 rgba(255, 255, 255, 0.9);
  transform: translateY(-2px);
}

.result-card:last-child {
  margin-bottom: 0;
}

.card-header {
  font-size: 1.3rem;
  color: #E07A5F;
  margin-bottom: 15px;
  font-weight: 700;
  display: flex;
  align-items: center;
  gap: 10px;
}

.card-header::before {
  content: '';
  width: 4px;
  height: 24px;
  background: linear-gradient(180deg, #E07A5F, #9D4EDD);
  border-radius: 2px;
}

.card-content {
  background: linear-gradient(135deg, rgba(248, 249, 250, 0.9) 0%, rgba(255, 255, 255, 0.95) 100%);
  backdrop-filter: blur(5px);
  -webkit-backdrop-filter: blur(5px);
  padding: 24px;
  border-radius: 14px;
  font-size: 0.95rem;
  line-height: 1.8;
  color: #333;
  border: 1px solid rgba(224, 122, 95, 0.08);
  box-shadow: 
    0 2px 12px rgba(0, 0, 0, 0.04),
    inset 0 1px 0 rgba(255, 255, 255, 1);
  /* Mobile responsiveness: prevent content overflow */
  box-sizing: border-box;
  max-width: 100%;
  overflow-x: hidden;
  word-wrap: break-word;
  overflow-wrap: break-word;
}

.transcript-content {
  position: relative;
  color: #555;
}

.notes-content {
  white-space: pre-wrap;
  color: #333;
  line-height: 1.9;
  /* Mobile responsiveness: prevent content overflow */
  word-wrap: break-word;
  overflow-wrap: break-word;
  word-break: break-word;
  max-width: 100%;
  overflow-x: hidden;
}

/* ===== ENHANCED NOTE STYLING ===== */
.notes-content strong,
.notes-content b {
  color: #E07A5F;
  font-weight: 700;
}

.notes-content em,
.notes-content i {
  color: #9D4EDD;
  font-style: italic;
}

.notes-content u {
  text-decoration: underline;
  text-decoration-color: #E07A5F;
  text-decoration-thickness: 2px;
}

/* Notes table styling */
.notes-table {
  width: 100%;
  border-collapse: collapse;
  margin: 20px 0;
  font-size: 0.95rem;
  background: #fff;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
  border: 1px solid #e0e0e0;
}

.notes-table thead {
  background: linear-gradient(135deg, #E07A5F 0%, #9D4EDD 100%);
}

.notes-table th {
  color: white;
  font-weight: 600;
  text-align: left;
  padding: 14px 16px;
  border-bottom: 2px solid #b01049;
}

.notes-table td {
  padding: 12px 16px;
  border-bottom: 1px solid #eee;
  vertical-align: top;
}

.notes-table tbody tr:last-child td {
  border-bottom: none;
}

.notes-table tbody tr:nth-child(even) {
  background: #fafafa;
}

.notes-table tbody tr:hover {
  background: #fff5f8;
}

.notes-table td strong {
  color: #E07A5F;
}

.notes-table td.term-cell {
  font-weight: 700;
  color: #E07A5F;
  background: #fff5f8;
  white-space: nowrap;
}

/* Style section dividers */
.notes-content::after {
  content: "";
  display: block;
}

.toggle-btn {
  display: block;
  margin-top: 10px;
  padding: 8px 16px;
  background: #E07A5F;
  color: white;
  border: none;
  border-radius: 8px;
  cursor: pointer;
  font-size: 0.9rem;
  transition: background 0.2s;
}

.toggle-btn:hover {
  background: #b01049;
}

/* ===== SEARCH SECTION ===== */
.search-section {
  background: rgba(255, 255, 255, 0.9);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-radius: 18px;
  padding: 20px;
  margin-bottom: 20px;
  border: 1px solid rgba(255, 255, 255, 0.7);
  box-shadow: 
    0 12px 40px rgba(0, 0, 0, 0.12),
    0 4px 15px rgba(0, 0, 0, 0.08),
    inset 0 1px 0 rgba(255, 255, 255, 1);
}

.search-container {
  position: relative;
}

.search-icon {
  position: absolute;
  left: 15px;
  top: 50%;
  transform: translateY(-50%);
  font-size: 1.2rem;
}

.search-input {
  width: 100%;
  padding: 12px 12px 12px 45px;
  border: 2px solid #e0e0e0;
  border-radius: 12px;
  font-size: 1rem;
  transition: border-color 0.3s;
}

.search-input:focus {
  outline: none;
  border-color: #E07A5F;
}

/* ===== NOTES GRID ===== */
.notes-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 20px;
}

.note-card {
  background: rgba(255, 255, 255, 0.85);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-radius: 20px;
  padding: 24px;
  border: 1px solid rgba(255, 255, 255, 0.6);
  box-shadow: 
    0 8px 32px rgba(0, 0, 0, 0.12),
    0 2px 8px rgba(0, 0, 0, 0.06),
    inset 0 1px 0 rgba(255, 255, 255, 0.9);
  transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
  cursor: pointer;
  position: relative;
  overflow: hidden;
}

.note-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: linear-gradient(90deg, #E07A5F, #ff6b9d, #9D4EDD);
  opacity: 0;
  transition: opacity 0.3s ease;
}

.note-card:hover {
  transform: translateY(-8px) scale(1.02);
  box-shadow: 
    0 20px 60px rgba(224, 122, 95, 0.2),
    0 8px 25px rgba(0, 0, 0, 0.15),
    inset 0 1px 0 rgba(255, 255, 255, 1);
  border-color: rgba(224, 122, 95, 0.3);
}

.note-card:hover::before {
  opacity: 1;
}

.note-card:active {
  transform: translateY(-4px) scale(1.01);
}

.note-header {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 12px;
}

.note-icon {
  font-size: 1.5rem;
}

.note-title {
  font-size: 1.1rem;
  color: #333;
  font-weight: 600;
  flex: 1;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.note-date {
  display: flex;
  align-items: center;
  gap: 5px;
  color: #999;
  font-size: 0.85rem;
  margin-bottom: 12px;
}

.note-preview {
  color: #666;
  font-size: 0.9rem;
  line-height: 1.4;
  margin-bottom: 15px;
  overflow: hidden;
  text-overflow: ellipsis;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

.note-actions {
  display: flex;
  gap: 10px;
}

.note-btn {
  flex: 1;
  padding: 8px;
  border: none;
  border-radius: 8px;
  cursor: pointer;
  font-size: 0.85rem;
  font-weight: 600;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 5px;
  transition: transform 0.2s;
}

.note-btn:hover {
  transform: translateY(-2px);
}

.export-note-btn {
  background: #E07A5F;
  color: white;
}

.delete-note-btn {
  padding: 8px 12px;
  background: #e53e3e;
  color: white;
}

/* ===== EMPTY STATE ===== */
.empty-state {
  background: rgba(255, 255, 255, 0.9);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-radius: 24px;
  padding: 60px;
  text-align: center;
  border: 1px solid rgba(255, 255, 255, 0.7);
  box-shadow: 
    0 20px 60px rgba(0, 0, 0, 0.15),
    0 8px 25px rgba(0, 0, 0, 0.1),
    inset 0 1px 0 rgba(255, 255, 255, 1);
}

.empty-icon {
  font-size: 3rem;
  margin-bottom: 20px;
}

.empty-title {
  font-size: 1.5rem;
  color: #333;
  margin-bottom: 10px;
}

.empty-text {
  color: #999;
}

/* ===== NOTE DETAIL VIEW ===== */
.note-detail {
  animation: fadeIn 0.3s ease;
}

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

.back-btn {
  background: white;
  color: #E07A5F;
  border: none;
  padding: 10px 20px;
  border-radius: 10px;
  cursor: pointer;
  margin-bottom: 20px;
  display: flex;
  align-items: center;
  gap: 8px;
  font-weight: 600;
  transition: transform 0.2s;
}

.back-btn:hover {
  transform: translateX(-5px);
}

/* ===== RESPONSIVE ===== */
@media (max-width: 768px) {
  .sidebar {
    transform: translateX(-240px);
  }
  
  .sidebar:not(.collapsed) {
    transform: translateX(0);
  }
  
  .sidebar-toggle {
    left: 10px;
    border-radius: 8px;
  }
  
  .sidebar-toggle:not(.shifted) {
    left: 10px;
  }
  
  .container.with-sidebar {
    margin-left: 0;
  }
  
  .container {
    padding: 10px;
  }

  .logo {
    font-size: 2.5rem;
  }

  .upload-section,
  .result-section,
  .search-section,
  .empty-state {
    padding: 20px;
  }

  .tab-navigation {
    flex-direction: column;
  }

  .tab-btn {
    width: 100%;
  }

  .notes-grid {
    grid-template-columns: 1fr;
  }

  .detail-actions {
    flex-direction: column;
  }

  .action-btn {
    width: 100%;
    justify-content: center;
  }

  /* Mobile notes content fixes */
  .result-section {
    padding: 15px;
    border-radius: 16px;
  }

  .result-card {
    padding: 16px;
    border-radius: 14px;
  }

  .card-content {
    padding: 16px;
    font-size: 0.9rem;
    line-height: 1.7;
  }

  .notes-content {
    font-size: 0.9rem;
    line-height: 1.7;
  }

  .card-header {
    font-size: 1.1rem;
  }

  .result-title {
    font-size: 1.4rem;
    word-break: break-word;
  }
}

/* ===== EXPORT MODAL ===== */
.export-modal {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.6);
  display: flex;
  justify-content: center;
  align-items: center;
  z-index: 1000;
  animation: fadeIn 0.2s ease;
}

.export-modal-content {
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(25px);
  -webkit-backdrop-filter: blur(25px);
  border-radius: 24px;
  padding: 30px;
  max-width: 400px;
  width: 90%;
  border: 1px solid rgba(255, 255, 255, 0.8);
  box-shadow: 
    0 25px 80px rgba(0, 0, 0, 0.3),
    0 10px 30px rgba(0, 0, 0, 0.2),
    inset 0 1px 0 rgba(255, 255, 255, 1);
  animation: slideUp 0.3s ease;
}

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

.export-option-btn {
  width: 100%;
  padding: 15px;
  margin-bottom: 10px;
  border: none;
  border-radius: 12px;
  font-size: 1rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
}

.export-option-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
}

.pdf-btn {
  background: linear-gradient(135deg, #E07A5F 0%, #9D4EDD 100%);
  color: white;
}

.txt-btn {
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  color: white;
}

.cancel-btn {
  background: #f0f0f0;
  color: #666;
  margin-bottom: 0;
}

.cancel-btn:hover {
  background: #e0e0e0;
}

/* ===== PREMIUM ANIMATIONS & MICRO-INTERACTIONS ===== */

/* Skeleton Loader */
.skeleton {
  background: linear-gradient(90deg, #f0f0f0 25%, #e0e0e0 50%, #f0f0f0 75%);
  background-size: 200% 100%;
  animation: shimmer 1.5s infinite;
  border-radius: 8px;
}

.skeleton-card {
  background: rgba(255, 255, 255, 0.9);
  border-radius: 16px;
  padding: 20px;
  margin-bottom: 15px;
}

.skeleton-title {
  height: 24px;
  width: 70%;
  margin-bottom: 12px;
}

.skeleton-text {
  height: 14px;
  width: 100%;
  margin-bottom: 8px;
}

.skeleton-text.short {
  width: 40%;
}

.skeleton-text.medium {
  width: 60%;
}

@keyframes shimmer {
  0% { background-position: -200% 0; }
  100% { background-position: 200% 0; }
}

/* Ripple Effect */
.ripple {
  position: relative;
  overflow: hidden;
}

.ripple::after {
  content: '';
  position: absolute;
  width: 100%;
  height: 100%;
  top: 0;
  left: 0;
  pointer-events: none;
  background-image: radial-gradient(circle, rgba(255, 255, 255, 0.4) 10%, transparent 10.01%);
  background-repeat: no-repeat;
  background-position: 50%;
  transform: scale(10, 10);
  opacity: 0;
  transition: transform 0.5s, opacity 0.8s;
}

.ripple:active::after {
  transform: scale(0, 0);
  opacity: 0.3;
  transition: 0s;
}

/* Button Hover Scale */
.note-action-btn {
  transition: all 0.2s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.note-action-btn:hover {
  transform: scale(1.1);
}

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

/* Fade In Animation for Notes */
.note-card {
  animation: fadeInUp 0.4s ease-out forwards;
  opacity: 0;
}

.note-card:nth-child(1) { animation-delay: 0.05s; }
.note-card:nth-child(2) { animation-delay: 0.1s; }
.note-card:nth-child(3) { animation-delay: 0.15s; }
.note-card:nth-child(4) { animation-delay: 0.2s; }
.note-card:nth-child(5) { animation-delay: 0.25s; }
.note-card:nth-child(6) { animation-delay: 0.3s; }

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

/* Progress Bar Pulse Animation */
.usage-bar-fill.loading,
.progress-fill.loading {
  animation: pulse 1.5s ease-in-out infinite, progressGlow 2s ease-in-out infinite;
}

@keyframes pulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.7; }
}

@keyframes progressGlow {
  0%, 100% {
    box-shadow: 0 0 5px rgba(224, 122, 95, 0.5);
  }
  50% {
    box-shadow: 0 0 20px rgba(224, 122, 95, 0.8), 0 0 30px rgba(224, 122, 95, 0.4);
  }
}

/* Typing Animation Container */
.typing-animation {
  overflow: hidden;
}

.typing-cursor {
  display: inline-block;
  width: 2px;
  height: 1em;
  background: #E07A5F;
  margin-left: 2px;
  animation: blink 0.7s infinite;
  vertical-align: text-bottom;
}

@keyframes blink {
  0%, 50% { opacity: 1; }
  51%, 100% { opacity: 0; }
}

/* Primary Button with Ripple */
.primary-btn {
  position: relative;
  overflow: hidden;
  transition: all 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.primary-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 10px 30px rgba(224, 122, 95, 0.4);
}

.primary-btn:active {
  transform: translateY(0);
}

/* Tab Button Transitions */
.tab-btn {
  transition: all 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.tab-btn:hover:not(.active) {
  transform: translateY(-2px);
  background: rgba(255, 255, 255, 0.95);
}

.tab-btn.active {
  animation: tabPop 0.3s ease-out;
}

@keyframes tabPop {
  0% { transform: scale(0.95); }
  50% { transform: scale(1.02); }
  100% { transform: scale(1); }
}

/* Card Hover Effect */
.note-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.15);
  transition: all 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

/* Smooth Content Reveal */
.content-reveal {
  animation: contentReveal 0.5s ease-out forwards;
}

@keyframes contentReveal {
  from {
    opacity: 0;
    filter: blur(10px);
    transform: scale(0.98);
  }
  to {
    opacity: 1;
    filter: blur(0);
    transform: scale(1);
  }
}

/* Loading Spinner Enhancement */
.loading-spinner {
  width: 40px;
  height: 40px;
  border: 3px solid rgba(224, 122, 95, 0.2);
  border-top-color: #E07A5F;
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

/* Success Checkmark Animation */
.success-check {
  animation: successPop 0.5s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

@keyframes successPop {
  0% { transform: scale(0); opacity: 0; }
  50% { transform: scale(1.2); }
  100% { transform: scale(1); opacity: 1; }
}

/* Input Focus Animation */
input:focus,
textarea:focus {
  animation: focusGlow 0.3s ease-out forwards;
}

@keyframes focusGlow {
  from {
    box-shadow: 0 0 0 0 rgba(224, 122, 95, 0.4);
  }
  to {
    box-shadow: 0 0 0 4px rgba(224, 122, 95, 0.1);
  }
}

/* Staggered List Animation */
.stagger-item {
  opacity: 0;
  animation: staggerIn 0.4s ease-out forwards;
}

.stagger-item:nth-child(1) { animation-delay: 0.1s; }
.stagger-item:nth-child(2) { animation-delay: 0.2s; }
.stagger-item:nth-child(3) { animation-delay: 0.3s; }
.stagger-item:nth-child(4) { animation-delay: 0.4s; }
.stagger-item:nth-child(5) { animation-delay: 0.5s; }

@keyframes staggerIn {
  from {
    opacity: 0;
    transform: translateX(-20px);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

/* Smooth GPU-accelerated transitions */
.note-card,
.primary-btn,
.tab-btn,
.auth-btn,
.note-action-btn {
  will-change: transform;
  transform: translateZ(0);
  backface-visibility: hidden;
}

/* ===== APP FOOTER ===== */
.app-footer {
  margin-top: 40px;
  padding: 25px 20px;
  text-align: center;
  border-top: 1px solid rgba(255, 255, 255, 0.15);
}

.app-footer .footer-links {
  display: flex;
  justify-content: center;
  gap: 20px;
  flex-wrap: wrap;
  margin-bottom: 12px;
}

.app-footer .footer-links a {
  color: rgba(255, 255, 255, 0.7);
  text-decoration: none;
  font-size: 0.85rem;
  transition: color 0.2s;
}

.app-footer .footer-links a:hover {
  color: white;
}

.app-footer .footer-copyright {
  color: rgba(255, 255, 255, 0.5);
  font-size: 0.8rem;
}