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

html {
    scroll-behavior: smooth;
    overflow-x: hidden;
    width: 100%;
}

body {
    font-family: 'Inter', sans-serif;
    line-height: 1.6;
    color: #333;
    background-color: #f8fafc;
    overflow-x: hidden;
    width: 100%;
    margin: 0;
    padding: 0;
}

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

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

p {
    margin-bottom: 1rem;
    color: #64748b;
}

.gradient-text {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.75rem 1.5rem;
    border: none;
    border-radius: 0.5rem;
    font-weight: 500;
    text-decoration: none;
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 0.875rem;
}

.btn-primary {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 25px rgba(102, 126, 234, 0.3);
}

.btn-secondary {
    background: #f1f5f9;
    color: #475569;
    border: 1px solid #e2e8f0;
}

.btn-secondary:hover {
    background: #e2e8f0;
    transform: translateY(-2px);
}

.btn-outline {
    background: transparent;
    color: #667eea;
    border: 1px solid #667eea;
}

.btn-outline:hover {
    background: #667eea;
    color: white;
}

.btn-success {
    background: #10b981;
    color: white;
}

.btn-success:hover {
    background: #059669;
    transform: translateY(-2px);
    box-shadow: 0 10px 25px rgba(16, 185, 129, 0.3);
}

/* Header */
.header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid #e2e8f0;
    z-index: 1000;
    transition: all 0.3s ease;
}

.header-content {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 1rem 0;
}

.logo {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 1.25rem;
    font-weight: 700;
    color: #1e293b;
}

.logo i {
    color: #667eea;
    font-size: 1.5rem;
}

.logo-icon {
    width: 32px;
    height: 32px;
    object-fit: contain;
}

.nav {
    display: flex;
    gap: 2rem;
}

.nav-link {
    text-decoration: none;
    color: #64748b;
    font-weight: 500;
    transition: color 0.3s ease;
    position: relative;
}

.nav-link:hover,
.nav-link.active {
    color: #667eea;
}

.nav-link.active::after {
    content: '';
    position: absolute;
    bottom: -0.5rem;
    left: 0;
    right: 0;
    height: 2px;
    background: #667eea;
    border-radius: 1px;
}

.admin-link {
    background: #f1f5f9;
    padding: 0.5rem 1rem;
    border-radius: 0.375rem;
    border: 1px solid #e2e8f0;
}

.admin-link:hover {
    background: #e2e8f0;
}

.mobile-menu-btn {
    display: none;
    background: none;
    border: none;
    font-size: 1.25rem;
    color: #64748b;
    cursor: pointer;
}

/* Mobile Menu */
.mobile-menu {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
    z-index: 1001;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}

.mobile-menu.active {
    opacity: 1;
    visibility: visible;
}

.mobile-menu-content {
    position: absolute;
    top: 0;
    right: 0;
    width: 250px;
    height: 100%;
    background: white;
    padding: 2rem;
    transform: translateX(100%);
    transition: transform 0.3s ease;
}

.mobile-menu.active .mobile-menu-content {
    transform: translateX(0);
}

.mobile-nav-link {
    display: block;
    padding: 1rem 0;
    text-decoration: none;
    color: #64748b;
    font-weight: 500;
    border-bottom: 1px solid #f1f5f9;
}

.mobile-nav-link:hover {
    color: #667eea;
}

/* Hero Section */
.hero {
    padding: 8rem 0 6rem;
    background: linear-gradient(135deg, #f8fafc 0%, #f1f5f9 100%);
    position: relative;
    overflow: hidden;
    min-height: 600px;
    width: 100%;
}

.hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><defs><pattern id="grid" width="10" height="10" patternUnits="userSpaceOnUse"><path d="M 10 0 L 0 0 0 10" fill="none" stroke="%23e2e8f0" stroke-width="0.5"/></pattern></defs><rect width="100" height="100" fill="url(%23grid)"/></svg>');
    opacity: 0.5;
}

.hero-content {
    position: relative;
    z-index: 2;
    max-width: 600px;
}

.hero-title {
    font-size: 3rem;
    font-weight: 700;
    margin-bottom: 1.5rem;
    color: #1e293b;
}

.hero-description {
    font-size: 1.125rem;
    margin-bottom: 2rem;
    color: #64748b;
}

.hero-buttons {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
}

.hero-visual {
    position: absolute;
    top: 50%;
    right: 5%;
    transform: translateY(-50%);
    z-index: 1;
}

.floating-cards {
    position: relative;
    width: 450px;
    height: 350px;
}

