* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Tajawal', sans-serif;
    background: #f9fafc;
    color: #1e2a3e;
    line-height: 1.5;
    overflow-x: hidden;
}

.container {
    max-width: 1300px;
    margin: 0 auto;
    padding: 0 24px;
}

.navbar {
    background: linear-gradient(135deg, #1e2b3c 0%, #0f1a24 100%);
    padding: 18px 0;
    position: sticky;
    top: 0;
    z-index: 1000;
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.08);
}

.nav-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
}

.logo h2 {
    color: #f4cda6;
    font-size: 1.6rem;
    font-weight: 700;
    animation: glowText 3s ease-in-out infinite;
}

@keyframes glowText {

    0%,
    100% {
        text-shadow: 0 0 0px rgba(244, 205, 166, 0);
    }

    50% {
        text-shadow: 0 0 10px rgba(244, 205, 166, 0.5);
    }
}

.logo span {
    color: #eab676;
    font-size: 0.85rem;
    display: block;
}

.nav-links {
    display: flex;
    gap: 28px;
    flex-wrap: wrap;
    list-style: none;
}

.nav-links a {
    color: #f0f3f8;
    text-decoration: none;
    font-weight: 500;
    font-size: 1rem;
    transition: 0.3s;
    padding: 6px 0;
    cursor: pointer;
    position: relative;
}

.nav-links a::before {
    content: '';
    position: absolute;
    bottom: -2px;
    right: 0;
    width: 0;
    height: 2px;
    background: #f4cda6;
    transition: width 0.3s ease;
}

.nav-links a:hover::before,
.nav-links a.active-page::before {
    width: 100%;
}

.nav-links a:hover,
.nav-links a.active-page {
    color: #f4cda6;
}

.menu-btn {
    display: none;
    font-size: 1.7rem;
    color: #f4cda6;
    cursor: pointer;
    background: none;
    border: none;
}

