:root {
    --primary: #4facfe;
    --primary-dark: #00f2fe;
    --secondary: #6366f1;
    --secondary-dark: #8b5cf6;
    --dark: #1a202c;
    --light: #f0f4f8;
    --gray: #718096;
}

html {
    scroll-behavior: smooth;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Segoe UI', system-ui, -apple-system, sans-serif;
}

body {
    background-color: var(--light);
    color: var(--dark);
    line-height: 1.6;
}

header {
    background: linear-gradient(135deg, var(--secondary), var(--secondary-dark));
    color: white;
    padding: 1rem;
    position: fixed;
    width: 100%;
    z-index: 100;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

a {
    color: inherit;
}

.hint {
    border-bottom: 1px dotted;
    display: inline-block;
}

@media (pointer: coarse), (hover: none) {
  [title] {
    position: relative;
    display: inline-flex;
    justify-content: center;
  }
  [title]:focus::after {
    content: attr(title);
    position: absolute;
    bottom: 95%;
    color: #000;
    background-color: #fff;
    border: 1px solid;
    width: fit-content;
    padding: 3px;
    font-size: 10px;
  }

}

.header-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
}

.logo-link {
    text-decoration: none;
    color: inherit;
}

.logo {
    display: flex;
    align-items: center;
    font-weight: bold;
    font-size: 1.5rem;
}

.logo svg {
    width: 40px;
    height: 40px;
    margin-right: 10px;
}


.logo img {
    width: 40px;
    padding: 3px;
    background: black;
    display: inline-block;
    margin-right: 8px;
    border-radius: 10px;
}

nav ul {
    display: flex;
    list-style: none;
}

nav ul li {
    margin-left: 2rem;
}

nav ul li a {
    color: white;
    text-decoration: none;
    transition: color 0.3s;
    font-weight: 500;
}

nav ul li a:hover {
    color: var(--primary-dark);
}

.hero {
    background: linear-gradient(to right, var(--dark), #2d3748);
    color: white;
    padding: 8rem 2rem 6rem;
    text-align: center;
}

.hero-content {
    max-width: 800px;
    margin: 0 auto;
}

.hero h1 {
    font-size: 3rem;
    margin-bottom: 1rem;
    background: linear-gradient(to right, var(--primary-dark), var(--primary));
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    line-height: 3.2rem;
}

.hero p {
    font-size: 1.25rem;
    margin-bottom: 2rem;
    color: #e2e8f0;
}

.btn {
    display: inline-block;
    background: linear-gradient(to right, var(--primary-dark), var(--primary));
    color: white;
    padding: 0.8rem 2rem;
    border-radius: 30px;
    text-decoration: none;
    font-weight: bold;
    transition: transform 0.3s, box-shadow 0.3s;
    border: none;
    cursor: pointer;
}

.btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.1);
}

section {
    padding: 5rem 2rem;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
}

.section-title {
    text-align: center;
    margin-bottom: 3rem;
    position: relative;
}

.section-title::after {
    content: "";
    display: block;
    width: 80px;
    height: 4px;
    background: linear-gradient(to right, var(--primary-dark), var(--primary));
    margin: 1rem auto 0;
    border-radius: 2px;
}

.services {
    background-color: white;
}

.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
}

.service-card {
    background: white;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s;
    padding: 2rem;
    border-top: 4px solid var(--primary);
}

.service-card:hover {
    transform: translateY(-10px);
}

.service-icon {
    width: 60px;
    height: 60px;
    margin-bottom: 1.5rem;
    color: var(--primary);
}

.service-card h3 {
    margin-bottom: 1rem;
    color: var(--dark);
}

.models {
    background-color: #f9fafc;
}

.models-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 2rem;
}

.model-card {
    background: white;
    padding: 1.5rem;
    border-radius: 10px;
    text-align: center;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
    transition: transform 0.3s;
}

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

.model-icon {
    width: 60px;
    height: 60px;
    margin: 0 auto 1rem;
}

