* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
}

html {
    font-size: 16px;
    scroll-behavior: smooth;
    -webkit-text-size-adjust: 100%;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

body {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    background: linear-gradient(135deg, #2a1b3d 0%, #44318d 50%, #632c7a 100%);
    position: relative;
    overflow-x: hidden;
    width: 100%;
    line-height: 1.5;
}

h1 { font-size: clamp(2rem, 8vw, 4rem); }
h2 { font-size: clamp(1.5rem, 6vw, 2.2rem); }
h3 { font-size: clamp(1.2rem, 4vw, 1.5rem); }
h4 { font-size: clamp(1rem, 3vw, 1.3rem); }
p { font-size: clamp(0.875rem, 2.5vw, 1.2rem); }

.main-nav {
    background: rgba(42, 27, 61, 0.95);
    border-bottom: 1px solid rgba(230, 126, 212, 0.2);
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.2);
    position: fixed;
    width: 100%;
    top: 0;
    z-index: 1000;
}

.nav-container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0.8rem clamp(0.5rem, 3vw, 2rem);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo a img {
    width: clamp(45px, 8vw, 65px);
    height: clamp(45px, 8vw, 65px);
    border: 3px solid #ffc17f;
    border-radius: 50%;
    object-fit: cover;
    transition: transform 0.4s ease;
    box-shadow: 0 0 10px rgba(255, 193, 127, 0.2);
}

.logo a img:hover {
    border-color: #32f5e5;
    transform: scale(1.12) rotate(-30deg);
}

.nav-menu {
    display: flex;
    list-style: none;
    gap: clamp(0.2rem, 1vw, 0.5rem);
}

.nav-menu li a {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    padding: 0.7rem clamp(0.8rem, 2vw, 1.3rem);
    text-decoration: none;
    color: rgba(255, 255, 255, 0.85);
    font-weight: 500;
    border-radius: 50px;
    transition: background-color 0.2s ease, color 0.2s ease;
    white-space: nowrap;
}

.nav-menu li a span {
    font-size: clamp(0.8rem, 2vw, 1rem);
}

.nav-menu li a i {
    font-size: clamp(0.9rem, 2.5vw, 1.1rem);
}

.nav-menu li a:hover,
.nav-menu li a.active {
    background: rgba(230, 126, 212, 0.15);
    color: #e67ed4;
}

.nav-menu li a.active {
    border: 1px solid rgba(230, 126, 212, 0.3);
}

.hamburger {
    display: none;
    flex-direction: column;
    cursor: pointer;
    padding: 5px;
    z-index: 1001;
}

.hamburger span {
    width: clamp(22px, 5vw, 28px);
    height: 3px;
    background: #e67ed4;
    margin: 3px 0;
    transition: 0.3s ease;
    border-radius: 2px;
}

.home-section {
    flex: 1;
    margin-top: 85px;
    min-height: calc(100vh - 85px);
    display: flex;
    align-items: center;
    padding: clamp(1rem, 3vw, 2rem);
    position: relative;
    width: 100%;
}

.home-content {
    max-width: 1400px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(min(300px, 100%), 1fr));
    gap: clamp(1rem, 4vw, 4rem);
    align-items: center;
    padding: clamp(1rem, 3vw, 2rem);
    width: 100%;
}

.home-text {
    position: relative;
    z-index: 2;
}

.badge {
    margin-bottom: clamp(1rem, 3vw, 1.5rem);
}

.live-badge {
    background: rgba(230, 126, 212, 0.15);
    border: 1px solid rgba(230, 126, 212, 0.4);
    color: #e67ed4;
    padding: 0.5rem clamp(0.8rem, 2vw, 1.2rem);
    border-radius: 50px;
    font-size: clamp(0.75rem, 2vw, 0.9rem);
    font-weight: 600;
    display: inline-block;
}

.home-text h4 {
    color: rgba(255, 255, 255, 0.8);
    font-size: clamp(1rem, 3vw, 1.3rem);
    margin-bottom: 1rem;
    font-weight: 400;
}

.home-text h1 {
    color: #fff;
    margin-bottom: 0.5rem;
    line-height: 1.2;
    word-wrap: break-word;
}

