/* 
  SBM Tech - Premium Theme CSS
*/

:root {
    --bg-light: #ffffff;
    --bg-dark: #0f172a;
    --text-light: #f8fafc;
    --text-dark: #1e293b;
    --text-muted: #64748b;
    --primary: #3b82f6;
    --primary-hover: #2563eb;
    --secondary: #10b981;
    --accent: #8b5cf6;
    
    --glass-bg: rgba(255, 255, 255, 0.05);
    --glass-border: rgba(255, 255, 255, 0.1);
    
    --radius-md: 12px;
    --radius-lg: 24px;
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Reset & Base */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Inter', sans-serif;
    background-color: var(--bg-light);
    color: var(--text-dark);
    line-height: 1.6;
    overflow-x: hidden;
}

html {
    scroll-behavior: smooth;
}

/* Container */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 24px;
}

.section-padding {
    padding: 100px 0;
}

/* Typography */
h1, h2, h3, h4 {
    font-weight: 700;
    line-height: 1.2;
    margin-bottom: 1rem;
}

h1 { font-size: clamp(2.5rem, 5vw, 4.5rem); letter-spacing: -0.02em; }
h2 { font-size: clamp(2rem, 4vw, 3rem); letter-spacing: -0.01em; }
h3 { font-size: 1.5rem; }

.highlight {
    background: linear-gradient(135deg, var(--primary), var(--accent));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

p {
    color: var(--text-muted);
    font-size: 1.125rem;
    margin-bottom: 1.5rem;
}

/* Buttons */
.btn-primary, .btn-secondary, .btn-primary-small {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 14px 28px;
    border-radius: 50px;
    font-weight: 600;
    text-decoration: none;
    transition: var(--transition);
    cursor: pointer;
    border: none;
    font-size: 1rem;
}

.btn-primary {
    background: linear-gradient(135deg, var(--primary), var(--accent));
    color: white;
    box-shadow: 0 4px 15px rgba(59, 130, 246, 0.3);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(59, 130, 246, 0.4);
    color: white;
}

.btn-primary-small {
    padding: 10px 20px;
    font-size: 0.9rem;
    background: var(--primary);
    color: white;
}
.btn-primary-small:hover {
    background: var(--primary-hover);
}

.btn-secondary {
    background: transparent;
    color: var(--text-dark);
    border: 2px solid var(--text-dark);
}

.btn-secondary:hover {
    background: var(--text-dark);
    color: white;
}

/* Header */
.site-header {
    position: fixed;
    top: 0;
    width: 100%;
    z-index: 1000;
    background: rgba(255, 255, 255, 0.8);
    backdrop-filter: blur(12px);
    border-bottom: 1px solid rgba(0,0,0,0.05);
    padding: 16px 0;
    transition: var(--transition);
}

.header-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo a {
    font-size: 1.5rem;
    font-weight: 700;
    text-decoration: none;
    color: var(--text-dark);
}

.logo span {
    color: var(--primary);
}

.main-nav ul {
    list-style: none;
    display: flex;
    align-items: center;
    gap: 32px;
}

.main-nav a {
    text-decoration: none;
    color: var(--text-dark);
    font-weight: 500;
    transition: var(--transition);
}

.main-nav a:hover:not(.btn-primary-small) {
    color: var(--primary);
}

.mobile-menu-toggle {
    display: none;
    flex-direction: column;
    gap: 5px;
    cursor: pointer;
}

.mobile-menu-toggle span {
    width: 25px;
    height: 3px;
    background: var(--text-dark);
    border-radius: 2px;
    transition: var(--transition);
}

/* Sections */
.dark-section {
    background-color: var(--bg-dark);
    color: var(--text-light);
}

.dark-section h2, .dark-section h3, .dark-section h4 {
    color: var(--text-light);
}

.dark-section p {
    color: #94a3b8;
}

.section-header {
    text-align: center;
    margin-bottom: 60px;
    max-width: 700px;
    margin-inline: auto;
}

/* Hero Section */
.hero-section {
    min-height: 100vh;
    display: flex;
    align-items: center;
    position: relative;
    padding-top: 80px;
    overflow: hidden;
}

.hero-content {
    position: relative;
    z-index: 2;
    max-width: 800px;
    text-align: center;
    margin: 0 auto;
}

.hero-actions {
    display: flex;
    gap: 16px;
    justify-content: center;
    margin-top: 32px;
}

/* Abstract Background Shapes */
.hero-bg-shapes {
    position: absolute;
    inset: 0;
    z-index: 1;
    overflow: hidden;
    pointer-events: none;
}

.shape {
    position: absolute;
    border-radius: 50%;
    filter: blur(80px);
    opacity: 0.5;
    z-index: 1;
}

.shape-1 {
    width: 400px;
    height: 400px;
    background: var(--primary);
    top: -100px;
    right: -100px;
}

.shape-2 {
    width: 300px;
    height: 300px;
    background: var(--accent);
    bottom: 100px;
    left: -50px;
}

/* Services Grid */
.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
}