.floating-card {
    position: absolute;
    background: white;
    border-radius: 1rem;
    padding: 1.5rem 1.75rem;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.75rem;
    animation: float 6s ease-in-out infinite;
    min-width: 110px;
}

.floating-card i {
    font-size: 2.25rem;
    margin-bottom: 0.25rem;
}

.floating-card svg {
    margin-bottom: 0.25rem;
    width: 50px;
    height: 50px;
}

.floating-card span {
    font-weight: 600;
    color: #1e293b;
    font-size: 0.95rem;
}

.card-1 {
    top: 0;
    left: 0;
    animation-delay: 0s;
}

.card-1 i,
.card-1 svg {
    color: #02569b;
}

.card-2 {
    top: 10px;
    right: 0;
    animation-delay: 2s;
}

.card-2 i {
    color: #f7df1e;
}

.card-3 {
    bottom: 20px;
    left: 0;
    animation-delay: 4s;
}

.card-3 i {
    color: #ff2d20;
}

.card-4 {
    top: calc(50% - 60px);
    left: calc(50% - 55px);
    animation-delay: 1s;
}

.card-4 i {
    color: #F05138;
}

.card-5 {
    bottom: 20px;
    right: 0;
    animation-delay: 3s;
}

.card-5 svg {
    color: #512BD4;
}

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

/* Statistics Section */
.statistics {
    padding: 5rem 0;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    position: relative;
    overflow: hidden;
    width: 100%;
}

.statistics::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%23ffffff' fill-opacity='0.05'%3E%3Cpath d='M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zm0-30V0h-2v4h-4v2h4v4h2V6h4V4h-4zM6 34v-4H4v4H0v2h4v4h2v-4h4v-2H6zM6 4V0H4v4H0v2h4v4h2V6h4V4H6z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
    opacity: 0.4;
}

.statistics-header {
    text-align: center;
    margin-bottom: 3rem;
    position: relative;
    z-index: 1;
}

.statistics-title {
    font-size: 2.5rem;
    font-weight: 700;
    color: white;
    margin-bottom: 0.75rem;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.statistics-subtitle {
    font-size: 1.125rem;
    color: rgba(255, 255, 255, 0.9);
    font-weight: 400;
}

.statistics-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 1.75rem;
    max-width: 1300px;
    margin: 0 auto;
    position: relative;
    z-index: 1;
    width: 100%;
}

.stat-card {
    position: relative;
    padding: 2rem;
    background: white;
    border-radius: 1.25rem;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.15);
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    overflow: hidden;
}

.stat-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, #667eea 0%, #764ba2 100%);
    transform: scaleX(0);
    transition: transform 0.3s ease;
}

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

.stat-card:hover {
    transform: translateY(-10px) scale(1.02);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.2);
}

.stat-card-primary .stat-icon {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
}

