/* Microsoft Fluent Design Inspired Styles */
/* Copyright © 2025 Isaiah Nyalali. All Rights Reserved. */

:root {
    /* Fluent Colors */
    --fluent-black: #1A1A1A;
    --fluent-white: #ffffff;
    --fluent-gray-10: #faf9f8;
    --fluent-gray-20: #f3f2f1;
    --fluent-gray-30: #edebe9;
    --fluent-gray-40: #e1dfdd;
    --fluent-gray-50: #d2d0ce;
    --fluent-gray-60: #c8c6c4;
    --fluent-gray-70: #a19f9d;
    --fluent-gray-80: #605e5c;
    --fluent-gray-90: #323130;
    --fluent-gray-100: #201f1e;

    /* Accent Colors */
    --fluent-accent: #0078d4;
    --fluent-accent-hover: #106ebe;
    --fluent-success: #107c10;
    --fluent-error: #d13438;
    --fluent-warning: #ffb900;

    /* Shadows */
    --fluent-shadow-2: 0 0.3px 0.9px rgba(0, 0, 0, 0.108), 0 1.6px 3.6px rgba(0, 0, 0, 0.132);
    --fluent-shadow-4: 0 1.6px 3.6px rgba(0, 0, 0, 0.132), 0 0.3px 0.9px rgba(0, 0, 0, 0.108);
    --fluent-shadow-8: 0 3.2px 7.2px rgba(0, 0, 0, 0.132), 0 0.6px 1.8px rgba(0, 0, 0, 0.108);
    --fluent-shadow-16: 0 6.4px 14.4px rgba(0, 0, 0, 0.132), 0 1.2px 3.6px rgba(0, 0, 0, 0.108);
    --fluent-shadow-64: 0 25.6px 57.6px rgba(0, 0, 0, 0.22), 0 4.8px 14.4px rgba(0, 0, 0, 0.18);

    /* Border Radius */
    --fluent-radius-small: 2px;
    --fluent-radius-medium: 4px;
    --fluent-radius-large: 8px;

    /* Transitions */
    --fluent-duration-fast: 0.1s;
    --fluent-duration-normal: 0.2s;
    --fluent-duration-slow: 0.3s;
    --fluent-easing: cubic-bezier(0.1, 0.9, 0.2, 1);
}

/* Acrylic Effect */
.acrylic {
    background: rgba(255, 255, 255, 0.7);
    backdrop-filter: blur(30px) saturate(125%);
    -webkit-backdrop-filter: blur(30px) saturate(125%);
}

.acrylic-dark {
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(30px) saturate(125%);
    -webkit-backdrop-filter: blur(30px) saturate(125%);
}

/* Reveal Effect on Hover */
.reveal {
    position: relative;
    overflow: hidden;
}

.reveal::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.1);
    transform: translate(-50%, -50%);
    transition: width var(--fluent-duration-normal) var(--fluent-easing),
        height var(--fluent-duration-normal) var(--fluent-easing);
}

.reveal:hover::before {
    width: 300px;
    height: 300px;
}

/* Fluent Cards */
.fluent-card {
    background: var(--fluent-white);
    border: 1px solid var(--fluent-gray-40);
    border-radius: var(--fluent-radius-large);
    box-shadow: var(--fluent-shadow-2);
    transition: all var(--fluent-duration-normal) var(--fluent-easing);
}

.fluent-card:hover {
    box-shadow: var(--fluent-shadow-8);
    transform: translateY(-2px);
}

/* Fluent Buttons */
.fluent-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 8px 16px;
    font-size: 14px;
    font-weight: 600;
    border: none;
    border-radius: var(--fluent-radius-medium);
    cursor: pointer;
    transition: all var(--fluent-duration-fast) var(--fluent-easing);
    position: relative;
    overflow: hidden;
}



.fluent-btn-primary {
    background: var(--fluent-black);
    color: var(--fluent-white);
}

.fluent-btn-primary:hover {
    background: var(--fluent-gray-90);
    box-shadow: var(--fluent-shadow-4);
}

.fluent-btn-secondary {
    background: var(--fluent-white);
    color: var(--fluent-black);
    border: 1px solid var(--fluent-gray-60);
}

.fluent-btn-secondary a {
    text-decoration: none;
}

.fluent-btn-secondary:hover {
    background: var(--fluent-gray-20);
    border-color: var(--fluent-gray-70);
}

.fluent-btn-success {
    background: var(--fluent-success);
    color: var(--fluent-white);
}

.fluent-btn-success:hover {
    background: #0e6b0e;
    box-shadow: var(--fluent-shadow-4);
}

