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

:root {
    --primary-color: #2563eb;
    --secondary-color: #1e40af;
    --accent-color: #f59e0b;
    --success-color: #10b981;
    --danger-color: #ef4444;
    --background-color: #f8fafc;
    --text-color: #1f2937;
    --card-bg: #ffffff;
    --shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    --shadow-hover: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
    --border-radius: 12px;
    --transition: all 0.3s ease;
    --gradient: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
}

/* Umumiy sozlamalar */
* {
    box-sizing: border-box;
}

body {
    margin: 0;
    font-family: 'Inter', sans-serif;
    background-color: var(--background-color);
    color: var(--text-color);
    line-height: 1.6;
    animation: fadeIn 0.5s ease-in;
}

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

/* Navigatsiya paneli */
.navbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: var(--gradient);
    color: #fff;
    padding: 1rem 2rem;
    box-shadow: var(--shadow);
    position: sticky;
    top: 0;
    z-index: 100;
    backdrop-filter: blur(10px);
}

.logo {
    font-size: 1.8rem;
    font-weight: 700;
    text-decoration: none;
    color: #fff;
    position: relative;
}

.logo::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--accent-color);
    transition: width 0.3s ease;
}

.logo:hover::after {
    width: 100%;
}

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

.nav-links li a {
    color: #fff;
    text-decoration: none;
    font-weight: 500;
    padding: 0.5rem 1rem;
    border-radius: var(--border-radius);
    transition: var(--transition);
    position: relative;
    overflow: hidden;
}

.nav-links li a::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: rgba(255, 255, 255, 0.1);
    transition: left 0.3s ease;
}

.nav-links li a:hover::before {
    left: 0;
}

.nav-links li a:hover {
    transform: translateY(-2px);
}

/* Site header for malumot.html */
.site-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    color: #fff;
    padding: 1rem 2rem;
    box-shadow: var(--shadow);
}

.brand {
    font-size: 1.8rem;
    font-weight: 700;
    color: #fff;
    text-decoration: none;
}

.actions {
    display: flex;
    gap: 1rem;
}

.actions a {
    color: #fff;
    text-decoration: none;
    padding: 0.75rem 1.5rem;
    border-radius: var(--border-radius);
    font-weight: 500;
    transition: var(--transition);
    border: 2px solid transparent;
}

.actions a:hover {
    background: var(--accent-color);
    color: var(--text-color);
    border-color: var(--accent-color);
}

/* Hero bo‘limi */
.hero {
    text-align: center;
    padding: 5rem 2rem;
    background: var(--gradient);
    color: #fff;
    position: relative;
    overflow: hidden;
    min-height: 60vh;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
}

.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="grain" width="100" height="100" patternUnits="userSpaceOnUse"><circle cx="25" cy="25" r="1" fill="rgba(255,255,255,0.1)"/><circle cx="75" cy="75" r="1" fill="rgba(255,255,255,0.1)"/><circle cx="50" cy="50" r="2" fill="rgba(255,255,255,0.05)"/></pattern></defs><rect width="100" height="100" fill="url(%23grain)"/></svg>');
    opacity: 0.1;
    animation: float 20s ease-in-out infinite;
}

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

.hero h1 {
    font-size: 3.5rem;
    margin-bottom: 1rem;
    font-weight: 700;
    position: relative;
    z-index: 1;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.3);
    animation: slideInUp 1s ease-out;
}

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

.hero p {
    font-size: 1.25rem;
    margin-bottom: 2rem;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
    position: relative;
    z-index: 1;
    animation: slideInUp 1s ease-out 0.2s both;
}

.btn {
    background: var(--accent-color);
    color: var(--text-color);
    padding: 1rem 2rem;
    text-decoration: none;
    border-radius: var(--border-radius);
    font-weight: 600;
    font-size: 1.1rem;
    transition: var(--transition);
    display: inline-block;
    position: relative;
    z-index: 1;
    border: none;
    cursor: pointer;
    box-shadow: 0 4px 15px rgba(245, 158, 11, 0.3);
    overflow: hidden;
}

.btn::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:hover::before {
    left: 100%;
}

.btn:hover {
    background: #d97706;
    transform: translateY(-3px);
    box-shadow: 0 10px 25px rgba(           245, 158, 11, 0.4);
}

.btn:active {
    transform: translateY(-1px);
}

/* Fayl yuklash bo‘limi */
.upload-container {
    display: flex;
    gap: 2rem;
    justify-content: center;
    flex-wrap: wrap;
    padding: 4rem 2rem;
    background: var(--background-color);
}

.upload-section {
    flex: 1;
    min-width: 300px;
    max-width: 600px;
}