.service-card {
    background: white;
    padding: 40px 30px;
    border-radius: var(--radius-md);
    box-shadow: 0 10px 30px rgba(0,0,0,0.03);
    border: 1px solid rgba(0,0,0,0.02);
    transition: var(--transition);
}

.service-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 20px 40px rgba(0,0,0,0.08);
}

.service-icon {
    font-size: 3rem;
    margin-bottom: 20px;
}

.link-arrow {
    text-decoration: none;
    color: var(--primary);
    font-weight: 600;
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.link-arrow span {
    transition: var(--transition);
}

.link-arrow:hover span {
    transform: translateX(5px);
}

/* Why Us / Features Grid */
.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 30px;
}

.feature-item {
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    padding: 30px;
    border-radius: var(--radius-md);
    backdrop-filter: blur(10px);
    transition: var(--transition);
}
.feature-item:hover {
    background: rgba(255,255,255,0.1);
    transform: translateY(-5px);
}
.feature-icon {
    font-size: 2.5rem;
    margin-bottom: 15px;
}

/* About Grid */
.grid-2-col {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 60px;
    align-items: center;
}

.glass-card {
    background: linear-gradient(135deg, rgba(255,255,255,0.9), rgba(255,255,255,0.5));
    border: 1px solid rgba(255,255,255,0.6);
    padding: 40px;
    border-radius: var(--radius-lg);
    box-shadow: 0 20px 40px rgba(0,0,0,0.05);
    backdrop-filter: blur(20px);
}
.glass-card h3 { margin-bottom: 5px; }
.glass-card .role { color: var(--primary); font-weight: 600; margin-bottom: 20px; }

.contact-chips {
    display: flex;
    flex-direction: column;
    gap: 10px;
}
.chip {
    background: #f1f5f9;
    padding: 10px 15px;
    border-radius: 50px;
    font-size: 0.9rem;
    font-weight: 500;
}

/* Portfolio */
.portfolio-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 40px;
}

.portfolio-card {
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-md);
    overflow: hidden;
    transition: var(--transition);
}

.portfolio-card:hover {
    transform: translateY(-5px);
    border-color: rgba(255,255,255,0.2);
}

.card-content {
    padding: 30px;
}

.tags {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 16px;
}

.tags span {
    background: rgba(59, 130, 246, 0.2);
    color: #93c5fd;
    padding: 4px 12px;
    border-radius: 50px;
    font-size: 0.8rem;
    font-weight: 600;
}

.problem-solution p {
    font-size: 0.95rem;
    margin-bottom: 10px;
}
.problem-solution strong { color: var(--text-light); }

/* Testimonials */
.testimonial-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
}

.testimonial-card {
    background: #f8fafc;
    padding: 40px;
    border-radius: var(--radius-md);
    position: relative;
}

.quote-icon {
    font-size: 4rem;
    color: var(--primary);
    opacity: 0.2;
    position: absolute;
    top: 10px;
    right: 30px;
    font-family: serif;
}