/* Fluent Inputs */
.fluent-input {
    width: 100%;
    padding: 8px 12px;
    font-size: 14px;
    border: 1px solid var(--fluent-gray-60);
    border-radius: var(--fluent-radius-medium);
    background: var(--fluent-white);
    transition: all var(--fluent-duration-fast) var(--fluent-easing);
}

.fluent-input:hover {
    border-color: var(--fluent-gray-80);
}

.fluent-input:focus {
    outline: none;
    border-color: var(--fluent-black);
    box-shadow: 0 0 0 1px var(--fluent-black);
}

/* Fluent Labels */
.fluent-label {
    display: block;
    font-size: 14px;
    font-weight: 600;
    color: var(--fluent-gray-90);
    margin-bottom: 4px;
}

/* Toast Notifications */
.toast-container {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 10000;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.toast {
    min-width: 300px;
    padding: 16px 20px;
    background: var(--fluent-white);
    border-left: 4px solid var(--fluent-black);
    border-radius: var(--fluent-radius-medium);
    box-shadow: var(--fluent-shadow-16);
    display: flex;
    align-items: center;
    gap: 12px;
    animation: slideInRight 0.3s var(--fluent-easing);
}

.toast.success {
    border-left-color: var(--fluent-success);
}

.toast.error {
    border-left-color: var(--fluent-error);
}

.toast.warning {
    border-left-color: var(--fluent-warning);
}

.toast-icon {
    font-size: 20px;
    flex-shrink: 0;
}

.toast-content {
    flex: 1;
}

.toast-title {
    font-weight: 600;
    margin-bottom: 4px;
}

.toast-message {
    font-size: 13px;
    color: var(--fluent-gray-80);
}

.toast-close {
    background: none;
    border: none;
    font-size: 18px;
    cursor: pointer;
    color: var(--fluent-gray-70);
    padding: 0;
    width: 24px;
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: all var(--fluent-duration-fast);
}

.toast-close:hover {
    background: var(--fluent-gray-30);
    color: var(--fluent-gray-90);
}

@keyframes slideInRight {
    from {
        transform: translateX(400px);
        opacity: 0;
    }

    to {
        transform: translateX(0);
        opacity: 1;
    }
}

@keyframes slideOutRight {
    from {
        transform: translateX(0);
        opacity: 1;
    }

    to {
        transform: translateX(400px);
        opacity: 0;
    }
}

/* Custom Modal */
.fluent-modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.4);
    backdrop-filter: blur(4px);
    z-index: 9999;
    align-items: center;
    justify-content: center;
    animation: fadeIn 0.2s var(--fluent-easing);
}

.fluent-modal.active {
    display: flex;
}

.fluent-modal-content {
    background: var(--fluent-white);
    border-radius: var(--fluent-radius-large);
    box-shadow: var(--fluent-shadow-64);
    max-width: 500px;
    width: 90%;
    max-height: 90vh;
    overflow-y: auto;
    animation: scaleIn 0.3s var(--fluent-easing);
}

.fluent-modal-header {
    padding: 20px 24px;
    border-bottom: 1px solid var(--fluent-gray-40);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.fluent-modal-title {
    font-size: 20px;
    font-weight: 600;
    margin: 0;
}

.fluent-modal-close {
    background: none;
    border: none;
    font-size: 24px;
    cursor: pointer;
    color: var(--fluent-gray-70);
    padding: 0;
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: all var(--fluent-duration-fast);
}

.fluent-modal-close:hover {
    background: var(--fluent-gray-30);
    color: var(--fluent-gray-90);
}

.fluent-modal-body {
    padding: 24px;
}

.fluent-modal-footer {
    padding: 16px 24px;
    border-top: 1px solid var(--fluent-gray-40);
    display: flex;
    justify-content: flex-end;
    gap: 12px;
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }

    to {
        opacity: 1;
    }
}

@keyframes scaleIn {
    from {
        transform: scale(0.9);
        opacity: 0;
    }

    to {
        transform: scale(1);
        opacity: 1;
    }
}

/* Compact Form Styles */
.fluent-form-group {
    margin-bottom: 16px;
}

.fluent-form-row {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 16px;
}

/* Loading Spinner */
.fluent-spinner {
    width: 20px;
    height: 20px;
    border: 2px solid var(--fluent-gray-40);
    border-top-color: var(--fluent-black);
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

/* Status Badges */
.fluent-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 4px 12px;
    font-size: 12px;
    font-weight: 600;
    border-radius: 12px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.fluent-badge.success {
    background: #dff6dd;
    color: #107c10;
}

.fluent-badge.pending {
    background: #fff4ce;
    color: #8a6d3b;
}

.fluent-badge.error {
    background: #fde7e9;
    color: #d13438;
}

.fluent-badge.info {
    background: #e1f5fe;
    color: #0078d4;
}