/* Mobile menu animation */
@media (max-width: 880px) {
    .nav-links {
        display: none;
        width: 100%;
        flex-direction: column;
        background: linear-gradient(135deg, #1e2b3c 0%, #0f1a24 100%);
        padding: 20px;
        border-radius: 20px;
        margin-top: 16px;
        gap: 16px;
        text-align: center;
        position: absolute;
        top: 100%;
        right: 0;
        left: 0;
        z-index: 999;
        transform: translateY(-20px);
        opacity: 0;
        transition: all 0.3s ease;
        pointer-events: none;
        box-shadow: 0 20px 30px rgba(0, 0, 0, 0.2);
    }

    .nav-links.show {
        display: flex;
        transform: translateY(0);
        opacity: 1;
        pointer-events: all;
    }

    .menu-btn {
        display: block;
    }

    .hero-text h1 {
        font-size: 2rem;
    }

    .section-title {
        font-size: 1.8rem;
    }
}

.page-wrapper {
    position: relative;
    min-height: 60vh;
}

.page {
    transition: opacity 0.4s ease;
}

/* Hero Section with animated background */
.hero {
    position: relative;
    background: linear-gradient(135deg, #f8f7f4 0%, #e8eef4 100%);
    padding: 80px 0 60px;
    border-radius: 0 0 50px 50px;
    overflow: hidden;
}

/* Animated background for all pages */
.animated-bg {
    position: relative;
    background: linear-gradient(135deg, #f8f7f4 0%, #e8eef4 100%);
    overflow: hidden;
}

.animated-bg::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: radial-gradient(circle at 20% 50%, rgba(192, 132, 92, 0.03) 0%, transparent 50%);
    animation: pulseBg 8s ease-in-out infinite;
    pointer-events: none;
}

@keyframes pulseBg {

    0%,
    100% {
        opacity: 0.5;
        transform: scale(1);
    }

    50% {
        opacity: 1;
        transform: scale(1.05);
    }
}

.hero-bg-shapes {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    overflow: hidden;
    z-index: 0;
}

.shape {
    position: absolute;
    background: linear-gradient(135deg, rgba(192, 132, 92, 0.08), rgba(244, 205, 166, 0.05));
    border-radius: 50%;
    animation: floatShape 20s infinite ease-in-out;
}

.shape-1 {
    width: 300px;
    height: 300px;
    top: -100px;
    right: -50px;
    animation-duration: 25s;
}

.shape-2 {
    width: 200px;
    height: 200px;
    bottom: -50px;
    left: -50px;
    animation-duration: 18s;
    animation-delay: 2s;
}

.shape-3 {
    width: 150px;
    height: 150px;
    top: 40%;
    right: 20%;
    animation-duration: 22s;
    animation-delay: 5s;
}

.shape-4 {
    width: 250px;
    height: 250px;
    bottom: 20%;
    left: 15%;
    animation-duration: 30s;
    animation-delay: 1s;
}

@keyframes floatShape {

    0%,
    100% {
        transform: translateY(0) rotate(0deg);
    }

    50% {
        transform: translateY(-30px) rotate(10deg);
    }
}

.particle {
    position: absolute;
    background: rgba(192, 132, 92, 0.3);
    border-radius: 50%;
    pointer-events: none;
    animation: floatParticle 15s infinite linear;
}

@keyframes floatParticle {
    0% {
        transform: translateY(100vh) rotate(0deg);
        opacity: 0;
    }

    10% {
        opacity: 1;
    }

    90% {
        opacity: 1;
    }

    100% {
        transform: translateY(-100vh) rotate(360deg);
        opacity: 0;
    }
}

.hero-content {
    position: relative;
    z-index: 2;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 30px;
}

.hero-text {
    flex: 2;
    animation: slideInRight 0.8s cubic-bezier(0.2, 0.9, 0.4, 1.1);
}

@keyframes slideInRight {
    from {
        opacity: 0;
        transform: translateX(50px);
    }

    to {
        opacity: 1;
        transform: translateX(0);
    }
}

.hero-text h1 {
    font-size: 3.2rem;
    font-weight: 800;
    background: linear-gradient(135deg, #1f3b4c 0%, #2c5f7a 50%, #c0845c 100%);
    background-size: 200% auto;
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    animation: gradientShift 5s ease infinite;
    margin-bottom: 20px;
}

@keyframes gradientShift {

    0%,
    100% {
        background-position: 0% 50%;
    }

    50% {
        background-position: 100% 50%;
    }
}

.hero-text p {
    font-size: 1.2rem;
    margin: 20px 0;
    color: #2c3e4e;
    line-height: 1.8;
    animation: fadeInUp 0.8s ease 0.2s both;
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.contact-info {
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
    margin-top: 25px;
    animation: fadeInUp 0.8s ease 0.4s both;
}

.contact-info a,
.contact-info span {
    color: #2c5f7a;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: white;
    padding: 10px 22px;
    border-radius: 60px;
    font-size: 0.95rem;
    transition: all 0.3s cubic-bezier(0.2, 0.9, 0.4, 1.1);
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
}

.contact-info a:hover {
    background: #c0845c;
    color: white;
    transform: translateY(-5px) scale(1.05);
    box-shadow: 0 10px 25px rgba(192, 132, 92, 0.3);
}

.hero-avatar {
    flex: 1;
    text-align: center;
    animation: scaleIn 0.8s cubic-bezier(0.2, 0.9, 0.4, 1.1) 0.1s both;
}

@keyframes scaleIn {
    from {
        opacity: 0;
        transform: scale(0.8);
    }

    to {
        opacity: 1;
        transform: scale(1);
    }
}

.profile-img {
    width: 260px;
    height: auto;
    border-radius: 30px;
    object-fit: cover;
    object-position: 50% 30%;
    border: 4px solid white;
    box-shadow: 0 20px 30px -10px rgba(0, 0, 0, 0.15);
    transition: all 0.3s ease;
    background: #e8d5c4;
}

.hero-avatar img:hover {
    transform: scale(1.05) rotate(5deg);
}

.typing-text {
    display: inline-block;
    font-weight: 600;
    color: #c0845c;
    border-left: 3px solid #c0845c;
    padding-left: 5px;
    animation: blink 0.7s infinite;
}

@keyframes blink {

    0%,
    100% {
        border-color: #c0845c;
    }

    50% {
        border-color: transparent;
    }
}

.section-title {
    font-size: 2rem;
    font-weight: 800;
    color: #1e2a3e;
    margin-bottom: 40px;
    position: relative;
    display: inline-block;
    padding-bottom: 12px;
}

.section-title:after {
    content: '';
    position: absolute;
    bottom: 0;
    right: 0;
    width: 70px;
    height: 4px;
    background: linear-gradient(90deg, #c0845c, #f4cda6);
    border-radius: 4px;
}

.grid-2 {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 30px;
}

.card {
    background: white;
    border-radius: 24px;
    padding: 28px;
    margin: 10px 0 20px;
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.05);
    transition: all 0.4s cubic-bezier(0.2, 0.9, 0.4, 1.1);
    border: 1px solid #edf2f7;
    position: relative;
    overflow: hidden;
}

.card::before {
    content: '';
    position: absolute;
    top: 0;
    right: 0;
    width: 100%;
    height: 5px;
    background: linear-gradient(90deg, #c0845c, #f4cda6);
    transform: translateX(-100%);
    transition: transform 0.4s ease;
}

.card:hover::before {
    transform: translateX(0);
}

.card:hover {
    transform: translateY(-8px) scale(1.02);
    box-shadow: 0 25px 40px -12px rgba(0, 0, 0, 0.15);
}

.badge {
    background: #fef3e8;
    color: #b85c1a;
    padding: 6px 12px;
    border-radius: 40px;
    font-size: 0.75rem;
    font-weight: 700;
    display: inline-block;
    margin-bottom: 12px;
}

.list-styled {
    list-style: none;
}

.list-styled li {
    padding: 10px 0;
    border-bottom: 1px solid #eef2f8;
    display: flex;
    align-items: baseline;
    gap: 12px;
    transition: all 0.3s;
}

.list-styled li:hover {
    padding-right: 10px;
    color: #c0845c;
}

.list-styled i {
    color: #c0845c;
    width: 24px;
}

/* Gallery Styles */
.gallery-modern {
    background: linear-gradient(135deg, #f8f6f2 0%, #f0ebe3 100%);
    border-radius: 40px;
    padding: 40px 30px;
    margin-top: 20px;
}

.gallery-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 25px;
    margin-top: 30px;
}

.gallery-item {
    position: relative;
    border-radius: 20px;
    overflow: hidden;
    cursor: pointer;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1);
    transition: all 0.4s cubic-bezier(0.2, 0.9, 0.4, 1.1);
}

.gallery-item:hover {
    transform: translateY(-10px) scale(1.02);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.2);
}

.gallery-img {
    width: 100%;
    height: 280px;
    object-fit: cover;
    transition: transform 0.5s cubic-bezier(0.2, 0.9, 0.4, 1.1);
}

.gallery-item:hover .gallery-img {
    transform: scale(1.1);
}

.gallery-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(transparent, rgba(0, 0, 0, 0.9));
    color: white;
    padding: 50px 20px 20px;
    transform: translateY(100%);
    transition: transform 0.4s cubic-bezier(0.2, 0.9, 0.4, 1.1);
}

.gallery-item:hover .gallery-overlay {
    transform: translateY(0);
}

.gallery-overlay h4 {
    font-size: 1.2rem;
    margin-bottom: 8px;
    font-weight: 700;
}

.gallery-overlay p {
    font-size: 0.85rem;
    opacity: 0.9;
}

/* Video Gallery Item */
.gallery-item.video-item video {
    width: 100%;
    height: 280px;
    object-fit: cover;
}

/* Certificates Section */
.certificates-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 20px;
    margin-top: 30px;
}

.cert-card {
    background: white;
    border-radius: 16px;
    padding: 20px;
    text-align: center;
    transition: all 0.3s;
    border: 1px solid #eef2f8;
}

.cert-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.1);
}