.author h4 { margin-bottom: 2px; }
.author span { font-size: 0.9rem; color: var(--text-muted); }

/* Contact Section */
.contact-wrapper {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 50px;
    align-items: center;
}

.glass-panel {
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    padding: 50px;
    border-radius: var(--radius-lg);
    backdrop-filter: blur(10px);
}

.contact-details {
    list-style: none;
    margin-top: 30px;
}
.contact-details li { margin-bottom: 15px; font-size: 1.1rem; }
.contact-details strong { color: white; }

.custom-form .form-group {
    margin-bottom: 20px;
}
.custom-form label {
    display: block;
    margin-bottom: 8px;
    font-weight: 500;
    color: var(--text-light);
}

.custom-form input, .custom-form textarea {
    width: 100%;
    padding: 14px;
    border-radius: 8px;
    border: 1px solid rgba(255,255,255,0.2);
    background: rgba(0,0,0,0.2);
    color: white;
    font-family: 'Inter', sans-serif;
    transition: var(--transition);
}

.custom-form input:focus, .custom-form textarea:focus {
    outline: none;
    border-color: var(--primary);
    background: rgba(0,0,0,0.4);
}

.form-response {
    margin-top: 15px;
    font-weight: 500;
}
.response-success { color: #4ade80; }
.response-error { color: #f87171; }

.loader {
    border: 2px solid rgba(255,255,255,0.3);
    border-top: 2px solid white;
    border-radius: 50%;
    width: 16px;
    height: 16px;
    animation: spin 1s linear infinite;
    display: inline-block;
    margin-left: 10px;
}

@keyframes spin { 0% { transform: rotate(0deg); } 100% { transform: rotate(360deg); } }

/* Footer */
.site-footer {
    background: #020617;
    color: white;
    padding: 60px 0 20px;
}
.footer-container {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr;
    gap: 40px;
    margin-bottom: 40px;
}
.footer-brand h3 { font-size: 1.5rem; }
.footer-brand span { color: var(--primary); }
.footer-links ul, .footer-legal ul { list-style: none; }
.footer-links a, .footer-legal a { color: #94a3b8; text-decoration: none; transition: var(--transition); display: block; margin-bottom: 10px; }
.footer-links a:hover, .footer-legal a:hover { color: white; padding-left: 5px; }

.footer-bottom {
    text-align: center;
    border-top: 1px solid rgba(255,255,255,0.1);
    padding-top: 20px;
    color: #64748b;
    font-size: 0.9rem;
}

/* Animations */
.reveal-up {
    opacity: 0;
    transform: translateY(30px);
    transition: all 0.8s ease-out;
}
.reveal-up.active {
    opacity: 1;
    transform: translateY(0);
}

/* Responsive */
@media (max-width: 768px) {
    .main-nav {
        position: absolute;
        top: 100%;
        left: 0;
        width: 100%;
        background: white;
        box-shadow: 0 10px 20px rgba(0,0,0,0.05);
        clip-path: polygon(0 0, 100% 0, 100% 0, 0 0);
        transition: clip-path 0.4s ease-in-out;
    }
    
    .main-nav.active {
        clip-path: polygon(0 0, 100% 0, 100% 100%, 0 100%);
    }

    .main-nav ul {
        flex-direction: column;
        padding: 30px;
        gap: 20px;
    }

    .mobile-menu-toggle {
        display: flex;
    }

    .hero-actions { flex-direction: column; }
    
    .grid-2-col, .contact-wrapper, .footer-container {
        grid-template-columns: 1fr;
    }
    
    .glass-panel { padding: 30px; }
}

/* Ask AI Chatbot Widget Styles */
.ai-chat-widget {
    position: fixed;
    bottom: 30px;
    right: 30px;
    z-index: 9999;
    font-family: 'Inter', sans-serif;
}

.ai-chat-toggle {
    background: linear-gradient(135deg, var(--primary), var(--accent));
    color: white;
    border: none;
    border-radius: 50px;
    padding: 12px 24px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    box-shadow: 0 10px 25px rgba(59, 130, 246, 0.4);
    display: flex;
    align-items: center;
    gap: 10px;
    transition: var(--transition);
}

.ai-chat-toggle:hover {
    transform: translateY(-5px) scale(1.05);
    box-shadow: 0 15px 30px rgba(59, 130, 246, 0.5);
}

.ai-chat-window {
    position: absolute;
    bottom: 80px;
    right: 0;
    width: 350px;
    height: 450px;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.5);
    border-radius: 20px;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.15);
    display: flex;
    flex-direction: column;
    overflow: hidden;
    transform: translateY(20px);
    opacity: 0;
    pointer-events: none;
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.ai-chat-window.active {
    transform: translateY(0);
    opacity: 1;
    pointer-events: all;
}

.ai-chat-header {
    background: linear-gradient(135deg, var(--bg-dark), #1e293b);
    color: white;
    padding: 15px 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

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

.ai-avatar {
    font-size: 1.5rem;
    background: rgba(255,255,255,0.1);
    padding: 8px;
    border-radius: 50%;
}

.ai-header-info h4 {
    margin: 0;
    font-size: 1rem;
    color: white;
}

.ai-status {
    font-size: 0.75rem;
    color: #4ade80;
    display: flex;
    align-items: center;
    gap: 5px;
}
.ai-status::before {
    content: '';
    display: inline-block;
    width: 6px;
    height: 6px;
    background: #4ade80;
    border-radius: 50%;
}

.close-chat-btn {
    background: none;
    border: none;
    color: white;
    font-size: 1.5rem;
    cursor: pointer;
    opacity: 0.7;
    transition: opacity 0.2s;
}
.close-chat-btn:hover { opacity: 1; }

.ai-chat-messages {
    flex: 1;
    padding: 20px;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
    gap: 15px;
    background: #f8fafc;
}

.message {
    max-width: 85%;
    padding: 12px 16px;
    border-radius: 18px;
    font-size: 0.95rem;
    line-height: 1.4;
    animation: fadeIn 0.3s ease-out forwards;
}

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

.ai-message {
    background: white;
    color: var(--text-dark);
    align-self: flex-start;
    border-bottom-left-radius: 4px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.02);
    border: 1px solid rgba(0,0,0,0.05);
}

.user-message {
    background: linear-gradient(135deg, var(--primary), var(--accent));
    color: white;
    align-self: flex-end;
    border-bottom-right-radius: 4px;
    box-shadow: 0 4px 15px rgba(59, 130, 246, 0.2);
}

.ai-chat-input-area {
    padding: 15px;
    background: white;
    border-top: 1px solid rgba(0,0,0,0.05);
    display: flex;
    gap: 10px;
}

.ai-chat-input-area input {
    flex: 1;
    border: 1px solid #e2e8f0;
    padding: 12px 15px;
    border-radius: 20px;
    font-size: 0.95rem;
    outline: none;
    transition: border-color 0.2s;
    background: #f8fafc;
}
.ai-chat-input-area input:focus {
    border-color: var(--primary);
    background: white;
}

.ai-send-btn {
    background: var(--primary);
    color: white;
    border: none;
    width: 45px;
    height: 45px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: var(--transition);
}
.ai-send-btn:hover {
    background: var(--primary-hover);
    transform: scale(1.05);
}

.typing-indicator {
    display: flex;
    gap: 4px;
    padding: 8px 12px;
    background: rgba(0,0,0,0.05);
    border-radius: 12px;
    width: fit-content;
    align-self: flex-start;
}
.typing-indicator span {
    width: 6px;
    height: 6px;
    background: var(--text-muted);
    border-radius: 50%;
    animation: typing 1.4s infinite both;
}
.typing-indicator span:nth-child(1) { animation-delay: 0s; }
.typing-indicator span:nth-child(2) { animation-delay: 0.2s; }
.typing-indicator span:nth-child(3) { animation-delay: 0.4s; }

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