.upload-card {
    background: var(--card-bg);
    border-radius: var(--border-radius);
    box-shadow: var(--shadow);
    padding: 3rem;
    text-align: center;
    animation: slideInUp 0.8s ease-out 0.4s both;
}

.upload-card h2 {
    color: var(--primary-color);
    margin-bottom: 0.5rem;
    font-size: 2rem;
}

.upload-card p {
    color: #6b7280;
    margin-bottom: 2rem;
}

.upload-form {
    display: flex;
    flex-direction: column;
    gap: 2rem;
    align-items: center;
}

.file-input-wrapper {
    position: relative;
    width: 100%;
}

.file-input {
    position: absolute;
    opacity: 0;
    width: 100%;
    height: 100%;
    cursor: pointer;
}

.file-label {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 3rem;
    border: 2px dashed #d1d5db;
    border-radius: var(--border-radius);
    background: #f9fafb;
    cursor: pointer;
    transition: var(--transition);
    width: 100%;
}

.file-label:hover {
    border-color: var(--primary-color);
    background: #eff6ff;
}

.file-icon {
    font-size: 3rem;
    margin-bottom: 1rem;
}

.file-text {
    font-weight: 500;
    color: var(--text-color);
}

.btn-upload {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 1rem 2rem;
    font-size: 1.1rem;
}

.btn-icon {
    font-size: 1.2rem;
}

.btn-small {
    display: inline-block;
    margin-top: 1rem;
    background: var(--primary-color);
    color: #fff;
    padding: 0.75rem 1.5rem;
    text-decoration: none;
    border-radius: var(--border-radius);
    font-weight: 500;
    transition: var(--transition);
}

.btn-small:hover {
    background: var(--secondary-color);
    transform: translateY(-2px);
}

.btn-danger {
    background: #ef4444;
    color: #fff;
}

.btn-danger:hover {
    background: #dc2626;
}

.btn-secondary {
    background: #6b7280;
    color: #fff;
}

.btn-secondary:hover {
    background: #4b5563;
}

.btn-warning:hover {
    background: #d97706;
}

.btn-primary {
    background: var(--primary-color);
    color: #fff;
    box-shadow: 0 4px 15px rgba(37, 99, 235, 0.3);
}

.btn-primary:hover {
    background: var(--secondary-color);
    box-shadow: 0 10px 25px rgba(37, 99, 235, 0.4);
}

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

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

.btn-outline {
    background: transparent;
    color: var(--primary-color);
    border: 2px solid var(--primary-color);
    box-shadow: none;
}

.btn-outline:hover {
    background: var(--primary-color);
    color: #fff;
}

.btn-light {
    background: rgba(255, 255, 255, 0.1);
    color: #fff;
    border: 1px solid rgba(255, 255, 255, 0.2);
    box-shadow: none;
}

.btn-light:hover {
    background: rgba(255, 255, 255, 0.2);
}

/* Malumot.html uchun yangi dizayn */
.file-list {
    list-style: none;
    padding: 0;
    max-width: 800px;
    margin: 0 auto;
}

.file-list li {
    display: flex;
    align-items: center;
    padding: 1.5rem;
    background: var(--card-bg);
    margin-bottom: 1rem;
    border-radius: var(--border-radius);
    box-shadow: var(--shadow);
    transition: var(--transition);
    justify-content: space-between;
}

.file-list li:hover {
    background: #f1f5f9;
    transform: translateY(-2px);
}

.file-list li input[type="checkbox"] {
    margin-right: 1rem;
    transform: scale(1.2);
}

.file-name {
    flex-grow: 1;
}

.file-name a {
    text-decoration: none;
    color: var(--primary-color);
    font-weight: 600;
    font-size: 1.1rem;
}

.file-name a:hover {
    color: var(--accent-color);
}

.file-buttons {
    display: flex;
    gap: 0.5rem;
}

.file-list li a {
    text-decoration: none;
    color: var(--primary-color);
    flex-grow: 1;
}

.file-list li a:hover {
    color: var(--accent-color);
}

.preview {
    margin-top: 3rem;
}

.text-block {
    background: var(--card-bg);
    border: 1px solid #e2e8f0;
    border-radius: var(--border-radius);
    padding: 2rem;
    font-family: 'Fira Code', monospace;
    white-space: pre-wrap;
    max-height: 500px;
    overflow-y: auto;
    box-shadow: var(--shadow);
}

.notice {
    padding: 1.5rem;
    border-radius: var(--border-radius);
    margin: 2rem 0;
    font-weight: 500;
}

.notice.error {
    background: #fef2f2;
    color: #991b1b;
    border: 1px solid #fecaca;
}

.delete-form {
    margin-top: 2rem;
}

.action-buttons {
    display: flex;
    gap: 1rem;
    margin-top: 2rem;
    flex-wrap: wrap;
}

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

