:root {
    --bg-color: #050505;
    --text-color: #e0e0e0;
    --accent-color: #7000ff;
    --accent-glow: rgba(112, 0, 255, 0.4);
    --card-bg: rgba(255, 255, 255, 0.03);
    --card-border: rgba(255, 255, 255, 0.1);
    --secondary-color: #00d4ff;
    --font-main: 'Inter', sans-serif;
    --font-heading: 'Outfit', sans-serif;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    background-color: var(--bg-color);
    color: var(--text-color);
    font-family: var(--font-main);
    line-height: 1.6;
    overflow-x: hidden;
}

/* Background Glow Effect */
.cursor-glow {
    position: fixed;
    width: 600px;
    height: 600px;
    background: radial-gradient(circle, var(--accent-glow) 0%, transparent 70%);
    border-radius: 50%;
    pointer-events: none;
    z-index: -1;
    transform: translate(-50%, -50%);
    transition: width 0.3s, height 0.3s;
}

/* Header & Nav */
header {
    position: fixed;
    top: 0;
    width: 100%;
    padding: 2rem 5%;
    z-index: 1000;
    background: rgba(5, 5, 5, 0.8);
    backdrop-filter: blur(10px);
}

nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    font-family: var(--font-heading);
    font-size: 1.8rem;
    font-weight: 700;
    color: #fff;
    letter-spacing: -1px;
}

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

.nav-links {
    display: flex;
    list-style: none;
    gap: 2rem;
}

.nav-links a {
    text-decoration: none;
    color: #aaa;
    font-weight: 400;
    transition: color 0.3s;
}

.nav-links a:hover {
    color: #fff;
}

/* Hero Section */
.hero {
    height: 100vh;
    display: flex;
    align-items: center;
    padding: 0 10%;
    position: relative;
}

.hero-content {
    max-width: 600px;
    z-index: 10;
}

.hero h1 {
    font-family: var(--font-heading);
    font-size: 4.5rem;
    line-height: 1.1;
    margin-bottom: 1.5rem;
    background: linear-gradient(to right, #fff, #888);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.hero p {
    font-size: 1.2rem;
    color: #aaa;
    margin-bottom: 2.5rem;
}

.hero-btns {
    display: flex;
    gap: 1.5rem;
}

.btn {
    padding: 1rem 2rem;
    border-radius: 50px;
    text-decoration: none;
    font-weight: 600;
    transition: transform 0.3s, box-shadow 0.3s;
}

.btn.primary {
    background: var(--accent-color);
    color: #fff;
    box-shadow: 0 10px 20px rgba(112, 0, 255, 0.3);
}

.btn.secondary {
    background: var(--secondary-color);
    color: #fff;
    box-shadow: 0 10px 20px rgba(0, 212, 255, 0.3);
}

.btn:hover {
    transform: translateY(-5px);
}

.hero-visual {
    position: absolute;
    right: 5%;
    width: 40%;
    height: 80%;
    display: flex;
    justify-content: center;
    align-items: center;
}

.abstract-shape {
    position: absolute;
    filter: blur(80px);
    border-radius: 50%;
    opacity: 0.6;
}

.shape-1 {
    width: 300px;
    height: 300px;
    background: var(--accent-color);
    top: 10%;
    left: 20%;
    animation: move 20s infinite alternate;
}

.shape-2 {
    width: 250px;
    height: 250px;
    background: var(--secondary-color);
    bottom: 20%;
    right: 10%;
    animation: move 15s infinite alternate-reverse;
}

.shape-3 {
    width: 200px;
    height: 200px;
    background: #ff00c8;
    top: 50%;
    left: 40%;
    animation: move 25s infinite linear;
}

@keyframes move {
    from { transform: translate(0, 0); }
    to { transform: translate(100px, 100px); }
}

/* Cases Section */
.cases {
    padding: 100px 5%;
}

.section-header {
    text-align: center;
    margin-bottom: 4rem;
}

.section-header h2 {
    font-family: var(--font-heading);
    font-size: 3rem;
    margin-bottom: 1rem;
}

.section-header p {
    color: #777;
    font-size: 1.1rem;
}

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

.case-card {
    background: var(--card-bg);
    border: 1px solid var(--card-border);
    border-radius: 20px;
    padding: 2rem;
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    cursor: pointer;
    position: relative;
    overflow: hidden;
}

.case-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, rgba(255,255,255,0.1), transparent);
    opacity: 0;
    transition: opacity 0.4s;
}

.case-card:hover {
    transform: translateY(-10px) scale(1.02);
    border-color: var(--accent-color);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.5), 0 0 20px var(--accent-glow);
}

.case-card:hover::before {
    opacity: 1;
}

.case-card h3 {
    font-family: var(--font-heading);
    font-size: 1.4rem;
    margin-bottom: 1rem;
    color: #fff;
}

.case-card p {
    color: #aaa;
    font-size: 0.95rem;
}

.case-card .tag {
    display: inline-block;
    padding: 0.3rem 0.8rem;
    background: rgba(112, 0, 255, 0.1);
    color: var(--accent-color);
    border-radius: 10px;
    font-size: 0.8rem;
    font-weight: 600;
    margin-bottom: 1rem;
}

/* About Section */
.about {
    padding: 100px 10%;
    background: #0a0a0a;
}

