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

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background: #f5f5f5;
    color: #333;
}

/* LOGIN PAGE */
.login-container {
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
    background: linear-gradient(135deg, #f4d03f 0%, #95a5a6 50%, #ffffff 100%);
}

.login-box {
    background: white;
    padding: 40px;
    border-radius: 10px;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.2);
    width: 100%;
    max-width: 400px;
}

.login-box h1 {
    color: #f4d03f;
    margin-bottom: 5px;
    font-size: 28px;
}

.login-box p {
    color: #95a5a6;
    margin-bottom: 30px;
    font-size: 14px;
}

.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
    color: #333;
}

.form-group input,
.form-group input,
.form-group textarea,
.form-group select {
    width: 100%;
    padding: 10px;
    border: 1px solid #ddd;
    border-radius: 5px;
    font-size: 14px;
    font-family: inherit;
}

.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    border-color: #667eea;
    box-shadow: 0 0 5px rgba(102, 126, 234, 0.3);
}

.btn-login,
.btn-login {
    width: 100%;
    padding: 12px;
    background: #f4d03f;
    color: #333;
    border: none;
    border-radius: 5px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.3s;
}

.btn-login:hover {
    background: #f1c40f;
}

.error-message {
    color: #e74c3c;
    margin-top: 15px;
    padding: 10px;
    background: #fadbd8;
    border-radius: 5px;
    display: none;
}

.error-message.show {
    display: block;
}

/* DASHBOARD */
.dashboard-container {
    display: flex;
    min-height: 100vh;
}

.sidebar {
    width: 250px;
    background: #2c3e50;
    color: white;
    padding: 20px;
    position: fixed;
    height: 100vh;
    overflow-y: auto;
}

.sidebar h2 {
    margin-bottom: 30px;
    font-size: 20px;
}

.sidebar nav {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.nav-item {
    padding: 12px 15px;
    color: #ecf0f1;
    text-decoration: none;
    border-radius: 5px;
    transition: background 0.3s;
    cursor: pointer;
    display: block;
}

.nav-item:hover,
.nav-item.active {
    background: #667eea;
    color: white;
}

.logout-btn {
    margin-top: auto;
    background: linear-gradient(135deg, #e74c3c 0%, #c0392b 100%);
    color: white;
    padding: 12px 15px;
    border-radius: 5px;
    font-weight: 600;
    transition: all 0.3s;
    border: none;
    cursor: pointer;
    text-align: center;
    display: block;
    width: 100%;
    text-decoration: none;
}

.logout-btn:hover {
    background: linear-gradient(135deg, #c0392b 0%, #a93226 100%);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(231, 76, 60, 0.3);
}

.main-content {
    margin-left: 250px;
    flex: 1;
    padding: 30px;
}

.section {
    display: none;
}

.section.active {
    display: block;
}

.section h1 {
    margin-bottom: 20px;
    color: #2c3e50;
}

/* TABS */
.tabs {
    display: flex;
    gap: 10px;
    margin-bottom: 20px;
    border-bottom: 2px solid #ddd;
}

.tab-btn {
    padding: 12px 20px;
    background: none;
    border: none;
    border-bottom: 3px solid transparent;
    cursor: pointer;
    font-size: 16px;
    color: #666;
    transition: all 0.3s;
}

.tab-btn.active {
    color: #667eea;
    border-bottom-color: #667eea;
}

.tab-content {
    display: none;
}

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

/* PROJECTS GALLERY - HORIZONTAL GRID */
.projects-gallery {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 20px;
}

.project-card {
    background: white;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s, box-shadow 0.3s;
    display: flex;
    flex-direction: column;
    position: relative;
}

.project-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.15);
}

.project-card:hover .project-delete-btn {
    opacity: 1;
}

.project-delete-btn {
    position: absolute;
    top: 10px;
    right: 10px;
    background: rgba(231, 76, 60, 0.9);
    color: white;
    border: none;
    border-radius: 50%;
    width: 35px;
    height: 35px;
    font-size: 18px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.3s, background 0.3s;
    z-index: 10;
}

.project-delete-btn:hover {
    background: rgba(192, 57, 43, 0.95);
}

.project-id-label {
    background: #667eea;
    color: white;
    padding: 10px;
    text-align: center;
    font-weight: 600;
    font-size: 14px;
}

.project-image {
    width: 100%;
    height: 250px;
    object-fit: cover;
    background: #f0f0f0;
}

.project-info {
    padding: 15px;
    flex: 1;
    display: flex;
    flex-direction: column;
}

.project-info h3 {
    margin-bottom: 8px;
    color: #2c3e50;
    font-size: 16px;
}

.project-info p {
    color: #666;
    font-size: 13px;
    line-height: 1.4;
    margin-bottom: 12px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    flex: 1;
}

.project-actions {
    display: flex;
    gap: 10px;
    margin-top: auto;
}

.btn-edit,
.btn-delete {
    flex: 1;
    padding: 8px;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-size: 13px;
    font-weight: 600;
    transition: background 0.3s;
}

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

.btn-edit:hover {
    background: #5568d3;
}

.btn-delete {
    background: #e74c3c;
    color: white;
}

.btn-delete:hover {
    background: #c0392b;
}

/* EDIT PAGE */
.edit-header {
    display: flex;
    align-items: center;
    gap: 20px;
    margin-bottom: 30px;
    border-bottom: 2px solid #ddd;
    padding-bottom: 15px;
}

.btn-back {
    padding: 10px 15px;
    background: #667eea;
    color: white;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    font-size: 14px;
    font-weight: 600;
    transition: background 0.3s;
}

.btn-back:hover {
    background: #5568d3;
}

.edit-form {
    max-width: 600px;
}

.form-actions {
    display: flex;
    gap: 10px;
    margin-top: 30px;
}

.btn-cancel {
    padding: 12px 30px;
    background: #999;
    color: white;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    font-size: 16px;
    font-weight: 600;
    transition: background 0.3s;
}

.btn-cancel:hover {
    background: #777;
}

/* IMAGES GALLERY ROWS - VERTICAL */
.images-gallery-rows {
    display: flex;
    flex-direction: column;
    gap: 15px;
    margin-top: 15px;
}

.gallery-row {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.gallery-item {
    position: relative;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    cursor: pointer;
    transition: transform 0.3s;
    width: 100%;
    height: 300px;
}

.gallery-item:hover {
    transform: scale(1.02);
}

.gallery-item:hover .delete-btn {
    opacity: 1;
}

.delete-btn {
    position: absolute;
    top: 10px;
    right: 10px;
    background: rgba(231, 76, 60, 0.9);
    color: white;
    border: none;
    border-radius: 50%;
    width: 40px;
    height: 40px;
    font-size: 20px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.3s, background 0.3s;
    z-index: 10;
}

.delete-btn:hover {
    background: rgba(192, 57, 43, 0.95);
}

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

.gallery-item-label {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    background: rgba(102, 126, 234, 0.9);
    color: white;
    padding: 12px;
    text-align: left;
    font-size: 14px;
    font-weight: 600;
}

.gallery-item.thumbnail {
    border: 3px solid #667eea;
}

/* MODALS */
.modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.6);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
}