.approach {
    background: linear-gradient(135deg, #f9fafc 0%, #ffffff 100%);
    position: relative;
    overflow: hidden;
}

.approach-content {
    max-width: 1000px;
    margin: 0 auto;
}

.approach-intro {
    text-align: center;
    margin-bottom: 3rem;
    font-size: 1.15rem;
    color: var(--dark);
}

.approach-intro p {
    line-height: 1.8;
}

.approach-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 2rem;
}

.approach-card {
    background: white;
    padding: 2.5rem 2rem;
    border-radius: 12px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
    transition: all 0.3s ease;
    border-top: 4px solid var(--primary);
}

.approach-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.12);
}

.approach-icon {
    width: 50px;
    height: 50px;
    margin-bottom: 1.5rem;
    color: var(--primary);
}

.approach-icon svg {
    width: 100%;
    height: 100%;
}

.approach-card h3 {
    font-size: 1.3rem;
    margin-bottom: 1rem;
    color: var(--dark);
}

.approach-card p {
    color: var(--gray);
    line-height: 1.7;
    font-size: 0.95rem;
}

.technologies {
    background-color: white;
    position: relative;
}

.technologies-content {
    max-width: 1000px;
    margin: 0 auto;
}

.technologies-intro {
    text-align: center;
    margin-bottom: 3rem;
    font-size: 1.15rem;
    color: var(--dark);
}

.technologies-intro p {
    line-height: 1.8;
}

.technologies-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 2rem;
}

.technology-item {
    background: white;
    padding: 2rem 1.5rem;
    border-radius: 12px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
    transition: all 0.3s ease;
    border-top: 4px solid var(--primary);
}

.technology-item:hover {
    transform: translateY(-8px);
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.12);
}

.technology-item h3 {
    font-size: 1.2rem;
    margin-bottom: 0.75rem;
    color: var(--dark);
    font-weight: 600;
}

.technology-item p {
    color: var(--gray);
    line-height: 1.7;
    font-size: 0.95rem;
}

.how-it-works {
    background-color: white;
}

.steps {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
}

.step {
    flex: 1;
    min-width: 250px;
    text-align: center;
    padding: 2rem;
    position: relative;
}

.step-number {
    background: linear-gradient(to right, var(--primary-dark), var(--primary));
    color: white;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
    font-weight: bold;
    margin: 0 auto 1.5rem;
}

.contact {
    background: linear-gradient(135deg, var(--dark), #2d3748);
    color: white;
}

.contact-form {
    max-width: 600px;
    margin: 0 auto;
    background: white;
    padding: 2rem;
    border-radius: 10px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
}

.contact-form form {
    position: relative;
}

.contact-form .success-msg {
    position: absolute;
    width: 100%;
    height: 100%;
    top: 0;
    left: 0;
    background: #ffffffd9;
    font-weight: bold;
    font-size: 1.5rem;
    display: none;
    justify-content: center;
    align-items: center;
    flex-direction: column;
}

.contact-form .success-msg p {
    color: #3cbdfe;
}

.form-group {
    margin-bottom: 1.5rem;
}

.form-group label {
    display: block;
    margin-bottom: 0.5rem;
    color: var(--dark);
    font-weight: 500;
}

.form-group input,
.form-group textarea,
.form-group select {
    width: 100%;
    padding: 0.75rem;
    border-radius: 5px;
    border: 1px solid #cbd5e0;
    transition: border-color 0.3s;
    font-size: 1rem;
}

.form-group textarea {
    resize: vertical;
}

.form-group.error input,
.form-group.error textarea,
.form-group.error select {
    border-color: red;
}

.form-group.error .faux-input {
    display: inline-block;
    border: 1px solid red;
}

.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus {
    outline: none;
    border-color: var(--primary);
}


.contact p {
    text-align: center;
    color: #a0aec0;
    margin-top: 2rem;
}

.faq {
    background-color: #f9fafc;
}

.faq-container {
    max-width: 800px;
    margin: 0 auto;
}

.faq-item {
    background: white;
    border-radius: 10px;
    margin-bottom: 1.5rem;
    box-shadow: 0 3px 10px rgba(0, 0, 0, 0.05);
    overflow: hidden;
}

.faq-question {
    padding: 1.5rem;
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-weight: 600;
    color: var(--dark);
    border-left: 4px solid transparent;
    transition: all 0.3s ease;
}

.faq-question:hover {
    border-left-color: var(--primary);
}

.faq-question.active {
    border-left-color: var(--primary);
}

.faq-question::after {
    content: '+';
    font-size: 1.5rem;
    color: var(--primary);
    transition: transform 0.3s;
}

.faq-question.active::after {
    transform: rotate(45deg);
}

.faq-answer {
    padding: 0 1.5rem;
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease;
    border-top: 1px solid #edf2f7;
}

.faq-answer.active {
    padding: 1.5rem;
    max-height: 300px;
}

.team {
    background-color: white;
}

.team-intro {
    text-align: center;
    margin-bottom: 3rem;
    font-size: 1.1rem;
    color: var(--gray);
}

.team-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2.5rem;
    max-width: 1100px;
    margin: 0 auto;
}