.cert-card i {
    font-size: 3rem;
    color: #c0845c;
    margin-bottom: 15px;
}

.cert-card h4 {
    margin-bottom: 10px;
}

.download-btn {
    display: inline-block;
    margin-top: 15px;
    padding: 8px 20px;
    background: #c0845c;
    color: white;
    border-radius: 30px;
    text-decoration: none;
    transition: 0.3s;
}

.download-btn:hover {
    background: #a06442;
    transform: scale(1.05);
}

/* Social Links */
.social-links-section {
    display: flex;
    justify-content: center;
    gap: 30px;
    margin: 30px 0;
    flex-wrap: wrap;
}

.social-card {
    background: white;
    padding: 20px 40px;
    border-radius: 60px;
    text-decoration: none;
    color: #1e2a3e;
    display: flex;
    align-items: center;
    gap: 15px;
    transition: all 0.3s;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

.social-card i {
    font-size: 2rem;
}

.social-card.twitter {
    background: #1DA1F2;
    color: white;
}

.social-card.facebook {
    background: #1877F2;
    color: white;
}

.social-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.15);
}

/* Dashboard Modal */
.dashboard-modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    z-index: 2001;
    justify-content: center;
    align-items: center;
}

.dashboard-modal.active {
    display: flex;
}

.dashboard-content {
    background: white;
    border-radius: 30px;
    padding: 30px;
    width: 90%;
    max-width: 750px;
    height: auto;
    max-height: 95vh;
    overflow-y: auto;
}

