/* Custom Styles for laex.com.tr */

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --primary: #00D9FF;
    --dark-bg: #0D1117;
    --dark-card: #161B22;
    --dark-border: #30363D;
}

body {
    overflow-x: hidden;
}

/* Gradient Text */
.gradient-text {
    background: linear-gradient(135deg, #00D9FF 0%, #0099FF 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* Navigation Links */
.nav-link {
    position: relative;
    color: #9CA3AF;
    transition: color 0.3s ease;
}

.nav-link:hover {
    color: var(--primary);
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--primary);
    transition: width 0.3s ease;
}

.nav-link:hover::after {
    width: 100%;
}

/* Animated Background */
.animated-bg {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    overflow: hidden;
    z-index: 0;
}

.animated-bg::before,
.animated-bg::after {
    content: '';
    position: absolute;
    width: 500px;
    height: 500px;
    border-radius: 50%;
    filter: blur(100px);
    opacity: 0.1;
    animation: float 20s infinite ease-in-out;
}

.animated-bg::before {
    background: var(--primary);
    top: -250px;
    left: -250px;
    animation-delay: 0s;
}

.animated-bg::after {
    background: #0099FF;
    bottom: -250px;
    right: -250px;
    animation-delay: 10s;
}

@keyframes float {
    0%, 100% {
        transform: translate(0, 0) scale(1);
    }
    33% {
        transform: translate(100px, -100px) scale(1.1);
    }
    66% {
        transform: translate(-100px, 100px) scale(0.9);
    }
}

/* Buttons */
.btn-primary {
    display: inline-flex;
    align-items: center;
    padding: 0.75rem 2rem;
    background: linear-gradient(135deg, var(--primary) 0%, #0099FF 100%);
    color: #0D1117;
    font-weight: 600;
    border-radius: 0.75rem;
    transition: all 0.3s ease;
    border: none;
    cursor: pointer;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 30px rgba(0, 217, 255, 0.3);
}

.btn-secondary {
    display: inline-flex;
    align-items: center;
    padding: 0.75rem 2rem;
    background: transparent;
    color: var(--primary);
    font-weight: 600;
    border-radius: 0.75rem;
    border: 2px solid var(--primary);
    transition: all 0.3s ease;
    cursor: pointer;
}

.btn-secondary:hover {
    background: var(--primary);
    color: #0D1117;
    transform: translateY(-2px);
}

/* Social Links */
.social-link {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 3rem;
    height: 3rem;
    background: var(--dark-card);
    border: 1px solid var(--dark-border);
    border-radius: 0.75rem;
    color: #9CA3AF;
    transition: all 0.3s ease;
}

.social-link:hover {
    background: var(--primary);
    color: #0D1117;
    border-color: var(--primary);
    transform: translateY(-4px);
}

/* Section Title */
.section-title {
    font-size: 2.5rem;
    font-weight: 800;
    position: relative;
    display: inline-block;
}

.section-title::after {
    content: '';
    position: absolute;
    bottom: -8px;
    left: 0;
    width: 60px;
    height: 4px;
    background: linear-gradient(90deg, var(--primary) 0%, transparent 100%);
    border-radius: 2px;
}

/* Cards */
.feature-card,
.project-card,
.blog-card,
.contact-card {
    background: var(--dark-card);
    border: 1px solid var(--dark-border);
    border-radius: 1rem;
    padding: 2rem;
    transition: all 0.3s ease;
    opacity: 0;
    transform: translateY(20px);
}

.feature-card.animate-fade-in,
.project-card.animate-fade-in,
.blog-card.animate-fade-in {
    opacity: 1;
    transform: translateY(0);
}

/* Modal Styles */
#project-modal,
#file-viewer-modal {
    backdrop-filter: blur(8px);
    animation: fadeIn 0.3s ease;
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

#project-modal > div > div,
#file-viewer-modal > div > div {
    animation: slideUp 0.3s ease;
}

@keyframes slideUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Tab Styles */
.tab-btn {
    padding: 1rem 1.5rem;
    background: transparent;
    border: none;
    border-bottom: 2px solid transparent;
    color: #9CA3AF;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
}

.tab-btn:hover {
    color: var(--primary);
}

.tab-btn.active {
    color: var(--primary);
    border-bottom-color: var(--primary);
}

/* Markdown Body */
.markdown-body {
    line-height: 1.8;
}

.markdown-body h1,
.markdown-body h2,
.markdown-body h3 {
    color: #F0F6FC;
}

.markdown-body code {
    background: var(--dark-bg);
    color: var(--primary);
    padding: 0.2rem 0.4rem;
    border-radius: 0.25rem;
    font-size: 0.875rem;
}

.markdown-body pre {
    background: var(--dark-bg);
    border: 1px solid var(--dark-border);
    border-radius: 0.5rem;
    padding: 1rem;
    overflow-x: auto;
}

.markdown-body pre code {
    background: transparent;
    padding: 0;
    color: #C9D1D9;
}

.markdown-body a {
    color: var(--primary);
    text-decoration: none;
}

.markdown-body a:hover {
    text-decoration: underline;
}

/* File Viewer */
#file-content {
    background: var(--dark-bg);
    color: #C9D1D9;
    font-family: 'Consolas', 'Monaco', 'Courier New', monospace;
    line-height: 1.6;
}

#file-content code {
    display: block;
    padding: 0 !important;
    background: transparent !important;
}

#file-content pre {
    margin: 0;
    padding: 0;
}