.modal-content {
    background: white;
    padding: 30px;
    border-radius: 10px;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.3);
}

.modal-content h2 {
    margin-bottom: 15px;
    color: #2c3e50;
    font-size: 20px;
}

.modal-content p {
    color: #666;
    margin-bottom: 20px;
    line-height: 1.5;
}

.modal-actions {
    display: flex;
    gap: 10px;
}

/* DASHBOARD CARDS */
.dashboard-cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
    margin-top: 40px;
}

.dashboard-card {
    background: white;
    border: 1px solid #ddd;
    border-radius: 12px;
    padding: 30px;
    text-align: center;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s, box-shadow 0.3s;
}

.dashboard-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.15);
}

.dashboard-card .card-icon {
    font-size: 48px;
    margin-bottom: 15px;
}

.dashboard-card h3 {
    margin: 0 0 10px 0;
    color: #2c3e50;
    font-size: 20px;
}

.dashboard-card p {
    margin: 0 0 20px 0;
    color: #666;
    font-size: 14px;
    line-height: 1.5;
}

.dashboard-card button {
    width: 100%;
}

/* FAQs LIST */
.faqs-list {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.faq-item {
    background: white;
    border: 1px solid #ddd;
    border-radius: 8px;
    padding: 20px;
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 15px;
}

.faq-content {
    flex: 1;
}

.faq-content h3 {
    margin: 0 0 5px 0;
    color: #2c3e50;
    font-size: 16px;
    font-weight: 600;
}

.faq-content .faq-lang {
    font-size: 12px;
    color: #999;
    margin-bottom: 10px;
    font-weight: 500;
}

.faq-content p {
    margin: 0 0 10px 0;
    color: #666;
    font-size: 14px;
    line-height: 1.5;
}

.faq-actions {
    display: flex;
    gap: 10px;
    margin-left: 20px;
}

.faq-actions button {
    padding: 8px 15px;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-size: 13px;
    font-weight: 600;
    transition: background 0.3s;
}

.faq-edit {
    background: #667eea;
    color: white;
}

.faq-edit:hover {
    background: #5568d3;
}

.faq-delete {
    background: #e74c3c;
    color: white;
}

.faq-delete:hover {
    background: #c0392b;
}

/* RESPONSIVE */
@media (max-width: 768px) {
    .sidebar {
        width: 100%;
        height: auto;
        position: relative;
        display: flex;
        justify-content: space-between;
        align-items: center;
    }

    .sidebar nav {
        flex-direction: row;
        gap: 5px;
    }

    .main-content {
        margin-left: 0;
        padding: 20px;
    }

    .projects-list {
        grid-template-columns: 1fr;
    }
}
