/* ============================================
   Grenze Soft - Modern Bootstrap 5.3 Theme
   ============================================ */

:root {
    --primary: #6366f1;
    --primary-dark: #4f46e5;
    --secondary: #8b5cf6;
    --accent: #06b6d4;
    --dark: #0f172a;
    --darker: #020617;
    --darkest: #000000;
    --surface: #1e293b;
    --surface-light: #334155;
    --text-primary: #f1f5f9;
    --text-muted: #94a3b8;
    --gradient-start: #6366f1;
    --gradient-end: #8b5cf6;
}

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

body {
    font-family: 'Inter', sans-serif;
    background-color: var(--dark);
    color: var(--text-primary);
    overflow-x: hidden;
}

/* ============================================
   Navbar
   ============================================ */
.navbar {
    padding: 1rem 0;
    transition: all 0.3s ease;
    z-index: 1050;
}

.navbar.scrolled {
    background: rgba(15, 23, 42, 0.95) !important;
    backdrop-filter: blur(20px);
    box-shadow: 0 4px 30px rgba(0, 0, 0, 0.3);
    padding: 0.5rem 0;
}

.navbar-brand {
    font-weight: 700;
    font-size: 1.5rem;
}

.brand-icon {
    width: 40px;
    height: 40px;
    background: linear-gradient(135deg, var(--gradient-start), var(--gradient-end));
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    color: white;
}

.brand-text {
    color: var(--text-primary);
    font-weight: 800;
}

.nav-link {
    color: var(--text-muted) !important;
    font-weight: 500;
    padding: 0.5rem 1rem !important;
    transition: color 0.3s ease;
    position: relative;
}

.nav-link:hover,
.nav-link.active {
    color: var(--text-primary) !important;
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 0;
    height: 2px;
    background: linear-gradient(90deg, var(--gradient-start), var(--gradient-end));
    transition: width 0.3s ease;
    border-radius: 2px;
}

.nav-link:hover::after,
.nav-link.active::after {
    width: 60%;
}

/* ============================================
   Buttons
   ============================================ */
.btn-gradient {
    background: linear-gradient(135deg, var(--gradient-start), var(--gradient-end));
    border: none;
    color: white;
    font-weight: 600;
    border-radius: 10px;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.btn-gradient::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 ease;
}

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

.btn-gradient:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 30px rgba(99, 102, 241, 0.4);
    color: white;
}

.btn-outline-custom {
    border: 2px solid var(--surface-light);
    color: var(--text-primary);
    background: transparent;
    font-weight: 600;
    border-radius: 10px;
    transition: all 0.3s ease;
}

.btn-outline-custom:hover {
    border-color: var(--primary);
    background: rgba(99, 102, 241, 0.1);
    color: var(--text-primary);
    transform: translateY(-2px);
}

/* ============================================
   Hero Section
   ============================================ */
.hero-section {
    position: relative;
    min-height: 100vh;
    overflow: hidden;
    background: linear-gradient(135deg, var(--dark) 0%, var(--darker) 100%);
}

.hero-bg-animation {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    overflow: hidden;
    z-index: 0;
}

.floating-shape {
    position: absolute;
    border-radius: 50%;
    opacity: 0.05;
    animation: float 20s infinite ease-in-out;
}

.shape-1 {
    width: 600px;
    height: 600px;
    background: var(--primary);
    top: -200px;
    right: -200px;
    animation-delay: 0s;
}

.shape-2 {
    width: 400px;
    height: 400px;
    background: var(--secondary);
    bottom: -100px;
    left: -100px;
    animation-delay: -5s;
}

.shape-3 {
    width: 300px;
    height: 300px;
    background: var(--accent);
    top: 50%;
    left: 50%;
    animation-delay: -10s;
}

.shape-4 {
    width: 200px;
    height: 200px;
    background: var(--primary);
    top: 20%;
    right: 30%;
    animation-delay: -15s;
}

