:root {
    --sidebar-width: 240px;
    --border-radius: 6px;
    --transition-speed: 0.2s;
    --bs-body-bg: #f9fafb;
    --bs-body-color: #374151;
    --card-bg: #ffffff;
    --hover-bg: #f3f4f6;
    --sidebar-bg: #ffffff;
    --border-color: #e5e7eb;
    --primary-color: #0066cc;
    --primary-hover: #0052a3;
    --text-secondary: #6b7280;
}

body {
    background-color: var(--bs-body-bg);
    color: var(--bs-body-color);
}

.sidebar {
    position: fixed;
    top: 0;
    left: 0;
    height: 100vh;
    width: var(--sidebar-width);
    background-color: var(--sidebar-bg);
    border-right: 1px solid var(--border-color);
    transition: background-color var(--transition-speed), transform var(--transition-speed);
    z-index: 1000;
}

.sidebar.collapsed {
    transform: translateX(calc(-1 * var(--sidebar-width) + 60px));
}

.sidebar-brand {
    padding: 1.2rem;
    border-bottom: 1px solid var(--border-color);
}

.sidebar-brand img {
    height: 36px;
}

.sidebar-menu {
    list-style: none;
    padding: 0;
    margin: 1rem 0;
}

.menu-item {
    padding: 0.8rem 1.2rem;
    border-radius: var(--border-radius);
    margin: 0.3rem 0.8rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    transition: background-color var(--transition-speed);
}

.menu-item {
    padding: 0;
    border-radius: var(--border-radius);
    margin: 0.3rem 0.8rem;
    cursor: pointer;
    transition: background-color var(--transition-speed);
}

.menu-item a {
    display: flex;
    align-items: center;
    width: 100%;
    padding: 0.75rem 1rem;
    text-decoration: none;
    color: inherit;
    border-radius: var(--border-radius);
    font-size: 14px;
}

.menu-item:hover a,
.menu-item.active a {
    background-color: var(--primary-color);
    color: white;
    box-shadow: 0 2px 4px rgba(0, 102, 204, 0.2);
}

.menu-item:hover, .menu-item.active {
    background-color: var(--primary-color);
    box-shadow: 0 2px 4px rgba(0, 102, 204, 0.2);
}

.menu-item.active {
    position: relative;
}

.menu-item.active::before {
    content: '';
    position: absolute;
    left: 0;
    top: 50%;
    transform: translateY(-50%);
    width: 3px;
    height: 70%;
    background-color: white;
    border-radius: 0 2px 2px 0;
}

.menu-item.active a {
    color: white;
    font-weight: 600;
}

.menu-item.active i {
    color: white;
}

.menu-item i {
    width: 18px;
    margin-right: 10px;
    font-size: 16px;
}

.main-content {
    margin-left: var(--sidebar-width);
    padding: 1.5rem;
    transition: margin-left var(--transition-speed);
}

.sidebar-collapsed .main-content {
    margin-left: 60px;
}

.navbar {
    border-radius: var(--border-radius);
    background-color: var(--card-bg);
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
    padding: 0.75rem 1rem;
    margin-bottom: 1.5rem;
}

.card {
    background-color: var(--card-bg);
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius);
    margin-bottom: 1.5rem;
    transition: transform 0.2s, box-shadow 0.2s;
}

.card:hover {
    transform: translateY(-3px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
}

.credits-card {
    background-color: var(--primary-color);
    color: white;
}

.feature-card {
    height: 100%;
    display: flex;
    flex-direction: column;
}

.feature-icon {
    width: 48px;
    height: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background-color: rgba(var(--bs-primary-rgb), 0.1);
    color: var(--bs-primary);
    margin-bottom: 0.8rem;
}

.card-arrow {
    color: var(--bs-primary);
    transition: transform 0.2s;
}

.card:hover .card-arrow {
    transform: translateX(4px);
}

.btn-credits {
    background-color: var(--primary-color);
    border: none;
    transition: background-color 0.2s;
}

.btn-credits:hover {
    background-color: var(--primary-hover);
}

.user-profile {
    display: flex;
    align-items: center;
    padding: 0.9rem 1rem;
    border-top: 1px solid var(--border-color);
    margin-top: auto;
}

.user-avatar {
    width: 34px;
    height: 34px;
    border-radius: 50%;
    background-color: var(--primary-color);
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
    font-size: 14px;
    margin-right: 10px;
}

.user-info {
    flex-grow: 1;
    overflow: hidden;
}

.user-name {
    font-weight: 600;
    font-size: 14px;
    margin-bottom: 0;
}

.user-email {
    font-size: 12px;
    opacity: 0.8;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.theme-toggle {
    cursor: pointer;
    padding: 0.4rem;
    border-radius: 50%;
    background-color: var(--hover-bg);
    margin-left: 0.8rem;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    transition: background-color 0.2s ease;
}

.theme-toggle:hover {
    background-color: var(--border-color);
}

@media (max-width: 768px) {
    .sidebar {
        transform: translateX(-100%);
    }

    .sidebar.show {
        transform: translateX(0);
    }

    .main-content {
        margin-left: 0;
    }

    .nav-toggler {
        display: block;
    }
}

.chat-button {
    position: fixed;
    bottom: 20px;
    right: 20px;
    width: 52px;
    height: 52px;
    border-radius: 50%;
    background-color: var(--primary-color);
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: var(--shadow-md);
    cursor: pointer;
    transition: all 0.2s ease;
    z-index: 100;
}

.chat-button:hover {
    background-color: var(--primary-hover);
    transform: scale(1.05);
    box-shadow: var(--shadow-lg);
}

/* Enhanced Billing Page Styles */
.billing-page {
    padding: 2rem 0;
    background-color: #f9fafb;
    min-height: 100vh;
}

/* Page Header */
.page-header {
    background-color: #0066cc;
    border-radius: 12px;
    padding: 2rem 1.75rem;
    color: white;
    box-shadow: 0 4px 6px rgba(0, 102, 204, 0.15);
    position: relative;
    overflow: hidden;
}

.page-header::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-image: none;
    pointer-events: none;
}

.header-content {
    position: relative;
    z-index: 2;
}

.page-title {
    font-size: 28px;
    font-weight: 700;
    margin-bottom: 0.8rem;
    line-height: 1.3;
}

.page-subtitle {
    font-size: 16px;
    opacity: 0.95;
    margin-bottom: 0;
    line-height: 1.6;
}

.header-visual {
    position: absolute;
    top: 50%;
    right: 3rem;
    transform: translateY(-50%);
}

.billing-icon {
    font-size: 72px;
    color: rgba(255, 255, 255, 0.15);
    animation: iconPulse 4s ease-in-out infinite;
}

@keyframes iconPulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.03); }
}