.team-member {
    text-align: center;
    padding: 2rem;
    background: white;
    border-radius: 12px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.08);
    transition: all 0.3s ease;
    border-top: 4px solid var(--primary);
}

.team-member:hover {
    transform: translateY(-8px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.12);
}

.member-photo {
    width: 120px;
    height: 120px;
    margin: 0 auto 1.5rem;
    border-radius: 50%;
    overflow: hidden;
    border: 4px solid var(--primary);
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
}

.member-photo img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.team-member h3 {
    font-size: 1.2rem;
    margin-bottom: 0.5rem;
    color: var(--dark);
}

.member-role {
    font-size: 0.9rem;
    color: var(--primary);
    font-weight: 600;
    margin-bottom: 1rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.team-member > p:last-child {
    color: var(--gray);
    line-height: 1.6;
    font-size: 0.95rem;
}

footer {
    background-color: var(--dark);
    color: #a0aec0;
    padding: 3rem 2rem;
    text-align: center;
}

.footer-content {
    max-width: 1200px;
    margin: 0 auto;
}

.footer-links {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    margin-bottom: 2rem;
}

.footer-links a {
    color: #e2e8f0;
    margin: 0 1rem;
    text-decoration: none;
    transition: color 0.3s;
}

.footer-links a:hover {
    color: var(--primary);
}

.languages-switcher {
    display: flex;
    align-items: center;
}

.language-btn {
    background: none;
    border: none;
    color: white;
    cursor: pointer;
    margin-left: 0.5rem;
    opacity: 0.7;
    transition: opacity 0.3s;
    font-size: 0.8rem;
    text-decoration: none;
}

.language-btn.active {
    opacity: 1;
    font-weight: bold;
}

.language-btn:hover {
    opacity: 1;
}

/* Chatbot widget styles */
.chat-widget {
    position: fixed;
    bottom: 2rem;
    right: 2rem;
    width: 60px;
    height: 60px;
    background: linear-gradient(135deg, var(--primary), var(--primary-dark));
    border-radius: 50%;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
    cursor: pointer;
    display: flex;
    justify-content: center;
    align-items: center;
    transition: transform 0.3s, box-shadow 0.3s;
    z-index: 99;
}

.chat-widget:hover {
    transform: scale(1.1);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.3);
}

.chat-icon {
    color: white;
    font-size: 1.5rem;
}

/* Hamburger menu styles */
.hamburger {
    display: none;
    flex-direction: column;
    cursor: pointer;
    background: none;
    border: none;
    padding: 0;
    z-index: 101;
}

.hamburger span {
    width: 25px;
    height: 3px;
    background-color: white;
    margin: 3px 0;
    transition: all 0.3s ease;
    border-radius: 2px;
}

.hamburger.active span:nth-child(1) {
    transform: rotate(45deg) translate(7px, 7px);
}

.hamburger.active span:nth-child(2) {
    opacity: 0;
}

.hamburger.active span:nth-child(3) {
    transform: rotate(-45deg) translate(7px, -7px);
}