.about-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 4rem;
}

.about-text {
    flex: 1;
}

.about-text h2 {
    font-family: var(--font-heading);
    font-size: 2.5rem;
    margin-bottom: 1.5rem;
}

.about-stats {
    display: flex;
    gap: 3rem;
}

.stat {
    display: flex;
    flex-direction: column;
    align-items: center;
}

.stat-num {
    font-family: var(--font-heading);
    font-size: 4rem;
    font-weight: 800;
    color: var(--accent-color);
}

.stat-label {
    color: #777;
    text-transform: uppercase;
    letter-spacing: 2px;
    font-size: 0.8rem;
}

/* Footer */
footer {
    padding: 3rem 5%;
    text-align: center;
    border-top: 1px solid #1a1a1a;
    color: #555;
}

/* Modal */
.modal {
    display: none;
    position: fixed;
    z-index: 2000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.9);
    backdrop-filter: blur(5px);
}

.modal-content {
    background: #111;
    margin: 2% auto;
    padding: 3rem;
    border: 1px solid #333;
    width: 90%;
    max-width: 1000px;
    max-height: 90vh;
    border-radius: 30px;
    position: relative;
    box-shadow: 0 0 50px rgba(0,0,0,0.5);
    overflow-y: auto;
}

.modal-content::-webkit-scrollbar {
    width: 8px;
}

.modal-content::-webkit-scrollbar-track {
    background: #050505;
}

.modal-content::-webkit-scrollbar-thumb {
    background: #333;
    border-radius: 4px;
}

.modal-content::-webkit-scrollbar-thumb:hover {
    background: var(--accent-color);
}

.close-modal {
    position: sticky;
    top: 0;
    float: right;
    color: #777;
    font-size: 2rem;
    font-weight: bold;
    cursor: pointer;
    transition: color 0.3s;
    z-index: 10;
}

.close-modal:hover {
    color: #fff;
}

.modal-case-header {
    margin-bottom: 2rem;
    border-bottom: 1px solid #222;
    padding-bottom: 1rem;
}

.modal-case-content {
    color: #ccc;
    font-size: 1.1rem;
    line-height: 1.8;
}

.modal-case-content h2, .modal-case-content h3 {
    margin-top: 2rem;
    margin-bottom: 1rem;
    color: #fff;
}

.modal-case-content p {
    margin-bottom: 1.5rem;
}

.modal-case-content ul, .modal-case-content ol {
    margin-left: 2rem;
    margin-bottom: 1.5rem;
}

.modal-case-content table {
    width: 100%;
    border-collapse: collapse;
    margin-bottom: 2rem;
    background: rgba(255,255,255,0.02);
}

.modal-case-content th, .modal-case-content td {
    padding: 1rem;
    border: 1px solid #333;
    text-align: left;
}

.modal-case-content th {
    background: rgba(112, 0, 255, 0.1);
    color: var(--accent-color);
}

.modal-case-code {
    margin-top: 3rem;
    border-top: 1px solid #333;
    padding-top: 2rem;
}

.modal-case-results {
    margin-top: 3rem;
    border-top: 1px solid #333;
    padding-top: 2rem;
}

.modal-case-results h3 {
    margin-bottom: 1rem;
    color: var(--secondary-color);
}

.results-content {
    background: rgba(0, 212, 255, 0.05);
    padding: 1.5rem;
    border-radius: 15px;
    border: 1px solid rgba(0, 212, 255, 0.1);
}

.modal-case-webapp {
    margin-top: 3rem;
    border-top: 1px solid #333;
    padding-top: 2rem;
}

.modal-case-webapp h3 {
    margin-bottom: 1rem;
    color: #10b981;
}

.modal-case-webapp code {
    display: block;
    background: #1a1a1a;
    padding: 1rem;
    border-radius: 10px;
    margin-bottom: 1rem;
    color: #10b981;
}

.btn.success {
    background: #10b981;
    color: #fff;
    box-shadow: 0 10px 20px rgba(16, 185, 129, 0.3);
}

.btn.info {
    background: #3b82f6;
    color: #fff;
    box-shadow: 0 10px 20px rgba(59, 130, 246, 0.3);
}

.modal-case-description {
    margin-top: 3rem;
    border-top: 1px solid #333;
    padding-top: 2rem;
}

.modal-case-description h3 {
    margin-bottom: 1rem;
    color: #3b82f6;
}

.description-content {
    background: rgba(59, 130, 246, 0.05);
    padding: 1.5rem;
    border-radius: 15px;
    border: 1px solid rgba(59, 130, 246, 0.1);
    color: #ccc;
    font-size: 1.1rem;
    line-height: 1.8;
}

.modal-actions button {
    cursor: pointer;
    border: none;
    outline: none;
}

/* Animations */
.animate-up {
    opacity: 0;
    transform: translateY(30px);
    animation: fadeInUp 0.8s forwards;
}

.delay-1 { animation-delay: 0.2s; }
.delay-2 { animation-delay: 0.4s; }

@keyframes fadeInUp {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Responsive */
@media (max-width: 768px) {
    .hero h1 { font-size: 3rem; }
    .about-container { flex-direction: column; text-align: center; }
    .modal-content { width: 90%; padding: 2rem; }
    .hero-visual { display: none; }
}