.brain-particles {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
}

.particle {
    position: absolute;
    width: 6px;
    height: 6px;
    background: rgba(255, 255, 255, 0.4);
    border-radius: 50%;
    animation: particleFloat 5s ease-in-out infinite;
}

.particle-1 {
    top: 20%;
    left: 30%;
    animation-delay: 0s;
}

.particle-2 {
    top: 60%;
    right: 20%;
    animation-delay: 2s;
}

.particle-3 {
    bottom: 30%;
    left: 60%;
    animation-delay: 4s;
}

@keyframes particleFloat {
    0%, 100% {
        transform: translateY(0px) scale(1);
        opacity: 0.6;
    }
    50% {
        transform: translateY(-20px) scale(1.2);
        opacity: 1;
    }
}

/* Current Plan Card */
.current-plan-card {
    background: white;
    border-radius: 16px;
    padding: 2rem;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    border: none;
}

.plan-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid #e9ecef;
}

.plan-title {
    font-size: 1.5rem;
    font-weight: 600;
    color: #333;
    margin-bottom: 0.25rem;
}

.plan-subtitle {
    color: #666;
    margin: 0;
    font-size: 0.9rem;
}

.plan-badge .badge {
    background: #0066cc;
    color: white;
    font-weight: 600;
    padding: 0.5rem 1rem;
    border-radius: 6px;
}

.plan-metrics {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1.5rem;
}

.metric-item {
    display: flex;
    align-items: center;
    padding: 1.5rem;
    background: #f8f9fa;
    border-radius: 12px;
    border: 1px solid #e9ecef;
    transition: all 0.3s ease;
}

.metric-item:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.1);
}

.metric-icon {
    width: 45px;
    height: 45px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.25rem;
    margin-right: 1rem;
    background: rgba(0, 102, 204, 0.1);
    color: #0066cc;
}

.metric-content {
    flex: 1;
}

.metric-value {
    font-size: 1.5rem;
    font-weight: 700;
    color: #333;
    display: block;
    margin-bottom: 0.25rem;
}

.metric-label {
    font-size: 0.9rem;
    color: #666;
    margin-bottom: 0.5rem;
}

.usage-progress {
    width: 100%;
    height: 6px;
    background: #e9ecef;
    border-radius: 3px;
    overflow: hidden;
}

.progress-bar {
    height: 100%;
    background: #0066cc;
    border-radius: 3px;
    transition: width 0.2s ease;
}

.reminder-setting {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-top: 0.5rem;
}

/* Plans Header */
.plans-header {
    text-align: center;
    margin-bottom: 2.5rem;
}

.plans-title {
    font-size: 1.75rem;
    font-weight: 600;
    color: #1a1a1a;
    margin-bottom: 0.75rem;
}

.plans-subtitle {
    font-size: 1rem;
    color: #666;
    margin: 0;
}

/* Pricing Cards */
.pricing-card {
    background: white;
    border-radius: 8px;
    padding: 1.75rem 1.5rem;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
    border: 1px solid #e9ecef;
    transition: all 0.2s ease;
    position: relative;
    height: 100%;
    display: flex;
    flex-direction: column;
}

.pricing-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.12);
    border-color: #0066cc;
}

.pricing-card.featured {
    border-color: #0066cc;
    border-width: 2px;
    box-shadow: 0 4px 12px rgba(0, 102, 204, 0.15);
}

.pricing-card.featured::before {
    display: none;
}

.popular-badge {
    position: absolute;
    top: -10px;
    left: 50%;
    transform: translateX(-50%);
    background: #0066cc;
    color: white;
    padding: 0.4rem 0.9rem;
    border-radius: 4px;
    font-size: 0.7rem;
    font-weight: 600;
    box-shadow: 0 2px 6px rgba(0, 102, 204, 0.25);
    text-transform: uppercase;
    letter-spacing: 0.3px;
    z-index: 10;
}

.pricing-header {
    text-align: center;
    margin-bottom: 1.5rem;
}

.plan-name {
    font-size: 1.35rem;
    font-weight: 600;
    color: #1a1a1a;
    margin-bottom: 0.75rem;
}

.pricing {
    display: flex;
    align-items: baseline;
    justify-content: center;
    gap: 0.25rem;
}

.price-amount {
    font-size: 2.25rem;
    font-weight: 700;
    color: #0066cc;
}

.price-period {
    font-size: 0.95rem;
    color: #666;
    font-weight: 500;
}

.price-custom {
    font-size: 2rem;
    font-weight: 700;
    color: #0066cc;
}

.pricing-body {
    flex: 1;
    margin-bottom: 1.5rem;
}

.plan-description {
    color: #666;
    text-align: center;
    margin-bottom: 1.5rem;
    font-size: 0.9rem;
    line-height: 1.5;
}

.features-list {
    display: flex;
    flex-direction: column;
    gap: 0.85rem;
}

.feature-item {
    display: flex;
    align-items: center;
    gap: 0.65rem;
    font-size: 0.875rem;
    color: #555;
}

.feature-icon {
    color: #0066cc;
    font-size: 1rem;
    width: 18px;
}

.pricing-footer {
    margin-top: auto;
}

.pricing-footer .btn {
    padding: 0.75rem 1.25rem;
    font-weight: 600;
    border-radius: 6px;
    transition: all 0.2s ease;
}

.pricing-footer .btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 102, 204, 0.2);
}

/* Billing History Card */
.billing-history-card {
    background: white;
    border-radius: 8px;
    padding: 1.75rem;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
    border: 1px solid #e9ecef;
}

.history-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.5rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid #e9ecef;
}

.history-title {
    font-size: 1.25rem;
    font-weight: 600;
    color: #1a1a1a;
    margin-bottom: 0.25rem;
}

.history-subtitle {
    color: #666;
    margin: 0;
    font-size: 0.875rem;
}

.history-actions .btn {
    border-radius: 6px;
    font-weight: 500;
    font-size: 0.9rem;
}

.transactions-list {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    margin-bottom: 2rem;
}

.transaction-item {
    display: flex;
    align-items: center;
    padding: 1.5rem;
    background: #f8f9fa;
    border-radius: 12px;
    border: 1px solid #e9ecef;
    transition: all 0.3s ease;
}

.transaction-item:hover {
    transform: translateX(5px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.1);
}

.transaction-icon {
    width: 50px;
    height: 50px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    margin-right: 1rem;
    background: rgba(102, 126, 234, 0.1);
    color: #0066cc;
}

.transaction-details {
    flex: 1;
}

.transaction-ref {
    font-weight: 600;
    color: #333;
    margin-bottom: 0.25rem;
    font-size: 1rem;
}