@keyframes float {
    0%, 100% { transform: translate(0, 0) scale(1); }
    25% { transform: translate(50px, -50px) scale(1.1); }
    50% { transform: translate(-30px, 30px) scale(0.9); }
    75% { transform: translate(40px, 20px) scale(1.05); }
}

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

.badge-custom {
    background: rgba(99, 102, 241, 0.15);
    color: var(--primary);
    border: 1px solid rgba(99, 102, 241, 0.3);
    padding: 0.5rem 1rem;
    border-radius: 50px;
    font-size: 0.85rem;
    font-weight: 500;
}

.text-muted-custom {
    color: var(--text-muted);
}

.stat-item h3 {
    font-size: 2rem;
    margin-bottom: 0.25rem;
}

/* Code Window */
.hero-illustration {
    position: relative;
}

/* ============================================
   Showcase Cards
   ============================================ */
.showcase-card {
    background: var(--surface);
    border: 1px solid rgba(255, 255, 255, 0.05);
    border-radius: 16px;
    padding: 1.5rem;
    transition: all 0.4s ease;
    height: 100%;
    position: relative;
    overflow: hidden;
}

.showcase-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 3px;
    background: linear-gradient(90deg, var(--primary), var(--accent));
    transform: scaleX(0);
    transition: transform 0.4s ease;
}

.showcase-card:hover::before {
    transform: scaleX(1);
}

.showcase-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 20px 40px rgba(99, 102, 241, 0.25);
    border-color: rgba(99, 102, 241, 0.3);
}

.showcase-img {
    width: 100%;
    height: 140px;
    background: rgba(99, 102, 241, 0.05);
    border-radius: 12px;
    margin-bottom: 1.25rem;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    transition: all 0.4s ease;
    border: 1px solid rgba(255, 255, 255, 0.05);
}

.showcase-card:hover .showcase-img {
    background: rgba(99, 102, 241, 0.12);
    transform: scale(1.02);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.3);
}

.showcase-img svg {
    width: 90%;
    height: 90%;
    transition: transform 0.4s ease;
}

.showcase-card:hover .showcase-img svg {
    transform: scale(1.08);
}

.showcase-card h5 {
    font-weight: 700;
    margin-bottom: 0.5rem;
    color: var(--text-primary);
}

.showcase-card p {
    color: var(--text-muted);
    font-size: 0.9rem;
    line-height: 1.6;
}

.code-window {
    background: var(--surface);
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 25px 60px rgba(0, 0, 0, 0.5);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.window-header {
    background: rgba(0, 0, 0, 0.3);
    padding: 12px 16px;
    display: flex;
    align-items: center;
}

.dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    display: inline-block;
    margin-right: 6px;
}

