/* ===== RESET & BASE STYLES ===== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Inter', sans-serif;
    line-height: 1.6;
    color: #374151;
    background-color: #f9fafb;
    transition: all 0.3s ease;
}

/* ===== HERO SECTION ===== */
/* Updated: Enhanced visibility and contrast */
.hero-bg {
    background: #000000 !important;
    background-image: 
        linear-gradient(135deg, #000000 0%, #111111 50%, #222222 100%),
        radial-gradient(circle at 20% 50%, rgba(59, 130, 246, 0.05) 0%, transparent 50%),
        radial-gradient(circle at 80% 20%, rgba(16, 185, 129, 0.05) 0%, transparent 50%),
        radial-gradient(circle at 40% 80%, rgba(139, 92, 246, 0.05) 0%, transparent 50%);
    position: relative;
    overflow: hidden;
}

.hero-bg::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-image: 
        radial-gradient(1px 1px at 20px 30px, #ffffff, transparent),
        radial-gradient(1px 1px at 40px 70px, #ffffff, transparent),
        radial-gradient(1px 1px at 60px 20px, #ffffff, transparent),
        radial-gradient(1px 1px at 80px 50px, #ffffff, transparent),
        radial-gradient(1px 1px at 100px 80px, #ffffff, transparent),
        radial-gradient(1px 1px at 120px 10px, #ffffff, transparent),
        radial-gradient(1px 1px at 140px 60px, #ffffff, transparent),
        radial-gradient(1px 1px at 160px 30px, #ffffff, transparent),
        radial-gradient(1px 1px at 180px 90px, #ffffff, transparent),
        radial-gradient(1px 1px at 200px 40px, #ffffff, transparent),
        radial-gradient(1px 1px at 220px 70px, #ffffff, transparent),
        radial-gradient(1px 1px at 240px 15px, #ffffff, transparent),
        radial-gradient(1px 1px at 260px 85px, #ffffff, transparent),
        radial-gradient(1px 1px at 280px 25px, #ffffff, transparent),
        radial-gradient(1px 1px at 300px 55px, #ffffff, transparent),
        radial-gradient(1px 1px at 320px 95px, #ffffff, transparent),
        radial-gradient(1px 1px at 340px 35px, #ffffff, transparent),
        radial-gradient(1px 1px at 360px 65px, #ffffff, transparent),
        radial-gradient(1px 1px at 380px 5px, #ffffff, transparent),
        radial-gradient(1px 1px at 400px 75px, #ffffff, transparent);
    background-repeat: repeat;
    background-size: 420px 100px;
    animation: sparkle 40s linear infinite;
}

.hero-content {
    position: relative;
    z-index: 2;
}

.hero-content h1 {
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.5);
    color: #ffffff !important;
}

.hero-content h2 {
    text-shadow: 1px 1px 3px rgba(0, 0, 0, 0.5);
    color: #93c5fd !important;
}

.hero-content p {
    text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.5);
    color: #e5e7eb !important;
}

.hero-content .btn-primary {
    background: linear-gradient(135deg, #3b82f6 0%, #1d4ed8 100%);
    box-shadow: 0 4px 15px rgba(59, 130, 246, 0.4);
    border: 2px solid rgba(255, 255, 255, 0.2);
}

.hero-content .btn-secondary {
    background: rgba(255, 255, 255, 0.1);
    border: 2px solid rgba(255, 255, 255, 0.8);
    backdrop-filter: blur(10px);
    color: #ffffff;
}

.hero-content .btn-secondary:hover {
    background: rgba(255, 255, 255, 0.9);
    color: #1e3a8a;
    transform: translateY(-2px);
}

.hero-content .floating {
    filter: drop-shadow(0 4px 8px rgba(0, 0, 0, 0.3));
}

.hero-content .floating i {
    color: #93c5fd !important;
    filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.4));
}

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

@keyframes sparkle {
    0% { transform: translateY(0px); }
    100% { transform: translateY(-100px); }
}

/* ===== FLOATING CONTROLS ===== */
.floating-controls {
    position: fixed;
    top: 120px;
    right: 24px;
    z-index: 30; /* Lower than header z-index (40) to ensure proper layering */
    display: flex;
    flex-direction: column;
    gap: 12px;
    transition: all 0.3s ease;
    opacity: 1;
    transform: translateY(0);
    /* Positioned below the header with proper spacing */
}

/* ===== CHATBOT WIDGET ===== */
.chatbot-widget {
    position: fixed;
    bottom: 24px;
    right: 24px;
    z-index: 50;
    font-family: 'Inter', sans-serif;
}

.chatbot-toggle {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    background: linear-gradient(135deg, #3b82f6 0%, #1d4ed8 100%);
    border: none;
    color: white;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 8px 25px rgba(59, 130, 246, 0.4);
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.chatbot-toggle:hover {
    transform: translateY(-2px) scale(1.05);
    box-shadow: 0 12px 35px rgba(59, 130, 246, 0.6);
}

.chatbot-toggle:active {
    transform: translateY(0) scale(0.95);
}

.chatbot-notification-dot {
    position: absolute;
    top: 8px;
    right: 8px;
    width: 12px;
    height: 12px;
    background: #ef4444;
    border-radius: 50%;
    border: 2px solid white;
    animation: pulse-notification 2s infinite;
}

@keyframes pulse-notification {
    0% { transform: scale(1); opacity: 1; }
    50% { transform: scale(1.2); opacity: 0.7; }
    100% { transform: scale(1); opacity: 1; }
}

.chatbot-window {
    position: absolute;
    bottom: 80px;
    right: 0;
    width: 350px;
    height: 500px;
    background: white;
    border-radius: 16px;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.15);
    display: none;
    flex-direction: column;
    overflow: hidden;
    border: 1px solid #e5e7eb;
    animation: chatbotSlideUp 0.3s ease-out;
    z-index: 9998;
}

.chatbot-window.active {
    display: flex;
}

@keyframes chatbotSlideUp {
    from {
        opacity: 0;
        transform: translateY(20px) scale(0.95);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

.chatbot-header {
    background: linear-gradient(135deg, #3b82f6 0%, #1d4ed8 100%);
    color: white;
    padding: 16px 20px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.chatbot-header-actions {
    display: flex;
    gap: 8px;
    align-items: center;
}

.chatbot-header-info {
    display: flex;
    align-items: center;
    gap: 12px;
}

.chatbot-avatar {
    width: 40px;
    height: 40px;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    backdrop-filter: blur(10px);
}

.chatbot-title h3 {
    margin: 0;
    font-size: 16px;
    font-weight: 600;
}

.chatbot-status {
    font-size: 12px;
    opacity: 0.8;
    display: flex;
    align-items: center;
    gap: 4px;
}

.chatbot-status::before {
    content: '';
    width: 8px;
    height: 8px;
    background: #10b981;
    border-radius: 50%;
    display: inline-block;
}

.chatbot-close,
.chatbot-fullscreen {
    background: none;
    border: none;
    color: white;
    cursor: pointer;
    padding: 4px;
    border-radius: 4px;
    transition: background-color 0.2s ease;
}

.chatbot-close:hover,
.chatbot-fullscreen:hover {
    background: rgba(255, 255, 255, 0.1);
}

.chatbot-messages {
    flex: 1;
    padding: 20px;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
    gap: 16px;
    background: #f9fafb;
}

.chatbot-message {
    display: flex;
    gap: 12px;
    animation: messageSlideIn 0.3s ease-out;
}

@keyframes messageSlideIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.bot-message {
    align-items: flex-start;
}

.user-message {
    align-items: flex-end;
    flex-direction: row-reverse;
}

.message-avatar {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.bot-message .message-avatar {
    background: linear-gradient(135deg, #3b82f6 0%, #1d4ed8 100%);
    color: white;
}

.user-message .message-avatar {
    background: #e5e7eb;
    color: #374151;
}

.message-content {
    max-width: 80%;
    background: white;
    padding: 12px 16px;
    border-radius: 18px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    position: relative;
}

.user-message .message-content {
    background: linear-gradient(135deg, #3b82f6 0%, #1d4ed8 100%);
    color: white;
}

.message-content p {
    margin: 0;
    font-size: 14px;
    line-height: 1.4;
}

/* Enhanced formatting for bot messages */
.message-text {
    font-size: 14px;
    line-height: 1.5;
}

.message-text strong {
    font-weight: 600;
    color: #1f2937;
}

.user-message .message-text strong {
    color: white;
}

.message-text em {
    font-style: italic;
    color: #6b7280;
}

.user-message .message-text em {
    color: rgba(255, 255, 255, 0.8);
}

/* Bullet point styling */
.message-text {
    text-align: left;
}

.message-text br {
    margin-bottom: 4px;
}

/* Better spacing for formatted content */
.message-text {
    white-space: pre-line;
}

/* Fullscreen mode styles */
.chatbot-window.fullscreen {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    max-width: none;
    max-height: none;
    border-radius: 0;
    z-index: 9999;
    transform: none;
    margin: 0;
    right: auto;
}

.chatbot-window.fullscreen .chatbot-messages {
    height: calc(100vh - 140px);
    max-height: none;
}

/* Fullscreen button icon change - now handled by JavaScript */

.message-time {
    font-size: 11px;
    opacity: 0.6;
    margin-top: 4px;
    display: block;
}

.chatbot-input-container {
    padding: 16px 20px;
    background: white;
    border-top: 1px solid #e5e7eb;
}

.chatbot-input-wrapper {
    display: flex;
    gap: 8px;
    align-items: center;
}

.chatbot-input {
    flex: 1;
    padding: 12px 16px;
    border: 1px solid #d1d5db;
    border-radius: 24px;
    font-size: 14px;
    outline: none;
    transition: border-color 0.2s ease;
    background: #f9fafb;
}

.chatbot-input:focus {
    border-color: #3b82f6;
    background: white;
}

.chatbot-send {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: linear-gradient(135deg, #3b82f6 0%, #1d4ed8 100%);
    border: none;
    color: white;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
}

.chatbot-send:hover {
    transform: scale(1.05);
    box-shadow: 0 4px 12px rgba(59, 130, 246, 0.4);
}

.chatbot-send:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    transform: none;
}

.chatbot-typing-indicator {
    display: flex;
    gap: 4px;
    padding: 8px 0;
    justify-content: center;
}

.chatbot-typing-indicator span {
    width: 8px;
    height: 8px;
    background: #9ca3af;
    border-radius: 50%;
    animation: typingBounce 1.4s infinite ease-in-out;
}

.chatbot-typing-indicator span:nth-child(1) {
    animation-delay: -0.32s;
}

.chatbot-typing-indicator span:nth-child(2) {
    animation-delay: -0.16s;
}

@keyframes typingBounce {
    0%, 80%, 100% {
        transform: scale(0);
    }
    40% {
        transform: scale(1);
    }
}

/* Dark mode styles for chatbot */
.dark-mode .chatbot-window {
    background: #2d2d2d;
    border-color: #404040;
}

.dark-mode .chatbot-messages {
    background: #1a1a1a;
}

.dark-mode .chatbot-input-container {
    background: #2d2d2d;
    border-color: #404040;
}

.dark-mode .message-content {
    background: #374151;
    color: #e5e5e5;
}

.dark-mode .user-message .message-content {
    background: linear-gradient(135deg, #3b82f6 0%, #1d4ed8 100%);
    color: white;
}

.dark-mode .chatbot-input {
    background: #374151;
    border-color: #6b7280;
    color: #e5e5e5;
}

.dark-mode .chatbot-input:focus {
    background: #4b5563;
    border-color: #3b82f6;
}

.dark-mode .user-message .message-avatar {
    background: #4b5563;
    color: #e5e5e5;
}

/* Mobile responsiveness for chatbot */
@media (max-width: 768px) {
    .chatbot-widget {
        bottom: 16px;
        right: 16px;
    }
    
    .chatbot-window {
        position: fixed !important;
        width: calc(100vw - 32px);
        height: calc(100vh - 140px);
        top: 50% !important;
        left: 50% !important;
        bottom: auto !important;
        right: auto !important;
        transform: translate(-50%, -50%) !important;
        margin: 0 !important;
        max-width: 400px;
    }
    
    .chatbot-toggle {
        width: 56px;
        height: 56px;
    }
    
    /* Prevent body scroll when chatbot is open */
    body.chatbot-open {
        overflow: hidden;
        position: fixed;
        width: 100%;
    }
}

@media (max-width: 480px) {
    .chatbot-window {
        position: fixed !important;
        width: calc(100vw - 16px) !important;
        height: calc(100vh - 120px) !important;
        border-radius: 12px;
        top: 50% !important;
        left: 50% !important;
        bottom: auto !important;
        right: auto !important;
        transform: translate(-50%, -50%) !important;
        margin: 0 !important;
    }
    
    .chatbot-header {
        padding: 12px 16px;
    }
    
    .chatbot-messages {
        padding: 16px;
    }
    
    .chatbot-input-container {
        padding: 12px 16px;
    }
}

/* Animation when scrolling */
.floating-controls.scrolled {
    opacity: 0.95;
    transform: scale(0.95);
}

/* Visual separation from header */
.floating-controls::before {
    content: '';
    position: absolute;
    top: -10px;
    left: -10px;
    right: -10px;
    bottom: -10px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    z-index: -1;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.floating-controls:hover::before {
    opacity: 1;
}

/* Pulse animation for attention */
.floating-controls .language-toggle,
.floating-controls .dark-mode-toggle {
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0% { box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15); }
    50% { box-shadow: 0 4px 12px rgba(59, 130, 246, 0.3); }
    100% { box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15); }
}

/* Hide on mobile to avoid conflicts */
@media (max-width: 768px) {
    .floating-controls {
        display: none;
    }
}

/* ===== TOGGLE BUTTONS ===== */
.language-toggle,
.dark-mode-toggle {
    background: rgba(255, 255, 255, 0.95);
    border: 1px solid rgba(0, 0, 0, 0.1);
    border-radius: 50%;
    width: 44px !important;
    height: 44px !important;
    min-width: 44px !important;
    min-height: 44px !important;
    max-width: 44px !important;
    max-height: 44px !important;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s ease;
    backdrop-filter: blur(10px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    font-size: 12px;
    font-weight: 600;
}

.language-toggle:hover,
.dark-mode-toggle:hover {
    background: rgba(255, 255, 255, 1);
    transform: translateY(-3px) scale(1.05);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.25);
}

/* Dark mode styles for toggle buttons */
.dark .language-toggle,
.dark .dark-mode-toggle {
    background: rgba(31, 41, 55, 0.9);
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: #f9fafb;
}

.dark .language-toggle:hover,
.dark .dark-mode-toggle:hover {
    background: rgba(31, 41, 55, 1);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.4);
}

/* Force floating buttons to be in column */
.flex.flex-col.items-end.relative {
    display: flex !important;
    flex-direction: column !important;
    align-items: flex-end !important;
    position: relative !important;
}

.flex.flex-col.items-end.relative .flex.gap-1.mt-2 {
    display: flex !important;
    flex-direction: row !important;
    gap: 0.25rem !important;
    margin-top: 0.5rem !important;
    width: auto !important;
}

/* Override any conflicting Tailwind styles */
.hidden.md\\:flex.flex-col.items-end.relative {
    display: flex !important;
    flex-direction: column !important;
    align-items: flex-end !important;
}

/* ===== PROJECT CARDS ===== */
.project-card {
    transition: all 0.3s ease;
    cursor: pointer;
    border: 1px solid #e5e7eb;
    position: relative;
    overflow: hidden;
}

.project-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.2), transparent);
    transition: left 0.5s;
}

.project-card:hover::before {
    left: 100%;
}

.project-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 20px 25px -5px rgb(0 0 0 / 0.1), 0 8px 10px -6px rgb(0 0 0 / 0.1);
    border-color: #3b82f6;
}

/* ===== SKILL BARS ===== */
.skill-bar {
    transition: width 1.5s ease-in-out;
    position: relative;
    overflow: hidden;
}

.skill-bar::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    bottom: 0;
    right: 0;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.3), transparent);
    transform: translateX(-100%);
    animation: skillShine 2s infinite;
}

@keyframes skillShine {
    0% { transform: translateX(-100%); }
    100% { transform: translateX(100%); }
}

/* ===== ANIMATIONS ===== */
.floating {
    animation: floating 3s ease-in-out infinite;
}

@keyframes floating {
    0%, 100% { transform: translateY(0px); }
    50% { transform: translateY(-10px); }
}

.fade-in {
    animation: fadeIn 0.8s ease-in;
}

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

.slide-in-left {
    animation: slideInLeft 0.8s ease-out;
}

@keyframes slideInLeft {
    from { opacity: 0; transform: translateX(-50px); }
    to { opacity: 1; transform: translateX(0); }
}

.slide-in-right {
    animation: slideInRight 0.8s ease-out;
}

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

/* ===== GRADIENT TEXT ===== */
.gradient-text {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    display: inline-block;
}

/* ===== DARK MODE STYLES ===== */
.dark-mode {
    background-color: #1a1a1a;
    color: #e5e5e5;
}

.dark-mode .bg-white {
    background-color: #2d2d2d !important;
    border-color: #404040;
}

.dark-mode .text-gray-900 {
    color: #e5e5e5 !important;
}

.dark-mode .text-gray-600 {
    color: #a0a0a0 !important;
}

.dark-mode .text-gray-500 {
    color: #9ca3af !important;
}

.dark-mode .bg-gray-50 {
    background-color: #1a1a1a !important;
}

.dark-mode .bg-gray-900 {
    background-color: #0d0d0d !important;
}

.dark-mode .bg-gray-800 {
    background-color: #374151 !important;
}

.dark-mode .border-gray-200 {
    border-color: #404040 !important;
}

.dark-mode .border-gray-700 {
    border-color: #6b7280 !important;
}

.dark-mode .project-card {
    border-color: #404040;
}

.dark-mode .project-card:hover {
    border-color: #3b82f6;
}

/* ===== MODAL STYLES ===== */
.modal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0,0,0,0.8);
    backdrop-filter: blur(5px);
    animation: modalFadeIn 0.3s ease-out;
}

@keyframes modalFadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

.modal-content {
    background-color: white;
    margin: 5% auto;
    padding: 0;
    border-radius: 12px;
    width: 90%;
    max-width: 800px;
    max-height: 90vh;
    overflow-y: auto;
    animation: modalSlideIn 0.3s ease-out;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
}

.dark-mode .modal-content {
    background-color: #2d2d2d;
    color: #e5e5e5;
}

/* Modal navigation */
.modal-navigation {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 100%;
    display: flex;
    justify-content: space-between;
    pointer-events: none;
    z-index: 1001; /* Higher than modal content */
    left: 0;
    right: 0;
}

.modal-nav-btn {
    background: rgba(0, 0, 0, 0.7);
    color: white;
    border: none;
    padding: 12px;
    border-radius: 50%;
    cursor: pointer;
    transition: all 0.3s ease;
    pointer-events: auto;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 48px;
    height: 48px;
    z-index: 1002; /* Higher than modal navigation container */
    position: relative;
}

.modal-nav-btn:hover {
    background: rgba(0, 0, 0, 0.9);
    transform: scale(1.1);
}

.modal-prev {
    margin-left: 20px;
}

.modal-next {
    margin-right: 20px;
}

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

/* Enhanced modal opening animation */
@keyframes modalOpen {
    from { 
        transform: scale(0.8) translateY(-30px);
        opacity: 0;
    }
    to { 
        transform: scale(1) translateY(0);
        opacity: 1;
    }
}

@keyframes modalBackdropFade {
    from { 
        opacity: 0;
        backdrop-filter: blur(0px);
    }
    to { 
        opacity: 1;
        backdrop-filter: blur(5px);
    }
}

.modal-content.modal-open {
    animation: modalOpen 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.modal.modal-backdrop-fade {
    animation: modalBackdropFade 0.3s ease-out;
}

/* Modal navigation animations */
@keyframes slideInFromRight {
    from { 
        transform: translateX(100%);
        opacity: 0;
    }
    to { 
        transform: translateX(0);
        opacity: 1;
    }
}

@keyframes slideInFromLeft {
    from { 
        transform: translateX(-100%);
        opacity: 0;
    }
    to { 
        transform: translateX(0);
        opacity: 1;
    }
}

@keyframes slideOutToLeft {
    from { 
        transform: translateX(0);
        opacity: 1;
    }
    to { 
        transform: translateX(-100%);
        opacity: 0;
    }
}

@keyframes slideOutToRight {
    from { 
        transform: translateX(0);
        opacity: 1;
    }
    to { 
        transform: translateX(100%);
        opacity: 0;
    }
}

.modal-content.slide-in-right {
    animation: slideInFromRight 0.3s ease-out;
}

.modal-content.slide-in-left {
    animation: slideInFromLeft 0.3s ease-out;
}

.modal-content.slide-out-left {
    animation: slideOutToLeft 0.3s ease-out;
}

.modal-content.slide-out-right {
    animation: slideOutToRight 0.3s ease-out;
}

.close {
    color: #aaa;
    float: right;
    font-size: 28px;
    font-weight: bold;
    cursor: pointer;
    position: absolute;
    right: 20px;
    top: 15px;
    z-index: 1001;
    transition: color 0.3s ease;
}

.close:hover {
    color: #000;
}

.dark-mode .close:hover {
    color: #fff;
}

/* ===== NAVIGATION STYLES ===== */
.nav-link {
    position: relative;
    transition: color 0.3s ease;
}

.nav-link::after {
    content: '';
    position: absolute;
    width: 0;
    height: 2px;
    bottom: -5px;
    left: 0;
    background-color: #3b82f6;
    transition: width 0.3s ease;
}

.nav-link:hover::after {
    width: 100%;
}

.nav-link:hover {
    color: #3b82f6;
}

/* ===== MOBILE MENU ===== */
.mobile-menu {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background-color: white;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
    border-radius: 0 0 8px 8px;
    z-index: 50;
}

.mobile-menu.active {
    display: block;
    animation: slideDown 0.3s ease-out;
}

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

.dark-mode .mobile-menu {
    background-color: #2d2d2d;
}

/* ===== BUTTON STYLES ===== */
.btn-primary {
    background: linear-gradient(135deg, #3b82f6 0%, #1d4ed8 100%);
    color: white;
    padding: 12px 24px;
    border-radius: 8px;
    font-weight: 600;
    transition: all 0.3s ease;
    border: none;
    cursor: pointer;
    position: relative;
    overflow: hidden;
}

.btn-primary::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.2), transparent);
    transition: left 0.5s;
}

.btn-primary:hover::before {
    left: 100%;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 20px rgba(59, 130, 246, 0.3);
}

.btn-secondary {
    background: transparent;
    color: white;
    border: 2px solid white;
    padding: 12px 24px;
    border-radius: 8px;
    font-weight: 600;
    transition: all 0.3s ease;
    cursor: pointer;
}

.btn-secondary:hover {
    background: white;
    color: #3b82f6;
    transform: translateY(-2px);
}

/* ===== FORM STYLES ===== */
.form-input {
    width: 100%;
    padding: 12px 16px;
    border-radius: 8px;
    border: 1px solid #d1d5db;
    background-color: white;
    color: #374151;
    transition: all 0.3s ease;
    font-size: 16px;
}

.form-input:focus {
    outline: none;
    border-color: #3b82f6;
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
}

.dark-mode .form-input {
    background-color: #374151;
    border-color: #6b7280;
    color: #e5e5e5;
}

.dark-mode .form-input:focus {
    border-color: #3b82f6;
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.2);
}

.form-textarea {
    resize: vertical;
    min-height: 120px;
}

/* ===== TESTIMONIAL CARDS ===== */
.testimonial-card {
    background: white;
    padding: 24px;
    border-radius: 12px;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
    border: 1px solid #e5e7eb;
}

.testimonial-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 10px 25px -3px rgba(0, 0, 0, 0.1);
}

.dark-mode .testimonial-card {
    background-color: #2d2d2d;
    border-color: #404040;
}

/* ===== SKILL CARDS ===== */
.skill-card {
    background: white;
    padding: 24px;
    border-radius: 12px;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
    border: 1px solid #e5e7eb;
}

.skill-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 15px -3px rgba(0, 0, 0, 0.1);
}

.dark-mode .skill-card {
    background-color: #2d2d2d;
    border-color: #404040;
}

/* ===== POSITIONED TOGGLE BUTTONS (Legacy - now handled by floating controls) ===== */
/* These styles are kept for backward compatibility but floating controls are preferred */

/* ===== HERO SECTION BUTTONS ===== */
.hero-content .flex {
    gap: 1rem;
    flex-wrap: wrap;
    justify-content: center;
    align-items: center;
}

.hero-content .btn-primary,
.hero-content .btn-secondary {
    min-width: 180px;
    margin: 0.5rem;
    position: relative;
    z-index: 10;
}

/* ===== RESPONSIVE DESIGN ===== */
@media (max-width: 768px) {
    .hero-bg {
        padding: 60px 0;
    }
    
    .project-card {
        margin-bottom: 20px;
    }
    
    .modal-content {
        width: 95%;
        margin: 10% auto;
    }
    
    .skill-card,
    .testimonial-card {
        margin-bottom: 16px;
    }
    
    .hero-content .btn-primary,
    .hero-content .btn-secondary {
        min-width: 160px;
        font-size: 0.9rem;
        padding: 0.75rem 1rem;
    }
}

@media (max-width: 480px) {
    .hero-bg {
        padding: 40px 0;
    }
    
    .modal-content {
        width: 98%;
        margin: 5% auto;
    }
    
    .btn-primary,
    .btn-secondary {
        width: 100%;
        margin-bottom: 12px;
    }
    
    .hero-content .btn-primary,
    .hero-content .btn-secondary {
        min-width: 140px;
        font-size: 0.85rem;
        padding: 0.6rem 0.8rem;
    }
}

/* ===== UTILITY CLASSES ===== */
/* Removed redundant Tailwind utility classes - using Tailwind CDN instead */

/* ===== LOADING ANIMATIONS ===== */
.loading {
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 3px solid rgba(255,255,255,.3);
    border-radius: 50%;
    border-top-color: #fff;
    animation: spin 1s ease-in-out infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* ===== SCROLL ANIMATIONS ===== */
.scroll-reveal {
    opacity: 0;
    transform: translateY(30px);
    transition: all 0.6s ease;
}

.scroll-reveal.revealed {
    opacity: 1;
    transform: translateY(0);
}

/* ===== CUSTOM SCROLLBAR ===== */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: #f1f1f1;
}

::-webkit-scrollbar-thumb {
    background: #c1c1c1;
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: #a8a8a8;
}

.dark-mode ::-webkit-scrollbar-track {
    background: #2d2d2d;
}

.dark-mode ::-webkit-scrollbar-thumb {
    background: #555;
}

.dark-mode ::-webkit-scrollbar-thumb:hover {
    background: #777;
}