.transaction-method {
    color: #666;
    font-size: 0.9rem;
    margin-bottom: 0.25rem;
}

.transaction-date {
    color: #999;
    font-size: 0.8rem;
}

.transaction-amount {
    text-align: right;
    margin-right: 1rem;
}

.amount {
    font-size: 1.2rem;
    font-weight: 700;
    color: #333;
    margin-bottom: 0.25rem;
}

.status-badge .badge {
    font-size: 0.75rem;
    padding: 0.25rem 0.5rem;
    border-radius: 12px;
}

.badge-success {
    background: #28a745;
    color: white;
}

.transaction-actions .btn {
    border-radius: 8px;
    width: 36px;
    height: 36px;
    padding: 0;
    display: flex;
    align-items: center;
    justify-content: center;
}

.history-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-top: 1rem;
    border-top: 1px solid #e9ecef;
}

.pagination-info {
    color: #666;
    font-size: 0.9rem;
}

.pagination-actions {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.page-indicator {
    background: #0066cc;
    color: white;
    width: 30px;
    height: 30px;
    border-radius: 6px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
    font-size: 14px;
}

/* Empty State */
.empty-state {
    text-align: center;
    padding: 2.5rem 2rem;
}

.empty-icon {
    font-size: 48px;
    color: #d1d5db;
    margin-bottom: 1.2rem;
}

.empty-title {
    font-size: 20px;
    color: #6b7280;
    margin-bottom: 0.8rem;
}

.empty-description {
    color: #9ca3af;
    font-size: 14px;
    line-height: 1.5;
    margin: 0;
}

/* Responsive Design */
@media (max-width: 1200px) {
    .page-title {
        font-size: 1.75rem;
    }

    .billing-icon {
        font-size: 4rem;
    }

    .plans-title {
        font-size: 2rem;
    }
}

@media (max-width: 992px) {
    .plan-metrics {
        grid-template-columns: 1fr;
    }

    .header-visual {
        position: static;
        transform: none;
        margin-top: 2rem;
        text-align: center;
    }

    .page-header {
        text-align: center;
    }

    .history-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 1rem;
    }
}

@media (max-width: 768px) {
    .billing-page {
        padding: 1rem 0;
    }

    .page-header {
        padding: 2rem 1.5rem;
    }

    .page-title {
        font-size: 2rem;
    }

    .current-plan-card {
        padding: 1.5rem;
    }

    .plan-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 1rem;
    }

    .plan-metrics {
        gap: 1rem;
    }

    .metric-item {
        padding: 1rem;
    }

    .pricing-card {
        padding: 1.5rem 1rem;
    }

    .billing-history-card {
        padding: 1.5rem;
    }

    .transaction-item {
        flex-direction: column;
        align-items: flex-start;
        gap: 1rem;
    }

    .transaction-amount {
        text-align: left;
        margin-right: 0;
    }

    .history-footer {
        flex-direction: column;
        gap: 1rem;
        align-items: center;
    }
}

@media (max-width: 576px) {
    .page-title {
        font-size: 1.8rem;
    }

    .plans-title {
        font-size: 1.8rem;
    }

    .plan-title {
        font-size: 1.25rem;
    }

    .metric-value {
        font-size: 1.25rem;
    }

    .price-amount {
        font-size: 1.75rem;
    }

    .history-title {
        font-size: 1.25rem;
    }

    .transaction-ref {
        font-size: 0.95rem;
    }
}

/* Animation Classes */
.animate__animated {
    animation-duration: 0.6s;
    animation-fill-mode: both;
}

.animate__fadeInDown {
    animation-name: fadeInDown;
}

.animate__fadeInUp {
    animation-name: fadeInUp;
}

@keyframes fadeInDown {
    from {
        opacity: 0;
        transform: translate3d(0, -30px, 0);
    }
    to {
        opacity: 1;
        transform: translate3d(0, 0, 0);
    }
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translate3d(0, 30px, 0);
    }
    to {
        opacity: 1;
        transform: translate3d(0, 0, 0);
    }
}

/* Enhanced Checkout Page Styles */
.checkout-page {
    background: #f8f9fa;
    min-height: 100vh;
}

/* Checkout Header */
.checkout-header {
    background: #0066cc;
    padding: 3rem 0 1.5rem;
    color: white;
    position: relative;
    overflow: hidden;
}

.checkout-header::before {
    display: none;
}

.header-content {
    position: relative;
    z-index: 2;
}

.checkout-title {
    font-size: 1.75rem;
    font-weight: 700;
    margin-bottom: 0.75rem;
    line-height: 1.3;
}

.checkout-subtitle {
    font-size: 1rem;
    opacity: 0.9;
    margin-bottom: 2rem;
    line-height: 1.5;
}

/* Checkout Progress */
.checkout-progress {
    display: flex;
    align-items: center;
    justify-content: center;
    max-width: 600px;
    margin: 0 auto;
    position: relative;
}

.progress-step {
    display: flex;
    flex-direction: column;
    align-items: center;
    position: relative;
    z-index: 2;
}

.step-icon {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.2);
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 1.2rem;
    margin-bottom: 0.5rem;
    transition: all 0.3s ease;
    border: 2px solid rgba(255, 255, 255, 0.3);
}

.progress-step.active .step-icon {
    background: white;
    color: #0066cc;
    border-color: white;
    box-shadow: 0 0 12px rgba(255, 255, 255, 0.3);
}

.step-label {
    font-size: 0.9rem;
    font-weight: 500;
    color: rgba(255, 255, 255, 0.8);
    text-align: center;
}

.progress-step.active .step-label {
    color: white;
    font-weight: 600;
}

.progress-line {
    height: 2px;
    background: rgba(255, 255, 255, 0.3);
    flex: 1;
    margin: 0 1rem;
    position: relative;
}

.progress-line.active {
    background: white;
    box-shadow: 0 0 10px rgba(255, 255, 255, 0.5);
}

/* Order Summary Card */
.order-summary-card {
    background: white;
    border-radius: 12px;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
    border: none;
    overflow: hidden;
    height: 100%;
}

.card-header-modern {
    background: #0066cc;
    color: white;
    padding: 1.5rem;
    display: flex;
    align-items: center;
    gap: 1rem;
}

.header-icon {
    width: 50px;
    height: 50px;
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.2);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
}

.header-title {
    font-size: 1.5rem;
    font-weight: 600;
    margin: 0;
}

.card-body-modern {
    padding: 2rem;
}

/* Package Details */
.package-details {
    margin-bottom: 2rem;
}

.package-header {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 1.5rem;
    padding: 1.25rem;
    background: #f8f9fa;
    border-radius: 8px;
    border: 1px solid #e9ecef;
}