.highlight {
    color: #e67ed4;
    position: relative;
    display: inline-block;
}

.highlight::after {
    content: '';
    position: absolute;
    bottom: 5px;
    left: 0;
    width: 100%;
    height: 8px;
    background: rgba(230, 126, 212, 0.2);
    border-radius: 4px;
    z-index: -1;
}

.home-text h2 {
    color: rgba(255, 255, 255, 0.95);
    margin-bottom: 1.5rem;
    font-weight: 400;
}

.home-text p {
    color: rgba(255, 255, 255, 0.7);
    line-height: 1.8;
    margin-bottom: 2.5rem;
    max-width: 550px;
}

.home-buttons {
    display: flex;
    gap: clamp(0.8rem, 2vw, 1.2rem);
    flex-wrap: wrap;
    margin-bottom: 2.5rem;
}

.btn {
    padding: clamp(0.8rem, 2vw, 1rem) clamp(1.5rem, 4vw, 2.2rem);
    text-decoration: none;
    border-radius: 50px;
    font-weight: 600;
    display: inline-flex;
    align-items: center;
    gap: 0.8rem;
    transition: all 0.2s ease;
    border: none;
    cursor: pointer;
    font-size: clamp(0.875rem, 2.5vw, 1rem);
}

.btn span {
    position: relative;
    z-index: 1;
}

.btn i {
    transition: transform 0.2s ease;
}

.btn.primary {
    background: #e67ed4;
    color: #2a1b3d;
    box-shadow: 0 4px 10px rgba(230, 126, 212, 0.3);
}

.btn.primary:hover {
    background: #a64d79;
    color: #fff;
    transform: translateY(-2px);
}

.btn.secondary {
    background: transparent;
    color: #fff;
    border: 2px solid rgba(230, 126, 212, 0.5);
}

.btn.secondary:hover {
    border-color: #a64d79;
    color: #a64d79;
    transform: translateY(-2px);
}

.social-links {
    display: flex;
    gap: clamp(0.8rem, 2vw, 1.2rem);
    flex-wrap: wrap;
}

.social-icon {
    width: clamp(35px, 8vw, 45px);
    height: clamp(35px, 8vw, 45px);
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(230, 126, 212, 0.2);
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    text-decoration: none;
    transition: all 0.2s ease;
    font-size: clamp(1rem, 2.5vw, 1.2rem);
}

