@import url('https://fonts.googleapis.com/css2?family=Roboto:wght@300;400;500;700;900&display=swap');

:root {
    --primary: #dc2626;
    --primary-dark: #b91c1c;
    --primary-light: #ef4444;
    --secondary: #64748b;
    --success: #10b981;
    --danger: #dc2626;
    --warning: #f59e0b;
    --info: #06b6d4;
    --light: #f8fafc;
    --dark: #0f172a;
    --white: #ffffff;
    --gradient-1: linear-gradient(135deg, #dc2626 0%, #991b1b 100%);
    --gradient-2: linear-gradient(135deg, #ef4444 0%, #dc2626 100%);
    --gradient-3: linear-gradient(135deg, #f87171 0%, #dc2626 100%);
    --gradient-4: linear-gradient(135deg, #fca5a5 0%, #ef4444 100%);
    --shadow-sm: 0 1px 2px 0 rgba(220, 38, 38, 0.1);
    --shadow-md: 0 4px 6px -1px rgba(220, 38, 38, 0.15), 0 2px 4px -1px rgba(220, 38, 38, 0.1);
    --shadow-lg: 0 10px 15px -3px rgba(220, 38, 38, 0.2), 0 4px 6px -2px rgba(220, 38, 38, 0.15);
    --shadow-xl: 0 20px 25px -5px rgba(220, 38, 38, 0.25), 0 10px 10px -5px rgba(220, 38, 38, 0.2);
}

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

body {
    font-family: 'Roboto', sans-serif;
    background: linear-gradient(180deg, #f8fafc 0%, #e2e8f0 100%);
    color: var(--dark);
    line-height: 1.6;
    min-height: 100vh;
    animation: fadeInPage 0.5s ease-in;
}

@keyframes fadeInPage {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

/* Header */
.header {
    background: rgba(255, 255, 255, 0.8);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    color: var(--dark);
    padding: 1.2rem 0;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
    position: sticky;
    top: 0;
    z-index: 100;
    border-bottom: 1px solid rgba(226, 232, 240, 0.8);
}

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

.header h1 {
    font-size: 1.75rem;
    font-weight: 900;
    background: var(--gradient-1);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    letter-spacing: -0.5px;
}

.header nav {
    display: flex;
    gap: 0.5rem;
    align-items: center;
}

.header nav > a {
    color: var(--dark);
    text-decoration: none;
    padding: 0.6rem 1.2rem;
    font-weight: 500;
    border-radius: 8px;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    font-size: 0.95rem;
}

.header nav > a:hover {
    background: var(--primary);
    color: var(--white);
    transform: translateY(-2px);
}

/* Language Switcher */
.language-switcher {
    display: flex;
    gap: 0.25rem;
    background: rgba(226, 232, 240, 0.5);
    padding: 0.25rem;
    border-radius: 8px;
}

.lang-btn {
    color: var(--dark);
    text-decoration: none;
    padding: 0.5rem 0.75rem;
    font-weight: 600;
    border-radius: 6px;
    transition: all 0.3s;
    font-size: 0.85rem;
    display: flex;
    align-items: center;
    gap: 0.3rem;
}

.lang-btn:hover {
    background: rgba(220, 38, 38, 0.1);
    color: var(--primary);
}

.lang-btn.active {
    background: var(--primary);
    color: var(--white);
    box-shadow: var(--shadow-sm);
}

/* Container */
.container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 3rem 2rem;
}

/* Grid Layout */
.file-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.25rem;
    margin-top: 1.5rem;
}

/* File Card */
.file-card {
    background: var(--white);
    border-radius: 20px;
    overflow: hidden;
    box-shadow: var(--shadow-md);
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    cursor: pointer;
    text-decoration: none;
    color: var(--dark);
    display: flex;
    flex-direction: column;
    border: 1px solid rgba(226, 232, 240, 0.8);
    position: relative;
}

.file-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: var(--gradient-1);
    opacity: 0;
    transition: opacity 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    z-index: 0;
    border-radius: 20px;
}

.file-card:hover {
    transform: translateY(-8px) scale(1.02);
    box-shadow: var(--shadow-xl);
    border-color: rgba(79, 70, 229, 0.3);
}

.file-card:hover::before {
    opacity: 0.03;
}

.file-card-icon {
    width: 100%;
    height: 160px;
    background: var(--gradient-1);
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    overflow: hidden;
}

.file-card:nth-child(4n+1) .file-card-icon {
    background: var(--gradient-1);
}

.file-card:nth-child(4n+2) .file-card-icon {
    background: var(--gradient-2);
}

.file-card:nth-child(4n+3) .file-card-icon {
    background: var(--gradient-3);
}

.file-card:nth-child(4n+4) .file-card-icon {
    background: var(--gradient-4);
}

.file-card-icon::after {
    content: '';
    position: absolute;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(255,255,255,0.1) 0%, transparent 70%);
    top: -50%;
    left: -50%;
    animation: shimmer 3s infinite;
}

@keyframes shimmer {
    0%, 100% { transform: translate(0, 0); }
    50% { transform: translate(20%, 20%); }
}

.file-card-icon img {
    max-width: 75%;
    max-height: 75%;
    object-fit: contain;
    filter: drop-shadow(0 4px 6px rgba(0, 0, 0, 0.1));
    z-index: 1;
    position: relative;
}

.file-card-icon .default-icon {
    font-size: 3.5rem;
    filter: drop-shadow(0 4px 6px rgba(0, 0, 0, 0.1));
    z-index: 1;
    position: relative;
}

.file-card-badge {
    position: absolute;
    top: 15px;
    right: 15px;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    color: var(--success);
    padding: 0.4rem 1rem;
    border-radius: 50px;
    font-size: 0.75rem;
    font-weight: 700;
    letter-spacing: 0.5px;
    text-transform: uppercase;
    box-shadow: var(--shadow-md);
    z-index: 2;
    border: 2px solid var(--success);
}

.file-card-badge.paid {
    background: rgba(245, 158, 11, 0.95);
    color: var(--white);
    border-color: var(--warning);
}

.file-card-body {
    padding: 1rem;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
    position: relative;
    z-index: 1;
    background: var(--white);
}

.file-card-title {
    font-size: 1rem;
    font-weight: 700;
    margin-bottom: 0.75rem;
    color: var(--dark);
    line-height: 1.3;
}

.file-card-description {
    font-size: 0.85rem;
    color: var(--secondary);
    margin-bottom: 1.25rem;
    flex-grow: 1;
    overflow: hidden;
    text-overflow: ellipsis;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    line-height: 1.6;
}

.file-card-stats {
    display: flex;
    justify-content: space-between;
    font-size: 0.9rem;
    color: var(--secondary);
    padding-top: 1rem;
    border-top: 2px solid #f1f5f9;
}

.file-card-stats span {
    display: flex;
    align-items: center;
    gap: 0.4rem;
    font-weight: 500;
}

.file-card-price {
    font-size: 1.2rem;
    font-weight: 900;
    background: var(--gradient-1);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-top: 0.75rem;
}

/* Detail Page */
.detail-container {
    background: var(--white);
    border-radius: 24px;
    padding: 3rem;
    box-shadow: var(--shadow-lg);
    margin-top: 2rem;
    border: 1px solid rgba(226, 232, 240, 0.8);
}

.detail-header {
    display: flex;
    gap: 3rem;
    margin-bottom: 3rem;
}

.detail-icon {
    flex-shrink: 0;
    width: 180px;
    height: 180px;
    background: var(--gradient-1);
    border-radius: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: var(--shadow-lg);
    position: relative;
    overflow: hidden;
}

.detail-icon::before {
    content: '';
    position: absolute;
    width: 100%;
    height: 100%;
    background: radial-gradient(circle at 30% 30%, rgba(255,255,255,0.2) 0%, transparent 60%);
}

.detail-icon img {
    max-width: 75%;
    max-height: 75%;
    object-fit: contain;
    filter: drop-shadow(0 4px 8px rgba(0, 0, 0, 0.15));
    z-index: 1;
    position: relative;
}

.detail-info {
    flex-grow: 1;
}

.detail-title {
    font-size: 2.5rem;
    font-weight: 900;
    margin-bottom: 0.75rem;
    line-height: 1.2;
    letter-spacing: -1px;
}

.detail-stats {
    display: flex;
    gap: 2.5rem;
    margin: 1.5rem 0;
    font-size: 1rem;
    color: var(--secondary);
}

.detail-stats span {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-weight: 500;
}

.detail-price {
    font-size: 2.5rem;
    font-weight: 900;
    background: var(--gradient-1);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin: 1.5rem 0;
}

.btn {
    display: inline-block;
    padding: 1rem 2rem;
    border: none;
    border-radius: 12px;
    font-size: 1rem;
    font-weight: 600;
    font-family: 'Roboto', sans-serif;
    cursor: pointer;
    text-decoration: none;
    text-align: center;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: var(--shadow-md);
    letter-spacing: 0.3px;
}

.btn:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
}

.btn:active {
    transform: translateY(0);
    box-shadow: var(--shadow-sm);
}

.btn-primary {
    background: var(--gradient-1);
    color: var(--white);
    border: 2px solid transparent;
}

.btn-primary:hover {
    filter: brightness(1.1);
}

.btn-success {
    background: var(--gradient-4);
    color: var(--white);
    border: 2px solid transparent;
}

.btn-success:hover {
    filter: brightness(1.1);
}

.btn-danger {
    background: linear-gradient(135deg, #f093fb 0%, #f5576c 100%);
    color: var(--white);
    border: 2px solid transparent;
}

.btn-danger:hover {
    filter: brightness(1.1);
}

.btn-warning {
    background: linear-gradient(135deg, #ffecd2 0%, #fcb69f 100%);
    color: var(--dark);
    border: 2px solid transparent;
}

.btn-warning:hover {
    filter: brightness(1.05);
}

.btn-secondary {
    background: var(--secondary);
    color: var(--white);
    border: 2px solid transparent;
}

.btn-secondary:hover {
    background: #475569;
}

/* Tabs */
.tabs {
    display: flex;
    gap: 0.75rem;
    border-bottom: 2px solid #e2e8f0;
    margin: 3rem 0 1.5rem 0;
    overflow-x: auto;
    padding-bottom: 0;
}

.tab-btn {
    padding: 1rem 1.75rem;
    background: transparent;
    border: none;
    border-bottom: 3px solid transparent;
    cursor: pointer;
    font-size: 1rem;
    font-weight: 600;
    color: var(--secondary);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    font-family: 'Roboto', sans-serif;
    border-radius: 8px 8px 0 0;
    white-space: nowrap;
}

.tab-btn:hover {
    background: rgba(79, 70, 229, 0.05);
    color: var(--primary);
}

.tab-btn.active {
    color: var(--primary);
    border-bottom-color: var(--primary);
    background: rgba(79, 70, 229, 0.05);
    font-weight: 700;
}

.tab-content {
    display: none;
    padding: 2rem 0;
    animation: fadeIn 0.3s ease-in;
}

.tab-content.active {
    display: block;
}

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

/* Screenshots Gallery */
.screenshots-container {
    margin-top: 1.5rem;
}

.screenshots-grid {
    display: grid;
    gap: 1rem;
    margin-top: 1.5rem;
}

/* Layout untuk 1 screenshot */
.screenshots-grid.single {
    grid-template-columns: 1fr;
}

/* Layout untuk 2 screenshot */
.screenshots-grid.double {
    grid-template-columns: repeat(2, 1fr);
}

/* Layout untuk 3 screenshot */
.screenshots-grid.triple {
    grid-template-columns: repeat(3, 1fr);
}

/* Layout untuk 4 screenshot */
.screenshots-grid.quad {
    grid-template-columns: repeat(2, 1fr);
    grid-template-rows: repeat(2, 1fr);
}

/* Layout khusus untuk 5 screenshot - 1 besar + 4 kecil */
.screenshots-grid.five {
    grid-template-columns: 2fr 1fr;
    grid-template-rows: repeat(2, 1fr);
    gap: 1rem;
}

.screenshots-grid.five .screenshot-item:first-child {
    grid-row: 1 / 3;
}

.screenshots-grid.five .screenshot-item:not(:first-child) {
    aspect-ratio: 1;
}

.screenshot-item {
    border-radius: 16px;
    overflow: hidden;
    box-shadow: var(--shadow-md);
    cursor: pointer;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    border: 2px solid rgba(226, 232, 240, 0.8);
    position: relative;
    background: var(--light);
    min-height: 200px;
}

.screenshot-item::before {
    content: '\f002';
    font-family: 'Font Awesome 6 Free';
    font-weight: 900;
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    font-size: 2.5rem;
    opacity: 0;
    transition: opacity 0.3s;
    z-index: 2;
    color: var(--white);
    text-shadow: 0 2px 8px rgba(0, 0, 0, 0.5);
}

.screenshot-item:hover::before {
    opacity: 1;
}

.screenshot-item:hover {
    transform: translateY(-4px) scale(1.02);
    box-shadow: var(--shadow-xl);
    border-color: var(--primary);
    z-index: 1;
}

.screenshot-item:hover img {
    filter: brightness(0.75);
}

.screenshot-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: filter 0.3s, transform 0.3s;
}

.screenshot-item:hover img {
    transform: scale(1.05);
}

/* Screenshot Gallery Viewer */
.screenshot-gallery-viewer {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(15, 23, 42, 0.95);
    backdrop-filter: blur(10px);
    z-index: 2000;
    display: none;
    align-items: center;
    justify-content: center;
    animation: fadeIn 0.3s ease-out;
}

.screenshot-gallery-viewer.active {
    display: flex;
}

.gallery-main-image {
    max-width: 90%;
    max-height: 85vh;
    object-fit: contain;
    border-radius: 12px;
    box-shadow: var(--shadow-xl);
}

.gallery-nav {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    border: 2px solid rgba(255, 255, 255, 0.2);
    color: var(--white);
    width: 50px;
    height: 50px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    font-size: 1.5rem;
    transition: all 0.3s;
    z-index: 10;
}

.gallery-nav:hover {
    background: rgba(255, 255, 255, 0.2);
    transform: translateY(-50%) scale(1.1);
}

.gallery-nav.prev {
    left: 2rem;
}

.gallery-nav.next {
    right: 2rem;
}

.gallery-nav:disabled {
    opacity: 0.3;
    cursor: not-allowed;
}

.gallery-close {
    position: absolute;
    top: 2rem;
    right: 2rem;
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    border: 2px solid rgba(255, 255, 255, 0.2);
    color: var(--white);
    width: 50px;
    height: 50px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    font-size: 1.5rem;
    transition: all 0.3s;
    z-index: 10;
}

.gallery-close:hover {
    background: rgba(220, 38, 38, 0.8);
    transform: scale(1.1);
}

.gallery-counter {
    position: absolute;
    bottom: 2rem;
    left: 50%;
    transform: translateX(-50%);
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    padding: 0.75rem 1.5rem;
    border-radius: 50px;
    color: var(--white);
    font-weight: 600;
    font-size: 0.95rem;
}

.gallery-thumbnails {
    position: absolute;
    bottom: 5rem;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 0.75rem;
    max-width: 80%;
    overflow-x: auto;
    padding: 1rem;
    background: rgba(0, 0, 0, 0.3);
    backdrop-filter: blur(10px);
    border-radius: 12px;
}

.gallery-thumbnail {
    width: 80px;
    height: 80px;
    border-radius: 8px;
    overflow: hidden;
    cursor: pointer;
    border: 3px solid transparent;
    transition: all 0.3s;
    flex-shrink: 0;
}

.gallery-thumbnail.active {
    border-color: var(--primary);
    transform: scale(1.1);
}

.gallery-thumbnail img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.gallery-thumbnail:hover {
    transform: scale(1.15);
}

/* Markdown Content Styles */
.markdown-content {
    background: #f8fafc;
    padding: 2rem;
    border-radius: 12px;
    line-height: 1.8;
    color: var(--dark);
}

.markdown-content h1,
.markdown-content h2,
.markdown-content h3,
.markdown-content h4,
.markdown-content h5,
.markdown-content h6 {
    margin-top: 1.5rem;
    margin-bottom: 1rem;
    font-weight: 700;
    color: var(--dark);
}

.markdown-content h1 {
    font-size: 2rem;
    border-bottom: 2px solid var(--primary);
    padding-bottom: 0.5rem;
}

.markdown-content h2 {
    font-size: 1.75rem;
    border-bottom: 1px solid rgba(220, 38, 38, 0.2);
    padding-bottom: 0.5rem;
}

.markdown-content h3 {
    font-size: 1.5rem;
}

.markdown-content h4 {
    font-size: 1.25rem;
}

.markdown-content p {
    margin-bottom: 1rem;
    color: var(--dark);
}

.markdown-content ul,
.markdown-content ol {
    margin-bottom: 1rem;
    padding-left: 2rem;
}

.markdown-content li {
    margin-bottom: 0.5rem;
}

.markdown-content code {
    background: rgba(220, 38, 38, 0.1);
    padding: 0.2rem 0.5rem;
    border-radius: 4px;
    font-family: 'Courier New', monospace;
    font-size: 0.9em;
    color: var(--primary);
}

.markdown-content pre {
    background: var(--dark);
    color: var(--white);
    padding: 1rem;
    border-radius: 8px;
    overflow-x: auto;
    margin-bottom: 1rem;
}

.markdown-content pre code {
    background: transparent;
    color: var(--white);
    padding: 0;
}

.markdown-content blockquote {
    border-left: 4px solid var(--primary);
    padding-left: 1rem;
    margin-left: 0;
    margin-bottom: 1rem;
    color: var(--secondary);
    font-style: italic;
}

.markdown-content a {
    color: var(--primary);
    text-decoration: none;
    font-weight: 500;
}

.markdown-content a:hover {
    text-decoration: underline;
}

.markdown-content table {
    width: 100%;
    border-collapse: collapse;
    margin-bottom: 1rem;
}

.markdown-content table th,
.markdown-content table td {
    border: 1px solid rgba(226, 232, 240, 0.8);
    padding: 0.75rem;
    text-align: left;
}

.markdown-content table th {
    background: var(--primary);
    color: var(--white);
    font-weight: 600;
}

.markdown-content table tr:nth-child(even) {
    background: rgba(248, 250, 252, 0.5);
}

.markdown-content img {
    max-width: 100%;
    height: auto;
    border-radius: 8px;
    margin: 1rem 0;
    box-shadow: var(--shadow-md);
}

.markdown-content hr {
    border: none;
    border-top: 2px solid rgba(226, 232, 240, 0.8);
    margin: 2rem 0;
}

.markdown-content strong {
    font-weight: 700;
    color: var(--dark);
}

.markdown-content em {
    font-style: italic;
}

/* Countries List */
.countries-list {
    list-style: none;
    background: #f8fafc;
    border-radius: 16px;
    padding: 1rem;
}

.countries-list li {
    padding: 1rem 1.25rem;
    border-bottom: 2px solid #e2e8f0;
    display: flex;
    justify-content: space-between;
    transition: all 0.2s;
    border-radius: 8px;
    margin-bottom: 0.5rem;
}

.countries-list li:last-child {
    border-bottom: none;
    margin-bottom: 0;
}

.countries-list li:hover {
    background: var(--white);
    transform: translateX(5px);
}

.countries-list li span:first-child {
    font-weight: 600;
}

.countries-list li span:last-child {
    color: var(--primary);
    font-weight: 700;
}

/* Forms */
.form-group {
    margin-bottom: 1.75rem;
}

.form-label {
    display: block;
    margin-bottom: 0.75rem;
    font-weight: 600;
    color: var(--dark);
    font-size: 0.95rem;
}

.form-control {
    width: 100%;
    padding: 1rem 1.25rem;
    border: 2px solid #e2e8f0;
    border-radius: 12px;
    font-size: 1rem;
    font-family: 'Roboto', sans-serif;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    background: #f8fafc;
}

.form-control:hover {
    border-color: #cbd5e1;
    background: var(--white);
}

.form-control:focus {
    outline: none;
    border-color: var(--primary);
    background: var(--white);
    box-shadow: 0 0 0 4px rgba(79, 70, 229, 0.1);
}

textarea.form-control {
    min-height: 140px;
    resize: vertical;
}

select.form-control {
    cursor: pointer;
}

input[type="file"].form-control {
    padding: 0.75rem 1rem;
    cursor: pointer;
}

input[type="file"].form-control::-webkit-file-upload-button {
    background: var(--primary);
    color: var(--white);
    border: none;
    padding: 0.5rem 1rem;
    border-radius: 8px;
    cursor: pointer;
    font-weight: 600;
    margin-right: 1rem;
    transition: all 0.3s;
}

input[type="file"].form-control::-webkit-file-upload-button:hover {
    background: var(--primary-dark);
    transform: translateY(-2px);
}

/* Modal */
.modal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background: rgba(15, 23, 42, 0.7);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    align-items: center;
    justify-content: center;
    animation: modalFadeIn 0.3s ease-out;
}

@keyframes modalFadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

.modal.active {
    display: flex;
}

.modal-content {
    background: var(--white);
    border-radius: 24px;
    padding: 2.5rem;
    max-width: 540px;
    width: 90%;
    max-height: 90vh;
    overflow-y: auto;
    box-shadow: var(--shadow-xl);
    animation: modalSlideUp 0.3s ease-out;
    border: 1px solid rgba(226, 232, 240, 0.8);
}

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

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

.modal-header h2 {
    font-size: 1.75rem;
    font-weight: 800;
    margin: 0;
}

.modal-close {
    font-size: 2rem;
    font-weight: 300;
    color: var(--secondary);
    cursor: pointer;
    background: rgba(226, 232, 240, 0.5);
    border: none;
    padding: 0.25rem 0.75rem;
    line-height: 1;
    border-radius: 8px;
    transition: all 0.3s;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.modal-close:hover {
    background: var(--danger);
    color: var(--white);
    transform: rotate(90deg);
}

/* Admin Styles */
.admin-sidebar {
    display: none;
}

.admin-container {
    max-width: 1600px;
    margin: 0 auto;
    padding: 3rem 2rem;
}

.admin-header {
    background: var(--white);
    padding: 2rem;
    border-radius: 20px;
    margin-bottom: 3rem;
    box-shadow: var(--shadow-md);
    display: flex;
    justify-content: space-between;
    align-items: center;
    border: 1px solid rgba(226, 232, 240, 0.8);
}

.admin-header h2 {
    font-size: 2rem;
    font-weight: 800;
    background: var(--gradient-1);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

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

.stat-card {
    background: var(--white);
    padding: 2rem;
    border-radius: 20px;
    box-shadow: var(--shadow-md);
    border: 1px solid rgba(226, 232, 240, 0.8);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
}

.stat-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 4px;
    height: 100%;
    background: var(--gradient-1);
}

.stat-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-lg);
}