.package-icon {
    width: 50px;
    height: 50px;
    border-radius: 12px;
    background: rgba(102, 126, 234, 0.1);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    color: #0066cc;
}

.package-name {
    font-size: 1.25rem;
    font-weight: 600;
    color: #333;
    margin-bottom: 0.25rem;
}

.package-description {
    color: #666;
    margin: 0;
    font-size: 0.9rem;
}

.package-features {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.feature-item {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    font-size: 0.9rem;
    color: #555;
}

.feature-icon-small {
    color: #0066cc;
    font-size: 1rem;
    width: 16px;
}

/* Pricing Breakdown */
.pricing-breakdown {
    background: #f8f9fa;
    border-radius: 12px;
    padding: 1.5rem;
    margin-bottom: 2rem;
}

.pricing-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.75rem 0;
    border-bottom: 1px solid #e9ecef;
}

.pricing-row:last-child {
    border-bottom: none;
}

.pricing-label {
    color: #666;
    font-size: 0.95rem;
}

.pricing-value {
    font-weight: 600;
    color: #333;
}

.total-row {
    background: #0066cc;
    color: white;
    margin: 0 -1.5rem -1.5rem;
    padding: 1.5rem;
    border-radius: 0 0 12px 12px;
}

.total-label {
    font-size: 1.1rem;
    font-weight: 600;
}

.total-value {
    font-size: 1.5rem;
    font-weight: 800;
}

/* Security Badges */
.security-badges {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
}

.badge-item {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    background: white;
    padding: 0.75rem 1rem;
    border-radius: 8px;
    border: 1px solid #e9ecef;
    font-size: 0.85rem;
    color: #666;
    flex: 1;
    min-width: 120px;
    justify-content: center;
}

.badge-item i {
    color: #28a745;
}

/* Payment Card */
.payment-card {
    background: white;
    border-radius: 12px;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
    border: none;
    overflow: hidden;
    height: 100%;
}

/* Payment Method */
.payment-method-enhanced {
    margin-bottom: 2rem;
}

.method-header {
    margin-bottom: 1rem;
}

.method-title {
    font-size: 1.1rem;
    font-weight: 600;
    color: #333;
    margin: 0;
}

.method-option {
    border: 2px solid #e9ecef;
    border-radius: 12px;
    padding: 1.5rem;
    transition: all 0.3s ease;
    cursor: pointer;
}

.method-option:hover {
    border-color: #0066cc;
    box-shadow: 0 8px 20px rgba(102, 126, 234, 0.1);
}

.method-option.active {
    border-color: #0066cc;
    background: rgba(0, 102, 204, 0.05);
}

.method-radio {
    position: relative;
    margin-right: 1rem;
}

.method-radio input[type="radio"] {
    position: absolute;
    opacity: 0;
    width: 0;
    height: 0;
}

.method-radio label {
    width: 20px;
    height: 20px;
    border: 2px solid #e9ecef;
    border-radius: 50%;
    display: inline-block;
    position: relative;
    cursor: pointer;
    transition: all 0.3s ease;
}

.method-radio input[type="radio"]:checked + label {
    background: #0066cc;
    border-color: #0066cc;
}

.method-radio input[type="radio"]:checked + label::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 8px;
    height: 8px;
    background: white;
    border-radius: 50%;
}

.method-content {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.payment-logo {
    width: 60px;
    height: 40px;
    object-fit: contain;
    border-radius: 6px;
}

.method-name {
    font-size: 1.1rem;
    font-weight: 600;
    color: #333;
    margin-bottom: 0.25rem;
}

.method-description {
    color: #666;
    font-size: 0.9rem;
    margin-bottom: 0.5rem;
}

.method-features {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
}

.feature-tag {
    background: #f8f9fa;
    color: #0066cc;
    padding: 0.25rem 0.5rem;
    border-radius: 12px;
    font-size: 0.75rem;
    font-weight: 500;
}

/* Payment Button */
.payment-actions {
    margin-bottom: 2rem;
}

.btn-payment-primary {
    width: 100%;
    background: #0066cc;
    border: none;
    border-radius: 12px;
    padding: 1.25rem;
    color: white;
    font-weight: 600;
    font-size: 1.1rem;
    position: relative;
    overflow: hidden;
    transition: all 0.3s ease;
    box-shadow: 0 8px 20px rgba(102, 126, 234, 0.3);
}

.btn-payment-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 15px 35px rgba(102, 126, 234, 0.4);
}

.btn-content {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 1rem;
    position: relative;
    z-index: 2;
}

.btn-icon {
    width: 24px;
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1rem;
}

.btn-text {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.25rem;
}

.btn-title {
    font-size: 1rem;
    font-weight: 600;
}

.btn-amount {
    font-size: 0.9rem;
    opacity: 0.9;
}

.btn-shine {
    display: none;
}

/* Trust Indicators */
.trust-indicators {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.trust-item {
    display: flex;
    align-items: flex-start;
    gap: 0.75rem;
    padding: 1rem;
    background: #f8f9fa;
    border-radius: 8px;
    border: 1px solid #e9ecef;
}

.trust-icon {
    color: #28a745;
    font-size: 1.1rem;
    margin-top: 0.1rem;
}

.trust-text {
    color: #666;
    font-size: 0.9rem;
    line-height: 1.4;
    margin: 0;
}

/* Card Footer */
.card-footer-modern {
    background: #f8f9fa;
    padding: 1.5rem 2rem;
    border-top: 1px solid #e9ecef;
}

.footer-content {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.75rem;
    color: #666;
    font-size: 0.9rem;
}

.footer-icon {
    color: #28a745;
}

/* Additional Information */
.additional-info {
    background: white;
    border-radius: 16px;
    padding: 2rem;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.08);
    border: none;
}

.info-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
}

.info-item {
    display: flex;
    align-items: flex-start;
    gap: 1rem;
    padding: 1.5rem;
    background: #f8f9fa;
    border-radius: 12px;
    border: 1px solid #e9ecef;
    transition: all 0.3s ease;
}

.info-item:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.1);
}

.info-icon {
    width: 50px;
    height: 50px;
    border-radius: 12px;
    background: #0066cc;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 1.5rem;
    flex-shrink: 0;
}

.info-content h6 {
    font-size: 1.1rem;
    font-weight: 600;
    color: #333;
    margin-bottom: 0.5rem;
}

.info-content p {
    color: #666;
    font-size: 0.9rem;
    line-height: 1.5;
    margin: 0;
}

/* Enhanced Pricing Cards */
.pricing-card {
    background: white;
    border-radius: 8px;
    padding: 1.75rem 1.5rem;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
    border: 1px solid #e9ecef;
    transition: all 0.2s ease;
    position: relative;
    height: 100%;
    display: flex;
    flex-direction: column;
    overflow: visible;
}