.dot-red { background: #ef4444; }
.dot-yellow { background: #f59e0b; }
.dot-green { background: #22c55e; }

.window-body {
    padding: 1.5rem;
    font-family: 'Courier New', monospace;
    font-size: 0.85rem;
    line-height: 1.8;
}

.window-body pre {
    color: #e2e8f0;
}

.code-purple { color: #d8b4fe; }
.code-blue { color: #93c5fd; }
.code-green { color: #86efac; }

.scroll-indicator {
    position: absolute;
    bottom: 2rem;
    left: 50%;
    transform: translateX(-50%);
    color: var(--text-muted);
    font-size: 1.5rem;
    animation: bounce 2s infinite;
    z-index: 10;
}

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

/* ============================================
   Sections
   ============================================ */
.section-padding {
    padding: 100px 0;
}

.bg-darker {
    background-color: var(--darker);
}

.bg-darkest {
    background-color: var(--darkest);
}

/* Service Cards */
.service-card {
    background: var(--surface);
    border: 1px solid rgba(255, 255, 255, 0.05);
    border-radius: 16px;
    padding: 2rem;
    transition: all 0.4s ease;
    height: 100%;
    position: relative;
    overflow: hidden;
}

.service-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 3px;
    background: linear-gradient(90deg, var(--gradient-start), var(--gradient-end));
    transform: scaleX(0);
    transition: transform 0.4s ease;
}

.service-card:hover::before {
    transform: scaleX(1);
}

.service-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
    border-color: rgba(99, 102, 241, 0.3);
}

.service-icon {
    width: 60px;
    height: 60px;
    background: linear-gradient(135deg, rgba(99, 102, 241, 0.2), rgba(139, 92, 246, 0.2));
    border-radius: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    color: var(--primary);
    margin-bottom: 1.25rem;
}

.service-card h5 {
    font-weight: 700;
    margin-bottom: 0.75rem;
}

.service-link {
    color: var(--primary);
    text-decoration: none;
    font-weight: 600;
    font-size: 0.9rem;
    display: inline-flex;
    align-items: center;
    transition: all 0.3s ease;
    cursor: pointer;
}

.service-link i {
    margin-left: 0.5rem;
    transition: transform 0.3s ease;
}

.service-link:hover i {
    transform: translateX(5px);
}

/* ============================================
   Technologies
   ============================================ */
.tech-card {
    background: var(--surface);
    border: 1px solid rgba(255, 255, 255, 0.05);
    border-radius: 12px;
    padding: 1.25rem 1rem;
    text-align: center;
    transition: all 0.3s ease;
    cursor: pointer;
    height: 100%;
}

.tech-card:hover {
    transform: translateY(-5px);
    border-color: var(--primary);
    box-shadow: 0 10px 30px rgba(99, 102, 241, 0.2);
}

.tech-icon {
    font-size: 2rem;
    margin-bottom: 0.5rem;
    color: var(--primary);
    transition: all 0.3s ease;
}

.tech-card:hover .tech-icon {
    transform: scale(1.1);
    color: var(--accent);
}

.tech-card h6 {
    font-weight: 600;
    margin-bottom: 0.25rem;
    font-size: 0.9rem;
}

.tech-tag {
    font-size: 0.7rem;
    color: var(--text-muted);
    background: rgba(255, 255, 255, 0.05);
    padding: 0.2rem 0.5rem;
    border-radius: 50px;
}

/* ============================================
   Expertise Cards
   ============================================ */
.expertise-card {
    background: var(--surface);
    border: 1px solid rgba(255, 255, 255, 0.05);
    border-radius: 12px;
    padding: 1.5rem 1rem;
    text-align: center;
    transition: all 0.3s ease;
    height: 100%;
}

.expertise-card:hover {
    transform: translateY(-5px);
    border-color: var(--primary);
    box-shadow: 0 10px 30px rgba(99, 102, 241, 0.2);
}

.expertise-icon {
    width: 50px;
    height: 50px;
    background: linear-gradient(135deg, rgba(99, 102, 241, 0.2), rgba(139, 92, 246, 0.2));
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.3rem;
    color: var(--primary);
    margin: 0 auto 0.75rem;
    transition: all 0.3s ease;
}

.expertise-card:hover .expertise-icon {
    transform: scale(1.1);
    color: var(--accent);
}

.expertise-card h6 {
    font-weight: 600;
    margin-bottom: 0.5rem;
    font-size: 0.95rem;
    color: var(--text-primary);
}

.expertise-tag {
    font-size: 0.8rem;
    color: var(--text-muted);
    line-height: 1.4;
    margin-bottom: 0;
}



/* ============================================
   Methodology Cards
   ============================================ */
.methodology-card {
    background: var(--surface);
    border: 1px solid rgba(255, 255, 255, 0.05);
    border-radius: 16px;
    padding: 2rem;
    transition: all 0.4s ease;
    height: 100%;
    position: relative;
    overflow: hidden;
}

.methodology-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 3px;
    background: linear-gradient(90deg, var(--gradient-start), var(--accent));
    transform: scaleX(0);
    transition: transform 0.4s ease;
}

.methodology-card:hover::before {
    transform: scaleX(1);
}

.methodology-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
    border-color: rgba(99, 102, 241, 0.3);
}

.methodology-icon {
    width: 60px;
    height: 60px;
    background: linear-gradient(135deg, rgba(99, 102, 241, 0.2), rgba(6, 182, 212, 0.2));
    border-radius: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    color: var(--primary);
    margin-bottom: 1.25rem;
}

.methodology-card h5 {
    font-weight: 700;
    margin-bottom: 0.75rem;
}

/* ============================================
   About Section
   ============================================ */
.about-image-wrapper {
    position: relative;
}

.about-image {
    width: 100%;
    height: 400px;
    background: linear-gradient(135deg, var(--surface), var(--surface-light));
    border-radius: 20px;
    position: relative;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
}

.about-pattern {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: 
        radial-gradient(circle at 20% 80%, rgba(99, 102, 241, 0.3) 0%, transparent 50%),
        radial-gradient(circle at 80% 20%, rgba(139, 92, 246, 0.3) 0%, transparent 50%);
}

.about-icon-box {
    width: 100px;
    height: 100px;
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    border-radius: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2.5rem;
    color: white;
    position: relative;
    z-index: 1;
    box-shadow: 0 15px 40px rgba(99, 102, 241, 0.4);
}

.experience-badge {
    position: absolute;
    bottom: -20px;
    right: -20px;
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    padding: 1.25rem 1.5rem;
    border-radius: 16px;
    text-align: center;
    box-shadow: 0 10px 30px rgba(99, 102, 241, 0.4);
}

.exp-number {
    display: block;
    font-size: 2rem;
    font-weight: 800;
    color: white;
}

.exp-text {
    font-size: 0.8rem;
    color: rgba(255, 255, 255, 0.8);
}

/* ============================================
   CTA Section
   ============================================ */
.cta-section {
    background: linear-gradient(135deg, var(--surface), var(--dark));
    position: relative;
    overflow: hidden;
}

.cta-section::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(99, 102, 241, 0.1) 0%, transparent 50%);
    animation: rotate 30s linear infinite;
}

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