.social-icon:hover {
    background: linear-gradient(135deg, #e67ed4, #a64d79);
    color: #fff;
    transform: translateY(-2px) scale(1.05);
}

.home-image {
    display: flex;
    justify-content: center;
    align-items: center;
    position: relative;
    z-index: 1;
}

.image-container {
    width: min(450px, 80vw);
    height: min(450px, 80vw);
    background: rgba(255, 255, 255, 0.03);
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
    border: 3px solid rgba(230, 126, 212, 0.3);
    position: relative;
    box-shadow: 0 20px 30px rgba(0, 0, 0, 0.3);
    overflow: hidden;
}

.profile-logo {
    width: 80%; 
    height: 80%;
    object-fit: contain;
    filter: drop-shadow(0 5px 10px rgba(255, 193, 127, 0.3));
    z-index: 2;
    transition: transform 0.3s ease;
    border-radius: 50%;
}

.image-container:hover .profile-logo {
    transform: scale(1.05) rotate(25deg);
}

.profile-logo {
    width: 100%;
    height: 100%;
    object-fit: cover;
}
.floating-shape, .floating-shape-2 {
    position: absolute;
    width: 100px;
    height: 100px;
    border-radius: 30% 70% 70% 30% / 30% 30% 70% 70%;
    background: rgba(230, 126, 212, 0.05);
    border: 2px dashed rgba(230, 126, 212, 0.2);
    z-index: 1;
}

.floating-shape {
    top: -20px;
    right: -20px;
}

.floating-shape-2 {
    bottom: -30px;
    left: -10px;
    width: 150px;
    height: 150px;
}

.scroll-indicator {
    position: absolute;
    bottom: clamp(10px, 3vh, 30px);
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
    color: rgba(255, 255, 255, 0.6);
    font-size: clamp(0.8rem, 2vw, 0.9rem);
    z-index: 5;
}

.scroll-indicator i {
    color: #e67ed4;
    font-size: 1.2rem;
}

footer {
    background: rgba(42, 27, 61, 0.95);
    border-top: 1px solid rgba(230, 126, 212, 0.1);
    padding: clamp(0.8rem, 2vh, 1.2rem);
    text-align: center;
    color: rgba(255, 255, 255, 0.7);
    font-size: clamp(0.8rem, 2vw, 0.95rem);
    width: 100%;
    margin-top: auto;
}

.footer-content p:hover {
    color: #e67ed4;
}

@media (max-width: 320px) {
    html { font-size: 14px; }
    
    .nav-menu li a span { display: none; }
    .nav-menu li a i { font-size: 1.2rem; }
    .nav-menu li a { padding: 0.5rem; }
    
    .home-buttons { flex-direction: column; }
    .btn { width: 100%; justify-content: center; }
}

@media (max-width: 480px) {
    .nav-container { padding: 0.5rem; }
    .logo a img { width: 45px; height: 45px; }
    
    .nav-menu li a span { 
        display: none; 
    }
    .nav-menu li a i { 
        font-size: 1.3rem; 
        margin: 0;
    }
    .nav-menu li a { 
        padding: 0.8rem; 
        justify-content: center;
    }
    
    .home-text { text-align: center; }
    .home-buttons { justify-content: center; }
    .social-links { justify-content: center; }
    
    .badge { margin-bottom: 1rem; }
    .profile-logo { width: 85%; height: 85%; }
}

@media (max-width: 768px) {
    .hamburger { display: flex; }

    .nav-menu {
        position: fixed;
        left: -100%;
        top: 85px;
        flex-direction: column;
        background: rgba(42, 27, 61, 0.98);
        width: 100%;
        text-align: center;
        transition: 0.3s ease-in-out;
        padding: 2rem 0;
        gap: 1rem;
        border-bottom: 1px solid rgba(230, 126, 212, 0.2);
    }

    .nav-menu.active {
        left: 0;
    }

    .nav-menu li a span { 
        display: inline-block; 
        font-size: 1.1rem;
    }
    .nav-menu li a { 
        padding: 1rem 2rem; 
        justify-content: center;
        gap: 1rem;
    }
    
    .home-content {
        grid-template-columns: 1fr;
        text-align: center;
    }
    
    .home-text p { margin: 0 auto 2.5rem; }
    .floating-shape, .floating-shape-2 { display: none; }
    .profile-logo { width: 85%; height: 85%; }
}

@media (min-width: 769px) and (max-width: 1024px) {
    .nav-menu li a { padding: 0.5rem 1rem; }
    .nav-menu li a span { font-size: 0.9rem; }
}

@media (min-width: 1025px) and (max-width: 1440px) {
    .nav-container { max-width: 1200px; }
    .home-content { max-width: 1200px; }
}

@media (min-width: 1441px) {
    html { font-size: 18px; }
    .nav-container { max-width: 1600px; }
    .home-content { max-width: 1600px; }
}

@media (max-height: 500px) and (orientation: landscape) {
    .home-section { margin-top: 70px; }
    .home-content { gap: 1rem; }
    .image-container { width: 200px; height: 200px; }
    .profile-logo { width: 90%; height: 90%; }
    .scroll-indicator { display: none; }
}

@media (prefers-reduced-motion: reduce) {
    * {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
        scroll-behavior: auto !important;
    }
}

@media (hover: none) and (pointer: coarse) {
    .btn:hover, .social-icon:hover {
        transform: none;
    }
    
    .nav-menu li a {
        padding: 1rem;
    }
}

.visitor-counter {
    position: fixed;
    bottom: 20px;
    left: 20px;
    z-index: 999;
}

.counter-container {
    background: rgba(230, 126, 212, 0.15);
    backdrop-filter: blur(5px);
    border: 1px solid rgba(230, 126, 212, 0.3);
    border-radius: 50px;
    padding: 0.5rem 1.2rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: #fff;
    font-size: 0.9rem;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.2);
}