.pricing-card::before {
    display: none;
}

.pricing-card:hover::before {
    display: none;
}

.pricing-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.12);
    border-color: #0066cc;
}

.pricing-card.featured {
    border-color: #0066cc;
    border-width: 2px;
    box-shadow: 0 4px 12px rgba(0, 102, 204, 0.15);
    background: white;
}

.pricing-card.featured::after {
    display: none;
}

.popular-badge {
    position: absolute;
    top: -10px;
    left: 50%;
    transform: translateX(-50%);
    background: #0066cc;
    color: white;
    padding: 0.4rem 0.9rem;
    border-radius: 4px;
    font-size: 0.7rem;
    font-weight: 600;
    box-shadow: 0 2px 6px rgba(0, 102, 204, 0.25);
    z-index: 3;
    letter-spacing: 0.3px;
    text-transform: uppercase;
}

.pricing-header {
    text-align: center;
    margin-bottom: 1.5rem;
    position: relative;
    z-index: 2;
}

.plan-name {
    font-size: 1.35rem;
    font-weight: 600;
    color: #1a1a1a;
    margin-bottom: 0.75rem;
    position: relative;
}

.plan-name::after {
    display: none;
}

.pricing {
    display: flex;
    align-items: baseline;
    justify-content: center;
    gap: 0.25rem;
    margin-bottom: 0.5rem;
}

.price-amount {
    font-size: 2.25rem;
    font-weight: 700;
    color: #0066cc;
    line-height: 1;
    position: relative;
}

.price-amount::before {
    content: '$';
    position: absolute;
    top: 0;
    left: -0.65em;
    font-size: 1.1rem;
    font-weight: 600;
    color: #0066cc;
}

.price-period {
    font-size: 0.95rem;
    color: #666;
    font-weight: 500;
    margin-left: 0.15rem;
}

.price-custom {
    font-size: 2rem;
    font-weight: 700;
    color: #0066cc;
}

.pricing-body {
    flex: 1;
    margin-bottom: 1.5rem;
    position: relative;
    z-index: 2;
}

.plan-description {
    color: #666;
    text-align: center;
    margin-bottom: 1.5rem;
    font-size: 0.9rem;
    line-height: 1.5;
    font-weight: 400;
}

.features-list {
    display: flex;
    flex-direction: column;
    gap: 1.2rem;
}

.feature-item {
    display: flex;
    align-items: center;
    gap: 1rem;
    font-size: 0.95rem;
    color: #555;
    padding: 0.5rem 0;
    border-bottom: 1px solid rgba(102, 126, 234, 0.1);
    transition: all 0.3s ease;
}

.feature-item:last-child {
    border-bottom: none;
}

.feature-item:hover {
    color: #333;
}

.feature-icon {
    color: #0066cc;
    font-size: 1rem;
    width: 18px;
    transition: none;
}

.feature-item:hover .feature-icon {
    transform: none;
    color: #0066cc;
}

.pricing-footer {
    margin-top: auto;
    position: relative;
    z-index: 2;
}

.pricing-footer .btn {
    padding: 0.75rem 1.25rem;
    font-weight: 600;
    border-radius: 6px;
    transition: all 0.2s ease;
    position: relative;
    font-size: 0.9rem;
}

.pricing-footer .btn::before {
    display: none;
}

.pricing-footer .btn:hover::before {
    display: none;
}

.pricing-footer .btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 102, 204, 0.2);
}

.pricing-footer .btn:active {
    transform: translateY(-1px) scale(1.02);
}

/* Responsive Design for Checkout */
@media (max-width: 1200px) {
    .checkout-title {
        font-size: 1.75rem;
    }

    .info-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 992px) {
    .checkout-progress {
        flex-direction: column;
        gap: 1rem;
    }

    .progress-line {
        width: 2px;
        height: 30px;
        margin: 0.5rem auto;
    }

    .info-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 768px) {
    .checkout-header {
        padding: 3rem 0 1.5rem;
    }

    .checkout-title {
        font-size: 2rem;
    }

    .checkout-subtitle {
        font-size: 1rem;
        margin-bottom: 2rem;
    }

    .order-summary-card,
    .payment-card {
        margin-bottom: 2rem;
    }

    .package-header {
        flex-direction: column;
        text-align: center;
        gap: 0.75rem;
    }

    .method-content {
        flex-direction: column;
        text-align: center;
        gap: 0.75rem;
    }

    .btn-content {
        flex-direction: column;
        gap: 0.5rem;
    }

    .btn-text {
        align-items: center;
    }

    .additional-info {
        padding: 1.5rem;
    }

    .info-item {
        flex-direction: column;
        text-align: center;
        gap: 0.75rem;
    }

    /* Enhanced pricing card responsive */
    .pricing-card {
        margin-bottom: 2rem;
    }

    .price-amount {
        font-size: 3rem;
    }

    .plan-name {
        font-size: 1.4rem;
    }
}

@media (max-width: 576px) {
    .checkout-title {
        font-size: 1.8rem;
    }

    .card-header-modern {
        padding: 1.5rem;
        flex-direction: column;
        text-align: center;
        gap: 0.75rem;
    }

    .header-title {
        font-size: 1.3rem;
    }

    .card-body-modern {
        padding: 1.5rem;
    }

    .pricing-breakdown {
        padding: 1rem;
    }

    .total-row {
        margin: 0 -1rem -1rem;
        padding: 1rem;
    }

    .security-badges {
        flex-direction: column;
    }

    .badge-item {
        min-width: auto;
    }

    .method-option {
        padding: 1rem;
    }

    .btn-payment-primary {
        padding: 1rem;
    }

    .btn-title {
        font-size: 0.9rem;
    }

    .btn-amount {
        font-size: 0.8rem;
    }

    .trust-item {
        padding: 0.75rem;
    }

    .card-footer-modern {
        padding: 1rem 1.5rem;
    }

    .additional-info {
        padding: 1rem;
    }

    /* Enhanced pricing card mobile */
    .pricing-card {
        padding: 1.5rem 1rem;
    }

    .price-amount {
        font-size: 1.75rem;
    }

    .plan-name {
        font-size: 1.2rem;
    }

    .pricing-footer .btn {
        padding: 0.875rem 1rem;
        font-size: 0.8rem;
    }
}

/* Animation Classes for Checkout */
.animate__fadeInLeft {
    animation: fadeInLeft 0.8s ease-out;
}

.animate__fadeInRight {
    animation: fadeInRight 0.8s ease-out;
}

@keyframes fadeInLeft {
    from {
        opacity: 0;
        transform: translate3d(-50px, 0, 0);
    }
    to {
        opacity: 1;
        transform: translate3d(0, 0, 0);
    }
}

