/* Universal App Classes */
:root {
    /* --primary: #6a11cb; */
    --primary: #0f2e61;
    --secondary: #3B71CA;
    --light: #f8f9fa;
    --dark: #343a40;
    --success: #14A44D;
    --danger: #DC4C64;
    --warning: #E4A11B;
    --info: #54B4D3;
    --border-radius: 10px;
    --box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
    --transition: all 0.3s ease;
}

body {
  /* background: linear-gradient(45deg, #6e8efb, #a777e3); */
  background: #f8f9fa;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  overflow-x: hidden;
}

.mobile-container {
  width: 100%;
  max-width: 400px;
  margin: 0 auto;
  background-color: #f8f9fa;
  /*border-radius: 20px;*/
  /* box-shadow: 0 10px 30px rgba(0, 0, 0, 0.15); */
  overflow: hidden;
  padding: 10px;
  min-height: 600px;
  height: 100vh;
  position: relative;
}

.app-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 20px 20px;
  background-color: var(--primary);
  color: var(--light);
  box-shadow: var(--box-shadow);
  border-radius: var(--border-radius);
}

.app-bottom-navbar {
    display: flex;
    justify-content: space-around;
    left: 50%;
    transform: translateX(-50%);
    background: linear-gradient(to right, var(--primary), var(--secondary));
    color: rgba(255, 255, 255, 0.596);
    padding: 8px 0;
    position: fixed;
    bottom: 0;
    width: 400px;
    align-items: center;
    /* border-radius: 5px; */
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
    z-index: 1000;
    transition: opacity 0.3s ease-in-out;
  }

.app-bottom-navbar .app-nav-link {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-decoration: none;
  color: #6c757d;
  padding: 8px 12px;
  border-radius: 8px;
  transition: all 0.3s ease;
  font-size: 12px;
  min-width: 60px;
}

.app-content {
  flex: 1;
  /* padding: 20px; */
  /* display: flex; */
  flex-direction: column;
  align-items: center;
  justify-content: center;
}

.app-text-primary {
    color: var(--primary)!important;
}

/* app-nav-link icon must be above text */

.app-bottom-navbar .app-nav-link.active {
    color: white;
    font-weight: bold;
}

.app-bottom-navbar .app-nav-link:hover {
    color: white;
}

.app-bottom-navbar-content {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.app-nav-link i {
  font-size: 20px;
  margin-bottom: 2px;
  transition: all 0.3s ease;
}

.app-nav-link .navbar-text {
    flex-grow: 1;
    font-size: 12px;
}


.app-primary-bg {
  /* background: linear-gradient(45deg, var(--primary), var(--secondary)); */
  background: linear-gradient(to right, var(--primary), var(--secondary));
  color: var(--light);
}

.app-header {
  text-align: center;
  padding: 15px 0;
  border-bottom: 1px solid #f0f0f0;
  margin-bottom: 20px;
}

.app-icon {
  width: 60px;
  height: 60px;
  background: linear-gradient(45deg, var(--secondary), var(--primary));
  border-radius: 15px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 10px;
  color: white;
  font-size: 24px;
}

.feature-card {
  transition: transform 0.3s, box-shadow 0.3s;
  border-radius: 12px;
  border: none;
  margin-bottom: 15px;
  cursor: pointer;
}

.feature-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

.app-title {
  font-weight: 600;
  color: var(--dark);
  margin-bottom: 5px;
}

.card-title {
  font-weight: 600;
  color: var(--dark);
}

.feature-card i {
  font-size: 24px;
  /* color: var(--primary); */
  /* margin-right: 10px; */
}

/* .app-nav-tabs {
  background-color: #f8f9fa;
  border-radius: 50px;
  padding: 5px;
  margin-bottom: 20px;
}

.app-nav-link {
  border-radius: 50px;
  font-weight: 500;
}

.app-nav-link.active {
  background: linear-gradient(45deg, #6e8efb, #a777e3);
  color: white;
} */

.app-footer {
  text-align: center;
  padding: 15px 0;
  margin-top: auto;
  color: #6c757d;
  font-size: 14px;
}

.status-bar {
  display: flex;
  justify-content: space-between;
  padding: 10px 15px;
  background-color: #f8f9fa;
  border-radius: 10px 10px 0 0;
  margin: -20px -20px 20px -20px;
  font-size: 14px;
  color: #495057;
}

.btn-mobile {
  border-radius: 50px;
  padding: 10px 20px;
  font-weight: 500;
  background: linear-gradient(45deg, var(--secondary), var(--primary));
  border: none;
  width: 100%;
  margin-top: 10px;
}

.app-bg-gradient {
    background: linear-gradient(to right, var(--primary), var(--secondary));
    min-height: 100vh;
}

.app-content-container {
    background: white;
    border-radius: 15px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    padding: 30px;
    max-width: 500px;
    width: 100%;
    text-align: center;
}

.app-card {
    width: 100%;
    max-width: 400px;
    background-color: #fff;
    border-radius: 20px;
    box-shadow: var(--box-shadow);
    overflow: hidden;
    padding: 25px;
}

.app-header {
    text-align: center;
    padding: 15px 0;
    margin-bottom: 20px;
}

.scrollable-content {
    max-height: 48vh;
    overflow-y: auto;
    padding-bottom: 40px;
}

.scrollable-container {
    max-height: 100vh;
    overflow-y: auto;
    padding-bottom: 40px;
}

.app-icon {
    width: 70px;
    height: 70px;
    background: linear-gradient(45deg, var(--primary), var(--secondary));
    border-radius: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 15px;
    color: white;
    font-size: 28px;
    box-shadow: 0 5px 15px rgba(17, 60, 203, 0.3);
}

.app-title {
    font-weight: 600;
    color: var(--light);
    margin-bottom: 5px;
}

.app-subtitle {
    color: #6c757d;
    font-size: 0.9rem;
}

.app-form-control {
    border-radius: var(--border-radius);
    padding: 12px 16px;
    border: 2px solid #e9ecef;
    transition: var(--transition);
}

.app-form-control:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 0.25rem rgba(106, 17, 203, 0.25);
}