@media (max-width: 1024px) {
    .header-container {
        padding: 1rem;
        position: relative;
        justify-content: space-between;
    }

    .hamburger {
        display: flex;
    }

    .logo-link {
        position: absolute;
        left: 50%;
        transform: translateX(-50%);
    }

    .languages-switcher {
        margin-left: auto;
    }

    nav {
        display: none;
        position: absolute;
        top: 100%;
        left: 0;
        width: 100%;
        background: linear-gradient(135deg, var(--secondary), var(--secondary-dark));
        padding: 1rem 0;
        box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
        z-index: 99;
    }

    nav.active {
        display: block;
    }

    nav ul {
        flex-direction: column;
        text-align: center;
    }

    nav ul li {
        margin: 0.5rem 0;
        margin-left: 0;
    }
}

@media (max-width: 768px) {
    .hero h1 {
        font-size: 2rem;
    }

    .services-grid, .models-grid {
        grid-template-columns: 1fr;
    }
}

.chatbot-button {
    position: fixed;
    right: 2rem;
    bottom: 2rem;
    background: none;
    border: none;
    cursor: pointer;
}

.chatbot-button img {
    width: 64px;
}


body.error {
    background-color: #1a1e2a;
    color: #ffffff;
}


.error-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 100px 20px;
    text-align: center;
}

.error-code {
    font-size: 120px;
    font-weight: bold;
    color: #00e5ff;
    margin-bottom: 20px;
}

.error-message {
    font-size: 32px;
    margin-bottom: 15px;
    color: #00e5ff;
}

.error-description {
    font-size: 18px;
    max-width: 800px;
    margin: 0 auto 40px;
    line-height: 1.6;
}

.particles {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
}

.particle {
    position: absolute;
    background: linear-gradient(to bottom, #00ffff, #0066ff);
    border-radius: 50%;
    opacity: 0.3;
    animation: float 6s infinite ease-in-out;
}

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

/* Hero Chat Component Styles */
.hero-chat {
    width: 100%;
    max-width: 450px;
    background: rgba(26, 32, 44, 0.9);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border: 1px solid rgba(79, 172, 254, 0.3);
    border-radius: 16px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
    margin: 2rem auto 0;
    display: block;
    overflow: hidden;
    text-align: left;
}

.hero-chat-header {
    padding: 1rem 1.5rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    font-weight: 500;
    color: white;
    display: flex;
    align-items: center;
    gap: 0.75rem;
    background: rgba(255, 255, 255, 0.05);
}

.chat-status-dot {
    width: 8px;
    height: 8px;
    background: #10b981;
    border-radius: 50%;
    animation: pulse-dot 2s infinite;
    flex-shrink: 0;
}

@keyframes pulse-dot {
    0%, 100% {
        opacity: 1;
        transform: scale(1);
    }
    50% {
        opacity: 0.6;
        transform: scale(1.2);
    }
}

.hero-chat-messages {
    height: 162px;
    overflow-y: auto;
    padding: 1rem;
    scrollbar-width: thin;
    scrollbar-color: rgba(79, 172, 254, 0.4) rgba(26, 32, 44, 0.5);
    transition: height 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}

.hero-chat-messages.expanded {
    height: 480px;
}

.hero-chat-messages::-webkit-scrollbar {
    width: 6px;
}

.hero-chat-messages::-webkit-scrollbar-track {
    background: rgba(26, 32, 44, 0.5);
}

.hero-chat-messages::-webkit-scrollbar-thumb {
    background: rgba(79, 172, 254, 0.4);
    border-radius: 3px;
}

.hero-chat-messages::-webkit-scrollbar-thumb:hover {
    background: rgba(79, 172, 254, 0.6);
}

.chat-message-user,
.chat-message-bot {
    padding: 0.75rem 1rem;
    border-radius: 12px;
    max-width: 85%;
    margin-bottom: 0.75rem;
    word-wrap: break-word;
    transform: translateZ(0);
    backface-visibility: hidden;
}

.chat-message-text {
    transition: opacity 0.05s ease-out;
}

.chat-message-user {
    margin-left: auto;
    background: linear-gradient(135deg, var(--primary), var(--primary-dark));
    color: white;
    text-align: left;
}

.chat-message-bot {
    margin-right: auto;
    background: rgba(255, 255, 255, 0.1);
    color: white;
    text-align: left;
}

.chat-message-tool {
    padding: 0.5rem 1rem;
    border-radius: 12px;
    max-width: 85%;
    margin-bottom: 0.75rem;
    margin-right: auto;
    background: rgba(79, 172, 254, 0.15);
    border: 1px solid rgba(79, 172, 254, 0.3);
    color: rgba(255, 255, 255, 0.9);
    text-align: left;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.9rem;
    font-style: italic;
    transform: translateZ(0);
    backface-visibility: hidden;
    animation: fadeInTool 0.3s ease-out;
}

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

.chat-message-tool .tool-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 16px;
    height: 16px;
    flex-shrink: 0;
    color: var(--primary);
}

