html {
  font-size: 14px;
}

@media (min-width: 768px) {
  html {
    font-size: 16px;
  }
}

.btn:focus, .btn:active:focus, .btn-link.nav-link:focus, .form-control:focus, .form-check-input:focus {
  box-shadow: 0 0 0 0.1rem white, 0 0 0 0.25rem #258cfb;
}

html {
  position: relative;
  min-height: 100%;
}

body {
  margin-bottom: 60px;
}

.form-floating > .form-control-plaintext::placeholder, .form-floating > .form-control::placeholder {
  color: var(--bs-secondary-color);
  text-align: end;
}

.form-floating > .form-control-plaintext:focus::placeholder, .form-floating > .form-control:focus::placeholder {
  text-align: start;
}

.balance-display {
    direction: ltr;
}

/* Currency Pool Footer Styling */
.currency-pool-section {
    font-size: 0.85rem;
    transition: all 0.3s ease;
    background: linear-gradient(135deg, #f8f9fa 0%, #ffffff 100%);
    border-bottom: 1px solid #dee2e6 !important;
    min-height: 20px; /* Ensure minimum height for toggle button visibility */
    padding: 0.5rem !important; /* Keep padding for toggle button space */
}

.currency-pool-section.minimizing {
    padding-top: 0.5rem !important;
    padding-bottom: 0.5rem !important;
}

.currency-pool-item {
    padding: 0.5rem 0.25rem;
    transition: background-color 0.2s ease;
    border-radius: 4px;
}

.currency-pool-item:hover {
    background-color: rgba(0, 123, 255, 0.1);
    transform: translateY(-1px);
}

.currency-pool-balance {
    font-weight: 600;
    font-size: 0.9rem;
    color: #2c3e50;
}

.currency-pool-code {
    font-size: 0.75rem;
    opacity: 0.8;
    color: #6c757d;
}

/* Currency flag emoji styling */
.currency-pool-flag {
    font-size: 1.5rem !important;
    margin-bottom: 2px !important;
    line-height: 1;
    filter: drop-shadow(0 1px 2px rgba(0,0,0,0.1));
    transition: transform 0.2s ease;
}

.currency-pool-item:hover .currency-pool-flag {
    transform: scale(1.1);
}

/* Footer separator styling */
.footer-separator {
    height: 1px;
    background: linear-gradient(to right, transparent 0%, #dee2e6 20%, #dee2e6 80%, transparent 100%);
    margin: 0;
    box-shadow: 0 1px 2px rgba(0,0,0,0.05);
}

/* Currency Pool Toggle Animations */
.currency-pool-section {
    transition: all 0.4s ease-in-out;
}

.currency-pool-content {
    transition: max-height 0.4s ease-in-out, opacity 0.3s ease-in-out, padding 0.4s ease-in-out;
    overflow: hidden;
    max-height: 1000px; /* Large enough to accommodate content */
    opacity: 1;
    padding-top: 0;
}

.currency-pool-content.collapsed {
    max-height: 0;
    opacity: 0;
    padding-top: 0;
    padding-bottom: 0;
}

.currency-pool-header {
    transition: all 0.3s ease-in-out;
}

.currency-pool-toggle {
    transition: all 0.3s ease-in-out;
    border: none !important;
    background: rgba(255, 255, 255, 0.9) !important;
    color: #6c757d !important;
    padding: 2px 6px !important;
    font-size: 0.7rem !important;
    border-radius: 3px !important;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1) !important;
}

.currency-pool-toggle:hover {
    background: rgba(108, 117, 125, 0.1) !important;
    color: #495057 !important;
    transform: scale(1.05);
}

.currency-pool-toggle i {
    transition: transform 0.3s ease-in-out;
}

.currency-pool-toggle.collapsed i {
    transform: rotate(180deg);
}

.currency-pool-title {
    font-size: 0.75rem !important;
    font-weight: 500;
    color: #6c757d !important;
    margin: 0;
}

/* Smooth minimize animation */
.currency-pool-section.minimizing {
    animation: minimizeToSeparator 0.4s ease-in-out forwards;
}

.currency-pool-section.maximizing {
    animation: maximizeFromSeparator 0.4s ease-in-out forwards;
}

@keyframes minimizeToSeparator {
    0% {
        opacity: 1;
        transform: translateY(0);
        max-height: 1000px;
    }
    100% {
        opacity: 0;
        transform: translateY(10px);
        max-height: 0;
    }
}

@keyframes maximizeFromSeparator {
    0% {
        opacity: 0;
        transform: translateY(10px);
        max-height: 0;
    }
    100% {
        opacity: 1;
        transform: translateY(0);
        max-height: 1000px;
    }
}

@media (max-width: 576px) {
    .currency-pool-section {
        font-size: 0.75rem;
    }
    
    .currency-pool-balance {
        font-size: 0.8rem;
    }
    
    .currency-pool-code {
        font-size: 0.7rem;
    }
    
    .currency-pool-header {
        margin-bottom: 8px !important;
    }
    
    .currency-pool-title {
        font-size: 0.7rem !important;
    }
    
    .currency-pool-toggle {
        font-size: 0.65rem !important;
    }
    
    /* Increase bottom padding for mobile to account for taller footer */
    .container {
        padding-bottom: 140px !important;
    }
}