@keyframes fadeInRight {
    from {
        opacity: 0;
        transform: translate3d(50px, 0, 0);
    }
    to {
        opacity: 1;
        transform: translate3d(0, 0, 0);
    }
}

/* Enhanced API Keys Page Styles */
.api-keys-page {
    background: #f8f9fa;
    min-height: 100vh;
    padding: 2rem 0;
}

/* Page Header */
.page-header-api {
    background: #0066cc;
    border-radius: 12px;
    padding: 2.5rem 2rem;
    color: white;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    position: relative;
    overflow: hidden;
}

.page-header-api::before {
    display: none;
}

.page-header-api .header-content {
    position: relative;
    z-index: 2;
}

.page-header-api .page-title {
    font-size: 1.75rem;
    font-weight: 700;
    margin-bottom: 0.75rem;
    line-height: 1.3;
}

.page-header-api .page-subtitle {
    font-size: 1rem;
    opacity: 0.9;
    margin-bottom: 0;
    line-height: 1.5;
}

.header-visual {
    position: absolute;
    top: 50%;
    right: 3rem;
    transform: translateY(-50%);
}

.api-icon {
    font-size: 6rem;
    color: rgba(255, 255, 255, 0.8);
    animation: iconPulse 3s ease-in-out infinite;
}

/* Metric Cards */
.metric-card {
    background: white;
    border-radius: 16px;
    padding: 2rem;
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.08);
    border: none;
    text-align: center;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.metric-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 102, 204, 0.05);
    opacity: 0;
    transition: opacity 0.3s ease;
}

.metric-card:hover::before {
    opacity: 1;
}

.metric-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.15);
}

.metric-icon {
    width: 60px;
    height: 60px;
    border-radius: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    margin: 0 auto 1rem;
    background: rgba(102, 126, 234, 0.1);
    color: #0066cc;
}

.metric-value {
    font-size: 1.75rem;
    font-weight: 800;
    color: #333;
    margin-bottom: 0.5rem;
    display: block;
}

.metric-label {
    font-size: 1rem;
    color: #666;
    font-weight: 500;
    margin: 0;
}

/* API Keys Card */
.api-keys-card {
    background: white;
    border-radius: 12px;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
    border: none;
    overflow: hidden;
}

.card-header-modern {
    background: #0066cc;
    color: white;
    padding: 2rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
}

.card-header-modern .header-icon {
    width: 50px;
    height: 50px;
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.2);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
}

.card-header-modern .header-title {
    font-size: 1.5rem;
    font-weight: 600;
    margin: 0;
    flex: 1;
}

.header-actions .btn-generate {
    background: rgba(255, 255, 255, 0.2);
    border: 2px solid rgba(255, 255, 255, 0.3);
    color: white;
    padding: 0.75rem 1.5rem;
    border-radius: 12px;
    font-weight: 600;
    transition: all 0.3s ease;
}

.header-actions .btn-generate:hover {
    background: white;
    color: #0066cc;
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(255, 255, 255, 0.3);
}

.card-body-modern {
    padding: 2rem;
}

/* Security Notice */
.security-notice {
    background: #ffc107;
    border: 1px solid #ffeaa7;
    border-radius: 12px;
    padding: 1.5rem;
    margin-bottom: 2rem;
    display: flex;
    align-items: flex-start;
    gap: 1rem;
}

.notice-icon {
    color: #856404;
    font-size: 1.5rem;
    margin-top: 0.1rem;
    flex-shrink: 0;
}

.notice-content {
    flex: 1;
}

.notice-title {
    font-size: 1.1rem;
    font-weight: 600;
    color: #856404;
    margin-bottom: 0.5rem;
}

.notice-text {
    color: #856404;
    font-size: 0.95rem;
    line-height: 1.5;
    margin: 0;
}

/* Keys Table */
.keys-table-container {
    margin-top: 2rem;
}

.keys-table {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0;
    background: white;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.08);
}

.keys-table thead {
    background: #f8f9fa;
}

.keys-table th {
    padding: 1.5rem 1rem;
    text-align: left;
    font-weight: 600;
    color: #333;
    border-bottom: 2px solid #dee2e6;
    font-size: 0.95rem;
}

.keys-table td {
    padding: 1.5rem 1rem;
    border-bottom: 1px solid #f1f3f4;
    vertical-align: middle;
}

.key-row {
    transition: all 0.3s ease;
}

.key-row:hover {
    background: #f8f9fa;
    transform: scale(1.01);
}

/* Key Name Cell */
.key-name-cell {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.key-avatar {
    width: 40px;
    height: 40px;
    border-radius: 10px;
    background: #0066cc;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 1rem;
}

.key-info {
    flex: 1;
}

.key-name {
    font-weight: 600;
    color: #333;
    margin-bottom: 0.25rem;
    font-size: 1rem;
}

.key-type {
    font-size: 0.85rem;
    color: #666;
    background: #f8f9fa;
    padding: 0.25rem 0.5rem;
    border-radius: 8px;
    display: inline-block;
}

/* Key Field Container */
.key-field-container {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    max-width: 400px;
}

.key-input {
    flex: 1;
    padding: 0.75rem 1rem;
    border: 2px solid #e9ecef;
    border-radius: 8px;
    font-family: 'Monaco', 'Menlo', 'Ubuntu Mono', monospace;
    font-size: 0.9rem;
    background: #f8f9fa;
    color: #333;
    transition: all 0.3s ease;
}

.key-input:focus {
    outline: none;
    border-color: #0066cc;
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}

.key-actions {
    display: flex;
    gap: 0.25rem;
}

.btn-action {
    width: 36px;
    height: 36px;
    border: none;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.9rem;
    cursor: pointer;
    transition: all 0.3s ease;
    background: #f8f9fa;
    color: #666;
}

.btn-action:hover {
    background: #0066cc;
    color: white;
    transform: scale(1.1);
}

.btn-action-secondary:hover {
    background: #17a2b8;
}

.btn-action-danger:hover {
    background: #dc3545;
}

/* Date Cell */
.date-cell {
    text-align: left;
}

.date-main {
    font-weight: 600;
    color: #333;
    margin-bottom: 0.25rem;
    font-size: 0.95rem;
}

.date-time {
    color: #666;
    font-size: 0.85rem;
}

/* Actions Cell */
.actions-cell {
    display: flex;
    gap: 0.5rem;
}

/* Empty State */
.empty-state-api {
    text-align: center;
    padding: 4rem 2rem;
    background: #f8f9fa;
    border-radius: 16px;
    margin-top: 2rem;
}

.empty-icon {
    font-size: 5rem;
    color: #ccc;
    margin-bottom: 1.5rem;
}

.empty-title {
    font-size: 2rem;
    color: #666;
    margin-bottom: 1rem;
    font-weight: 600;
}

.empty-description {
    font-size: 1.1rem;
    color: #999;
    margin-bottom: 2rem;
    line-height: 1.6;
    max-width: 500px;
    margin-left: auto;
    margin-right: auto;
}

/* Usage Card */
.usage-card {
    background: white;
    border-radius: 12px;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
    border: none;
    overflow: hidden;
}

.usage-card .card-header-modern {
    background: #00a86b;
}

.usage-card .card-body-modern {
    padding: 2rem;
}

.usage-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
}