.chat-message-tool .tool-icon img {
    width: 100%;
    height: 100%;
    animation: spin-cog 2s linear infinite;
    filter: brightness(0) saturate(100%) invert(65%) sepia(85%) saturate(1425%) hue-rotate(178deg) brightness(101%) contrast(101%);
}

@keyframes spin-cog {
    from {
        transform: rotate(0deg);
    }
    to {
        transform: rotate(360deg);
    }
}

.chat-message-tool .tool-name {
    font-weight: 500;
}

.chat-message-text {
    white-space: pre-wrap;
}

.stream-chunk {
    animation: fadeInChunk 0.12s ease-out;
}

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

.chat-welcome {
    text-align: center;
    color: #a0aec0;
    font-size: 0.9rem;
    padding: 1rem;
}

.chat-welcome p {
    margin: 0;
}

.hero-chat-input {
    display: flex;
    width: 100%;
    box-sizing: border-box;
    padding: 1rem;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    gap: 0.5rem;
    background: rgba(255, 255, 255, 0.02);
}

.hero-chat-input textarea {
    flex: 1 1 auto;
    min-width: 0;
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid transparent;
    border-radius: 8px;
    padding: 0.75rem 1rem;
    color: white;
    font-size: 0.95rem;
    transition: all 0.3s ease;
    resize: none;
    font-family: inherit;
    line-height: 1.4;
    max-height: 120px;
    overflow-y: auto;
    scrollbar-width: none;
    -ms-overflow-style: none;
}

.hero-chat-input textarea::-webkit-scrollbar {
    display: none;
}

.hero-chat-input textarea::placeholder {
    color: #718096;
}

.hero-chat-input textarea:focus {
    outline: none;
    border-color: var(--primary);
    background: rgba(255, 255, 255, 0.15);
}

.chat-send-btn {
    width: 44px;
    height: 44px;
    background: linear-gradient(135deg, var(--primary), var(--primary-dark));
    border: none;
    border-radius: 8px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    flex-shrink: 0;
}

.chat-send-btn:hover {
    transform: scale(1.05);
    box-shadow: 0 4px 15px rgba(79, 172, 254, 0.4);
}

.chat-send-btn svg {
    width: 20px;
    height: 20px;
    color: white;
}

.typing-indicator {
    display: flex;
    align-items: center;
    gap: 4px;
    padding: 0.75rem 1rem;
    margin-bottom: 0.75rem;
}

.typing-indicator .dot {
    width: 8px;
    height: 8px;
    background: rgba(255, 255, 255, 0.5);
    border-radius: 50%;
    animation: typing-bounce 1.4s infinite ease-in-out both;
}

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

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

@keyframes typing-bounce {
    0%, 80%, 100% {
        transform: scale(0.6);
        opacity: 0.4;
    }
    40% {
        transform: scale(1);
        opacity: 1;
    }
}

/* Mobile responsive for hero chat */
@media (max-width: 768px) {
    .hero-chat {
        width: 100%;
        margin: 1rem auto;
    }

    .hero-chat-messages {
        height: 240px;
    }

    .chat-message-user,
    .chat-message-bot {
        max-width: 90%;
    }
}