.dashboard-content input {
    width: 100%;
    padding: 12px;
    margin: 10px 0;
    border: 1px solid #ddd;
    border-radius: 10px;
    font-family: inherit;
}

.dashboard-content button {
    width: 100%;
    padding: 12px;
    background: #c0845c;
    /* color: white; */
    border: none;
    border-radius: 10px;
    cursor: pointer;
    margin-top: 10px;
}

.dashboard-toggle {
    position: fixed;
    bottom: 20px;
    left: 20px;
    background: #c0845c;
    color: white;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    z-index: 999;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
    transition: 0.3s;
}

.dashboard-toggle:hover {
    transform: scale(1.1);
}

/* Article Links */
.articles-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-top: 20px;
}

.article-link {
    display: flex;
    align-items: center;
    gap: 15px;
    padding: 15px;
    background: white;
    border-radius: 15px;
    text-decoration: none;
    color: #1e2a3e;
    transition: 0.3s;
    border: 1px solid #eef2f8;
}

.article-link:hover {
    transform: translateX(-5px);
    border-color: #c0845c;
}

.lightbox {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.95);
    z-index: 2000;
    justify-content: center;
    align-items: center;
    cursor: pointer;
}

.lightbox.active {
    display: flex;
    animation: fadeInLightbox 0.3s ease;
}

@keyframes fadeInLightbox {
    from {
        opacity: 0;
    }

    to {
        opacity: 1;
    }
}

.lightbox-content {
    max-width: 90%;
    max-height: 80%;
    position: relative;
}

.lightbox-img {
    width: 100%;
    height: auto;
    max-height: 80vh;
    object-fit: contain;
    border-radius: 16px;
}

.lightbox-caption {
    position: absolute;
    bottom: -50px;
    left: 0;
    right: 0;
    text-align: center;
    color: white;
    background: rgba(0, 0, 0, 0.7);
    padding: 12px;
    border-radius: 12px;
    font-size: 1rem;
}