.counter-container i {
    color: #e67ed4;
    font-size: 1rem;
}

#visitorCount {
    color: #e67ed4;
    font-weight: 600;
    min-width: 30px;
    text-align: center;
}

@media (max-width: 480px) {
    .visitor-counter {
        bottom: 10px;
        left: 10px;
    }
    
    .counter-container {
        padding: 0.3rem 1rem;
        font-size: 0.8rem;
    }
}

.login-trigger {
    position: fixed;
    bottom: 50px;
    right: 20px;
    background: rgba(230, 126, 212, 0.15);
    border: 1px solid rgba(230, 126, 212, 0.3);
    border-radius: 50px;
    padding: 0.6rem 1.2rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: #fff;
    font-size: 0.9rem;
    cursor: pointer;
    z-index: 998;
    backdrop-filter: blur(5px);
    transition: background 0.2s;
}

.login-trigger i {
    color: #e67ed4;
    font-size: 1.1rem;
}

.login-trigger:hover {
    background: rgba(230, 126, 212, 0.3);
}

.popup-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.7);
    backdrop-filter: blur(5px);
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 9999;
}

.popup-overlay.active {
    display: flex;
}

.popup-container {
    width: 90%;
    max-width: 450px;
    background: rgba(42, 27, 61, 0.95);
    border: 2px solid rgba(230, 126, 212, 0.3);
    border-radius: 20px;
    padding: 2rem;
    position: relative;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.4);
}

.popup-close {
    position: absolute;
    top: 15px;
    right: 15px;
    background: none;
    border: none;
    color: rgba(255, 255, 255, 0.5);
    font-size: 1.2rem;
    cursor: pointer;
    transition: color 0.2s;
}

.popup-close:hover {
    color: #e67ed4;
}

.popup-tabs {
    display: flex;
    gap: 1rem;
    margin-bottom: 2rem;
    border-bottom: 1px solid rgba(230, 126, 212, 0.2);
    padding-bottom: 1rem;
}

.tab-btn {
    background: none;
    border: none;
    color: rgba(255, 255, 255, 0.5);
    font-size: 1.1rem;
    font-weight: 600;
    padding: 0.5rem 1rem;
    cursor: pointer;
    transition: all 0.2s;
    border-radius: 8px;
}

.tab-btn.active {
    color: #e67ed4;
    background: rgba(230, 126, 212, 0.1);
}

.popup-form {
    display: none;
}

.popup-form.active {
    display: block;
}

.popup-form h3 {
    color: #fff;
    font-size: 1.5rem;
    margin-bottom: 0.3rem;
}

.popup-form p {
    color: rgba(255, 255, 255, 0.6);
    font-size: 0.9rem;
    margin-bottom: 1.5rem;
}

.popup-input-group {
    display: flex;
    align-items: center;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(230, 126, 212, 0.2);
    border-radius: 10px;
    padding: 0.8rem 1rem;
    margin-bottom: 1rem;
}

.popup-input-group i {
    color: #e67ed4;
    width: 20px;
    margin-right: 0.8rem;
}

.popup-input-group input {
    background: none;
    border: none;
    color: #fff;
    font-size: 0.95rem;
    width: 100%;
    outline: none;
}

.popup-input-group input::placeholder {
    color: rgba(255, 255, 255, 0.3);
}

.popup-options {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.5rem;
}

.popup-checkbox {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: rgba(255, 255, 255, 0.7);
    font-size: 0.9rem;
    cursor: pointer;
}

.popup-checkbox input[type="checkbox"] {
    accent-color: #e67ed4;
    width: 16px;
    height: 16px;
}

.terms {
    margin: 1rem 0;
}

.forgot-link {
    color: #e67ed4;
    text-decoration: none;
    font-size: 0.9rem;
}

.forgot-link:hover {
    text-decoration: underline;
}

.popup-submit {
    width: 100%;
    background: #e67ed4;
    color: #2a1b3d;
    border: none;
    border-radius: 10px;
    padding: 1rem;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.2s;
    margin-bottom: 1.5rem;
}

