/* Custom styles for English Tutor Bot SaaS Platform */

:root {
    --primary-color: #007bff;
    --secondary-color: #6c757d;
    --success-color: #28a745;
    --danger-color: #dc3545;
    --warning-color: #ffc107;
    --info-color: #17a2b8;
    --light-color: #f8f9fa;
    --dark-color: #343a40;
}

/* Log display styling for admin panel */
.log-display {
    background-color: #1e1e1e;
    color: #d4d4d4;
    padding: 15px;
    border-radius: 5px;
    max-height: 500px;
    overflow-y: auto;
    font-family: 'Courier New', monospace;
    font-size: 12px;
    white-space: pre-wrap;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background-color: #f8f9fc;
}

/* Hero Section */
.hero-section {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 60px 0;
    margin-top: -20px;
}

.hero-section h1 {
    color: white;
}

.hero-section .text-primary {
    color: #ffd700 !important;
}

/* Feature Cards */
.features-section .card {
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.features-section .card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.15) !important;
}

.feature-icon {
    width: 80px;
    height: 80px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, rgba(102, 126, 234, 0.1) 0%, rgba(118, 75, 162, 0.1) 100%);
    border-radius: 50%;
}

/* CTA Section */
.cta-section {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
}

.cta-section h2,
.cta-section p {
    color: white;
}

/* How It Works */
.step-number {
    width: 60px;
    height: 60px;
    background: var(--primary-color);
    color: white;
    border-radius: 50%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    font-weight: bold;
}

/* Dashboard Cards */
.card {
    border-radius: 16px;
    overflow: hidden;
    transition: all 0.3s ease;
}

.bot-card {
    transition: all 0.3s ease;
}

.bot-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.15) !important;
}

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

.bot-info {
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
    padding: 1rem;
    border-radius: 12px;
    border-left: 4px solid #667eea;
}

.bot-info .info-item {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 0.5rem;
    font-size: 0.9rem;
}

.bot-info .info-item:last-child {
    margin-bottom: 0;
}

.bot-info code {
    background-color: rgba(102, 126, 234, 0.1);
    color: #667eea;
    padding: 2px 8px;
    border-radius: 6px;
    font-size: 0.8rem;
    font-weight: 600;
}

.bot-controls {
    margin-top: 1.5rem;
}

/* Custom button styles for dashboard */
.btn-success-custom {
    background: linear-gradient(135deg, #28a745 0%, #20c997 100%);
    border: none;
    color: white;
    font-weight: 600;
    transition: all 0.3s ease;
    border-radius: 10px;
}

.btn-success-custom:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(40, 167, 69, 0.4);
    color: white;
}

.btn-warning-custom {
    background: linear-gradient(135deg, #ffc107 0%, #fd7e14 100%);
    border: none;
    color: white;
    font-weight: 600;
    transition: all 0.3s ease;
    border-radius: 10px;
}

.btn-warning-custom:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(255, 193, 7, 0.4);
    color: white;
}

.btn-primary-custom {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border: none;
    color: white;
    font-weight: 600;
    transition: all 0.3s ease;
    border-radius: 10px;
}

.btn-primary-custom:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(102, 126, 234, 0.4);
    color: white;
}

.btn-danger-custom {
    background: linear-gradient(135deg, #dc3545 0%, #c82333 100%);
    border: none;
    color: white;
    font-weight: 600;
    transition: all 0.3s ease;
    border-radius: 10px;
}

.btn-danger-custom:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(220, 53, 69, 0.4);
    color: white;
}

.btn-outline-secondary-custom {
    border: 2px solid #6c757d;
    color: #6c757d;
    background: white;
    font-weight: 600;
    transition: all 0.3s ease;
    border-radius: 10px;
}

.btn-outline-secondary-custom:hover {
    background: #6c757d;
    color: white;
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(108, 117, 125, 0.3);
}