.close-lightbox {
    position: absolute;
    top: 20px;
    left: 30px;
    color: white;
    font-size: 2rem;
    cursor: pointer;
    transition: all 0.3s;
}

.close-lightbox:hover {
    color: #c0845c;
    transform: rotate(90deg);
}

.animate-on-scroll {
    opacity: 0;
    transform: translateY(40px);
    transition: all 0.7s cubic-bezier(0.2, 0.9, 0.4, 1.1);
}

.animate-on-scroll.animated {
    opacity: 1;
    transform: translateY(0);
}

footer {
    background: #0f1a24;
    color: #cddfe7;
    text-align: center;
    padding: 30px;
    margin-top: 40px;
}

@media (max-width: 580px) {
    .hero-content {
        flex-direction: column-reverse;
        text-align: center;
    }

    .contact-info {
        justify-content: center;
    }

    .gallery-grid {
        grid-template-columns: 1fr;
    }

    .social-links-section {
        flex-direction: column;
        align-items: center;
    }
}

.dashboard-tabs .tab-btn.active {
    border-bottom: 2px solid #c0845c;
    color: #c0845c;
}

#contentEditor {
    font-family: monospace;
    font-size: 13px;
    line-height: 1.5;
    direction: ltr;
    text-align: left;
}

#pageSelect {
    font-family: 'Tajawal', sans-serif;
}

/* Edit mode indicator when logged in */
body.edit-mode .editable {
    outline: 2px dashed #c0845c;
    cursor: pointer;
    transition: 0.2s;
}

body.edit-mode .editable:hover {
    background: rgba(192, 132, 92, 0.1);
}
/* Dashboard Form Styles */
.dashboard-tabs {
    display: flex;
    flex-wrap: wrap;
    gap: 5px;
    margin-bottom: 20px;
    border-bottom: 1px solid #ddd;
    padding-bottom: 10px;
}

.dashboard-tabs .tab-btn {
    background: none;
    border: none;
    padding: 8px 12px;
    cursor: pointer;
    border-radius: 20px;
    transition: 0.3s;
    font-family: inherit;
}

.dashboard-tabs .tab-btn:hover {
    background: #f0f0f0;
}

.dashboard-tabs .tab-btn.active {
    background: #c0845c;
    color: white;
}

.tab-content {
    display: none;
    max-height: 500px;
    overflow-y: auto;
    padding: 5px;
}

.tab-content.active {
    display: block;
}

.form-group {
    margin-bottom: 15px;
}

.form-group label {
    display: block;
    margin-bottom: 5px;
    font-weight: 600;
    color: #1e2a3e;
}

.form-control {
    width: 100%;
    padding: 10px;
    border: 1px solid #ddd;
    border-radius: 10px;
    font-family: inherit;
    font-size: 14px;
}

.form-control:focus {
    outline: none;
    border-color: #c0845c;
}

.save-btn, .add-btn, .backup-btn, .danger-btn {
    padding: 10px 20px;
    border: none;
    border-radius: 30px;
    cursor: pointer;
    font-family: inherit;
    transition: 0.3s;
    margin-top: 10px;
}

.save-btn {
    background: #27ae60;
    color: white;
}

.save-btn:hover {
    background: #219a52;
}

.add-btn {
    background: #3498db;
    color: white;
}

.add-btn:hover {
    background: #2980b9;
}

.backup-btn {
    background: #2980b9;
    color: white;
    display: inline-block;
    margin: 5px;
}

.danger-btn {
    background: #c0392b;
    color: white;
}

.danger-btn:hover {
    background: #a93226;
}

/* Item list styling */
.item-list {
    border: 1px solid #eee;
    border-radius: 10px;
    padding: 10px;
    margin-bottom: 10px;
    background: #f9f9f9;
}

.item-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 10px;
}

.delete-item {
    background: #e74c3c;
    color: white;
    border: none;
    padding: 5px 10px;
    border-radius: 20px;
    cursor: pointer;
}