.app-form-select {
    border-radius: var(--border-radius);
    padding: 12px 20px;
    border: 2px solid #e9ecef;
    transition: var(--transition);
}

.app-form-select:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 0.25rem rgba(17, 60, 203, 0.3);
}

.app-input-group {
    margin-bottom: 1rem;
}

.app-input-group-text {
    background: transparent;
    border-radius: var(--border-radius) 0 0 var(--border-radius);
    border: 2px solid #e9ecef;
    /*border-right: none;*/
}

.app-btn-primary {
    background: linear-gradient(to right, var(--primary), var(--secondary));
    border: none;
    color: white;
    padding: 12px;
    border-radius: var(--border-radius);
    font-weight: 600;
    /* margin-top: 10px; */
    transition: var(--transition);
    box-shadow: 0 5px 15px rgba(17, 60, 203, 0.3);;
}

.app-btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(17, 60, 203, 0.4);
}

.app-btn-primary-outlined {
    background: transparent;
    border: 2px solid var(--primary);
    color: var(--primary);
}

.app-btn-primary-outlined:hover {
    background: var(--primary);
    color: white;
}

.app-btn-primary:disabled {
    background: #e9ecef!important;
    color: #6c757d!important;
    cursor: not-allowed;
}

.app-btn-block {
    display: block;
    width: 100%;
}

.app-btn-xs {
  padding: .25rem .4rem;
  font-size: .875rem;
  line-height: .5;
  border-radius: .2rem;
}

.app-divider {
    display: flex;
    align-items: center;
    margin: 20px 0;
}

.app-divider::before, .app-divider::after {
    content: '';
    flex: 1;
    height: 1px;
    background: #e9ecef;
}

.app-divider span {
    padding: 0 15px;
    color: #6c757d;
    font-size: 14px;
}

.app-social-login {
    display: flex;
    justify-content: center;
    gap: 15px;
    margin-bottom: 20px;
}

.app-social-btn {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 20px;
    transition: var(--transition);
}

.app-social-facebook {
    background: #3b5998;
}

.app-social-google {
    background: #dd4b39;
}

.app-social-twitter {
    background: #1da1f2;
}

.app-social-btn:hover {
    transform: translateY(-3px);
    opacity: 0.9;
}

.app-remember-forgot {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin: 15px 0;
}

.app-form-check-input:checked {
    background-color: var(--primary);
    border-color: var(--primary);
}

.app-link {
    color: var(--primary);
    text-decoration: none;
    font-size: 14px;
    transition: var(--transition);
}

.app-link:hover {
    color: var(--secondary);
    text-decoration: underline;
}

.app-footer {
    text-align: center;
    padding: 15px 0;
    margin-top: 20px;
    color: #6c757d;
    font-size: 14px;
    border-top: 1px solid #e9ecef;
}

.app-invalid-feedback {
    display: block;
    margin-top: 5px;
    font-size: 14px;
    color: var(--danger);
}

.app-snackbar {
    position: fixed;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%);
    width: 380px;
    background-color: #343a40;
    color: white;
    padding: 15px 20px;
    border-radius: 5px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
    z-index: 1000;
    transition: opacity 0.3s ease-in-out;
}

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

.app-snackbar i {
    font-size: 20px;
    margin-right: 10px;
}

.app-snackbar button {
    background: none;
    border: none;
    color: white;
    font-size: 20px;
    cursor: pointer;
}

.app-snackbar button:hover {
    color: #adb5bd;
}

.app-snackbar #snackbar-message {
    flex-grow: 1;
}