/* ============================================
   Contact Section
   ============================================ */
.contact-info-card {
    background: var(--surface);
    border: 1px solid rgba(255, 255, 255, 0.05);
    border-radius: 12px;
    padding: 1.5rem;
    margin-bottom: 1rem;
    transition: all 0.3s ease;
}

.contact-info-card:hover {
    border-color: var(--primary);
    transform: translateX(5px);
}

.contact-icon {
    width: 45px;
    height: 45px;
    background: linear-gradient(135deg, rgba(99, 102, 241, 0.2), rgba(139, 92, 246, 0.2));
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--primary);
    font-size: 1.2rem;
    margin-bottom: 0.75rem;
}

.contact-info-card h6 {
    font-weight: 600;
    margin-bottom: 0.25rem;
}

.contact-form-wrapper {
    background: var(--surface);
    border: 1px solid rgba(255, 255, 255, 0.05);
    border-radius: 16px;
    padding: 2rem;
}

.custom-input {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: var(--text-primary);
    border-radius: 10px;
}

.custom-input:focus {
    background: rgba(255, 255, 255, 0.08);
    border-color: var(--primary);
    color: var(--text-primary);
    box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.2);
}

.form-floating label {
    color: var(--text-muted);
}

.form-floating > .form-control:focus ~ label,
.form-floating > .form-control:not(:placeholder-shown) ~ label {
    color: var(--primary);
}

/* ============================================
   Modal
   ============================================ */
.modal-content {
    background: var(--surface) !important;
    border: 1px solid rgba(255, 255, 255, 0.1) !important;
    color: var(--text-primary) !important;
    border-radius: 16px !important;
    overflow: hidden !important;
}

.modal-custom {
    background: var(--surface);
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: var(--text-primary);
}

.modal-custom .modal-header,
.modal-custom .modal-footer {
    border-color: rgba(255, 255, 255, 0.05);
}

.modal-content .modal-title {
    color: var(--text-primary);
    font-weight: 700;
}

.modal-body {
    color: var(--text-primary) !important;
    line-height: 1.7;
}

.modal-body p,
.modal-body li,
.modal-body span {
    color: var(--text-muted) !important;
}