.popup-submit:hover {
    background: #a64d79;
    color: #fff;
}

@media (max-width: 480px) {
    .login-trigger {
        bottom: 15px;
        right: 15px;
        padding: 0.5rem 1rem;
        font-size: 0.85rem;
    }
    
    .popup-container {
        padding: 1.5rem;
    }
    
    .popup-tabs {
        gap: 0.5rem;
    }
    
    .tab-btn {
        font-size: 1rem;
        padding: 0.4rem 0.8rem;
    }
    
    .popup-form h3 {
        font-size: 1.3rem;
    }
    
    .popup-options {
        flex-direction: column;
        gap: 0.8rem;
        align-items: flex-start;
    }
}

.profile-dropdown {
    position: fixed;
    bottom: 80px;
    right: 20px;
    width: 280px;
    background: rgba(42, 27, 61, 0.98);
    border: 2px solid rgba(230, 126, 212, 0.3);
    border-radius: 16px;
    backdrop-filter: blur(10px);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
    z-index: 1000;
    transform: scale(0.95);
    opacity: 0;
    visibility: hidden;
    transition: all 0.2s ease;
    transform-origin: bottom right;
}

.profile-dropdown.show {
    transform: scale(1);
    opacity: 1;
    visibility: visible;
}

.profile-header {
    padding: 1.2rem;
    display: flex;
    align-items: center;
    gap: 1rem;
    border-bottom: 1px solid rgba(230, 126, 212, 0.2);
}

.profile-circle {
    width: 50px;
    height: 50px;
    background: linear-gradient(135deg, #e67ed4, #a64d79);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    font-size: 1.5rem;
    font-weight: 600;
    text-transform: uppercase;
    border: 2px solid rgba(255, 255, 255, 0.3);
    box-shadow: 0 5px 10px rgba(0, 0, 0, 0.2);
}

.profile-info {
    display: flex;
    flex-direction: column;
    gap: 0.2rem;
}

.profile-name {
    color: #fff;
    font-size: 1rem;
    font-weight: 600;
}

.profile-email {
    color: rgba(255, 255, 255, 0.6);
    font-size: 0.8rem;
}

.dropdown-divider {
    height: 1px;
    background: rgba(230, 126, 212, 0.2);
    margin: 0.5rem 0;
}

.dropdown-item {
    padding: 0.8rem 1.2rem;
    display: flex;
    align-items: center;
    gap: 1rem;
    color: rgba(255, 255, 255, 0.8);
    cursor: pointer;
    transition: background 0.2s;
}

.dropdown-item:hover {
    background: rgba(230, 126, 212, 0.15);
    color: #e67ed4;
}

.dropdown-item i {
    width: 20px;
    color: #e67ed4;
}

.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.7);
    backdrop-filter: blur(5px);
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 10000;
}

.modal-overlay.active {
    display: flex;
}

.modal-container {
    width: 90%;
    max-width: 400px;
    background: rgba(42, 27, 61, 0.98);
    border: 2px solid rgba(230, 126, 212, 0.3);
    border-radius: 20px;
    overflow: hidden;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.4);
}

.modal-header {
    padding: 1.2rem 1.5rem;
    background: rgba(230, 126, 212, 0.1);
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid rgba(230, 126, 212, 0.2);
}

.modal-header h3 {
    color: #e67ed4;
    font-size: 1.2rem;
    margin: 0;
}

.modal-close {
    background: none;
    border: none;
    color: rgba(255, 255, 255, 0.5);
    font-size: 1.2rem;
    cursor: pointer;
    transition: color 0.2s;
}

.modal-close:hover {
    color: #e67ed4;
}

.modal-body {
    padding: 1.5rem;
}

.user-detail-item {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 0.8rem;
    border-bottom: 1px solid rgba(230, 126, 212, 0.1);
}

.user-detail-item:last-child {
    border-bottom: none;
}

.user-detail-item i {
    width: 20px;
    color: #e67ed4;
}

.detail-label {
    color: rgba(255, 255, 255, 0.6);
    font-size: 0.9rem;
    min-width: 80px;
}