.main-card {
    background: var(--card-bg);
    border-radius: var(--border-radius);
    box-shadow: var(--shadow);
    padding: 3rem;
    margin-top: 2rem;
}

.meta h1 {
    color: var(--primary-color);
    margin-bottom: 2rem;
    font-size: 2.5rem;
}

.meta h2 {
    color: var(--secondary-color);
    margin-bottom: 1.5rem;
    font-size: 1.8rem;
}

.meta-actions {
    display: flex;
    gap: 1rem;
    margin-top: 1.5rem;
    flex-wrap: wrap;
}

/* Footer */
    /* Footer umumiy dizayn */
/* Footer umumiy dizayn */
/* Footer umumiy dizayn */
.footer {
    background: var(--gradient);
    color: #fff;
    padding: 2rem 1rem 0.5rem;
    margin-top: 3rem;
}

/* Footer ichidagi bo‘limlar */
.footer-content {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 1rem;
    max-width: 1200px;
    margin: 0 auto 1rem;
}

/* Logo qismi */
.footer-logo {
    border-right: 1px solid rgba(255, 255, 255, 0.15);
    padding-right: 1rem;
}
.footer-logo h3 {
    margin-bottom: 0.5rem;
    font-size: 1rem;
    font-weight: bold;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: #fff; /* oq rang */
}
.footer-logo p {
    color: rgba(255, 255, 255, 0.8);
    margin: 0;
}

/* Linklar */
.footer-links {
    display: flex;
    flex-direction: column;
    gap: 0.6rem;
}
.footer-link {
    color: rgba(255, 255, 255, 0.75);
    text-decoration: none;
    transition: all 0.3s ease;
}
.footer-link:hover {
    color: #fff;
    transform: translateX(6px);
}

/* O'ng qism */
.footer-right {
    display: grid;
    grid-template-columns: 1fr 1fr 1fr;
    gap: 1rem;
    flex: 1;
}

/* Aloqa bo‘limi */
.aloqa {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    color: rgba(255, 255, 255, 0.9);
    font-size: 14px;
}
.aloqa p {
    margin: 0;
}
.aloqa i {
    margin-right: 0.5rem;
    color: #fff; /* ikonalar oq rangda */
}

/* Social iconlar */
.footer-social {
    display: flex;
    gap: 1rem;
    font-size: 1.5rem;
}
.footer-social a {
    color: rgba(255, 255, 255, 0.8);
    transition: all 0.3s ease;
}
.footer-social a:hover {
    color: #fff;
    transform: scale(1.2);
}

/* Pastki qism */
.footer-bottom {
    display: flex;
    justify-content: center;
    align-items: center;
    border-top: 1px solid rgba(255, 255, 255, 0.15);
    padding-top: 0.5rem;
    color: rgba(255, 255, 255, 0.7);
    font-size: 12px;
}

/* Responsiv dizayn */
@media (max-width: 768px) {
    .footer-content {
        flex-direction: column;
        gap: 1.5rem;
        text-align: center;
    }
    .footer-logo {
        border-right: none;
        border-bottom: 1px solid rgba(255, 255, 255, 0.15);
        padding-right: 0;
        padding-bottom: 1rem;
    }
    .footer-right {
        grid-template-columns: 1fr;
        gap: 1rem;
    }
    .footer-social {
        justify-content: center;
    }
}
/* Responsiv dizayn */
@media (max-width: 768px) {
    .footer-content {
        flex-direction: column;
        gap: 1.5rem;
        text-align: center;
    }
    .footer-logo {
        border-right: none;
        border-bottom: 1px solid rgba(255, 255, 255, 0.15);
        padding-right: 0;
        padding-bottom: 1rem;
    }
    .footer-right {
        grid-template-columns: 1fr;
        gap: 1rem;
    }
    .footer-social {
        justify-content: center;
    }
}

/* Responsiv dizayn */
@media (max-width: 768px) {
    .footer-content {
        flex-direction: column;
        gap: 1.5rem;
        text-align: center;
    }
    .footer-logo {
        border-right: none;
        border-bottom: 1px solid rgba(255, 255, 255, 0.15);
        padding-right: 0;
        padding-bottom: 1rem;
    }
    .footer-right {
        grid-template-columns: 1fr;
        gap: 1rem;
    }
    .footer-social {
        justify-content: center;
    }
}
.search-section {
    margin: 2rem 0;
    padding: 2rem;
    background: #f8f9fa;
    border-radius: var(--border-radius);
    border: 1px solid #e9ecef;
}

.search-section h3 {
    margin-bottom: 1.5rem;
    color: var(--primary-color);
    font-size: 1.5rem;
}

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