.modal-body strong,
.modal-body b {
    color: var(--text-primary) !important;
}

.modal-body h6 {
    color: var(--primary) !important;
    font-weight: 700;
    margin-top: 1.25rem;
    margin-bottom: 0.5rem;
}

.modal-body a {
    color: var(--primary) !important;
    text-decoration: none;
}

.modal-body a:hover {
    text-decoration: underline !important;
}

/* ============================================
   Footer
   ============================================ */
.footer {
    border-top: 1px solid rgba(255, 255, 255, 0.05);
}

.footer-brand p {
    max-width: 300px;
}

.social-links {
    display: flex;
    gap: 0.75rem;
}

.social-link {
    width: 40px;
    height: 40px;
    background: var(--surface);
    border: 1px solid rgba(255, 255, 255, 0.05);
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-muted);
    text-decoration: none;
    transition: all 0.3s ease;
}

.social-link:hover {
    background: var(--primary);
    color: white;
    border-color: var(--primary);
    transform: translateY(-3px);
}

.footer-links {
    list-style: none;
    padding: 0;
}

.footer-links li {
    margin-bottom: 0.5rem;
}

.footer-links a {
    color: var(--text-muted);
    text-decoration: none;
    font-size: 0.9rem;
    transition: color 0.3s ease;
}

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

.email-link {
    transition: color 0.3s ease;
}

.email-link:hover {
    color: var(--primary) !important;
}

/* ============================================
   Back to Top
   ============================================ */
.back-to-top {
    position: fixed;
    bottom: 2rem;
    right: 2rem;
    width: 45px;
    height: 45px;
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    text-decoration: none;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
    z-index: 1000;
    box-shadow: 0 5px 20px rgba(99, 102, 241, 0.4);
}

.back-to-top.show {
    opacity: 1;
    visibility: visible;
}

.back-to-top:hover {
    transform: translateY(-3px);
    color: white;
}

/* ============================================
   Toast Notification
   ============================================ */
.toast-container {
    position: fixed;
    top: 100px;
    right: 20px;
    z-index: 9999;
}

.custom-toast {
    background: var(--surface);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    padding: 1rem 1.5rem;
    display: flex;
    align-items: center;
    gap: 0.75rem;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.4);
    transform: translateX(120%);
    transition: transform 0.4s ease;
    min-width: 300px;
}

.custom-toast.show {
    transform: translateX(0);
}

.custom-toast.success {
    border-left: 4px solid #22c55e;
}

.custom-toast.error {
    border-left: 4px solid #ef4444;
}

.custom-toast-icon {
    font-size: 1.5rem;
}

.custom-toast.success .custom-toast-icon {
    color: #22c55e;
}

.custom-toast.error .custom-toast-icon {
    color: #ef4444;
}

/* ============================================
   Responsive
   ============================================ */
@media (max-width: 991.98px) {
    .navbar-collapse {
        background: rgba(15, 23, 42, 0.98);
        backdrop-filter: blur(20px);
        padding: 1rem;
        border-radius: 12px;
        margin-top: 0.5rem;
        border: 1px solid rgba(255, 255, 255, 0.1);
    }

    .navbar-nav {
        text-align: center;
    }

    .nav-link {
        padding: 0.75rem 1rem !important;
    }

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

    .experience-badge {
        bottom: -10px;
        right: 10px;
    }
}

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

    .stat-item h3 {
        font-size: 1.5rem;
    }

    .experience-badge {
        position: relative;
        bottom: auto;
        right: auto;
        margin-top: 1rem;
        display: inline-block;
    }
}

/* ============================================
   Animations
   ============================================ */
.fade-in-up {
    opacity: 0;
    transform: translateY(30px);
    transition: all 0.6s ease;
}

.fade-in-up.visible {
    opacity: 1;
    transform: translateY(0);
}

html {
    scroll-behavior: smooth;
}

::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: var(--darker);
}

::-webkit-scrollbar-thumb {
    background: var(--surface-light);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--primary);
}