.detail-value {
    color: #fff;
    font-size: 0.95rem;
    font-weight: 500;
    word-break: break-all;
}

.notification {
    position: fixed;
    top: 20px;
    right: 20px;
    background: rgba(42, 27, 61, 0.95);
    border-left: 4px solid #e67ed4;
    border-radius: 8px;
    padding: 1rem 1.5rem;
    display: flex;
    align-items: center;
    gap: 1rem;
    color: #fff;
    z-index: 10000;
    transform: translateX(120%);
    transition: transform 0.3s ease;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
}

.notification.show {
    transform: translateX(0);
}

.notification.success {
    border-left-color: #00ff00;
}

.notification.success i {
    color: #00ff00;
}

.notification.error {
    border-left-color: #ff4444;
}

.notification.error i {
    color: #ff4444;
}

@media (max-width: 480px) {
    .profile-dropdown {
        width: 260px;
        right: 10px;
        bottom: 70px;
    }
    
    .modal-container {
        width: 95%;
    }
    
    .user-detail-item {
        flex-wrap: wrap;
        gap: 0.5rem;
    }
    
    .detail-label {
        min-width: 70px;
    }
    
    .notification {
        top: 10px;
        right: 10px;
        left: 10px;
        padding: 0.8rem 1rem;
        font-size: 0.9rem;
    }
}

/* ===== SMART AI ASSISTANT STYLES - OPTIMIZED FOR 1366x768 ===== */

/* AI Trigger Button */
.smart-ai-trigger {
    position: fixed;
    bottom: 100px;
    right: 20px;
    width: 50px;
    height: 50px;
    background: linear-gradient(135deg, #667eea, #764ba2);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 1.5rem;
    cursor: pointer;
    z-index: 999999;
    box-shadow: 0 5px 20px rgba(102, 126, 234, 0.5);
    transition: all 0.3s ease;
    border: 2px solid rgba(255, 255, 255, 0.3);
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0% { transform: scale(1); }
    50% { transform: scale(1.05); }
    100% { transform: scale(1); }
}

.smart-ai-trigger:hover {
    transform: scale(1.1) rotate(5deg);
    box-shadow: 0 8px 25px rgba(102, 126, 234, 0.8);
}

.smart-ai-badge {
    position: absolute;
    top: -5px;
    right: -5px;
    background: #ff4444;
    color: white;
    font-size: 0.65rem;
    padding: 2px 6px;
    border-radius: 12px;
    font-weight: bold;
    border: 2px solid #2a1b3d;
    letter-spacing: 0.5px;
}

/* AI Main Container - Small Size for 1366x768 */
.smart-ai-container {
    position: fixed;
    bottom: 150px;
    right: 20px;
    width: 300px;  /* Compact width */
    height: 420px; /* Compact height */
    background: rgba(30, 25, 40, 0.98);
    backdrop-filter: blur(10px);
    border: 2px solid rgba(102, 126, 234, 0.5);
    border-radius: 16px;
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.5);
    z-index: 999998;
    display: flex;
    flex-direction: column;
    transform: scale(0);
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s cubic-bezier(0.68, -0.55, 0.265, 1.55);
    transform-origin: bottom right;
}

.smart-ai-container.show {
    transform: scale(1);
    opacity: 1;
    visibility: visible;
}