.search-controls input {
    flex: 1;
    padding: 0.75rem;
    border: 1px solid #d1d5db;
    border-radius: var(--border-radius);
    font-size: 1rem;
    transition: var(--transition);
}

.search-controls input:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.1);
}

.export-buttons {
    display: flex;
    gap: 1rem;
    margin-top: 1.5rem;
    flex-wrap: wrap;
}

/* Highlighting */
mark {
    background-color: yellow;
    padding: 0 2px;
}

.search-results {
    margin-top: 1rem;
    font-weight: bold;
    color: var(--primary-color);
}

/* Fayl ma’lumotlari bo‘limi */
.file-info {
    padding: 4rem 2rem;
    background: linear-gradient(135deg, #f8fafc 0%, #e2e8f0 100%);
}

.info-card, .no-file-card {
    max-width: 1000px;
    margin: 0 auto;
    background: var(--card-bg);
    border-radius: var(--border-radius);
    box-shadow: var(--shadow);
    padding: 3rem;
    animation: slideInUp 0.8s ease-out 0.6s both;
}

.info-card h2 {
    color: var(--success-color);
    margin-bottom: 2rem;
    font-size: 2rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.file-details {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1.5rem;
    margin-bottom: 3rem;
}

.detail-item {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.detail-label {
    font-weight: 600;
    color: var(--text-color);
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.detail-value {
    font-size: 1.1rem;
    color: var(--primary-color);
    font-weight: 500;
}

.detail-link {
    color: var(--primary-color);
    text-decoration: none;
    font-weight: 500;
    transition: var(--transition);
}

.detail-link:hover {
    color: var(--accent-color);
}

.content-preview {
    margin-top: 3rem;
    padding-top: 2rem;
    border-top: 1px solid #e5e7eb;
}

.content-preview h3 {
    color: var(--primary-color);
    margin-bottom: 1.5rem;
    font-size: 1.5rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.text-preview, .pdf-preview {
    background: #f8f9fa;
    border: 1px solid #e9ecef;
    border-radius: var(--border-radius);
    padding: 1.5rem;
    max-height: 300px;
    overflow-y: auto;
}

.text-preview pre, .pdf-preview pre {
    margin: 0;
    white-space: pre-wrap;
    word-wrap: break-word;
    font-family: 'Fira Code', monospace;
    font-size: 0.9rem;
    line-height: 1.5;
}

.table-container {
    overflow-x: auto;
    background: #f8f9fa;
    border-radius: var(--border-radius);
    padding: 1rem;
}

.table-container table {
    width: 100%;
    border-collapse: collapse;
    background: var(--card-bg);
    border-radius: var(--border-radius);
    overflow: hidden;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.table-container th, .table-container td {
    padding: 0.75rem 1rem;
    text-align: left;
    border-bottom: 1px solid #e5e7eb;
}

.table-container th {
    background: var(--primary-color);
    color: #fff;
    font-weight: 600;
}

.table-container tr:nth-child(even) {
    background: #f9fafb;
}

.excel-preview, .json-preview {
    background: #f8f9fa;
    border: 1px solid #e9ecef;
    border-radius: var(--border-radius);
    padding: 1.5rem;
}

.excel-preview pre, .json-preview pre {
    margin: 0;
    font-family: 'Fira Code', monospace;
    font-size: 0.9rem;
}

.image-preview {
    text-align: center;
}

.preview-image {
    max-width: 100%;
    height: auto;
    border-radius: var(--border-radius);
    box-shadow: var(--shadow);
    transition: var(--transition);
}

.preview-image:hover {
    transform: scale(1.05);
}

.truncated-note {
    color: #6b7280;
    font-style: italic;
    margin-top: 1rem;
}

.no-file-card {
    text-align: center;
    padding: 4rem 2rem;
}

.no-file-icon {
    font-size: 4rem;
    margin-bottom: 1rem;
}

.no-file-card h3 {
    color: var(--text-color);
    margin-bottom: 0.5rem;
}

.no-file-card p {
    color: #6b7280;
}

/* Edit form styles */
.edit-form {
    display: flex;
    flex-direction: column;
    gap: 2rem;
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.form-group label {
    font-weight: 600;
    color: var(--text-color);
    font-size: 1.1rem;
}

.edit-textarea {
    width: 100%;
    font-family: 'Fira Code', monospace;
    padding: 1rem;
    border: 1px solid #d1d5db;
    border-radius: var(--border-radius);
    font-size: 0.9rem;
    line-height: 1.5;
    resize: vertical;
    transition: var(--transition);
    background: #f8f9fa;
}

.edit-textarea:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.1);
    background: #fff;
}

.form-actions {
    display: flex;
    gap: 1rem;
    justify-content: flex-start;
    flex-wrap: wrap;
}