.stat-card-flutter .stat-icon {
    background: linear-gradient(135deg, #0468d7 0%, #02569b 100%);
}

.stat-card-web .stat-icon {
    background: linear-gradient(135deg, #10b981 0%, #059669 100%);
}

.stat-card-games .stat-icon {
    background: linear-gradient(135deg, #f59e0b 0%, #ea580c 100%);
}

.stat-card-utility .stat-icon {
    background: linear-gradient(135deg, #8b5cf6 0%, #7c3aed 100%);
}

.stat-icon-wrapper {
    position: relative;
    margin-bottom: 1.5rem;
    display: inline-block;
}

.stat-icon {
    width: 70px;
    height: 70px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 1rem;
    font-size: 2rem;
    color: white;
    position: relative;
    z-index: 2;
    transition: transform 0.3s ease;
}

.stat-icon svg {
    width: 32px;
    height: 32px;
    fill: currentColor;
}

.stat-card:hover .stat-icon {
    transform: scale(1.1) rotate(5deg);
}

.stat-icon-bg {
    position: absolute;
    top: 50%;
    left: 50%;
    width: 90px;
    height: 90px;
    background: inherit;
    border-radius: 1.5rem;
    opacity: 0.1;
    transform: translate(-50%, -50%);
    z-index: 1;
}

.stat-content {
    text-align: left;
}

.stat-number {
    font-size: 3rem;
    font-weight: 800;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    line-height: 1;
    margin-bottom: 0.5rem;
    letter-spacing: -0.02em;
}

.stat-label {
    font-size: 1rem;
    color: #1e293b;
    font-weight: 600;
    margin-bottom: 0.25rem;
    letter-spacing: -0.01em;
}

.stat-description {
    font-size: 0.875rem;
    color: #64748b;
    font-weight: 400;
}

/* Tablet Responsive */
@media (min-width: 769px) and (max-width: 1024px) {
    .statistics-grid {
        grid-template-columns: repeat(3, 1fr);
        gap: 1.5rem;
    }
}

@media (min-width: 481px) and (max-width: 768px) {
    .statistics-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 1.5rem;
    }
}

/* Section Styles */
section {
    padding: 4rem 0;
    width: 100%;
    overflow-x: hidden;
}

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

.section-title {
    font-size: 2.5rem;
    color: #1e293b;
    margin-bottom: 1rem;
}

.section-description {
    font-size: 1.125rem;
    color: #64748b;
    max-width: 600px;
    margin: 0 auto;
}

/* Portfolio Section */
.portfolio {
    background: white;
}

.filters {
    display: flex;
    align-items: center;
    gap: 2rem;
    margin-bottom: 3rem;
    padding: 1.5rem;
    background: #f8fafc;
    border-radius: 1rem;
    flex-wrap: wrap;
}

.filter-group {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.filter-group label {
    font-weight: 500;
    color: #475569;
}

.filter-select {
    padding: 0.5rem 1rem;
    border: 1px solid #e2e8f0;
    border-radius: 0.375rem;
    background: white;
    color: #475569;
    cursor: pointer;
}

.filter-select:focus {
    outline: none;
    border-color: #667eea;
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}

.portfolio-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
    gap: 2rem;
    margin-bottom: 3rem;
}

.app-card {
    background: white;
    border-radius: 1rem;
    overflow: hidden;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.05);
    transition: all 0.3s ease;
    cursor: pointer;
}

.app-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
}

.app-image {
    position: relative;
    height: 200px;
    overflow: hidden;
    background: #f1f5f9;
}

.app-image img,
.app-image video {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

/* Video specific styles */
.app-image video {
    will-change: transform;
}

.app-media-video {
    display: block;
}

.app-media-fallback {
    display: block;
}

.app-media-fallback.hidden {
    display: none;
}

.app-card:hover .app-image img,
.app-card:hover .app-image video {
    transform: scale(1.05);
}

/* Loading state for videos */
.app-media-video:not(.loaded) {
    background: linear-gradient(90deg, #f0f0f0 25%, #e0e0e0 50%, #f0f0f0 75%);
    background-size: 200% 100%;
    animation: loading 1.5s infinite;
}

@keyframes loading {
    0% { background-position: 200% 0; }
    100% { background-position: -200% 0; }
}

.app-type-badge {
    position: absolute;
    top: 1rem;
    right: 1rem;
    padding: 0.25rem 0.75rem;
    border-radius: 1rem;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
}

.app-type-badge.flutter {
    background: #02569b;
    color: white;
}

.app-type-badge.web {
    background: #10b981;
    color: white;
}

.app-icon {
    position: absolute;
    bottom: 1rem;
    left: 1rem;
    width: 40px;
    height: 40px;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
    background: white;
    padding: 2px;
}

.app-icon-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 6px;
}

.app-content {
    padding: 1.5rem;
}

.app-meta {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 1rem;
}

.app-category {
    background: #f1f5f9;
    color: #475569;
    padding: 0.25rem 0.75rem;
    border-radius: 0.375rem;
    font-size: 0.75rem;
    font-weight: 500;
}

.app-year {
    color: #94a3b8;
    font-size: 0.875rem;
}

.app-title {
    font-size: 1.25rem;
    font-weight: 600;
    color: #1e293b;
    margin-bottom: 0.5rem;
}

.app-description {
    color: #64748b;
    font-size: 0.875rem;
    line-height: 1.5;
    margin-bottom: 1rem;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.app-actions {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
}

.app-actions .btn {
    font-size: 0.75rem;
    padding: 0.5rem 1rem;
}

/* Loading and Empty States */
.loading {
    text-align: center;
    padding: 3rem;
}

.loading-spinner {
    width: 40px;
    height: 40px;
    border: 4px solid #f1f5f9;
    border-top: 4px solid #667eea;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin: 0 auto 1rem;
}

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

.empty-state {
    text-align: center;
    padding: 3rem;
    color: #94a3b8;
}

.empty-state i {
    font-size: 3rem;
    margin-bottom: 1rem;
}

/* About Section */
.about {
    background: #f8fafc;
}

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

.about-card {
    background: white;
    padding: 2rem;
    border-radius: 1rem;
    text-align: center;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.05);
    transition: transform 0.3s ease;
}

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

.about-icon {
    width: 60px;
    height: 60px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1rem;
}

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

.about-card h3 {
    color: #1e293b;
    margin-bottom: 1rem;
}

.about-card p {
    color: #64748b;
    font-size: 0.875rem;
}

/* Contact Section */
.contact {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 5rem 0;
}

.contact-header {
    text-align: center;
    margin-bottom: 3rem;
}

.contact-header .section-title {
    color: white;
}

.contact-header .section-description {
    color: rgba(255, 255, 255, 0.9);
    max-width: 600px;
    margin: 0 auto;
}

.contact-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 3rem;
    margin-top: 2rem;
}

.contact-card {
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    padding: 2rem;
    border-radius: 1rem;
    border: 1px solid rgba(255, 255, 255, 0.2);
    margin-bottom: 2rem;
}

.contact-icon {
    width: 60px;
    height: 60px;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 1rem;
}

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

.contact-card h3 {
    color: white;
    margin-bottom: 1rem;
    font-size: 1.25rem;
}

.contact-card p {
    color: rgba(255, 255, 255, 0.9);
    font-size: 0.95rem;
    line-height: 1.6;
}

.contact-methods {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.contact-method {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1rem;
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    border-radius: 0.75rem;
    border: 1px solid rgba(255, 255, 255, 0.2);
    text-decoration: none;
    transition: all 0.3s ease;
}

.contact-method:hover {
    background: rgba(255, 255, 255, 0.15);
    transform: translateX(5px);
}

.method-icon {
    width: 48px;
    height: 48px;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.method-icon i {
    font-size: 1.25rem;
    color: white;
}

.method-info h4 {
    color: white;
    font-size: 0.875rem;
    font-weight: 600;
    margin-bottom: 0.25rem;
}

.method-info p {
    color: rgba(255, 255, 255, 0.8);
    font-size: 0.875rem;
    margin: 0;
}

.contact-form-card {
    background: white;
    padding: 2rem;
    border-radius: 1rem;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
}

.contact-form-card h3 {
    color: #1e293b;
    margin-bottom: 1.5rem;
    font-size: 1.5rem;
}

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

.contact-form label {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: #475569;
    font-weight: 500;
    margin-bottom: 0.5rem;
    font-size: 0.875rem;
}

.contact-form label i {
    color: #667eea;
    font-size: 0.875rem;
}

.contact-form input,
.contact-form select,
.contact-form textarea {
    width: 100%;
    padding: 0.75rem 1rem;
    border: 2px solid #e2e8f0;
    border-radius: 0.5rem;
    font-family: 'Inter', sans-serif;
    font-size: 0.95rem;
    transition: all 0.3s ease;
    background: #f8fafc;
}

.contact-form input:focus,
.contact-form select:focus,
.contact-form textarea:focus {
    outline: none;
    border-color: #667eea;
    background: white;
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}

.contact-form textarea {
    resize: vertical;
    min-height: 100px;
}

.contact-form .btn-block {
    width: 100%;
    justify-content: center;
    padding: 1rem;
    font-size: 1rem;
    font-weight: 600;
}

.form-note {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-top: 1rem;
    padding: 0.75rem 1rem;
    background: #f1f5f9;
    border-radius: 0.5rem;
    font-size: 0.875rem;
    color: #64748b;
}

.form-note i {
    color: #667eea;
    flex-shrink: 0;
}

/* Modal Styles */
.modal {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.8);
    z-index: 2000;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
    padding: 2rem;
}

.modal.active {
    opacity: 1;
    visibility: visible;
}

.modal-content {
    background: white;
    border-radius: 1rem;
    max-width: 1100px;
    width: 100%;
    max-height: 90vh;
    overflow-y: auto;
    transform: scale(0.9);
    transition: transform 0.3s ease;
}

.modal.active .modal-content {
    transform: scale(1);
}

.modal-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 1.5rem;
    border-bottom: 1px solid #e2e8f0;
}

.modal-header h3 {
    margin: 0;
    color: #1e293b;
}

.modal-close {
    background: none;
    border: none;
    font-size: 1.5rem;
    color: #94a3b8;
    cursor: pointer;
    padding: 0.5rem;
    border-radius: 0.375rem;
    transition: all 0.3s ease;
}

.modal-close:hover {
    background: #f1f5f9;
    color: #475569;
}

.modal-body {
    padding: 1.5rem;
    display: grid;
    grid-template-columns: minmax(300px, 1.2fr) minmax(300px, 1fr);
    gap: 2rem;
    align-items: start;
}

.modal-image-gallery {
    width: 100%;
    max-width: 100%;
}

.modal-info {
    min-width: 0; /* Allows text to wrap properly */
    overflow-wrap: break-word;
}

.main-image {
    position: relative;
    margin-bottom: 1rem;
    cursor: pointer;
    border-radius: 0.75rem;
    overflow: hidden;
    background: #f8fafc;
}

.main-image img,
.main-image video {
    width: 100%;
    height: auto;
    max-height: 400px;
    object-fit: contain;
    border-radius: 0.75rem;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
    background: white;
}

.main-image video {
    display: block;
}

.main-image:hover img {
    transform: scale(1.02);
}

/* Don't scale video on hover since it has controls */
.main-image:hover video {
    transform: none;
}

.fullscreen-hint {
    position: absolute;
    top: 1rem;
    left: 1rem;
    background: rgba(0, 0, 0, 0.7);
    color: white;
    padding: 0.5rem 1rem;
    border-radius: 0.5rem;
    font-size: 0.75rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    opacity: 0;
    transition: opacity 0.3s ease;
    pointer-events: none;
}

.main-image:hover .fullscreen-hint {
    opacity: 1;
}

.image-navigation {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 100%;
    display: flex;
    justify-content: space-between;
    padding: 0 1rem;
    pointer-events: none;
}

.nav-btn {
    background: rgba(0, 0, 0, 0.7);
    color: white;
    border: none;
    border-radius: 50%;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    pointer-events: all;
    transition: all 0.3s ease;
    opacity: 0.8;
}

.nav-btn:hover {
    background: rgba(0, 0, 0, 0.9);
    opacity: 1;
    transform: scale(1.1);
}

.nav-btn:disabled {
    opacity: 0.3;
    cursor: not-allowed;
    transform: none;
}

.image-counter {
    position: absolute;
    bottom: 1rem;
    right: 1rem;
    background: rgba(0, 0, 0, 0.7);
    color: white;
    padding: 0.5rem 1rem;
    border-radius: 1rem;
    font-size: 0.875rem;
    font-weight: 500;
}

.image-thumbnails {
    display: flex;
    gap: 0.5rem;
    overflow-x: auto;
    padding: 0.5rem 0;
    scrollbar-width: thin;
    scrollbar-color: #cbd5e1 #f1f5f9;
}

.image-thumbnails::-webkit-scrollbar {
    height: 4px;
}

.image-thumbnails::-webkit-scrollbar-track {
    background: #f1f5f9;
    border-radius: 2px;
}

.image-thumbnails::-webkit-scrollbar-thumb {
    background: #cbd5e1;
    border-radius: 2px;
}

.thumbnail-image {
    flex-shrink: 0;
    width: 60px;
    height: 60px;
    border-radius: 0.5rem;
    overflow: hidden;
    cursor: pointer;
    border: 2px solid transparent;
    transition: all 0.3s ease;
    position: relative;
}

.thumbnail-image:hover {
    border-color: #667eea;
    transform: scale(1.05);
}

.thumbnail-image.active {
    border-color: #667eea;
    box-shadow: 0 0 0 2px rgba(102, 126, 234, 0.2);
}

.thumbnail-image img,
.thumbnail-image video {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* Thumbnail video styles */
.thumbnail-video {
    display: block;
}

/* Video indicator for thumbnails */
.video-indicator {
    position: absolute;
    bottom: 4px;
    right: 4px;
    width: 20px;
    height: 20px;
    background: rgba(0, 0, 0, 0.7);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    pointer-events: none;
}

.video-indicator i {
    color: white;
    font-size: 10px;
}

.modal-meta {
    display: flex;
    gap: 1rem;
    margin-bottom: 1rem;
    flex-wrap: wrap;
}

.modal-category,
.modal-year,
.modal-type {
    padding: 0.25rem 0.75rem;
    border-radius: 0.375rem;
    font-size: 0.75rem;
    font-weight: 500;
}

.modal-category {
    background: #f1f5f9;
    color: #475569;
}

.modal-year {
    background: #fef3c7;
    color: #92400e;
}

.modal-type {
    background: #dbeafe;
    color: #1e40af;
}

.modal-description {
    margin-bottom: 1.5rem;
    line-height: 1.6;
}

.modal-technologies,
.modal-features {
    margin-bottom: 1.5rem;
}

.modal-technologies h4,
.modal-features h4 {
    color: #1e293b;
    margin-bottom: 0.75rem;
    font-size: 1rem;
}

.tech-tags {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
}

.tech-tag {
    background: #667eea;
    color: white;
    padding: 0.25rem 0.75rem;
    border-radius: 1rem;
    font-size: 0.75rem;
    font-weight: 500;
}

.modal-features ul {
    list-style: none;
    padding: 0;
}

.modal-features li {
    padding: 0.25rem 0;
    color: #64748b;
    position: relative;
    padding-left: 1.5rem;
}

.modal-features li::before {
    content: '✓';
    position: absolute;
    left: 0;
    color: #10b981;
    font-weight: bold;
}

.modal-actions {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
}

/* Share Modal Styles */
.share-modal {
    max-width: 500px;
}

.share-content {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.share-url {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.share-url label {
    font-weight: 500;
    color: #374151;
}

.url-input-group {
    display: flex;
    gap: 0.5rem;
}

.url-input-group input {
    flex: 1;
    padding: 0.75rem;
    border: 1px solid #d1d5db;
    border-radius: 0.5rem;
    font-size: 0.875rem;
    background: #f9fafb;
    color: #374151;
}

.url-input-group input:focus {
    outline: none;
    border-color: #667eea;
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}

.share-options h4 {
    margin: 0 0 1rem 0;
    font-weight: 500;
    color: #374151;
}

.social-buttons {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
    gap: 0.75rem;
}

.social-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.75rem 1rem;
    border-radius: 0.5rem;
    text-decoration: none;
    font-weight: 500;
    font-size: 0.875rem;
    transition: all 0.3s ease;
    color: white;
}

.social-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.social-btn.whatsapp {
    background: #25d366;
}

.social-btn.whatsapp:hover {
    background: #1da851;
}

.social-btn.twitter {
    background: #1da1f2;
}

.social-btn.twitter:hover {
    background: #0d8bd9;
}

.social-btn.facebook {
    background: #1877f2;
}

.social-btn.facebook:hover {
    background: #166fe5;
}

.social-btn.linkedin {
    background: #0a66c2;
}

.social-btn.linkedin:hover {
    background: #004182;
}

.social-btn.telegram {
    background: #0088cc;
}

.social-btn.telegram:hover {
    background: #006699;
}

.share-qr {
    text-align: center;
}

.share-qr h4 {
    margin: 0 0 1rem 0;
    font-weight: 500;
    color: #374151;
}

.qr-container {
    display: flex;
    justify-content: center;
    padding: 1rem;
    background: #f9fafb;
    border-radius: 0.5rem;
    border: 1px solid #e5e7eb;
}

#qrCanvas {
    max-width: 200px;
    height: auto;
}

.share-btn {
    color: #667eea;
    border-color: #667eea;
}

.share-btn:hover {
    background: #667eea;
    color: white;
}

.btn-success {
    background: #10b981 !important;
    border-color: #10b981 !important;
    color: white !important;
}

/* Flutter Modal Styles */
.flutter-modal .modal-content {
    max-width: 1000px;
}

/* Fullscreen Image Modal Styles */
.fullscreen-modal {
    background: rgba(0, 0, 0, 0.95);
    z-index: 3000;
}

.fullscreen-modal-content {
    background: transparent;
    border-radius: 0;
    max-width: 100vw;
    max-height: 100vh;
    width: 100%;
    height: 100%;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.fullscreen-header {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    z-index: 10;
    padding: 1rem 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: linear-gradient(to bottom, rgba(0, 0, 0, 0.7), transparent);
}

.fullscreen-controls {
    display: flex;
    align-items: center;
    gap: 2rem;
}

.fullscreen-btn {
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    color: white;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s ease;
    backdrop-filter: blur(10px);
}

.fullscreen-btn:hover:not(:disabled) {
    background: rgba(255, 255, 255, 0.2);
    transform: scale(1.1);
}

.fullscreen-btn:disabled {
    opacity: 0.3;
    cursor: not-allowed;
}

.fullscreen-counter {
    color: white;
    font-weight: 500;
    font-size: 1rem;
    background: rgba(0, 0, 0, 0.5);
    padding: 0.5rem 1rem;
    border-radius: 2rem;
    backdrop-filter: blur(10px);
}

.fullscreen-close {
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    color: white;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s ease;
    backdrop-filter: blur(10px);
    font-size: 1.2rem;
}

.fullscreen-close:hover {
    background: rgba(255, 0, 0, 0.3);
    transform: scale(1.1);
}

.fullscreen-body {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 4rem 2rem 2rem;
    overflow: hidden;
}

.fullscreen-body img,
.fullscreen-body video {
    max-width: 100%;
    max-height: 100%;
    width: auto;
    height: auto;
    object-fit: contain;
    border-radius: 0.5rem;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
    cursor: default;
}

.fullscreen-body video {
    display: block;
}

/* Fullscreen modal content video styles */
.fullscreen-modal-content img,
.fullscreen-modal-content video {
    max-width: 90vw;
    max-height: 90vh;
    width: auto;
    height: auto;
}

.flutter-preview {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
    align-items: center;
}

.phone-frame {
    background: #1e293b;
    padding: 2rem 1rem;
    border-radius: 2rem;
    position: relative;
    max-width: 300px;
    margin: 0 auto;
}

.phone-frame::before {
    content: '';
    position: absolute;
    top: 1rem;
    left: 50%;
    transform: translateX(-50%);
    width: 60px;
    height: 4px;
    background: #64748b;
    border-radius: 2px;
}

.phone-screen {
    background: white;
    border-radius: 1.5rem;
    overflow: hidden;
    aspect-ratio: 9/16;
}

.phone-screen iframe {
    width: 100%;
    height: 100%;
}

.flutter-info h4 {
    color: #1e293b;
    margin-bottom: 1rem;
}

.flutter-info p {
    margin-bottom: 1.5rem;
}

/* Footer */
.footer {
    background: #1e293b;
    color: white;
    padding: 3rem 0 1rem;
}

.footer-content {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 2rem;
}

.footer-logo {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 1.25rem;
    font-weight: 700;
}

.footer-logo i {
    color: #667eea;
    font-size: 1.5rem;
}

.footer-links {
    display: flex;
    gap: 2rem;
}

.footer-links a {
    color: #94a3b8;
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    transition: color 0.3s ease;
}

.footer-links a:hover {
    color: white;
}

.footer-bottom {
    text-align: center;
    padding-top: 2rem;
    border-top: 1px solid #334155;
}

.footer-bottom p {
    color: #94a3b8;
    margin: 0;
}

/* Responsive Design */

/* Tablet Styles */
@media (max-width: 1024px) and (min-width: 769px) {
    .modal-content {
        max-width: 95vw;
    }
    
    .modal-body {
        grid-template-columns: 1fr 1fr;
        gap: 1.5rem;
    }
}

/* Mobile Styles */
@media (max-width: 768px) {
    html, body {
        max-width: 100vw;
        overflow-x: hidden;
    }
    
    section {
        width: 100%;
        overflow-x: hidden;
    }
    
    .container {
        max-width: 100%;
        padding: 0 20px;
        overflow-x: hidden;
    }
    
    .nav {
        display: none;
    }
    
    .mobile-menu-btn {
        display: block;
    }
    
    .hero-title {
        font-size: 2rem;
    }
    
    .hero-visual {
        display: none;
    }
    
    .portfolio-grid {
        grid-template-columns: 1fr;
    }
    
    .filters {
        flex-direction: column;
        align-items: stretch;
        gap: 1rem;
    }
    
    .filter-group {
        flex-direction: column;
        align-items: stretch;
    }
    
    .about-grid {
        grid-template-columns: 1fr;
    }
    
    .contact-grid {
        grid-template-columns: 1fr;
        gap: 2rem;
    }
    
    .contact-methods {
        gap: 0.75rem;
    }
    
    .contact-method {
        padding: 0.875rem;
    }
    
    .flutter-preview {
        grid-template-columns: 1fr;
        text-align: center;
    }
    
    .footer-content {
        flex-direction: column;
        gap: 2rem;
        text-align: center;
    }
    
    .footer-links {
        justify-content: center;
    }
    
    .hero-buttons {
        justify-content: center;
    }
    
    .modal {
        padding: 1rem;
    }
    
    .modal-header {
        padding: 1rem;
    }
    
    .modal-header h3 {
        font-size: 1.25rem;
    }
    
    .modal-content {
        max-width: 95vw;
    }
    
    .modal-body {
        display: flex;
        flex-direction: column;
        grid-template-columns: none;
        gap: 1rem;
        padding: 1rem;
    }
    
    .modal-image-gallery {
        margin-bottom: 1rem;
    }
    
    .modal-info {
        display: flex;
        flex-direction: column;
    }
    
    .modal-actions {
        justify-content: center;
        order: -1; /* Move to top */
        margin-bottom: 1.5rem;
        padding-bottom: 1rem;
        border-bottom: 1px solid #e2e8f0;
    }
    
    .modal-actions .btn {
        font-size: 0.9375rem;
        padding: 0.75rem 1.25rem;
        min-width: 120px;
    }
    
    .modal-meta {
        order: 0;
    }
    
    .modal-category,
    .modal-year,
    .modal-type {
        font-size: 0.875rem;
        padding: 0.375rem 0.875rem;
    }
    
    .modal-description {
        order: 1;
        font-size: 1rem;
        line-height: 1.7;
    }
    
    .modal-technologies {
        order: 2;
    }
    
    .modal-technologies h4,
    .modal-features h4 {
        font-size: 1.125rem;
        margin-bottom: 1rem;
    }
    
    .tech-tag {
        font-size: 0.875rem;
        padding: 0.375rem 0.875rem;
    }
    
    .modal-features {
        order: 3;
    }
    
    .modal-features li {
        font-size: 1rem;
        padding: 0.375rem 0;
        padding-left: 1.75rem;
        line-height: 1.6;
    }
    
    .fullscreen-header {
        padding: 0.5rem 1rem;
    }
    
    .fullscreen-controls {
        gap: 1rem;
    }
    
    .fullscreen-btn,
    .fullscreen-close {
        width: 40px;
        height: 40px;
        font-size: 0.9rem;
    }
    
    .fullscreen-counter {
        font-size: 0.875rem;
        padding: 0.375rem 0.75rem;
    }
    
    .fullscreen-body {
        padding: 3rem 1rem 1rem;
    }
    
    .statistics {
        padding: 3rem 0;
    }
    
    .statistics-header {
        margin-bottom: 2rem;
    }
    
    .statistics-title {
        font-size: 2rem;
    }
    
    .statistics-subtitle {
        font-size: 1rem;
    }
    
    .statistics-grid {
        grid-template-columns: 1fr;
        gap: 1.5rem;
        width: 100%;
        padding: 0;
    }
    
    .stat-card {
        padding: 1.75rem;
    }
    
    .stat-icon {
        width: 60px;
        height: 60px;
        font-size: 1.75rem;
    }
    
    .stat-icon svg {
        width: 28px;
        height: 28px;
    }
    
    .stat-icon-bg {
        width: 80px;
        height: 80px;
    }
    
    .stat-number {
        font-size: 2.5rem;
    }
    
    .stat-label {
        font-size: 0.9rem;
    }
    
    .stat-description {
        font-size: 0.8rem;
    }
}

@media (max-width: 480px) {
    html, body {
        max-width: 100vw;
        overflow-x: hidden;
    }
    
    section {
        width: 100%;
        overflow-x: hidden;
    }
    
    .container {
        padding: 0 15px;
        max-width: 100%;
        overflow-x: hidden;
    }
    
    .hero {
        padding: 6rem 0 4rem;
        min-height: 500px;
    }
    
    .hero-title {
        font-size: 1.75rem;
    }
    
    .section-title {
        font-size: 2rem;
    }
    
    .btn {
        font-size: 0.8rem;
        padding: 0.6rem 1.2rem;
    }
    
    .app-actions {
        justify-content: center;
    }
    
    .statistics {
        padding: 2.5rem 0;
    }
    
    .statistics-title {
        font-size: 1.75rem;
    }
    
    .statistics-subtitle {
        font-size: 0.9rem;
    }
    
    .stat-card {
        padding: 1.5rem;
    }
    
    .stat-icon {
        width: 55px;
        height: 55px;
        font-size: 1.5rem;
    }
    
    .stat-icon svg {
        width: 24px;
        height: 24px;
    }
    
    .stat-icon-bg {
        width: 70px;
        height: 70px;
    }
    
    .stat-number {
        font-size: 2rem;
    }
}

/* Notification Messages */
.notification-message {
    position: fixed;
    top: 20px;
    right: 20px;
    min-width: 300px;
    max-width: 500px;
    padding: 1rem 1.5rem;
    background: white;
    border-radius: 0.75rem;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.15);
    display: flex;
    align-items: center;
    gap: 1rem;
    z-index: 10000;
    transform: translateX(120%);
    transition: transform 0.3s ease, opacity 0.3s ease;
    opacity: 0;
}

.notification-message.show {
    transform: translateX(0);
    opacity: 1;
}

.notification-message i:first-child {
    font-size: 1.5rem;
    flex-shrink: 0;
}

.notification-message span {
    flex: 1;
    color: #334155;
    font-size: 0.95rem;
    line-height: 1.5;
    white-space: pre-line;
}

.notification-close {
    background: none;
    border: none;
    cursor: pointer;
    padding: 0.25rem;
    color: #94a3b8;
    transition: color 0.2s ease;
    flex-shrink: 0;
}

.notification-close:hover {
    color: #64748b;
}

/* Notification types */
.notification-success {
    border-left: 4px solid #10b981;
}

.notification-success i:first-child {
    color: #10b981;
}

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

.notification-error i:first-child {
    color: #ef4444;
}

.notification-info {
    border-left: 4px solid #3b82f6;
}

.notification-info i:first-child {
    color: #3b82f6;
}

.notification-warning {
    border-left: 4px solid #f59e0b;
}

.notification-warning i:first-child {
    color: #f59e0b;
}

@media (max-width: 640px) {
    .notification-message {
        right: 10px;
        left: 10px;
        min-width: auto;
        max-width: none;
    }
}