.app-snackbar-progress {
    height: 4px;
    background-color: #6c757d;
    border-radius: 2px;
    width: 100%;
    position: absolute;
    bottom: 0;
    left: 0;
    transition: width 0.3s ease-in-out;
}

.app-button {
    border: none;
    background: none;
    padding: 0;
    cursor: pointer;
    max-width: 340px!important;
}

/* position and style alert dismiss button */
.alert .btn-close {
    position: absolute;
    top: 10px;
    right: 10px;
    border: none;
    /* background: none; */
    color: #6c757d;
    font-size: 10px;
    cursor: pointer;
}

.alert .btn-close:hover {
    color: #dc3545;
}

/* build listview */

.app-list-view {
    list-style: none;
    padding: 0;
    margin: 0;
    width: 100%;
}

.app-text-bold {
    font-weight: 600;
}

.app-list-tile {
    display: flex;
    align-items: center;
    padding: 15px;
    border-bottom: 1px solid #e9ecef;
    transition: var(--transition);
    position: relative;
}

.app-list-tile:hover {
    background-color: rgba(106, 17, 203, 0.05);
}

.app-list-tile .app-list-item {
    flex: 1;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
}

.app-list-tile .app-list-item .leading {
    font-weight: 600;
    font-size: 16px;
    margin-right: 15px;
    color: var(--dark);
    min-width: 200px;
}

.app-list-tile .app-list-item .subtitle {
    color: var(--muted);
    font-size: 14px;
    margin-top: 5px;
    width: 100%;
}

/* Trailing element - floats to the center right */
.app-list-tile .trailing {
    margin-left: 15px;
    font-size: 14px;
    position: absolute;
    right: 15px;
    top: 50%;
    transform: translateY(-50%);
}

.badge {
    padding: 8px 12px;
    border-radius: 20px;
    font-weight: 600;
    font-size: 12px;
}

.bg-success {
    background: linear-gradient(45deg, var(--success), #20c997);
}

.bg-warning {
    background: linear-gradient(45deg, var(--warning), #fd7e14);
}

.filter-container {
    display: flex;
    justify-content: flex-end;
    margin-bottom: 20px;
    gap: 10px;
}

.filter-btn {
    border: none;
    padding: 8px 15px;
    border-radius: 20px;
    font-size: 14px;
    cursor: pointer;
    transition: var(--transition);
}

.filter-btn.active {
    background: linear-gradient(45deg, var(--primary), var(--secondary));
    color: white;
}

.empty-state {
    text-align: center;
    padding: 40px 0;
    color: var(--muted);
}

.empty-state i {
    font-size: 50px;
    margin-bottom: 15px;
    opacity: 0.5;
}

.cancel-container {
    background: white;
    border-radius: 15px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    padding: 30px;
    max-width: 500px;
    width: 100%;
    text-align: center;
}

.cancel-icon {
    font-size: 80px;
    color: var(--danger);
    margin-bottom: 20px;
}

.success-container {
    background: white;
    border-radius: 15px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    padding: 30px;
    max-width: 500px;
    width: 100%;
    text-align: center;
}

.success-icon {
    font-size: 80px;
    color: var(--success);
    margin-bottom: 20px;
}

.error-icon {
    font-size: 80px;
    color: var(--danger);
    margin-bottom: 20px;
}

.info-icon {
    font-size: 80px;
    color: var(--info);
    margin-bottom: 20px;
}

.success-title {
    color: var(--dark);
    font-weight: 700;
    margin-bottom: 15px;
}

.cancel-message {
    color: var(--muted);
    margin-bottom: 25px;
    font-size: 16px;
}

.order-info {
    background-color: #f8f9fa;
    border-radius: 10px;
    padding: 15px;
    margin-bottom: 25px;
}

.options-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.options-list li {
    margin-bottom: 10px;
}

.options-list a {
    display: block;
    padding: 12px 20px;
    background: linear-gradient(45deg, var(--primary), var(--secondary));
    color: white;
    text-decoration: none;
    border-radius: 8px;
    font-weight: 600;
    transition: all 0.3s ease;
}

.options-list a:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(17, 60, 203, 0.3);;
}

.app-notifications-menu {
    position: absolute;
    top: 60px;
    right: 20px;
    width: 300px;
    background: white;
    border-radius: 15px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    z-index: 1000;
    max-height: 400px;
    overflow-y: auto;
}

.app-notifications-menu::before {
    content: '';
    position: absolute;
    top: -10px;
    right: 20px;
    border-width: 0 10px 10px 10px;
    border-style: solid;
    border-color: transparent transparent white transparent;
}

.app-notifications-menu .app-list-view {
    max-height: 400px;
    overflow-y: auto;
}

.app-notifications-menu .app-list-item {
    flex-direction: column;
    align-items: flex-start;
    font-size: 12px!important;
    font-weight: 500!important;
}

.app-user-menu {
    position: absolute;
    top: 60px;
    right: 20px;
    width: 200px;
    background: white;
    border-radius: 15px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    z-index: 1000;
}

.app-user-menu .app-user-menu-item {
    padding: 12px 20px;
    border-bottom: 1px solid #eee;
    cursor: pointer;
    transition: background 0.3s ease;
    color: var(--dark);
}

.app-user-menu .app-user-menu-item:hover {
    background: #f8f9fa;
}

.app-rounded-circle {
    width: 80px;
    height: 80px;
    border-radius: 50%;
}

.profile-avatar {
  width: 100px;
  height: 100px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--primary) 0%, var(--secondary) 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 15px rgba(17, 60, 203, 0.3);
  position: relative;
  overflow: hidden;
}