/* Header */
.smart-ai-header {
    padding: 10px 15px;
    background: linear-gradient(135deg, rgba(102, 126, 234, 0.2), rgba(118, 75, 162, 0.2));
    border-bottom: 1px solid rgba(102, 126, 234, 0.3);
    border-radius: 16px 16px 0 0;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.smart-ai-header-left {
    display: flex;
    align-items: center;
    gap: 8px;
}

.smart-ai-header-left i {
    color: #667eea;
    font-size: 1.2rem;
}

.smart-ai-header-left h3 {
    color: white;
    font-size: 0.9rem;
    margin: 0;
    font-weight: 600;
}

.smart-ai-status {
    color: #4ade80;
    font-size: 0.6rem;
    display: block;
    margin-top: 2px;
    font-weight: 400;
}

.smart-ai-header-right {
    display: flex;
    gap: 5px;
}

.smart-ai-clear, .smart-ai-close {
    background: rgba(255, 255, 255, 0.1);
    border: none;
    color: rgba(255, 255, 255, 0.7);
    width: 26px;
    height: 26px;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.2s;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.8rem;
}

.smart-ai-clear:hover {
    background: #ff4444;
    color: white;
}

.smart-ai-close:hover {
    background: #667eea;
    color: white;
}

/* Messages Area */
.smart-ai-messages {
    flex: 1;
    overflow-y: auto;
    padding: 12px;
    display: flex;
    flex-direction: column;
    gap: 10px;
    scroll-behavior: smooth;
    background: rgba(0, 0, 0, 0.2);
}

/* Custom Scrollbar */
.smart-ai-messages::-webkit-scrollbar {
    width: 4px;
}

.smart-ai-messages::-webkit-scrollbar-track {
    background: rgba(102, 126, 234, 0.1);
    border-radius: 4px;
}

.smart-ai-messages::-webkit-scrollbar-thumb {
    background: #667eea;
    border-radius: 4px;
}

/* Message Bubbles */
.smart-ai-message {
    display: flex;
    gap: 8px;
    max-width: 100%;
    animation: fadeIn 0.3s ease;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

.smart-ai-user {
    flex-direction: row-reverse;
}

.smart-ai-avatar {
    width: 26px;
    height: 26px;
    border-radius: 50%;
    background: rgba(102, 126, 234, 0.2);
    display: flex;
    align-items: center;
    justify-content: center;
    color: #667eea;
    font-size: 0.75rem;
    flex-shrink: 0;
    border: 1px solid rgba(102, 126, 234, 0.3);
}

.smart-ai-user .smart-ai-avatar {
    background: rgba(255, 255, 255, 0.1);
    color: white;
    border-color: rgba(255, 255, 255, 0.2);
}

.smart-ai-bubble {
    background: rgba(102, 126, 234, 0.1);
    padding: 8px 12px;
    border-radius: 12px;
    border-top-left-radius: 0;
    color: rgba(255, 255, 255, 0.95);
    font-size: 0.8rem;
    line-height: 1.5;
    word-wrap: break-word;
    max-width: calc(100% - 40px);
    border: 1px solid rgba(102, 126, 234, 0.2);
}

.smart-ai-user .smart-ai-bubble {
    background: rgba(102, 126, 234, 0.2);
    border-radius: 12px;
    border-top-right-radius: 0;
    border-color: rgba(102, 126, 234, 0.3);
}

.smart-ai-bubble p {
    margin: 0;
}

.smart-ai-bubble p + p {
    margin-top: 8px;
}

.smart-ai-bubble ul, .smart-ai-bubble ol {
    margin: 5px 0 5px 20px;
    padding: 0;
}

.smart-ai-bubble li {
    margin: 3px 0;
    line-height: 1.4;
}

.smart-ai-bubble a {
    color: #667eea;
    text-decoration: none;
    font-weight: 500;
}

.smart-ai-bubble a:hover {
    text-decoration: underline;
}

.smart-ai-bubble strong {
    color: #fff;
    font-weight: 600;
}

.smart-ai-bubble em {
    color: #a78bfa;
    font-style: italic;
}

/* Typing Indicator */
.smart-ai-typing {
    display: flex;
    gap: 4px;
    padding: 8px 12px;
    background: rgba(102, 126, 234, 0.1);
    border-radius: 12px;
    border-top-left-radius: 0;
    width: fit-content;
    border: 1px solid rgba(102, 126, 234, 0.2);
}

.smart-ai-typing span {
    width: 6px;
    height: 6px;
    background: #667eea;
    border-radius: 50%;
    animation: typing 1s infinite ease-in-out;
}

.smart-ai-typing span:nth-child(2) {
    animation-delay: 0.2s;
}

.smart-ai-typing span:nth-child(3) {
    animation-delay: 0.4s;
}

@keyframes typing {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-6px); }
}