/* Syntax Highlighting Overrides */
.hljs {
    background: var(--dark-bg) !important;
    padding: 1.5rem !important;
    border-radius: 0.5rem;
    font-size: 0.875rem;
    line-height: 1.6;
}

.markdown-body .hljs {
    border: 1px solid var(--dark-border);
}

/* Line Numbers */
.hljs-ln-numbers {
    text-align: right;
    color: #6B7280;
    border-right: 1px solid var(--dark-border);
    padding-right: 1rem;
    margin-right: 1rem;
    user-select: none;
}

.hljs-ln-code {
    padding-left: 1rem;
}

/* Custom Code Block Styling */
pre code.hljs {
    padding: 1.5rem !important;
}

/* Scrollbar for code blocks */
.hljs::-webkit-scrollbar {
    height: 8px;
}

.hljs::-webkit-scrollbar-track {
    background: var(--dark-card);
    border-radius: 4px;
}

.hljs::-webkit-scrollbar-thumb {
    background: var(--dark-border);
    border-radius: 4px;
}

.hljs::-webkit-scrollbar-thumb:hover {
    background: var(--primary);
}

.feature-card:hover,
.project-card:hover,
.blog-card:hover,
.contact-card:hover {
    border-color: var(--primary);
    transform: translateY(-8px);
    box-shadow: 0 20px 40px rgba(0, 217, 255, 0.1);
}

.card-hover {
    transition: all 0.3s ease;
}

.card-hover:hover {
    transform: translateY(-4px);
    box-shadow: 0 10px 30px rgba(0, 217, 255, 0.15);
}

/* Skill Cards */
.skill-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    background: var(--dark-card);
    border: 1px solid var(--dark-border);
    border-radius: 1rem;
    padding: 1.5rem 1rem;
    transition: all 0.3s ease;
    text-align: center;
}

.skill-card:hover {
    border-color: var(--primary);
    transform: translateY(-4px) scale(1.05);
    box-shadow: 0 10px 20px rgba(0, 217, 255, 0.2);
}

.skill-category {
    margin-bottom: 3rem;
}

/* Tech Badge */
.tech-badge {
    display: inline-block;
    padding: 0.5rem 1rem;
    background: rgba(0, 217, 255, 0.1);
    color: var(--primary);
    border: 1px solid rgba(0, 217, 255, 0.2);
    border-radius: 0.5rem;
    font-size: 0.875rem;
    font-weight: 500;
    transition: all 0.3s ease;
}

.tech-badge:hover {
    background: rgba(0, 217, 255, 0.2);
    border-color: var(--primary);
}

/* Filter Buttons */
.filter-btn {
    padding: 0.5rem 1.5rem;
    background: var(--dark-card);
    color: #9CA3AF;
    border: 1px solid var(--dark-border);
    border-radius: 0.5rem;
    font-size: 0.875rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
}

.filter-btn:hover,
.filter-btn.active {
    background: var(--primary);
    color: #0D1117;
    border-color: var(--primary);
}

/* Line Clamp */
.line-clamp-2 {
    display: -webkit-box;
    -webkit-line-clamp: 2;
    line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* Scrollbar */
::-webkit-scrollbar {
    width: 10px;
}

::-webkit-scrollbar-track {
    background: var(--dark-bg);
}

::-webkit-scrollbar-thumb {
    background: var(--dark-border);
    border-radius: 5px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--primary);
}

/* Selection */
::selection {
    background: var(--primary);
    color: #0D1117;
}

/* Loading Animation */
@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

.animate-spin {
    animation: spin 1s linear infinite;
}

/* Fade In Animation */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.animate-fade-in {
    animation: fadeIn 0.6s ease-out forwards;
}

/* Pulse Animation */
@keyframes pulse {
    0%, 100% {
        opacity: 1;
    }
    50% {
        opacity: 0.5;
    }
}

.animate-pulse {
    animation: pulse 2s cubic-bezier(0.4, 0, 0.6, 1) infinite;
}

/* Responsive Typography */
@media (max-width: 768px) {
    .section-title {
        font-size: 2rem;
    }
}

/* Focus Styles */
button:focus,
a:focus,
input:focus {
    outline: 2px solid var(--primary);
    outline-offset: 2px;
}

/* Blog Article Styles */
.prose {
    color: #C9D1D9;
}

.prose h2,
.prose h3,
.prose h4 {
    color: #F0F6FC;
    margin-top: 2rem;
    margin-bottom: 1rem;
}

.prose a {
    color: var(--primary);
    text-decoration: none;
    transition: color 0.3s ease;
}

.prose a:hover {
    color: #0099FF;
    text-decoration: underline;
}

.prose code {
    background: var(--dark-card);
    padding: 0.2rem 0.4rem;
    border-radius: 0.25rem;
    font-size: 0.875rem;
    color: var(--primary);
}

.prose pre {
    background: var(--dark-bg);
    padding: 1rem;
    border-radius: 0.5rem;
    overflow-x: auto;
}

.prose ul {
    list-style-type: disc;
    padding-left: 1.5rem;
}

.prose ol {
    list-style-type: decimal;
    padding-left: 1.5rem;
}

/* Print Styles */
@media print {
    nav,
    footer,
    .social-link,
    .btn-primary,
    .btn-secondary {
        display: none;
    }
    
    body {
        background: white;
        color: black;
    }
}

/* Accessibility */
.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border-width: 0;
}

/* Reduced Motion */
@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}