/* Badge gradient styles */
.bg-success-gradient {
    background: linear-gradient(135deg, #28a745 0%, #20c997 100%) !important;
}

.bg-danger-gradient {
    background: linear-gradient(135deg, #dc3545 0%, #e83e8c 100%) !important;
}

.bg-warning-gradient {
    background: linear-gradient(135deg, #ffc107 0%, #fd7e14 100%) !important;
}

.bg-secondary-gradient {
    background: linear-gradient(135deg, #6c757d 0%, #495057 100%) !important;
}

/* Pulse animation for running status */
@keyframes pulse {
    0%, 100% {
        opacity: 1;
    }
    50% {
        opacity: 0.5;
    }
}

.pulse-animation {
    animation: pulse 2s ease-in-out infinite;
}

/* Forms */
.form-control:focus {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 0.2rem rgba(0, 123, 255, 0.25);
}

.btn-primary {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border: none;
    transition: all 0.3s ease;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(102, 126, 234, 0.4);
}

.btn-outline-primary {
    border-color: var(--primary-color);
    color: var(--primary-color);
    transition: all 0.3s ease;
}

.btn-outline-primary:hover {
    background-color: var(--primary-color);
    border-color: var(--primary-color);
    transform: translateY(-2px);
}

/* Navbar */
.navbar {
    box-shadow: 0 2px 15px rgba(0, 0, 0, 0.1);
    padding: 0.75rem 0;
    transition: all 0.3s ease;
}

/* Stylish registration button in navbar */
.btn-gradient-register {
    background: linear-gradient(135deg, #ffd700 0%, #ffa500 100%) !important;
    color: #000 !important;
    border: none !important;
    font-weight: 700 !important;
    transition: all 0.3s ease !important;
    box-shadow: 0 4px 15px rgba(255, 215, 0, 0.4) !important;
}

.btn-gradient-register:hover {
    transform: translateY(-2px) !important;
    box-shadow: 0 6px 20px rgba(255, 215, 0, 0.6) !important;
    color: #000 !important;
    text-decoration: none !important;
}

.btn-gradient-register i {
    font-weight: 700;
}

.navbar.sticky-top {
    backdrop-filter: blur(10px); /* Modern browsers only - gracefully degrades */
    -webkit-backdrop-filter: blur(10px); /* Safari support */
}

.bg-gradient-primary {
    background: linear-gradient(135deg, #4a5dc9 0%, #5a2d7a 100%) !important;
}

.navbar-brand {
    font-weight: 700;
    font-size: 1.25rem;
    transition: transform 0.3s ease;
}

.navbar-brand:hover {
    transform: scale(1.05);
}

.nav-link {
    font-weight: 500;
    transition: all 0.3s ease;
    position: relative;
}

.nav-link-hover:hover {
    background-color: rgba(255, 255, 255, 0.15);
    transform: translateY(-2px);
    text-decoration: none;
}

/* Fix dropdown toggle hover area to match content width better */
.navbar .nav-item.dropdown .nav-link.dropdown-toggle.rounded-pill.px-3 {
    padding-right: 0.75rem;
    padding-left: 0.75rem;
}

.nav-link.active {
    background-color: rgba(255, 255, 255, 0.2);
}

.navbar-nav .btn {
    transition: all 0.3s ease;
}

.navbar-nav .btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

/* Enhanced Dropdown Menu Styling */
.navbar .dropdown-menu {
    border-radius: 16px;
    padding: 0.75rem;
    min-width: 240px;
    border: none;
    animation: fadeInDown 0.3s ease;
    background: white;
    margin-top: 0.5rem;
}

@keyframes fadeInDown {
    from {
        opacity: 0;
        transform: translateY(-15px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.navbar .dropdown-item {
    transition: all 0.3s ease;
    border-radius: 10px;
    margin: 0.25rem 0;
    padding: 0.65rem 1rem;
    font-weight: 500;
    display: flex;
    align-items: center;
}

.navbar .dropdown-item i {
    width: 20px;
    font-size: 1rem;
    margin-right: 0.75rem;
    opacity: 0.7;
}

.navbar .dropdown-item:hover {
    background: linear-gradient(135deg, rgba(102, 126, 234, 0.1) 0%, rgba(118, 75, 162, 0.1) 100%);
    transform: translateX(3px);
    text-decoration: none;
}

.navbar .dropdown-item:hover i {
    opacity: 1;
}

.navbar .dropdown-item.text-danger:hover {
    background: linear-gradient(135deg, rgba(220, 53, 69, 0.1) 0%, rgba(200, 35, 51, 0.1) 100%);
    text-decoration: none;
}

.navbar .dropdown-divider {
    margin: 0.5rem 0;
    opacity: 0.15;
}

/* User dropdown toggle improvements */
.navbar .nav-item.dropdown .nav-link.dropdown-toggle {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 1rem;
    font-weight: 500;
}

.navbar .nav-item.dropdown .nav-link.dropdown-toggle i.fa-user-circle {
    font-size: 1.5rem;
}

/* Footer */
footer a {
    transition: color 0.3s ease;
}

footer a:hover {
    color: #ffc107 !important;
}

/* Alerts */
.alert {
    border-radius: 8px;
    border: none;
}

/* Fixed notification container */
.notification-container {
    position: fixed;
    top: 80px;
    right: 20px;
    z-index: 1050;
    max-width: 400px;
    width: 90%;
}

.notification-container .alert {
    margin-bottom: 10px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
    animation: slideInRight 0.3s ease-out;
}

@keyframes slideInRight {
    from {
        transform: translateX(400px);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }
}

/* Badges */
.badge {
    padding: 8px 12px;
    font-size: 0.85rem;
    font-weight: 500;
}

/* Modal */
.modal-content {
    border-radius: 12px;
    border: none;
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .hero-section {
        text-align: center;
        padding: 40px 0;
    }
    
    .hero-title {
        font-size: 2rem;
    }
    
    .hero-subtitle {
        font-size: 1rem;
    }
    
    .hero-image {
        max-height: 300px;
        margin-top: 20px;
    }
    
    .hero-section .display-3 {
        font-size: 2rem;
    }
    
    .btn-lg {
        width: 100%;
        margin-bottom: 10px;
    }
}

@media (min-width: 769px) and (max-width: 992px) {
    .hero-title {
        font-size: 2.2rem;
    }
    
    .hero-image {
        max-height: 350px;
    }
}

/* Animation */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.card,
.alert {
    animation: fadeIn 0.5s ease-out;
}

/* Status indicators */
.bg-success {
    background: linear-gradient(135deg, #28a745 0%, #20c997 100%) !important;
}

.bg-danger {
    background: linear-gradient(135deg, #dc3545 0%, #e83e8c 100%) !important;
}

.bg-warning {
    background: linear-gradient(135deg, #ffc107 0%, #fd7e14 100%) !important;
}

.bg-secondary {
    background: linear-gradient(135deg, #6c757d 0%, #495057 100%) !important;
}

/* Loading spinner */
.spinner-border {
    width: 3rem;
    height: 3rem;
}

/* Code blocks */
code {
    color: #e83e8c;
    background-color: #f8f9fa;
    padding: 2px 6px;
    border-radius: 4px;
}

/* Links */
a {
    text-decoration: none;
    transition: all 0.3s ease;
}

a:hover {
    text-decoration: underline;
}

/* Remove underline from buttons on hover */
.btn:hover,
a.btn:hover {
    text-decoration: none;
}

/* Shadow utilities */
.shadow-sm {
    box-shadow: 0 0.125rem 0.25rem rgba(0, 0, 0, 0.075) !important;
}

.shadow-lg {
    box-shadow: 0 1rem 3rem rgba(0, 0, 0, 0.175) !important;
}