.profile-avatar::after {
  content: '';
  position: absolute;
  top: -50%;
  left: -50%;
  width: 200%;
  height: 200%;
  background: linear-gradient(45deg, transparent, rgba(255,255,255,0.1), transparent);
  transform: rotate(45deg);
  animation: shimmer 3s infinite;

}

.app-badge {
  display: inline-block;
  padding: 0.5em 0.75em;
  border-radius: 0.5em;
  font-size: 0.875em;
  font-weight: 600;
  text-align: center;
}

.app-badge-success {
  background-color: #d4edda;
  border-color: #c3e6cb;
  color: #155724;
}

.app-badge-warning {
  background-color: #fff3cd;
  border-color: #ffeeba;
  color: #856404;
}

.app-badge-danger {
  background-color: #f8d7da;
  border-color: #f5c6cb;
  color: #721c24;
}

.app-badge-info {
  background-color: #d1ecf1;
  border-color: #bee5eb;
  color: #0c5460;
}

@keyframes shimmer {
  0% { transform: translateX(-100%) rotate(45deg); }
  100% { transform: translateX(100%) rotate(45deg); }
}

.avatar-text {
  color: white;
  font-weight: bold;
  font-size: 2rem;
  text-shadow: 0 2px 4px rgba(0,0,0,0.3);
}

.stat-item {
  padding: 10px 5px;
}

.stat-number {
  font-weight: 700;
  font-size: 1.1rem;
  color: var(--primary);
  margin-bottom: 2px;
}

.stat-label {
  font-size: 0.75rem;
  color: #6c757d;
}

.list-group-item {
  border: none;
  border-bottom: 1px solid #f1f1f1;
  padding: 15px;
  transition: all 0.3s ease;
}

.list-group-item:hover {
  background-color: #f8f9fa;
  transform: translateX(5px);
}

.list-group-item:last-child {
  border-bottom: none;
}

.list-icon {
  width: 40px;
  height: 40px;
  border-radius: 10px;
  background: linear-gradient(45deg, var(--primary), var(--secondary));
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
}

.app-icon-button {
  width: 35px;
  height: 35px;
  border-radius: 50%;
  background: linear-gradient(45deg, var(--primary), var(--secondary));
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  font-size: 1rem;
  box-shadow: 0 2px 8px rgba(17, 60, 203, 0.3);
}

.list-group-item h6 {
  color: #343a40;
  margin-bottom: 3px;
}

.list-group-item small {
  font-size: 0.8rem;
}

.bi-chevron-right {
  font-size: 1.2rem;
}

/* Responsive adjustments */
@media (max-width: 576px) {
  .profile-avatar {
    width: 80px;
    height: 80px;
  }
  
  .avatar-text {
    font-size: 1.5rem;
  }
  
  .stat-number {
    font-size: 0.9rem;
  }
  
  .stat-label {
    font-size: 0.7rem;
  }
  
  .list-group-item {
    padding: 12px 10px;
  }
  
  .list-icon {
    width: 35px;
    height: 35px;
    font-size: 0.9rem;
  }
}

.app-alert-warning {
    background-color: #fff3cd;
    border-color: #ffeeba;
    color: #856404;
}

.app-gold-bg {
    background-color: #997404;
    border-color: #856404;
    color: #856404;
}

.app-gold-bg .bi {
    color: #644c05;
}

/* Responsive adjustments */
@media (max-width: 576px) {
    .app-card {
        padding: 20px 15px;
    }
    
    /* .app-container {
        padding: 10px;
    } */

    .status-bar {
        display: none;
        
    }

    .app-list-tile {
        flex-direction: column;
        align-items: flex-start;
    }
    
    .leading {
        min-width: auto;
        margin-right: 0;
        margin-bottom: 5px;
    }
    
    .trailing {
        position: relative;
        right: auto;
        top: auto;
        transform: none;
        margin-left: 0;
        margin-top: 10px;
        align-self: flex-end;
    }
    
    .filter-container {
        flex-direction: column;
    }
}