.edit-item {
    background: #f39c12;
    color: white;
    border: none;
    padding: 5px 10px;
    border-radius: 20px;
    cursor: pointer;
    margin-left: 5px;
}

.item-fields {
    display: grid;
    gap: 10px;
}
/* Page Selector Wrapper */
.page-selector-wrapper {
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
    border-radius: 20px;
    padding: 20px;
    margin-bottom: 10px;
    border: 1px solid rgba(192, 132, 92, 0.2);
    margin-top: 20px;
    width: 100%;
}

.page-selector-label {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 15px;
    font-weight: 700;
    color: #1e2b3c;
    font-size: 1rem;
}

.page-selector-label i {
    color: #c0845c;
    font-size: 1.3rem;
}

.page-select {
    width: 100%;
    padding: 14px 18px;
    background: white;
    border: 2px solid #e9ecef;
    border-radius: 16px;
    font-family: 'Tajawal', sans-serif;
    font-size: 1rem;
    font-weight: 500;
    color: #1e2a3e;
    cursor: pointer;
    transition: all 0.3s ease;
    appearance: none;
    background-image: url("data:image/svg+xml;charset=UTF-8,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23c0845c' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3e%3cpolyline points='6 9 12 15 18 9'%3e%3c/polyline%3e%3c/svg%3e");
    background-repeat: no-repeat;
    background-position: left 15px center;
    background-size: 20px;
    text-align: right;
}

.page-select:hover {
    border-color: #c0845c;
    background-color: #fffaf5;
}

.page-select:focus {
    outline: none;
    border-color: #c0845c;
    box-shadow: 0 0 0 4px rgba(192, 132, 92, 0.15);
}

.page-select option {
    padding: 12px;
    font-family: 'Tajawal', sans-serif;
    font-size: 0.95rem;
}

/* تبويب المحتوى - إخفاء التبويبات الأخرى */
.tab-content {
    display: none;
    animation: fadeInContent 0.3s ease;
}

.tab-content.active {
    display: block;
}
/* تحسين عرض الفيديو في المعرض */
.gallery-item.video-gallery-item,
.gallery-item.video-item {
    position: relative;
    cursor: pointer;
}

.gallery-item.video-gallery-item video,
.gallery-item.video-item video {
    width: 100%;
    height: 280px;
    object-fit: cover;
    background: #000;
}

.gallery-item.video-gallery-item .gallery-overlay i,
.gallery-item.video-item .gallery-overlay i {
    animation: pulse 1.5s infinite;
}

@keyframes pulse {
    0%, 100% {
        transform: scale(1);
        opacity: 0.8;
    }
    50% {
        transform: scale(1.1);
        opacity: 1;
    }
}

/* أيقونة تشغيل على الفيديو */
.gallery-item.video-gallery-item .gallery-overlay::before,
.gallery-item.video-item .gallery-overlay::before {
    content: "▶";
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    font-size: 3rem;
    color: white;
    opacity: 0.8;
    text-shadow: 0 0 10px rgba(0,0,0,0.5);
}

/* تحسين روابط التواصل */
.social-card {
    transition: all 0.3s ease;
}

.social-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 5px 15px rgba(0,0,0,0.2);
}