.usage-item {
    display: flex;
    align-items: center;
    gap: 1.5rem;
    padding: 1.5rem;
    background: #f8f9fa;
    border-radius: 12px;
    border: 1px solid #e9ecef;
    transition: all 0.3s ease;
}

.usage-item:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.1);
}

.usage-icon {
    width: 50px;
    height: 50px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    background: rgba(40, 167, 69, 0.1);
    color: #28a745;
}

.usage-content {
    flex: 1;
}

.usage-value {
    font-size: 2rem;
    font-weight: 800;
    color: #333;
    margin-bottom: 0.25rem;
    display: block;
}

.usage-label {
    font-size: 0.95rem;
    color: #666;
    margin-bottom: 0.5rem;
    font-weight: 500;
}

.usage-change {
    font-size: 0.85rem;
    font-weight: 600;
    padding: 0.25rem 0.5rem;
    border-radius: 8px;
    display: inline-block;
}

.usage-change.positive {
    background: rgba(40, 167, 69, 0.1);
    color: #28a745;
}

/* Enhanced Modal Styles */
.api-key-modal .modal-dialog {
    max-width: 500px;
}

.modal-content-enhanced {
    border: none;
    border-radius: 12px;
    box-shadow: 0 25px 50px rgba(0, 0, 0, 0.15);
    overflow: hidden;
}

.modal-header-enhanced {
    background: #0066cc;
    color: white;
    padding: 2rem;
    display: flex;
    align-items: center;
    gap: 1rem;
    position: relative;
}

.modal-icon {
    width: 50px;
    height: 50px;
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.2);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
}

.modal-title-section {
    flex: 1;
}

.modal-title {
    font-size: 1.5rem;
    font-weight: 600;
    margin-bottom: 0.25rem;
}

.modal-subtitle {
    font-size: 0.95rem;
    opacity: 0.9;
    margin: 0;
}

.btn-close-enhanced {
    background: rgba(255, 255, 255, 0.2);
    border: none;
    border-radius: 8px;
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 1rem;
    transition: all 0.3s ease;
}

.btn-close-enhanced:hover {
    background: rgba(255, 255, 255, 0.3);
    transform: scale(1.1);
}

.modal-body-enhanced {
    padding: 2rem;
    background: #f8f9fa;
}