/* Input Area */
.smart-ai-input-area {
    padding: 12px;
    border-top: 1px solid rgba(102, 126, 234, 0.2);
    background: rgba(0, 0, 0, 0.2);
    border-radius: 0 0 16px 16px;
}

.smart-ai-input-wrapper {
    display: flex;
    gap: 8px;
    margin-bottom: 8px;
}

.smart-ai-input-wrapper input {
    flex: 1;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(102, 126, 234, 0.3);
    border-radius: 20px;
    padding: 8px 15px;
    color: white;
    font-size: 0.8rem;
    outline: none;
    transition: all 0.2s;
}

.smart-ai-input-wrapper input:focus {
    border-color: #667eea;
    box-shadow: 0 0 10px rgba(102, 126, 234, 0.3);
    background: rgba(255, 255, 255, 0.08);
}

.smart-ai-input-wrapper input::placeholder {
    color: rgba(255, 255, 255, 0.4);
    font-size: 0.75rem;
}

.smart-ai-input-wrapper button {
    width: 34px;
    height: 34px;
    border-radius: 50%;
    background: #667eea;
    border: none;
    color: white;
    font-size: 0.9rem;
    cursor: pointer;
    transition: all 0.2s;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0.5;
    transform: scale(0.95);
}

.smart-ai-input-wrapper button.active {
    opacity: 1;
    cursor: pointer;
    transform: scale(1);
}

.smart-ai-input-wrapper button.active:hover {
    background: #764ba2;
    transform: scale(1.05);
    box-shadow: 0 0 15px rgba(102, 126, 234, 0.5);
}

/* Suggested Questions */
.smart-ai-suggestions {
    display: flex;
    flex-wrap: wrap;
    gap: 5px;
    justify-content: center;
}

.smart-ai-suggestion {
    background: rgba(102, 126, 234, 0.1);
    border: 1px solid rgba(102, 126, 234, 0.3);
    border-radius: 12px;
    padding: 4px 8px;
    color: #a78bfa;
    font-size: 0.65rem;
    cursor: pointer;
    transition: all 0.2s;
    white-space: nowrap;
    font-weight: 500;
    letter-spacing: 0.3px;
}

.smart-ai-suggestion:hover {
    background: #667eea;
    color: white;
    border-color: #667eea;
    transform: translateY(-1px);
    box-shadow: 0 3px 8px rgba(102, 126, 234, 0.3);
}

/* Mobile Responsive */
@media (max-width: 480px) {
    .smart-ai-container {
        width: 280px;
        height: 400px;
        right: 10px;
        bottom: 70px;
    }
    
    .smart-ai-trigger {
        right: 10px;
        width: 45px;
        height: 45px;
        font-size: 1.3rem;
    }
    
    .login-trigger {
        right: 50px !important;
    }
}

/* Update login trigger position */
.login-trigger {
    right: 20px !important;
    bottom: 20px !important;
    z-index: 999997;
}

/* Small height screens */
@media (max-height: 700px) {
    .smart-ai-container {
        height: 380px;
    }
    
    .smart-ai-messages {
        padding: 8px;
    }
    
    .smart-ai-bubble {
        padding: 6px 10px;
        font-size: 0.75rem;
    }
}

/* Loading animation for first message */
.smart-ai-container.show .smart-ai-message:first-child {
    animation: slideIn 0.5s ease;
}

@keyframes slideIn {
    from {
        opacity: 0;
        transform: translateX(-10px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

/* Code block styling */
.smart-ai-bubble pre {
    background: rgba(0, 0, 0, 0.4);
    padding: 8px;
    border-radius: 6px;
    overflow-x: auto;
    margin: 8px 0;
    border: 1px solid rgba(102, 126, 234, 0.2);
}

.smart-ai-bubble code {
    font-family: 'Courier New', monospace;
    font-size: 0.75rem;
    color: #f472b6;
}

.smart-ai-bubble pre code {
    color: #a78bfa;
}

/* Link styling */
.smart-ai-bubble a {
    color: #60a5fa;
    text-decoration: none;
    border-bottom: 1px dashed #60a5fa;
}

.smart-ai-bubble a:hover {
    color: #93c5fd;
    border-bottom-style: solid;
}