.extra-contacts .badge:hover {
    background: #c0845c !important;
    color: white !important;
    transform: translateY(-2px);
}
/* تحسين عرض ملفات PDF في المعرض */
.pdf-thumbnail {
    background: linear-gradient(135deg, #fef3e8 0%, #f8e6d4 100%);
    transition: all 0.3s ease;
}

.pdf-gallery-item:hover .pdf-thumbnail {
    transform: scale(1.05);
}

.pdf-gallery-item .gallery-overlay i {
    animation: pulse 1.5s infinite;
}

@keyframes pulse {
    0%, 100% {
        transform: scale(1);
        opacity: 0.8;
    }
    50% {
        transform: scale(1.1);
        opacity: 1;
    }
}

/* تحسين عرض PDF في المعرض */
.pdf-thumbnail-container {
    position: relative;
    background: #f0ebe3;
    min-height: 280px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.pdf-canvas {
    max-width: 100%;
    max-height: 280px;
    object-fit: cover;
    border-radius: 12px;
}

.pdf-loading {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    color: #c0845c;
    font-size: 0.9rem;
    white-space: nowrap;
}

.pdf-gallery-item:hover .pdf-canvas {
    transform: scale(1.05);
    transition: transform 0.3s ease;
}

.active-sort {
    background: #c0845c !important;
    color: white !important;
}

#customSortIndicator {
    background: #27ae60;
    color: white;
    padding: 2px 8px;
    border-radius: 20px;
    font-size: 0.7rem;
    margin-right: 10px;
}

#customSortIndicator {
    transition: all 0.3s ease;
    font-size: 0.75rem;
    animation: fadeIn 0.3s ease;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: scale(0.9);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

/* تنسيق أزرار الترتيب النشطة */
.btn-outline.active-sort {
    background: #c0845c;
    color: white;
    border-color: #c0845c;
}

/* تنسيق عناصر القائمة القابلة للسحب */
.sortable-item {
    transition: all 0.2s ease;
}

.sortable-item:active {
    cursor: grabbing !important;
}

/* تنسيق مؤقت السحب */
.sortable-item.dragging {
    opacity: 0.3;
    cursor: grabbing;
}

/* تحسين مظهر العناصر القابلة للسحب */
.sortable-container .sortable-item {
    transition: all 0.2s ease;
    cursor: default;
}

.sortable-container .sortable-item:active {
    cursor: grabbing;
}

.sortable-container .drag-handle {
    cursor: grab;
}

.sortable-container .drag-handle:active {
    cursor: grabbing;
}

.filter-btn.active {
    background: #c0845c !important;
    color: white !important;
}

.btn-save {
    transition: all 0.3s ease;
}

.btn-save:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.2);
}

.filter-btn {
    background: #e9ecef;
    color: #333;
    transition: all 0.3s ease;
}

.filter-btn.active {
    background: #c0845c !important;
    color: white !important;
}

.drag-handle {
    cursor: grab;
    user-select: none;
}

.drag-handle:active {
    cursor: grabbing;
}

.sortable-item {
    transition: all 0.2s ease;
}

/* تنسيق معاينة الملفات */
#previewImg, #previewVideo {
    transition: all 0.3s ease;
}

/* تنسيق زر الرفع */
#uploadImageBtn {
    transition: all 0.3s ease;
}

#uploadImageBtn:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.2);
}

#uploadImageBtn:disabled {
    opacity: 0.7;
    cursor: not-allowed;
    transform: none;
}

/* تنسيق منطقة رفع الملف */
#imagePreview {
    animation: fadeIn 0.3s ease;
}


/* تنسيق سبينر التحميل */
#loadingSpinner {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, #1e2b3c 0%, #0f1a24 100%);
    z-index: 9999;
    display: flex;
    justify-content: center;
    align-items: center;
    flex-direction: column;
    transition: opacity 0.5s ease, visibility 0.5s ease;
}

.spinner-container {
    text-align: center;
    animation: fadeInUp 0.5s ease;
}

.spinner {
    width: 60px;
    height: 60px;
    margin: 0 auto 20px;
    border: 5px solid rgba(244, 205, 166, 0.2);
    border-top: 5px solid #f4cda6;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

.spinner-text {
    color: #f4cda6;
    font-size: 1.2rem;
    margin-top: 20px;
}

.spinner-logo {
    margin-top: 30px;
    color: #cddfe7;
    font-size: 0.9rem;
    text-align: center;
}

.spinner-logo i {
    font-size: 2rem;
    color: #f4cda6;
    margin-bottom: 10px;
    display: block;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.spinner-fade-out {
    opacity: 0 !important;
    visibility: hidden !important;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}