.stat-card h3 {
    font-size: 0.95rem;
    color: var(--secondary);
    margin-bottom: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.stat-card .stat-value {
    font-size: 2.5rem;
    font-weight: 900;
    background: var(--gradient-1);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.table {
    width: 100%;
    background: var(--white);
    border-radius: 20px;
    overflow: hidden;
    box-shadow: var(--shadow-md);
    border: 1px solid rgba(226, 232, 240, 0.8);
}

.table table {
    width: 100%;
    border-collapse: collapse;
}

.table th,
.table td {
    padding: 1.25rem 1.5rem;
    text-align: left;
    border-bottom: 1px solid #f1f5f9;
}

.table th {
    background: linear-gradient(180deg, #f8fafc 0%, #f1f5f9 100%);
    font-weight: 700;
    color: var(--dark);
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.table tbody tr {
    transition: all 0.2s;
}

.table tbody tr:hover {
    background: #f8fafc;
    transform: scale(1.01);
}

/* Page Headings */
h2, h3 {
    font-weight: 800;
}

/* Selection */
::selection {
    background: var(--primary);
    color: var(--white);
}

::-moz-selection {
    background: var(--primary);
    color: var(--white);
}

/* Smooth Scrollbar */
::-webkit-scrollbar {
    width: 10px;
    height: 10px;
}

::-webkit-scrollbar-track {
    background: #f1f5f9;
}

::-webkit-scrollbar-thumb {
    background: var(--primary);
    border-radius: 10px;
}

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

/* Loading */
.loading {
    text-align: center;
    padding: 4rem;
    color: var(--secondary);
}

.loading::before {
    content: '\f017';
    font-family: 'Font Awesome 6 Free';
    font-weight: 900;
    font-size: 3rem;
    display: block;
    margin-bottom: 1rem;
    animation: spin 2s linear infinite;
    color: var(--primary);
}

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

/* Responsive */
@media (max-width: 968px) {
    .container, .admin-container {
        padding: 2rem 1.5rem;
    }

    .detail-container {
        padding: 2rem 1.5rem;
    }
}

@media (max-width: 768px) {
    body {
        font-size: 15px;
    }

    .header {
        position: relative;
    }

    .header .container {
        flex-direction: column;
        text-align: center;
        gap: 1rem;
        padding: 0 1rem;
    }

    .header h1 {
        font-size: 1.5rem;
    }

    .header nav {
        width: 100%;
        justify-content: center;
        flex-wrap: wrap;
        gap: 0.5rem;
    }

    .header nav > a {
        font-size: 0.9rem;
        padding: 0.5rem 1rem;
    }

    .language-switcher {
        margin-top: 0.5rem;
    }

    .container, .admin-container {
        padding: 1.5rem 1rem;
    }

    .file-grid {
        grid-template-columns: repeat(3, 1fr);
        gap: 1rem;
    }

    .file-card-icon {
        height: 140px;
    }

    .file-card-title {
        font-size: 0.95rem;
    }

    .file-card-body {
        padding: 0.75rem;
    }

    .file-card-description {
        -webkit-line-clamp: 2;
    }

    .detail-container {
        padding: 1.5rem;
        border-radius: 16px;
    }

    .detail-header {
        flex-direction: column;
        gap: 2rem;
    }

    .detail-icon {
        width: 140px;
        height: 140px;
        margin: 0 auto;
    }

    .detail-title {
        font-size: 1.75rem;
        text-align: center;
    }

    .detail-stats {
        flex-direction: column;
        gap: 0.75rem;
        align-items: center;
    }

    .detail-price {
        font-size: 2rem;
        text-align: center;
    }

    .tabs {
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
    }

    .tab-btn {
        font-size: 0.9rem;
        padding: 0.75rem 1.25rem;
    }

    .stats-grid {
        grid-template-columns: 1fr;
        gap: 1.25rem;
    }

    .admin-header {
        flex-direction: column;
        gap: 1.5rem;
        text-align: center;
    }

    .admin-header h2 {
        font-size: 1.5rem;
    }

    .modal-content {
        width: 95%;
        padding: 1.75rem;
    }

    .modal-header h2 {
        font-size: 1.4rem;
    }

    .btn {
        padding: 0.875rem 1.5rem;
        font-size: 0.95rem;
    }

    .table th,
    .table td {
        padding: 0.875rem 1rem;
        font-size: 0.9rem;
    }
}

@media (max-width: 480px) {
    .file-grid {
        grid-template-columns: repeat(3, 1fr);
        gap: 0.75rem;
    }

    .file-card-icon {
        height: 100px;
    }

    .file-card-icon .default-icon {
        font-size: 2.5rem;
    }

    .file-card-title {
        font-size: 0.8rem;
    }

    .file-card-description {
        display: none;
    }

    .file-card-stats {
        font-size: 0.75rem;
        padding-top: 0.5rem;
    }

    .file-card-price {
        font-size: 0.9rem;
    }

    .screenshots-grid {
        grid-template-columns: 1fr !important;
    }
    
    .screenshots-grid.five {
        grid-template-columns: 1fr !important;
        grid-template-rows: auto !important;
    }
    
    .screenshots-grid.five .screenshot-item:first-child {
        grid-row: auto !important;
    }
    
    .gallery-nav {
        width: 40px;
        height: 40px;
        font-size: 1.2rem;
    }
    
    .gallery-nav.prev {
        left: 1rem;
    }
    
    .gallery-nav.next {
        right: 1rem;
    }
    
    .gallery-close {
        width: 40px;
        height: 40px;
        top: 1rem;
        right: 1rem;
    }
    
    .gallery-thumbnails {
        bottom: 4rem;
        gap: 0.5rem;
    }
    
    .gallery-thumbnail {
        width: 60px;
        height: 60px;
    }
}

/* Alert */
.alert {
    padding: 1.25rem 1.5rem;
    border-radius: 12px;
    margin-bottom: 1.5rem;
    font-weight: 500;
    box-shadow: var(--shadow-sm);
    border-left: 4px solid;
}

.alert-success {
    background: #d1fae5;
    color: #065f46;
    border-left-color: var(--success);
}

.alert-danger {
    background: #fee2e2;
    color: #991b1b;
    border-left-color: var(--danger);
}

.alert-warning {
    background: #fef3c7;
    color: #92400e;
    border-left-color: var(--warning);
}

.alert-info {
    background: #dbeafe;
    color: #1e40af;
    border-left-color: var(--info);
}

/* Page section (Tips & Trick, About Me) */
.page-section {
    padding: 2.5rem 0;
    max-width: 900px;
    margin: 0 auto;
}

.page-title {
    font-size: 2rem;
    font-weight: 800;
    color: var(--dark);
    margin-bottom: 0.75rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.page-title i {
    color: var(--primary);
}

.page-lead {
    color: var(--secondary);
    font-size: 1.1rem;
    margin-bottom: 2rem;
    line-height: 1.6;
}

.page-note {
    margin-top: 2rem;
    padding: 1rem 1.25rem;
    background: rgba(220, 38, 38, 0.06);
    border-radius: 10px;
    color: var(--secondary);
    font-size: 0.95rem;
}

/* Tips grid */
.tips-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
    gap: 1.5rem;
}

.tip-card {
    background: var(--white);
    border-radius: 14px;
    padding: 1.75rem;
    box-shadow: var(--shadow-md);
    border: 1px solid rgba(226, 232, 240, 0.8);
    transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.tip-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-lg);
}

.tip-icon {
    width: 48px;
    height: 48px;
    border-radius: 12px;
    background: var(--gradient-2);
    color: var(--white);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.35rem;
    margin-bottom: 1rem;
}

.tip-card h3 {
    font-size: 1.15rem;
    font-weight: 700;
    color: var(--dark);
    margin-bottom: 0.5rem;
}

.tip-card p {
    color: var(--secondary);
    font-size: 0.95rem;
    line-height: 1.55;
    margin: 0;
}

.tip-card-link {
    text-decoration: none;
    color: inherit;
    display: block;
}

.tip-card-link:hover h3,
.tip-card-link:hover p {
    color: var(--dark);
}

.article-full {
    background: var(--white);
    border-radius: 14px;
    padding: 2rem;
    box-shadow: var(--shadow-md);
    border: 1px solid rgba(226, 232, 240, 0.8);
}

.article-full-icon {
    width: 56px;
    height: 56px;
    border-radius: 14px;
    background: var(--gradient-2);
    color: var(--white);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    margin-bottom: 1.25rem;
}

.article-content {
    margin-top: 1rem;
}

/* Full-page article (Tips & Trick single) */
.article-page-full {
    min-height: calc(100vh - 120px);
    padding: 0;
    width: 100%;
    background: linear-gradient(180deg, #f8fafc 0%, #e2e8f0 100%);
}

.article-page-container {
    max-width: none;
    margin: 0;
    padding: 2rem 4rem 3rem;
    width: 100%;
}

.article-back {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    color: var(--primary);
    text-decoration: none;
    font-weight: 600;
    margin-bottom: 1.5rem;
    padding: 0.5rem 0;
    transition: opacity 0.2s, transform 0.2s;
}

.article-back:hover {
    opacity: 0.85;
    transform: translateX(-4px);
}

.article-back i {
    font-size: 0.9rem;
}

.article-wrapper {
    background: var(--white);
    border-radius: 16px;
    padding: 3rem 5rem;
    box-shadow: var(--shadow-md);
    border: 1px solid rgba(226, 232, 240, 0.8);
    max-width: none;
    width: 100%;
}

.article-header {
    margin-bottom: 2.5rem;
    padding-bottom: 2rem;
    border-bottom: 1px solid rgba(226, 232, 240, 0.8);
}

.article-wrapper .article-icon {
    width: 64px;
    height: 64px;
    border-radius: 16px;
    background: var(--gradient-2);
    color: var(--white);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.75rem;
    margin-bottom: 1.5rem;
    box-shadow: var(--shadow-md);
}

.article-title {
    font-size: clamp(1.75rem, 4vw, 2.75rem);
    font-weight: 800;
    color: var(--dark);
    line-height: 1.25;
    margin-bottom: 1rem;
    letter-spacing: -0.5px;
}

.article-meta {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 1.25rem;
    color: var(--secondary);
    font-size: 0.95rem;
}

.article-meta time {
    font-weight: 500;
}

.article-views {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    font-weight: 500;
}

.article-views i {
    opacity: 0.7;
    font-size: 0.9rem;
}

.article-body {
    margin-top: 0;
    font-size: 1.05rem;
    line-height: 1.8;
}

.article-body.markdown-content {
    background: transparent;
    padding: 0;
    border-radius: 0;
}

/* Responsive: article page */
@media (max-width: 1024px) {
    .article-page-container {
        padding: 2rem 2.5rem 3rem;
    }

    .article-wrapper {
        padding: 2.5rem 3.5rem;
    }
}

@media (max-width: 768px) {
    .article-page-container {
        padding: 1.5rem 1.5rem 2.5rem;
    }

    .article-wrapper {
        padding: 2rem 2rem;
        border-radius: 12px;
    }

    .article-header {
        margin-bottom: 2rem;
        padding-bottom: 1.5rem;
    }

    .article-wrapper .article-icon {
        width: 56px;
        height: 56px;
        font-size: 1.5rem;
    }

    .article-title {
        font-size: 1.75rem;
    }

    .article-body {
        font-size: 1rem;
    }

    .article-body.markdown-content h1 {
        font-size: 1.65rem;
    }

    .article-body.markdown-content h2 {
        font-size: 1.45rem;
    }

    .article-body.markdown-content h3 {
        font-size: 1.25rem;
    }

    .article-body.markdown-content pre {
        padding: 0.75rem;
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
        font-size: 0.9rem;
    }

    .article-body.markdown-content table {
        display: block;
        overflow-x: auto;
        font-size: 0.9rem;
    }
}

@media (max-width: 480px) {
    .article-page-container {
        padding: 1rem 0.75rem 2rem;
    }

    .article-wrapper {
        padding: 1.5rem 1.25rem;
    }

    .article-header {
        margin-bottom: 1.5rem;
        padding-bottom: 1.25rem;
    }

    .article-wrapper .article-icon {
        width: 48px;
        height: 48px;
        font-size: 1.25rem;
        margin-bottom: 1rem;
    }

    .article-title {
        font-size: 1.5rem;
    }

    .article-meta {
        font-size: 0.85rem;
        gap: 1rem;
    }

    .article-body {
        font-size: 0.95rem;
    }

    .article-body.markdown-content h1 {
        font-size: 1.4rem;
    }

    .article-body.markdown-content h2 {
        font-size: 1.25rem;
    }

    .article-body.markdown-content h3 {
        font-size: 1.1rem;
    }
}

/* About Me */
.about-section .page-title {
    justify-content: center;
}

.about-header {
    text-align: center;
    margin-bottom: 2.5rem;
}

.about-avatar {
    width: 100px;
    height: 100px;
    border-radius: 50%;
    background: var(--gradient-1);
    color: var(--white);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2.5rem;
    margin: 0 auto 1.25rem;
    box-shadow: var(--shadow-lg);
    overflow: hidden;
}

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

.about-role {
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--primary);
    margin-bottom: 0.35rem;
}

.about-location {
    color: var(--secondary);
    font-size: 0.95rem;
}

.about-content {
    background: var(--white);
    border-radius: 14px;
    padding: 2rem;
    box-shadow: var(--shadow-md);
    border: 1px solid rgba(226, 232, 240, 0.8);
}

.about-bio {
    color: var(--dark);
    line-height: 1.7;
    margin-bottom: 2rem;
    font-size: 1.05rem;
}

.about-links h3,
.about-projects h3 {
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--dark);
    margin-bottom: 1rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.about-links h3 i,
.about-projects h3 i {
    color: var(--primary);
}

.about-links {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
    margin-bottom: 2rem;
}

.about-link-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.35rem;
    padding: 1.25rem 1.5rem;
    background: linear-gradient(135deg, #f8fafc 0%, #f1f5f9 100%);
    border: 1px solid rgba(226, 232, 240, 0.9);
    border-radius: 12px;
    color: var(--dark);
    text-decoration: none;
    font-weight: 600;
    transition: all 0.25s ease;
    min-width: 140px;
}

.about-link-card i {
    font-size: 1.75rem;
    color: var(--primary);
}

.about-link-card img.about-link-logo {
    height: 1.75rem;
    width: auto;
    object-fit: contain;
    display: block;
}

.about-link-card small {
    font-size: 0.8rem;
    font-weight: 400;
    color: var(--secondary);
}

.about-link-card:hover {
    background: var(--primary);
    color: var(--white);
    border-color: var(--primary);
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}

.about-link-card:hover i,
.about-link-card:hover small {
    color: var(--white);
    opacity: 0.95;
}

.about-link-card:hover img.about-link-logo {
    filter: brightness(0) invert(1);
    opacity: 0.95;
}

.about-projects ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.about-projects li {
    padding: 0.5rem 0;
    border-bottom: 1px solid rgba(226, 232, 240, 0.6);
    color: var(--secondary);
    line-height: 1.5;
}

.about-projects li:last-child {
    border-bottom: none;
}

.about-projects li strong {
    color: var(--dark);
}