.key-form-container {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

/* Form Groups */
.form-group-enhanced {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.form-label-enhanced {
    font-size: 1rem;
    font-weight: 600;
    color: #333;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.form-control-enhanced,
.form-select-enhanced {
    padding: 0.75rem 0.9rem;
    border: 1px solid #e5e7eb;
    border-radius: 6px;
    font-size: 14px;
    transition: all 0.2s ease;
    background: white;
}

.form-control-enhanced:focus,
.form-select-enhanced:focus {
    outline: none;
    border-color: #0066cc;
    box-shadow: 0 0 0 3px rgba(0, 102, 204, 0.1);
}

.form-help {
    font-size: 13px;
    color: #6b7280;
    margin-top: 0.25rem;
}

/* Permissions Preview */
.permissions-preview {
    background: white;
    border-radius: 8px;
    padding: 1.25rem;
    border: 1px solid #e5e7eb;
}

.permissions-title {
    font-size: 16px;
    font-weight: 600;
    color: #374151;
    margin-bottom: 0.8rem;
}

.permissions-list {
    display: flex;
    flex-direction: column;
    gap: 0.6rem;
}

.permission-item {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    font-size: 14px;
    color: #6b7280;
}

/* Security Alert */
.security-alert {
    background-color: #fef3c7;
    border: 1px solid #fde68a;
    border-radius: 8px;
    padding: 1.25rem;
    display: flex;
    align-items: flex-start;
    gap: 0.9rem;
}

.alert-icon {
    color: #92400e;
    font-size: 20px;
    margin-top: 0.1rem;
    flex-shrink: 0;
}

.alert-content {
    flex: 1;
}

.alert-title {
    font-size: 16px;
    font-weight: 600;
    color: #92400e;
    margin-bottom: 0.4rem;
}

.alert-text {
    color: #92400e;
    font-size: 14px;
    line-height: 1.5;
    margin: 0;
}

.modal-footer-enhanced {
    padding: 1.75rem;
    background: white;
    border-top: 1px solid #e5e7eb;
    display: flex;
    gap: 0.8rem;
    justify-content: flex-end;
}

.btn-cancel {
    background: #f9fafb;
    border: 1px solid #e5e7eb;
    color: #6b7280;
    padding: 0.75rem 1.25rem;
    border-radius: 6px;
    font-weight: 600;
    font-size: 14px;
    transition: all 0.2s ease;
}

.btn-cancel:hover {
    background: #f3f4f6;
    border-color: #d1d5db;
    color: #374151;
}

.btn-generate {
    background-color: #0066cc;
    border: none;
    color: white;
    padding: 0.75rem 1.25rem;
    border-radius: 6px;
    font-weight: 600;
    font-size: 14px;
    transition: all 0.2s ease;
}

.btn-generate:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 102, 204, 0.2);
    background-color: #0052a3;
}

/* Responsive Design for API Keys */
@media (max-width: 1200px) {
    .page-title {
        font-size: 1.75rem;
    }

    .api-icon {
        font-size: 4rem;
    }

    .usage-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 992px) {
    .card-header-modern {
        flex-direction: column;
        text-align: center;
        gap: 1rem;
    }

    .header-actions {
        width: 100%;
    }

    .header-actions .btn-generate {
        width: 100%;
    }

    .usage-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 768px) {
    .api-keys-page {
        padding: 1rem 0;
    }

    .page-header-api {
        padding: 2rem 1.5rem;
    }

    .page-title {
        font-size: 2rem;
    }

    .page-subtitle {
        font-size: 1rem;
    }

    .metric-card {
        padding: 1.5rem;
    }

    .metric-value {
        font-size: 2rem;
    }

    .api-keys-card,
    .usage-card {
        margin-bottom: 2rem;
    }

    .card-header-modern {
        padding: 1.5rem;
    }

    .card-body-modern {
        padding: 1.5rem;
    }

    .keys-table th,
    .keys-table td {
        padding: 1rem 0.5rem;
    }

    .key-name-cell {
        flex-direction: column;
        text-align: center;
        gap: 0.5rem;
    }

    .key-field-container {
        flex-direction: column;
        gap: 0.5rem;
        max-width: none;
    }

    .key-actions {
        justify-content: center;
    }

    .actions-cell {
        justify-content: center;
    }

    .empty-state-api {
        padding: 3rem 1rem;
    }

    .empty-title {
        font-size: 1.5rem;
    }

    .usage-item {
        flex-direction: column;
        text-align: center;
        gap: 1rem;
    }

    .modal-body-enhanced {
        padding: 1.5rem;
    }

    .modal-header-enhanced {
        padding: 1.5rem;
        flex-direction: column;
        text-align: center;
        gap: 0.75rem;
    }

    .modal-footer-enhanced {
        padding: 1.5rem;
        flex-direction: column;
    }

    .btn-cancel,
    .btn-generate {
        width: 100%;
    }
}

@media (max-width: 576px) {
    .page-title {
        font-size: 1.8rem;
    }

    .metric-value {
        font-size: 1.8rem;
    }

    .metric-icon {
        width: 50px;
        height: 50px;
        font-size: 1.25rem;
    }

    .header-title {
        font-size: 1.3rem;
    }

    .security-notice,
    .security-alert {
        flex-direction: column;
        text-align: center;
        gap: 0.75rem;
    }

    .key-input {
        font-size: 0.85rem;
        padding: 0.625rem 0.75rem;
    }

    .btn-action {
        width: 32px;
        height: 32px;
        font-size: 0.8rem;
    }

    .usage-value {
        font-size: 1.5rem;
    }

    .permissions-preview {
        padding: 1rem;
    }

    .permissions-list {
        gap: 0.5rem;
    }
}

/* Legacy API Key Styles (for backward compatibility) */
.api-key-alert {
    max-height: 150px;
    overflow-y: auto;
    word-wrap: break-word;
}

.api-key-field {
    font-family: 'Monaco', 'Menlo', 'Ubuntu Mono', monospace;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.input-group {
    display: flex;
    gap: 5px;
}

/* Authentication Pages Styles */
.login-page, .register-page {
    min-height: 100vh;
    background-color: #f9fafb;
    position: relative;
    overflow: hidden;
}

.login-bg-pattern, .register-bg-pattern {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-image: url("data:image/svg+xml,%3Csvg width='60' height='60' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M0 0h60v60H0z' fill='none'/%3E%3Cpath d='M0 0l60 60M60 0L0 60' stroke='rgba(0,102,204,0.02)' stroke-width='1'/%3E%3C/svg%3E");
    opacity: 0.5;
}

.brand-section {
    padding: 2rem 0;
}

.brand-logo {
    margin-bottom: 2rem;
}

.brand-title {
    font-size: 42px;
    font-weight: 700;
    letter-spacing: -1px;
}

.brand-text {
    color: #374151;
}

.brand-accent {
    color: #0066cc;
}

.brand-subtitle {
    font-size: 24px;
    font-weight: 600;
    color: #374151;
    margin-bottom: 1rem;
}

.brand-description {
    font-size: 15px;
    color: #6b7280;
    line-height: 1.6;
    margin-bottom: 2rem;
}

.login-card, .register-card {
    background: white;
    border-radius: 12px;
    padding: 2rem;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.05);
    border: 1px solid #e5e7eb;
}

.login-header, .register-header {
    text-align: center;
    margin-bottom: 2rem;
}

.login-title, .register-title {
    font-size: 24px;
    font-weight: 700;
    color: #374151;
    margin-bottom: 0.5rem;
}

.login-subtitle, .register-subtitle {
    font-size: 14px;
    color: #6b7280;
}

.login-form, .register-form {
    display: flex;
    flex-direction: column;
    gap: 1.25rem;
}

.form-group {
    margin-bottom: 0;
}

.form-label {
    font-size: 14px;
    font-weight: 600;
    color: #374151;
    margin-bottom: 0.5rem;
    display: flex;
    align-items: center;
    gap: 0.4rem;
}

.form-label i {
    font-size: 13px;
    color: #0066cc;
}

.input-group {
    position: relative;
}

.form-control {
    padding: 0.75rem 1rem;
    border: 1px solid #e5e7eb;
    border-radius: 6px;
    font-size: 14px;
    transition: all 0.2s ease;
    width: 100%;
}

.form-control:focus {
    outline: none;
    border-color: #0066cc;
    box-shadow: 0 0 0 3px rgba(0, 102, 204, 0.1);
}

.input-icon {
    position: absolute;
    right: 1rem;
    top: 50%;
    transform: translateY(-50%);
    color: #9ca3af;
    cursor: pointer;
    font-size: 14px;
}

.form-options {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0.5rem;
}

.form-check-label {
    font-size: 14px;
    color: #6b7280;
}

.forgot-link {
    font-size: 14px;
    color: #0066cc;
    text-decoration: none;
    font-weight: 500;
}

.forgot-link:hover {
    text-decoration: underline;
}

.btn-login, .btn-register {
    background-color: #0066cc;
    border: none;
    color: white;
    padding: 0.875rem 1.5rem;
    border-radius: 6px;
    font-size: 15px;
    font-weight: 600;
    transition: all 0.2s ease;
    width: 100%;
}

.btn-login:hover, .btn-register:hover {
    background-color: #0052a3;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(0, 102, 204, 0.2);
}

.divider {
    text-align: center;
    margin: 1.5rem 0;
    position: relative;
}

.divider::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 0;
    right: 0;
    height: 1px;
    background: #e5e7eb;
}

.divider-text {
    background: white;
    padding: 0 1rem;
    color: #9ca3af;
    font-size: 13px;
    position: relative;
}

.social-login {
    display: flex;
    gap: 1rem;
}

.btn-social {
    flex: 1;
    padding: 0.75rem;
    border-radius: 6px;
    font-size: 14px;
    font-weight: 600;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
}

.btn-google {
    background: white;
    border: 1px solid #e5e7eb;
    color: #374151;
}

.btn-google:hover {
    background: #f9fafb;
    transform: translateY(-1px);
}

.signup-link, .signin-link {
    text-align: center;
    margin-top: 1.5rem;
    font-size: 14px;
    color: #6b7280;
}

.signup-link a, .signin-link a {
    color: #0066cc;
    text-decoration: none;
    font-weight: 600;
}

.signup-link a:hover, .signin-link a:hover {
    text-decoration: underline;
}

.login-alert, .register-alert {
    border-radius: 6px;
    padding: 0.875rem 1rem;
    font-size: 14px;
    margin-bottom: 1rem;
}
