﻿@import url(https://fonts.googleapis.com/earlyaccess/droidarabickufi.css);

:root {
    --default-font: "Droid Arabic Kufi", system-ui, -apple-system, "Segoe UI", Droid Arabic Kufi, "Helvetica Neue", Arial, "Noto Sans", "Liberation Sans", sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol", "Noto Color Emoji";
    --heading-font: "Droid Arabic Kufi", sans-serif;
    --nav-font: "Droid Arabic Kufi", sans-serif;
}

/* Global Colors - The following color variables are used throughout the website. Updating them here will change the color scheme of the entire website */
:root {
    --background-color: #f4f7fb; /* soft light gray */
    --surface-color: #ffffff;
    --default-color: #7A4A2E; /* Default color used for the majority of the text content across the entire website */
    --heading-color: #7A4A2E; /* Color for headings, subheadings and title throughout the website */
    --accent-color: #2F5F4E; /* Accent color that represents your brand on the website. It's used for buttons, links, and other elements that need to stand out */
    --contrast-color: #ffffff; /* Contrast color for text, ensuring readability against backgrounds of accent, heading, or default colors. */
}

/* Nav Menu Colors - The following color variables are used specifically for the navigation menu. They are separate from the global colors to allow for more customization options */
:root {
    --nav-color: #124265; /* The default color of the main navmenu links */
    --nav-hover-color: #2487ce; /* Applied to main navmenu links when they are hovered over or active */
    --nav-mobile-background-color: #ffffff; /* Used as the background color for mobile navigation menu */
    --nav-dropdown-background-color: #ffffff; /* Used as the background color for dropdown items that appear when hovering over primary navigation items */
    --nav-dropdown-color: #124265; /* Used for navigation links of the dropdown items in the navigation menu. */
    --nav-dropdown-hover-color: #2487ce; /* Similar to --nav-hover-color, this color is applied to dropdown navigation links when they are hovered over. */
}

/* Color Presets - These classes override global colors when applied to any section or element, providing reuse of the sam color scheme. */

.light-background {
    --background-color: #F6F3EE;
    /*--surface-color: #fff;*/
}

.dark-background {
    --background-color: #060606;
    --default-color: #ffffff;
    --heading-color: #ffffff;
    --surface-color: #252525;
    --contrast-color: #ffffff;
}

.accent-background {
    --background-color: #2F5F4E;
    --default-color: #ffffff;
    --heading-color: #ffffff;
    --accent-color: #ffffff;
    --surface-color: #469fdf;
    --contrast-color: #ffffff;
}

.accent-color {
    color: var(--accent-color) !important;
}

.accent-bg {
    background-color: var(--accent-color) !important;
}

.headingt-bg {
    background-color: var(--heading-color) !important;
}

.heading-color {
    color: var(--heading-color) !important;
}
/* ================= BUTTON ================= */
.relation-btn {
    border-radius: 16px;
    padding: 14px;
    font-weight: 600;
    background: #198754;
    color: #fff;
    box-shadow: 0 6px 18px rgba(0,0,0,.08);
}


/* ================= MODAL CORE (match profile cards) ================= */
.modal-content.relation-modal {
    border-radius: 24px; /* نفس كروت الصفحة */
    overflow: hidden;
    background: #fff;
    box-shadow: 0 12px 40px rgba(0,0,0,.12); /* نفس إحساس الكروت */
}


/* ================= HEADER ================= */
.relation-header {
    padding: 14px 18px;
    background: #fff;
    border-bottom: 1px solid #f1f3f5;
    font-weight: 600;
}



/* ================= BODY ================= */
.relation-body {
    padding: 14px 16px; /* أقل = أجمل */
}
.relation-header-card {
    background: #fff;
    border-radius: 18px;
    box-shadow: 0 6px 18px rgba(0,0,0,.06);
    padding: 14px 18px;
}

/* العنوان الرئيسي */
.relation-title {
    font-size: 22px;
    font-weight: 800;
    color: var(--heading-color);
}

/* الدرجة كبادج */
.degree-badge {
    background: #d56602; /* لون براندك */
    color: #fff;
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 16px;
    font-weight: 600;
}

/* موبايل */
@media(max-width:576px) {
    .relation-title {
        font-size: 18px;
    }
}

/* ================= fab-btn ================= */

.fab-btn {
    width: 35px;
    height: 35px;
    top: -5px;
    left: -5px;
    z-index: 10;
    background: var(--heading-color); /* brand color */
    color: var(--contrast-color);
    transition: all .15s ease;
    cursor: pointer;
}

    /* hover */
    .fab-btn:hover {
        transform: scale(1.08);
        box-shadow: 0 6px 14px rgba(0,0,0,.35);
        color: #fff;
    }

    /* click feedback */
    .fab-btn:active {
        transform: scale(.92);
    }


/* ================= SEARCH ================= */
.relation-search {
    margin-bottom: 12px;
}

.relation-input {
    border-radius: 14px;
    padding: 12px 14px;
    font-size: 15px;
    border: 1px solid #e9ecef;
}

.relation-dropdown {
    max-height: 260px;
    overflow: auto;
    border-radius: 12px;
}


/* ================= RESULT CARD (match profile cards) ================= */
.relation-result-card {
    background: #f8faf9; /* نفس الخلفية الناعمة */
    border-radius: 16px;
    padding: 12px;
    border: 1px solid #e9ecef;
}


/* badge */
.relation-badge {
    background-color: var(--accent-color);
    color: var(--surface-color);
    padding: 4px 12px;
    border-radius: 20px;
    font-weight: bold;
}



/* ================= TIMELINE (cleaner & aligned) ================= */
/* header alignment */
.relation-header-mini {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    margin-bottom: 10px;
}

/* degree look softer */
.relation-degree {
    color: var(--accent-color);
    font-weight: bold;
}

/* small separator */
.relation-sep {
    width: 4px;
    height: 4px;
    background: #dee2e6;
    border-radius: 50%;
}
.relation-degree {
    background: #f1f3f5;
    padding: 3px 10px;
    border-radius: 20px;
}
.relation-via {
    /*opacity: .7;*/
    padding:10px;
}

.relation-timeline {
    position: relative;
    display: flex;
    flex-direction: column;
    gap: 8px;
    padding-right: 20px;
    direction: rtl;
}

    /* line */
    .relation-timeline::before {
        content: "";
        position: absolute;
        right: 7px;
        top: 4px;
        bottom: 4px;
        width: 2px;
        background: #e2e6ea;
    }

/* step */
.relation-step {
    display: flex;
    grid-template-columns: 1fr 90px; /* name | via */
    align-items: center;
    gap: 10px;
}

    /* dot */
    .relation-step::before {
        content: "";
        position: absolute;
        right: 3px;
        width: 9px;
        height: 9px;
        border-radius: 50%;
        background: #0d6efd;
    }

    /* first (closest) */
    .relation-step:first-child::before {
        background: #198754;
        width: 11px;
        height: 11px;
    }


/* ================= MOBILE ================= */
@media(max-width:576px) {

    .modal-content.relation-modal {
        border-radius: 18px 18px 0 0;
    }

    .relation-input {
        font-size: 16px;
    }
}


/* Smooth scroll */
:root {
    scroll-behavior: smooth;
}

/*--------------------------------------------------------------
# General Styling & Shared Classes
--------------------------------------------------------------*/
html, body {
    height: 100%;
}

body {
    color: var(--default-color);
    background-color: var(--background-color);
    /*background-image: radial-gradient( rgba(0,0,0,.015) 1px, transparent 1px );*/
    background-size: 18px 18px;
    font-family: var(--default-font);
    display: flex;
    flex-direction: column;
}

    body.rtl {
        direction: rtl;
        text-align: right;
    }

.main {
    flex: 1 0 auto;
}

.footer {
    margin-top: auto;
    flex-shrink: 0;
}

a {
    color: var(--accent-color);
    text-decoration: none;
    transition: 0.3s;
}

    a:hover {
        color: color-mix(in srgb, var(--accent-color), transparent 25%);
        text-decoration: none;
    }

h1,
h2,
h3,
h4,
h5,
h6 {
    color: var(--heading-color);
    font-family: var(--heading-font);
}

/* Pulsating Play Button
------------------------------*/
.pulsating-play-btn {
    width: 94px;
    height: 94px;
    background: radial-gradient(var(--accent-color) 50%, color-mix(in srgb, var(--accent-color), transparent 75%) 52%);
    border-radius: 50%;
    display: block;
    position: relative;
    overflow: hidden;
}

    .pulsating-play-btn:before {
        content: "";
        position: absolute;
        width: 120px;
        height: 120px;
        animation-delay: 0s;
        animation: pulsate-play-btn 2s;
        animation-direction: forwards;
        animation-iteration-count: infinite;
        animation-timing-function: steps;
        opacity: 1;
        border-radius: 50%;
        border: 5px solid color-mix(in srgb, var(--accent-color), transparent 30%);
        top: -15%;
        left: -15%;
        background: rgba(198, 16, 0, 0);
    }

    .pulsating-play-btn:after {
        content: "";
        position: absolute;
        left: 50%;
        top: 50%;
        transform: translateX(-40%) translateY(-50%);
        width: 0;
        height: 0;
        border-top: 10px solid transparent;
        border-bottom: 10px solid transparent;
        border-left: 15px solid #fff;
        z-index: 100;
        transition: all 400ms cubic-bezier(0.55, 0.055, 0.675, 0.19);
    }

    .pulsating-play-btn:hover:before {
        content: "";
        position: absolute;
        left: 50%;
        top: 50%;
        transform: translateX(-40%) translateY(-50%);
        width: 0;
        height: 0;
        border: none;
        border-top: 10px solid transparent;
        border-bottom: 10px solid transparent;
        border-left: 15px solid #fff;
        z-index: 200;
        animation: none;
        border-radius: 0;
    }

    .pulsating-play-btn:hover:after {
        border-left: 15px solid var(--accent-color);
        transform: scale(20);
    }

@keyframes pulsate-play-btn {
    0% {
        transform: scale(0.6, 0.6);
        opacity: 1;
    }

    100% {
        transform: scale(1, 1);
        opacity: 0;
    }
}

/* PHP Email Form Messages
------------------------------*/
.php-email-form .error-message {
    display: none;
    background: #df1529;
    color: #ffffff;
    text-align: left;
    padding: 15px;
    margin-bottom: 24px;
    font-weight: 600;
}

.php-email-form .sent-message {
    display: none;
    color: #ffffff;
    background: #059652;
    text-align: center;
    padding: 15px;
    margin-bottom: 24px;
    font-weight: 600;
}

.php-email-form .loading {
    display: none;
    background: var(--surface-color);
    text-align: center;
    padding: 15px;
    margin-bottom: 24px;
}

    .php-email-form .loading:before {
        content: "";
        display: inline-block;
        border-radius: 50%;
        width: 24px;
        height: 24px;
        margin: 0 10px -6px 0;
        border: 3px solid var(--accent-color);
        border-top-color: var(--surface-color);
        animation: php-email-form-loading 1s linear infinite;
    }

@keyframes php-email-form-loading {
    0% {
        transform: rotate(0deg);
    }

    100% {
        transform: rotate(360deg);
    }
}

/*--------------------------------------------------------------
# Global Header
--------------------------------------------------------------*/
.header {
    color: var(--default-color);
    background-color: var(--background-color);
    padding: 0px 0;
    transition: all 0.5s;
    z-index: 997;
    border-bottom: 1px solid color-mix(in srgb, var(--accent-color), transparent 85%);
}

    .header .logo {
        line-height: 1;
    }

        .header .logo img {
            height: 80px;
            width: auto;
        }



        .header .logo h1 {
            font-size: 30px;
            margin: 0;
            font-weight: 300;
            color: var(--heading-color);
        }

    .header .btn-getstarted,
    .header .btn-getstarted:focus {
        color: var(--contrast-color);
        background: var(--accent-color);
        font-size: 14px;
        padding: 8px 25px;
        margin: 0 0 0 30px;
        border-radius: 4px;
        transition: 0.3s;
    }

        .header .btn-getstarted:hover,
        .header .btn-getstarted:focus:hover {
            color: var(--contrast-color);
            background: color-mix(in srgb, var(--accent-color), transparent 15%);
        }

@media (max-width: 1200px) {
    .header .logo {
        order: 1;
    }

    .header .btn-getstarted {
        order: 2;
        margin: 0 15px 0 0;
        padding: 6px 15px;
    }

    .header .navmenu {
        order: 3;
    }
}

@media (min-width: 992px) {
    .header .logo img {
        height: 80px;
    }
}

.scrolled .header {
    border-color: var(--contrast-color);
    box-shadow: 0px 0 18px rgba(0, 0, 0, 0.1);
}

/* ===== Header layout fix ===== */
.header-row {
    display: grid;
    grid-template-columns: auto 1fr auto;
    align-items: center;
    width: 100%;
}

/* RTL logical positions */
.header-right {
    display: flex;
    align-items: center;
    justify-content: flex-start; /* logo */
}

    .header-right img {
        height: 100px; /* logo */
    }

.header-center {
    display: flex;
    align-items: center;
    justify-content: center; /* Arhami */
    text-align: center;
}

.header-left {
    display: flex;
    align-items: center;
    justify-content: flex-end; /* menus */
    gap: 10px;
}

/* Prevent wrapping */
.header-row > * {
    white-space: nowrap;
}

/* Mobile fixes */
@media (max-width: 768px) {
    .header-row {
        grid-template-columns: auto 1fr auto;
    }

    .header-right img {
        height: 80px;
    }

    .brand-title {
        font-size: 18px;
    }
}


/* Brand */
.brand-title {
    font-weight: 800;
    letter-spacing: .5px;
    color: var(--accent-color, #7a4a2e);
    font-size: 18px;
}

@media (max-width: 576px) {
    .brand-title {
        font-size: 18px;
    }
}

/* Family button */
.btn-family {
    border-radius: 999px;
    border: 1px solid #ddd;
    background: #f8f9fa;
    font-weight: 600;
    padding: .4rem .9rem;
}

/* User button */
.btn-user {
    border-radius: 999px;
    border: 1px solid var(--accent-color, #7a4a2e);
    color: var(--accent-color, #7a4a2e);
    background: transparent;
    padding: .4rem .9rem;
}

/* Dropdowns */
.dropdown-menu {
    border-radius: 12px;
    box-shadow: 0 8px 30px rgba(0,0,0,.08);
}

/* Mobile spacing */
@media (max-width: 768px) {
    .header .container-xl {
        /*flex-wrap: wrap;*/
        row-gap: .5rem;
    }
}
/*--------------------------------------------------------------
# Navigation Menu
--------------------------------------------------------------*/
/* Navmenu - Desktop */
@media (min-width: 1200px) {
    .navmenu {
        padding: 0;
    }

        .navmenu ul {
            margin: 0;
            padding: 0;
            display: flex;
            list-style: none;
            align-items: center;
        }

        .navmenu li {
            position: relative;
        }

        .navmenu a,
        .navmenu a:focus {
            color: var(--nav-color);
            padding: 18px 15px;
            font-size: 16px;
            font-family: var(--nav-font);
            font-weight: 400;
            display: flex;
            align-items: center;
            justify-content: space-between;
            white-space: nowrap;
            transition: 0.3s;
        }

            .navmenu a i,
            .navmenu a:focus i {
                font-size: 12px;
                line-height: 0;
                margin-left: 5px;
                transition: 0.3s;
            }

        .navmenu li:last-child a {
            padding-right: 0;
        }

        .navmenu li:hover > a,
        .navmenu .active,
        .navmenu .active:focus {
            color: var(--nav-hover-color);
        }

        .navmenu .dropdown ul {
            margin: 0;
            padding: 10px 0;
            background: var(--nav-dropdown-background-color);
            display: block;
            position: absolute;
            visibility: hidden;
            left: 14px;
            top: 130%;
            opacity: 0;
            transition: 0.3s;
            border-radius: 4px;
            z-index: 99;
            box-shadow: 0px 0px 30px rgba(0, 0, 0, 0.1);
        }

            .navmenu .dropdown ul li {
                min-width: 200px;
            }

            .navmenu .dropdown ul a {
                padding: 10px 20px;
                font-size: 15px;
                text-transform: none;
                color: var(--nav-dropdown-color);
            }

                .navmenu .dropdown ul a i {
                    font-size: 12px;
                }

                .navmenu .dropdown ul a:hover,
                .navmenu .dropdown ul .active:hover,
                .navmenu .dropdown ul li:hover > a {
                    color: var(--nav-dropdown-hover-color);
                }

        .navmenu .dropdown:hover > ul {
            opacity: 1;
            top: 100%;
            visibility: visible;
        }

        .navmenu .dropdown .dropdown ul {
            top: 0;
            left: -90%;
            visibility: hidden;
        }

        .navmenu .dropdown .dropdown:hover > ul {
            opacity: 1;
            top: 0;
            left: -100%;
            visibility: visible;
        }
}

/* Navmenu - Mobile */
@media (max-width: 1199px) {
    .mobile-nav-toggle {
        color: var(--nav-color);
        font-size: 28px;
        line-height: 0;
        margin-right: 10px;
        cursor: pointer;
        transition: color 0.3s;
    }

    .navmenu {
        padding: 0;
        z-index: 9997;
    }

        .navmenu ul {
            display: none;
            list-style: none;
            position: absolute;
            inset: 60px 20px 20px 20px;
            padding: 10px 0;
            margin: 0;
            border-radius: 6px;
            background-color: var(--nav-mobile-background-color);
            overflow-y: auto;
            transition: 0.3s;
            z-index: 9998;
            box-shadow: 0px 0px 30px rgba(0, 0, 0, 0.1);
        }

        .navmenu a,
        .navmenu a:focus {
            color: var(--nav-dropdown-color);
            padding: 10px 20px;
            font-family: var(--nav-font);
            font-size: 17px;
            font-weight: 500;
            display: flex;
            align-items: center;
            justify-content: space-between;
            white-space: nowrap;
            transition: 0.3s;
        }

            .navmenu a i,
            .navmenu a:focus i {
                font-size: 12px;
                line-height: 0;
                margin-left: 5px;
                width: 30px;
                height: 30px;
                display: flex;
                align-items: center;
                justify-content: center;
                border-radius: 50%;
                transition: 0.3s;
                background-color: color-mix(in srgb, var(--accent-color), transparent 90%);
            }

                .navmenu a i:hover,
                .navmenu a:focus i:hover {
                    background-color: var(--accent-color);
                    color: var(--contrast-color);
                }

            .navmenu a:hover,
            .navmenu .active,
            .navmenu .active:focus {
                color: var(--nav-dropdown-hover-color);
            }

                .navmenu .active i,
                .navmenu .active:focus i {
                    background-color: var(--accent-color);
                    color: var(--contrast-color);
                    transform: rotate(180deg);
                }

        .navmenu .dropdown ul {
            position: static;
            display: none;
            z-index: 99;
            padding: 10px 0;
            margin: 10px 20px;
            background-color: var(--nav-dropdown-background-color);
            border: 1px solid color-mix(in srgb, var(--default-color), transparent 90%);
            box-shadow: none;
            transition: all 0.5s ease-in-out;
        }

            .navmenu .dropdown ul ul {
                background-color: rgba(33, 37, 41, 0.1);
            }

        .navmenu .dropdown > .dropdown-active {
            display: block;
            background-color: rgba(33, 37, 41, 0.03);
        }

    .mobile-nav-active {
        overflow: hidden;
    }

        .mobile-nav-active .mobile-nav-toggle {
            color: #fff;
            position: absolute;
            font-size: 32px;
            top: 15px;
            right: 15px;
            margin-right: 0;
            z-index: 9999;
        }

        .mobile-nav-active .navmenu {
            position: fixed;
            overflow: hidden;
            inset: 0;
            background: rgba(33, 37, 41, 0.8);
            transition: 0.3s;
        }

            .mobile-nav-active .navmenu > ul {
                display: block;
            }
}
/*--------------------------------------------------------------
# Global Footer
--------------------------------------------------------------*/
.footer {
    color: var(--default-color);
    border-top: 1px solid color-mix(in srgb, var(--accent-color), transparent 80%);
    font-size: 14px;
    position: relative;
}

    /* Top area */
    .footer .footer-top {
        background: linear-gradient(135deg, color-mix(in srgb, var(--accent-color), #000 15%), var(--accent-color) );
        color: var(--surface-color);
        padding-top: 50px;
        padding-bottom: 30px;
        align-items: flex-start;
    }


    .footer .footer-links a,
    .footer .footer-links h4 {
        color: var(--surface-color);
    }

    .footer .footer-about p {
        margin-top: -50px;
    }

.footer-logo {
    height: 200px;
    width: auto;
    display: block;
    margin-top: -50px;
    margin-bottom: 16px;
}

.footer .footer-links a:hover {
    color: var(--surface-color);
    text-decoration: underline;
}

/* Social icons */
.footer .social-links {
    display: flex;
    gap: 10px;
}

    .footer .social-links a {
        display: flex;
        align-items: center;
        justify-content: center;
        width: 40px;
        height: 40px;
        border-radius: 6px;
        background: rgba(255,255,255,.08);
        border: 1px solid rgba(255,255,255,.2);
        color: var(--surface-color);
        transition: .2s ease;
    }

        .footer .social-links a:hover {
            background: #fff;
            color: var(--surface-color);
        }

/* Headings */
.footer h4 {
    font-size: 16px;
    font-weight: 700;
    padding-bottom: 10px;
}

    .footer h4 a {
        color: var(--surface-color);
    }

/* Links */
.footer .footer-links {
    margin-bottom: 30px;
}

    .footer .footer-links ul {
        list-style: none;
        padding: 0;
        margin: 0;
    }

        .footer .footer-links ul li {
            padding: 8px 0;
            display: flex;
            align-items: center;
        }

        .footer .footer-links ul a {
            color: var(--surface-color);
            line-height: 1.4;
        }

            .footer .footer-links ul a:hover {
                color: var(--surface-color);
            }

/* Bottom copyright bar */
.footer .copyright {
    background: var(--surface-color);
    color: var(--accent-color);
    padding: 14px 0;
    border-top: 1px solid rgba(0,0,0,.08);
}

/* Copyright inner */
.footer .copyright-inner {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    font-size: 14px;
    font-weight: 500;
    flex-wrap: wrap;
}

.footer .sitename {
    color: var(--surface-color);
    font-weight: 700;
}

.footer .sitenameCopyright {
    color: var(--heading-color);
    font-weight: 700;
}

/* Credits */
.footer .credits {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 13px;
}

.footer .credits-link img {
    height: 60px;
    width: auto;
}

    .footer .credits-link img:hover {
        transform: scale(1.05);
    }

/* Mobile */
@media (max-width: 768px) {
    .footer .copyright-inner {
        flex-direction: column;
        text-align: center;
    }

    .footer .social-links {
        justify-content: center;
    }

    .footer-logo {
        margin-left: auto;
        margin-right: auto;
        display: block;
        height: 140px;
        margin-top: -50px;
        margin-bottom: 30px;
    }
}


/*--------------------------------------------------------------
# Global Preloader – Family System Premium
--------------------------------------------------------------*/
#preloader {
    position: fixed;
    inset: 0;
    z-index: 999999;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(245, 245, 245, 0.88);
    backdrop-filter: blur(6px);
    transition: opacity 0.4s ease, visibility 0.4s ease;
}

    #preloader.hidden {
        opacity: 0;
        visibility: hidden;
    }

/* content wrapper */
.preloader-content {
    text-align: center;
    animation: fadeInUp 0.6s ease;
}

/* family icon (CSS only, SVG-like) */
.family-icon {
    width: 72px;
    height: 72px;
    margin: 0 auto 12px;
    border-radius: 50%;
    position: relative;
    border: 4px solid rgba(0, 0, 0, 0.08);
    border-top-color: var(--accent-color);
    animation: family-spin 1.2s linear infinite;
}

    /* inner connection */
    .family-icon::after {
        content: "";
        position: absolute;
        inset: 12px;
        border-radius: 50%;
        border: 3px solid rgba(0, 0, 0, 0.05);
        border-bottom-color: var(--accent-color);
        animation: family-spin-reverse 0.9s linear infinite;
    }

/* text */
.preloader-text {
    margin-top: 8px;
    font-size: 0.95rem;
    color: #666;
    letter-spacing: 0.3px;
    animation: pulseText 1.6s ease-in-out infinite;
}

/* animations */
@keyframes family-spin {
    to {
        transform: rotate(360deg);
    }
}

@keyframes family-spin-reverse {
    to {
        transform: rotate(-360deg);
    }
}

@keyframes pulseText {
    0%, 100% {
        opacity: 0.5;
    }

    50% {
        opacity: 1;
    }
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(6px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* =========================
   Modal Loader (Same Style)
========================= */

.modal-loading-overlay {
    position: absolute;
    inset: 0;
    z-index: 1056;
    background: rgba(245, 245, 245, 0.85);
    backdrop-filter: blur(4px);
    display: flex;
    align-items: center;
    justify-content: center;
    pointer-events: none;
}

.modal-loading-content {
    text-align: center;
}

/* reuse global preloader animation */
.modal-loader {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    border: 4px solid rgba(0, 0, 0, 0.08);
    border-top-color: var(--accent-color);
    animation: family-spin 1.2s linear infinite;
    margin: 0 auto 10px;
}

.modal-loading-text {
    font-size: 0.9rem;
    color: #666;
}

/* reuse existing animation */
@keyframes family-spin {
    to {
        transform: rotate(360deg);
    }
}

/*--------------------------------------------------------------
# Scroll Top Button
--------------------------------------------------------------*/
.scroll-top {
    position: fixed;
    visibility: hidden;
    opacity: 0;
    right: 15px;
    bottom: 15px;
    z-index: 99999;
    background-color: var(--accent-color);
    width: 40px;
    height: 40px;
    border-radius: 4px;
    transition: all 0.4s;
}

    .scroll-top i {
        font-size: 24px;
        color: var(--contrast-color);
        line-height: 0;
    }

    .scroll-top:hover {
        background-color: color-mix(in srgb, var(--accent-color), transparent 20%);
        color: var(--contrast-color);
    }

    .scroll-top.active {
        visibility: visible;
        opacity: 1;
    }

/*--------------------------------------------------------------
# Disable aos animation delay on mobile devices
--------------------------------------------------------------*/
@media screen and (max-width: 768px) {
    [data-aos-delay] {
        transition-delay: 0 !important;
    }
}

/*--------------------------------------------------------------
# Global Page Titles & Breadcrumbs
--------------------------------------------------------------*/
.page-title {
    color: var(--default-color);
    background-color: var(--background-color);
    padding: 120px 0;
    text-align: center;
    position: relative;
}

    .page-title h1 {
        font-size: 42px;
        font-weight: 700;
        margin-bottom: 10px;
    }

    .page-title .breadcrumbs ol {
        display: flex;
        flex-wrap: wrap;
        list-style: none;
        justify-content: center;
        padding: 0;
        margin: 0;
        font-size: 16px;
        font-weight: 400;
    }

        .page-title .breadcrumbs ol a {
            color: color-mix(in srgb, var(--default-color), transparent 20%);
        }

        .page-title .breadcrumbs ol li + li {
            padding-left: 10px;
        }

            .page-title .breadcrumbs ol li + li::before {
                content: "/";
                display: inline-block;
                padding-right: 10px;
                color: color-mix(in srgb, var(--default-color), transparent 70%);
            }

.breadcrumb-inline {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    align-items: center;
    gap: 6px;
    white-space: normal;
    text-align: center;
}

.breadcrumb-link {
    font-weight: 600;
    color: var(--accent-color);
    text-decoration: none;
    word-break: break-word;
}

    .breadcrumb-link:hover {
        text-decoration: underline;
    }

.breadcrumb-sep {
    color: #C47A4A;
    font-size: 0.9rem;
}


/*--------------------------------------------------------------
# Global Sections
--------------------------------------------------------------*/
section,
.section {
    color: var(--default-color);
    /*background-color: var(--background-color);*/
    padding: 30px 0;
    scroll-margin-top: 100px;
    overflow: clip;
}

@media (max-width: 1199px) {

    section,
    .section {
        scroll-margin-top: 76px;
    }
}

/*--------------------------------------------------------------
# Global Section Titles
--------------------------------------------------------------*/
.section-title {
    text-align: center;
    padding-bottom: 20px;
    position: relative;
}

    .section-title h2 {
        font-size: 32px;
        font-weight: 700;
        margin-bottom: 5px;
        text-transform: uppercase;
    }

    .section-title p {
        margin-bottom: 0;
    }

/*--------------------------------------------------------------
# Hero Section
--------------------------------------------------------------*/
.hero {
    width: 100%;
    min-height: auto !important; /* remove full screen feel */
    padding: 20px 0 20px 0 !important;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

    .hero:before {
        content: "";
        background-color: #768a83;
        /*background: color-mix(in srgb, var(--background-color), transparent 30%);*/
        position: absolute;
        inset: 0;
        z-index: 2;
    }

    .hero img {
        position: absolute;
        inset: 0;
        display: block;
        width: 100%;
        height: 100%;
        object-fit: cover;
        z-index: 1;
    }

    .hero .container {
        position: relative;
        z-index: 3;
    }

    .hero h1 {
        margin: 0;
        font-size: 56px;
        font-weight: 700;
        line-height: 72px;
    }

    .hero p {
        font-size: 18px;
        margin-bottom: 20px;
        color: color-mix(in srgb, var(--default-color), transparent 30%);
    }

@media (max-width: 992px) {
    .hero h1 {
        font-size: 28px;
        line-height: 36px;
    }

    .hero p {
        font-size: 12px;
        line-height: 24px;
    }

    .hero-search input {
        height: 42px;
        font-size: 14px;
    }
}

.hero .btn-get-started {
    color: var(--contrast-color);
    background: var(--accent-color);
    font-weight: 600;
    font-size: 16px;
    letter-spacing: 0.5px;
    display: inline-block;
    padding: 14px 50px;
    border-radius: 5px;
    transition: 0.5s;
    margin-top: 30px;
}

    .hero .btn-get-started:hover {
        background: color-mix(in srgb, var(--accent-color), transparent 15%);
    }

.hero .icon-box {
    background-color: var(--surface-color);
    padding: 50px 30px;
    position: relative;
    overflow: hidden;
    box-shadow: 0 0 29px 0 rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease-in-out;
    border-radius: 8px;
    z-index: 1;
    height: 100%;
    width: 100%;
}

    .hero .icon-box .title {
        font-weight: 700;
        margin-bottom: 15px;
        font-size: 18px;
    }

        .hero .icon-box .title a {
            color: var(--heading-color);
            transition: 0.3s;
        }

    .hero .icon-box .description {
        font-size: 15px;
        margin-bottom: 0;
        color: color-mix(in srgb, var(--default-color), transparent 40%);
    }

    .hero .icon-box .icon {
        margin-bottom: 20px;
        padding-top: 10px;
        display: inline-block;
        transition: all 0.3s ease-in-out;
        font-size: 36px;
        line-height: 1;
        color: var(--accent-color);
    }

.hero .hero-search {
    position: relative;
    max-width: 100%;
    margin: auto;
    padding: 16px 24px;
}

.hero-search input {
    text-align: center;
    width: 100%;
    padding: 16px 16px;
    padding-left: 56px; /* space for icon */
    border-radius: 50px;
    border: 1px solid #e6eef6;
    background: #fff;
    font-size: 16px;
    outline: none;
    box-shadow: 0 4px 20px rgba(0,0,0,.05);
}

    /* KEEP SAME BORDER ON FOCUS */
    .hero-search input:focus {
        border: 1px solid #e6eef6;
        box-shadow: 0 4px 20px rgba(0,0,0,.05);
        outline: none;
    }

/* icon inside input */
.hero-search i {
    position: absolute;
    left: 80%; /* move to right if needed */
    top: 50%;
    transform: translateY(-50%);
    font-size: 18px;
    color: #9bb3c7;
    pointer-events: none;
}

@media (min-width: 640px) {
    .hero .icon-box:hover {
        transform: scale(1.08);
    }

        .hero .icon-box:hover .title a {
            color: var(--accent-color);
        }
}

/*--------------------------------------------------------------
# About Section
--------------------------------------------------------------*/
.about ul {
    list-style: none;
    padding: 0;
}

    .about ul li {
        padding-bottom: 5px;
        display: flex;
        align-items: center;
    }

    .about ul i {
        font-size: 20px;
        padding-right: 4px;
        color: var(--accent-color);
    }

.about .read-more {
    background: var(--accent-color);
    color: var(--contrast-color);
    font-family: var(--heading-font);
    font-weight: 500;
    font-size: 16px;
    letter-spacing: 1px;
    padding: 10px 28px;
    border-radius: 5px;
    transition: 0.3s;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

    .about .read-more i {
        font-size: 18px;
        margin-left: 5px;
        line-height: 0;
        transition: 0.3s;
    }

    .about .read-more:hover {
        background: color-mix(in srgb, var(--accent-color), transparent 20%);
    }

        .about .read-more:hover i {
            transform: translate(5px, 0);
        }

/*--------------------------------------------------------------
# Stats Section
--------------------------------------------------------------*/
/* ================= PROFILE ================= */
.profile-hero {
    background: #fff;
    border-radius: 20px;
    padding: 30px;
    text-align: center;
    box-shadow: 0 10px 40px rgba(0,0,0,.05);
    position: relative;
}

.profile-avatar {
    width: 120px;
    height: 120px;
    border-radius: 50%;
    border: 5px solid #fff;
    box-shadow: 0 8px 30px rgba(0,0,0,.12);
    object-fit: cover;
    margin-top: -60px;
}

.profile-hero h1 {
    font-weight: 800;
    margin-top: 10px;
    color: #2F3E39;
}

.location {
    color: #7A8A84;
    font-size: 13px;
}

.profile-actions {
    display: flex;
    justify-content: center;
    gap: 10px;
    margin-top: 15px;
}

    .profile-actions button,
    .edit-btn {
        border: none;
        background: #f0f3f2;
        padding: 8px 12px;
        border-radius: 10px;
        color: #2F3E39;
    }

/* ================= STATS ================= */
.profile-stats {
    display: grid;
    grid-template-columns: repeat(4,1fr);
    gap: 12px;
    margin: 30px 0;
}

.stat {
    background: #fff;
    border-radius: 14px;
    padding: 14px;
    box-shadow: 0 8px 25px rgba(0,0,0,.04);
    text-align: center;
    position: relative;
}

    .stat::before {
        content: "";
        position: absolute;
        right: 0;
        top: 0;
        width: 5px;
        height: 100%;
        border-radius: 5px 0 0 5px;
    }

    .stat.male::before {
        background: #6E9FD3;
    }

    .stat.female::before {
        background: #E3A0B5;
    }

    .stat span {
        font-size: 28px;
        font-weight: 800;
        color: #2F3E39;
    }

/* ================= PARENTS ================= */
.parents-avatars {
    display: flex;
    justify-content: center;
    gap: 40px;
    margin: 40px 0;
}

.parent-avatar {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-decoration: none;
    color: #2F3E39;
    transition: 0.3s;
}

    .parent-avatar img {
        width: 96px;
        height: 96px;
        border-radius: 50%;
        object-fit: cover;
        box-shadow: 0 10px 30px rgba(0,0,0,.08);
        border: 4px solid white;
    }

    .parent-avatar span {
        font-size: 12px;
        margin-top: 10px;
        opacity: .6;
    }

    .parent-avatar strong {
        font-size: 14px;
        margin-top: 4px;
        text-align: center;
    }

    .parent-avatar.male img {
        border-color: #6E9FD3;
    }

    .parent-avatar.female img {
        border-color: #E3A0B5;
    }

    .parent-avatar:hover {
        transform: translateY(-4px);
    }


.parent {
    flex: 1;
    background: #fff;
    border-radius: 14px;
    padding: 14px;
    text-decoration: none;
    color: #2F3E39;
    box-shadow: 0 6px 20px rgba(0,0,0,.05);
}

    .parent.male {
        border-right: 5px solid #6E9FD3;
    }

    .parent.female {
        border-right: 5px solid #E3A0B5;
    }

/* ================= FAMILY ================= */
/* ===== Spouse Section ===== */
.spouse-section {
    margin: 30px 0;
    padding: 20px;
    background: #fff;
    border-radius: 16px;
    box-shadow: 0 10px 30px rgba(0,0,0,.05);
}

/* ===== Spouse Header ===== */
.spouse-card {
    background: #ffffff;
    border-radius: 18px;
    padding: 20px;
    box-shadow: 0 10px 25px rgba(0,0,0,.06);
    margin-bottom: 32px;
}

.spouse-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-bottom: 12px;
    border-bottom: 1px solid #e5ece9;
}

.spouse-info {
    display: flex;
    align-items: center;
    gap: 12px;
}

    .spouse-info img {
        width: 52px;
        height: 52px;
        border-radius: 50%;
        object-fit: cover;
        border: 3px solid #dfe7e3;
    }

    .spouse-info .role {
        font-size: 12px;
        color: #7a8a84;
        display: block;
    }

    .spouse-info a {
        font-weight: 600;
        color: #2f3e39;
        text-decoration: none;
    }

.spouse-counts span {
    font-weight: 600;
    margin-left: 12px;
}

.spouse-counts .male {
    color: #6E9FD3;
}

.spouse-counts .female {
    color: #E3A0B5;
}

.children-title {
    margin-top: 14px;
    margin-bottom: 12px;
    font-size: 14px;
    font-weight: 600;
    color: #6c7f78;
}

.children-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill,minmax(110px,1fr));
    gap: 14px;
    min-height: 60px;
}

.child-card {
    background: #f6f8f7;
    border-radius: 14px;
    padding: 12px 8px;
    text-align: center;
    text-decoration: none;
    color: #2f3e39;
    transition: .2s;
}

    .child-card img {
        width: 48px;
        height: 48px;
        border-radius: 50%;
        object-fit: cover;
        margin-bottom: 6px;
    }

    .child-card.male img {
        border: 3px solid #6E9FD3;
    }

    .child-card.female img {
        border: 3px solid #E3A0B5;
    }

    .child-card:hover {
        transform: translateY(-4px);
        box-shadow: 0 8px 20px rgba(0,0,0,.08);
    }

.children-title {
    font-weight: 700;
    color: #2f3e39;
    margin: 10px 0 6px;
    font-size: 14px;
}

.children-list {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.child-pill {
    /*display: inline-flex;*/
    align-items: center;
    gap: 6px;
    padding: 6px 12px;
    border-radius: 20px;
    /*font-size: 13px;*/
    font-weight: 600;
    text-decoration: none;
    background: #f3f5f4;
    transition: .2s;
    text-align:center;
}

    .child-pill.male {
        color: #3b6ea8;
        background: rgba(110,159,211,.12);
    }

    .child-pill.female {
        color: #b5526f;
        background: rgba(227,160,181,.15);
    }

    .child-pill:hover {
        transform: translateY(-2px);
        box-shadow: 0 4px 12px rgba(0,0,0,.08);
    }


.counts span {
    font-size: 12px;
    margin-left: 6px;
    padding: 4px 8px;
    border-radius: 20px;
    background: #f3f3f3;
}

.counts .male {
    color: #6E9FD3
}

.counts .female {
    color: #E3A0B5
}

/* children */
.children-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill,minmax(140px,1fr));
    gap: 10px;
    margin-top: 12px;
}

.child-tile {
    background: #f9faf9;
    padding: 10px;
    border-radius: 12px;
    text-decoration: none;
    font-size: 13px;
    color: #2F3E39;
    text-align: center;
    box-shadow: 0 4px 10px rgba(0,0,0,.03);
}

    .child-tile.male {
        border-right: 4px solid #6E9FD3;
    }

    .child-tile.female {
        border-right: 4px solid #E3A0B5;
    }


/* ===== SIBLINGS ===== */
.siblings-section {
    background: #fff;
    border-radius: 18px;
    padding: 20px;
    box-shadow: 0 10px 25px rgba(0,0,0,.04);
}

.section-title-sm {
    font-weight: 700;
    margin-bottom: 14px;
    color: #2f3e39;
}

.siblings-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill,minmax(130px,1fr));
    gap: 14px;
}

.sibling-card {
    background: #f8fbfa;
    border-radius: 14px;
    padding: 12px 8px;
    text-align: center;
    text-decoration: none;
    color: #2f3e39;
    position: relative;
    transition: .2s;
}

    .sibling-card:hover {
        transform: translateY(-4px);
        box-shadow: 0 8px 20px rgba(0,0,0,.08);
    }

    .sibling-card img {
        width: 52px;
        height: 52px;
        border-radius: 50%;
        object-fit: cover;
        margin-bottom: 6px;
    }

    .sibling-card.male img {
        border: 3px solid #6E9FD3;
    }

    .sibling-card.female img {
        border: 3px solid #E3A0B5;
    }

.sibling-name {
    font-size: 13px;
    font-weight: 700;
}

.sibling-badge {
    position: absolute;
    top: 8px;
    left: 8px;
    font-size: 10px;
    padding: 3px 8px;
    border-radius: 20px;
    font-weight: 600;
}

    .sibling-badge.full {
        background: #e8f1ff;
        color: #1e6fff;
    }

    .sibling-badge.father {
        background: #fff3cd;
        color: #9a7b00;
    }

    .sibling-badge.mother {
        background: #ffecec;
        color: #e55353;
    }

/*--------------------------------------------------------------
# About Alt Section
--------------------------------------------------------------*/
.about-alt .content h3 {
    font-size: 1.75rem;
    font-weight: 700;
}

.about-alt .content ul {
    list-style: none;
    padding: 0;
}

    .about-alt .content ul li {
        padding: 10px 0 0 0;
        display: flex;
    }

    .about-alt .content ul i {
        color: var(--accent-color);
        margin-right: 0.5rem;
        line-height: 1.2;
        font-size: 1.25rem;
    }

.about-alt .content p:last-child {
    margin-bottom: 0;
}

.about-alt .pulsating-play-btn {
    position: absolute;
    left: calc(50% - 47px);
    top: calc(50% - 47px);
}
/* Families dropdown */
.families-dropdown .families-menu {
    min-width: 260px;
    max-height: 60vh;
    overflow-y: auto;
}

.family-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 12px;
    cursor: pointer;
}

    .family-item img {
        width: 34px;
        height: 34px;
        object-fit: cover;
        border-radius: 50%;
        background: #f1f1f1;
    }

    .family-item span {
        font-size: 14px;
        font-weight: 500;
    }

    .family-item.active {
        background: #eef5ff;
        color: #0d6efd;
    }

    .family-item:hover {
        background: #f8f9fa;
    }


/*--------------------------------------------------------------
# Testimonials Section
--------------------------------------------------------------*/
.testimonials .testimonials-carousel,
.testimonials .testimonials-slider {
    overflow: hidden;
}

.testimonials .testimonial-item {
    box-sizing: content-box;
    min-height: 320px;
}

    .testimonials .testimonial-item .testimonial-img {
        width: 90px;
        border-radius: 50%;
        margin: -40px 0 0 40px;
        position: relative;
        z-index: 2;
        border: 6px solid var(--background-color);
    }

    .testimonials .testimonial-item h3 {
        font-size: 18px;
        font-weight: bold;
        margin: 10px 0 5px 45px;
    }

    .testimonials .testimonial-item h4 {
        font-size: 14px;
        color: color-mix(in srgb, var(--default-color), transparent 20%);
        margin: 0 0 0 45px;
    }

    .testimonials .testimonial-item .quote-icon-left,
    .testimonials .testimonial-item .quote-icon-right {
        color: color-mix(in srgb, var(--accent-color), transparent 50%);
        font-size: 26px;
        line-height: 0;
    }

    .testimonials .testimonial-item .quote-icon-left {
        display: inline-block;
        left: -5px;
        position: relative;
    }

    .testimonials .testimonial-item .quote-icon-right {
        display: inline-block;
        right: -5px;
        position: relative;
        top: 10px;
        transform: scale(-1, -1);
    }

    .testimonials .testimonial-item p {
        font-style: italic;
        margin: 0 15px 0 15px;
        padding: 20px 20px 60px 20px;
        background: color-mix(in srgb, var(--default-color), transparent 97%);
        position: relative;
        border-radius: 6px;
        position: relative;
        z-index: 1;
    }

.testimonials .swiper-wrapper {
    height: auto;
}

.testimonials .swiper-pagination {
    margin-top: 20px;
    position: relative;
}

    .testimonials .swiper-pagination .swiper-pagination-bullet {
        width: 12px;
        height: 12px;
        background-color: var(--background-color);
        opacity: 1;
        border: 1px solid var(--accent-color);
    }

    .testimonials .swiper-pagination .swiper-pagination-bullet-active {
        background-color: var(--accent-color);
    }

/*--------------------------------------------------------------
# Services Section
--------------------------------------------------------------*/
.services .service-item {
    background-color: var(--surface-color);
    box-shadow: 0px 5px 90px 0px rgba(0, 0, 0, 0.1);
    height: 100%;
    padding: 60px 30px;
    text-align: center;
    transition: 0.3s;
    border-radius: 5px;
}

    .services .service-item .icon {
        margin: 0 auto;
        width: 100px;
        height: 100px;
        display: flex;
        align-items: center;
        justify-content: center;
        transition: ease-in-out 0.3s;
        position: relative;
    }

        .services .service-item .icon i {
            font-size: 36px;
            transition: 0.5s;
            position: relative;
        }

        .services .service-item .icon svg {
            position: absolute;
            top: 0;
            left: 0;
        }

            .services .service-item .icon svg path {
                transition: 0.5s;
                fill: color-mix(in srgb, var(--default-color), transparent 95%);
            }

    .services .service-item h3 {
        font-weight: 700;
        margin: 10px 0 15px 0;
        font-size: 22px;
    }

    .services .service-item p {
        line-height: 24px;
        font-size: 14px;
        margin-bottom: 0;
    }

    .services .service-item:hover {
        box-shadow: 0px 5px 35px 0px rgba(0, 0, 0, 0.1);
    }

    .services .service-item.item-cyan i {
        color: #0dcaf0;
    }

    .services .service-item.item-cyan:hover .icon i {
        color: #fff;
    }

    .services .service-item.item-cyan:hover .icon path {
        fill: #0dcaf0;
    }

    .services .service-item.item-orange i {
        color: #fd7e14;
    }

    .services .service-item.item-orange:hover .icon i {
        color: #fff;
    }

    .services .service-item.item-orange:hover .icon path {
        fill: #fd7e14;
    }

    .services .service-item.item-teal i {
        color: #20c997;
    }

    .services .service-item.item-teal:hover .icon i {
        color: #fff;
    }

    .services .service-item.item-teal:hover .icon path {
        fill: #20c997;
    }

    .services .service-item.item-red i {
        color: #df1529;
    }

    .services .service-item.item-red:hover .icon i {
        color: #fff;
    }

    .services .service-item.item-red:hover .icon path {
        fill: #df1529;
    }

    .services .service-item.item-indigo i {
        color: #6610f2;
    }

    .services .service-item.item-indigo:hover .icon i {
        color: #fff;
    }

    .services .service-item.item-indigo:hover .icon path {
        fill: #6610f2;
    }

    .services .service-item.item-pink i {
        color: #f3268c;
    }

    .services .service-item.item-pink:hover .icon i {
        color: #fff;
    }

    .services .service-item.item-pink:hover .icon path {
        fill: #f3268c;
    }

/*--------------------------------------------------------------
# Call To Action Section
--------------------------------------------------------------*/
.call-to-action {
    padding: 80px 0;
    position: relative;
    clip-path: inset(0);
}

    .call-to-action h3 {
        font-size: 28px;
        font-weight: 700;
        color: var(--default-color);
    }

    .call-to-action p {
        color: var(--default-color);
    }

    .call-to-action .cta-btn {
        font-family: var(--heading-font);
        font-weight: 500;
        font-size: 16px;
        letter-spacing: 1px;
        display: inline-block;
        padding: 12px 40px;
        border-radius: 5px;
        transition: 0.5s;
        margin: 10px;
        border: 2px solid var(--contrast-color);
        color: var(--contrast-color);
    }

        .call-to-action .cta-btn:hover {
            background: var(--surface-color);
            color: var(--accent-color);
        }

/*--------------------------------------------------------------
# Portfolio Section
--------------------------------------------------------------*/
.portfolio .portfolio-filters {
    padding: 0;
    margin: 0 auto 20px auto;
    list-style: none;
    text-align: center;
}

    .portfolio .portfolio-filters li {
        cursor: pointer;
        display: inline-block;
        padding: 8px 20px 10px 20px;
        margin: 0;
        font-size: 15px;
        font-weight: 600;
        line-height: 1;
        margin-bottom: 5px;
        border-radius: 50px;
        transition: all 0.3s ease-in-out;
        font-family: var(--heading-font);
    }

        .portfolio .portfolio-filters li:hover,
        .portfolio .portfolio-filters li.filter-active {
            color: var(--accent-color);
        }

        .portfolio .portfolio-filters li:first-child {
            margin-left: 0;
        }

        .portfolio .portfolio-filters li:last-child {
            margin-right: 0;
        }

@media (max-width: 575px) {
    .portfolio .portfolio-filters li {
        font-size: 14px;
        margin: 0 0 10px 0;
    }
}

.portfolio .portfolio-item {
    position: relative;
    overflow: hidden;
}

    .portfolio .portfolio-item .portfolio-info {
        opacity: 0;
        position: absolute;
        left: 12px;
        right: 12px;
        bottom: -100%;
        z-index: 3;
        transition: all ease-in-out 0.5s;
        background: color-mix(in srgb, var(--background-color), transparent 10%);
        padding: 15px;
    }

        .portfolio .portfolio-item .portfolio-info h4 {
            font-size: 18px;
            font-weight: 600;
            padding-right: 50px;
        }

        .portfolio .portfolio-item .portfolio-info p {
            color: color-mix(in srgb, var(--default-color), transparent 30%);
            font-size: 14px;
            margin-bottom: 0;
            padding-right: 50px;
        }

        .portfolio .portfolio-item .portfolio-info .preview-link,
        .portfolio .portfolio-item .portfolio-info .details-link {
            position: absolute;
            right: 50px;
            font-size: 24px;
            top: calc(50% - 14px);
            color: color-mix(in srgb, var(--default-color), transparent 30%);
            transition: 0.3s;
            line-height: 0;
        }

            .portfolio .portfolio-item .portfolio-info .preview-link:hover,
            .portfolio .portfolio-item .portfolio-info .details-link:hover {
                color: var(--accent-color);
            }

        .portfolio .portfolio-item .portfolio-info .details-link {
            right: 14px;
            font-size: 28px;
        }

    .portfolio .portfolio-item:hover .portfolio-info {
        opacity: 1;
        bottom: 0;
    }

/*--------------------------------------------------------------
# Team Section
--------------------------------------------------------------*/
.team .team-member {
    background-color: var(--surface-color);
    position: relative;
    overflow: visible !important;
    border-radius: 5px;
    box-shadow: 0px 0 10px rgba(0, 0, 0, 0.1);
    height: 100%;
    text-align: center;
}

    .team .team-member .member-img {
        position: relative;
        overflow: hidden;
    }

    .team .team-member .social {
        position: absolute;
        left: 0;
        bottom: 30px;
        right: 0;
        opacity: 0;
        transition: ease-in-out 0.3s;
        text-align: center;
    }

        .team .team-member .social a {
            background: color-mix(in srgb, var(--contrast-color), transparent 25%);
            color: color-mix(in srgb, var(--default-color), transparent 20%);
            margin: 0 3px;
            border-radius: 4px;
            width: 36px;
            height: 36px;
            transition: ease-in-out 0.3s;
            display: inline-flex;
            justify-content: center;
            align-items: center;
        }

            .team .team-member .social a:hover {
                color: var(--contrast-color);
                background: var(--accent-color);
            }

        .team .team-member .social i {
            font-size: 18px;
            line-height: 0;
        }

    .team .team-member .member-info {
        padding: 25px 15px;
        color: var(--surface-color);
    }

        .team .team-member .member-info h4 {
            font-weight: 700;
            margin-bottom: 5px;
            font-size: 18px;
        }

        .team .team-member .member-info span {
            display: block;
            font-size: 13px;
            font-weight: 400;
            color: color-mix(in srgb, var(--default-color), transparent 0%);
        }

    .team .team-member:hover .social {
        opacity: 1;
        bottom: 15px;
    }

@media (max-width: 768px) {
    .team-member {
        margin-left: auto;
        margin-right: auto;
        display: block;
        justify-content: center;
    }

        .team-member .arham-card {
            max-width: 360px;
            width: 100%;
        }

        .team-member img {
            max-height: 220px;
            object-fit: contain;
        }
}

.member-img a {
    display: block;
    cursor: pointer;
    -webkit-tap-highlight-color: transparent;
}

.member-img img {
    transition: .25s;
}

.member-img:hover img {
    transform: scale(1.05);
    filter: brightness(.95);
}

/*--------------------------------------------------------------
# Pricing Section
--------------------------------------------------------------*/
.pricing .pricing-item {
    background-color: var(--surface-color);
    padding: 60px 40px;
    box-shadow: 0 3px 20px -2px rgba(0, 0, 0, 0.1);
    height: 100%;
    position: relative;
}

.pricing h3 {
    font-weight: 600;
    margin-bottom: 15px;
    font-size: 20px;
}

.pricing h4 {
    font-size: 48px;
    color: var(--accent-color);
    font-family: var(--heading-font);
    font-weight: 400;
}

    .pricing h4 sup {
        font-size: 28px;
    }

    .pricing h4 span {
        color: color-mix(in srgb, var(--default-color), transparent 60%);
        font-size: 18px;
    }

.pricing ul {
    padding: 20px 0;
    list-style: none;
    color: color-mix(in srgb, var(--default-color), transparent 30%);
    text-align: left;
    line-height: 20px;
}

    .pricing ul li {
        padding: 10px 0;
        display: flex;
        align-items: center;
    }

    .pricing ul i {
        color: #059652;
        font-size: 24px;
        padding-right: 3px;
    }

    .pricing ul .na {
        color: color-mix(in srgb, var(--default-color), transparent 60%);
    }

        .pricing ul .na i {
            color: color-mix(in srgb, var(--default-color), transparent 60%);
        }

        .pricing ul .na span {
            text-decoration: line-through;
        }

.pricing .buy-btn {
    color: color-mix(in srgb, var(--default-color), transparent 40%);
    background-color: var(--background-color);
    display: inline-block;
    padding: 8px 35px 10px 35px;
    border-radius: 4px;
    border: 1px solid color-mix(in srgb, var(--default-color), transparent 60%);
    transition: none;
    font-size: 16px;
    font-weight: 500;
    font-family: var(--heading-font);
    transition: 0.3s;
}

    .pricing .buy-btn:hover {
        background: var(--accent-color);
        border-color: var(--accent-color);
        color: var(--contrast-color);
    }

.pricing .featured {
    z-index: 10;
}

    .pricing .featured .pricing-item {
        background: var(--accent-color);
    }

@media (min-width: 992px) {
    .pricing .featured .pricing-item {
        transform: scale(1.02, 1.1);
    }
}

.pricing .featured h3,
.pricing .featured h4,
.pricing .featured h4 span,
.pricing .featured ul,
.pricing .featured ul .na,
.pricing .featured ul i,
.pricing .featured ul .na i {
    color: var(--contrast-color);
}

.pricing .featured .buy-btn {
    background: var(--accent-color);
    color: var(--contrast-color);
    border-color: var(--contrast-color);
}

    .pricing .featured .buy-btn:hover {
        background: color-mix(in srgb, var(--background-color), transparent 92%);
    }

/*--------------------------------------------------------------
# Faq Section
--------------------------------------------------------------*/
.faq .faq-container .faq-item {
    background-color: var(--surface-color);
    position: relative;
    padding: 20px;
    margin-bottom: 15px;
    border: 1px solid color-mix(in srgb, var(--default-color), transparent 85%);
    border-radius: 5px;
    overflow: hidden;
}

    .faq .faq-container .faq-item:last-child {
        margin-bottom: 0;
    }

    .faq .faq-container .faq-item h3 {
        font-weight: 600;
        font-size: 18px;
        line-height: 24px;
        margin: 0 30px 0 0;
        transition: 0.3s;
        cursor: pointer;
        display: flex;
        align-items: center;
    }

        .faq .faq-container .faq-item h3 .num {
            color: var(--accent-color);
            padding-right: 5px;
        }

        .faq .faq-container .faq-item h3:hover {
            color: var(--accent-color);
        }

    .faq .faq-container .faq-item .faq-content {
        display: grid;
        grid-template-rows: 0fr;
        transition: 0.3s ease-in-out;
        visibility: hidden;
        opacity: 0;
    }

        .faq .faq-container .faq-item .faq-content p {
            margin-bottom: 0;
            overflow: hidden;
        }

    .faq .faq-container .faq-item .faq-toggle {
        position: absolute;
        top: 20px;
        right: 20px;
        font-size: 16px;
        line-height: 0;
        transition: 0.3s;
        cursor: pointer;
    }

        .faq .faq-container .faq-item .faq-toggle:hover {
            color: var(--accent-color);
        }

.faq .faq-container .faq-active {
    background-color: var(--accent-color);
    border-color: var(--accent-color);
    color: var(--contrast-color);
}

    .faq .faq-container .faq-active h3 {
        color: var(--contrast-color);
    }

    .faq .faq-container .faq-active .faq-content {
        grid-template-rows: 1fr;
        visibility: visible;
        opacity: 1;
        padding-top: 10px;
    }

    .faq .faq-container .faq-active .faq-toggle {
        transform: rotate(90deg);
        color: var(--accent-color);
    }

/*--------------------------------------------------------------
# Contact Section
--------------------------------------------------------------*/
.contact .info-item + .info-item {
    margin-top: 40px;
}

.contact .info-item i {
    color: var(--contrast-color);
    background: var(--accent-color);
    font-size: 20px;
    width: 44px;
    height: 44px;
    display: flex;
    justify-content: center;
    align-items: center;
    border-radius: 4px;
    transition: all 0.3s ease-in-out;
    margin-right: 15px;
}

.contact .info-item h3 {
    padding: 0;
    font-size: 18px;
    font-weight: 700;
    margin-bottom: 5px;
}

.contact .info-item p {
    padding: 0;
    margin-bottom: 0;
    font-size: 14px;
}

.contact .php-email-form {
    height: 100%;
}

    .contact .php-email-form input[type=text],
    .contact .php-email-form input[type=email],
    .contact .php-email-form textarea {
        font-size: 14px;
        padding: 10px 15px;
        box-shadow: none;
        border-radius: 0;
        color: var(--default-color);
        background-color: color-mix(in srgb, var(--background-color), transparent 50%);
        border-color: color-mix(in srgb, var(--default-color), transparent 80%);
    }

        .contact .php-email-form input[type=text]:focus,
        .contact .php-email-form input[type=email]:focus,
        .contact .php-email-form textarea:focus {
            border-color: var(--accent-color);
        }

        .contact .php-email-form input[type=text]::placeholder,
        .contact .php-email-form input[type=email]::placeholder,
        .contact .php-email-form textarea::placeholder {
            color: color-mix(in srgb, var(--default-color), transparent 70%);
        }

    .contact .php-email-form button[type=submit] {
        color: var(--contrast-color);
        background: var(--accent-color);
        border: 0;
        padding: 10px 30px;
        transition: 0.4s;
        border-radius: 4px;
    }

        .contact .php-email-form button[type=submit]:hover {
            background: color-mix(in srgb, var(--accent-color), transparent 20%);
        }

/*--------------------------------------------------------------
# Portfolio Details Section
--------------------------------------------------------------*/
.portfolio-details .portfolio-details-slider img {
    width: 100%;
}

.portfolio-details .swiper-wrapper {
    height: auto;
}

.portfolio-details .swiper-button-prev,
.portfolio-details .swiper-button-next {
    width: 48px;
    height: 48px;
}

    .portfolio-details .swiper-button-prev:after,
    .portfolio-details .swiper-button-next:after {
        color: rgba(255, 255, 255, 0.8);
        background-color: rgba(0, 0, 0, 0.15);
        font-size: 24px;
        border-radius: 50%;
        width: 48px;
        height: 48px;
        display: flex;
        align-items: center;
        justify-content: center;
        transition: 0.3s;
    }

    .portfolio-details .swiper-button-prev:hover:after,
    .portfolio-details .swiper-button-next:hover:after {
        background-color: rgba(0, 0, 0, 0.3);
    }

@media (max-width: 575px) {

    .portfolio-details .swiper-button-prev,
    .portfolio-details .swiper-button-next {
        display: none;
    }
}

.portfolio-details .swiper-pagination {
    margin-top: 20px;
    position: relative;
}

    .portfolio-details .swiper-pagination .swiper-pagination-bullet {
        width: 10px;
        height: 10px;
        background-color: color-mix(in srgb, var(--default-color), transparent 85%);
        opacity: 1;
    }

    .portfolio-details .swiper-pagination .swiper-pagination-bullet-active {
        background-color: var(--accent-color);
    }

.portfolio-details .portfolio-info h3 {
    font-size: 22px;
    font-weight: 700;
    margin-bottom: 20px;
    padding-bottom: 20px;
    position: relative;
}

    .portfolio-details .portfolio-info h3:after {
        content: "";
        position: absolute;
        display: block;
        width: 50px;
        height: 3px;
        background: var(--accent-color);
        left: 0;
        bottom: 0;
    }

.portfolio-details .portfolio-info ul {
    list-style: none;
    padding: 0;
    font-size: 15px;
}

    .portfolio-details .portfolio-info ul li {
        display: flex;
        flex-direction: column;
        padding-bottom: 15px;
    }

    .portfolio-details .portfolio-info ul strong {
        text-transform: uppercase;
        font-weight: 400;
        color: color-mix(in srgb, var(--default-color), transparent 50%);
        font-size: 14px;
    }

.portfolio-details .portfolio-info .btn-visit {
    padding: 8px 40px;
    background: var(--accent-color);
    color: var(--contrast-color);
    border-radius: 50px;
    transition: 0.3s;
}

    .portfolio-details .portfolio-info .btn-visit:hover {
        background: color-mix(in srgb, var(--accent-color), transparent 20%);
    }

.portfolio-details .portfolio-description h2 {
    font-size: 26px;
    font-weight: 700;
    margin-bottom: 20px;
}

.portfolio-details .portfolio-description p {
    padding: 0;
}

.portfolio-details .portfolio-description .testimonial-item {
    padding: 30px 30px 0 30px;
    position: relative;
    background: color-mix(in srgb, var(--default-color), transparent 97%);
    margin-bottom: 50px;
}

    .portfolio-details .portfolio-description .testimonial-item .testimonial-img {
        width: 90px;
        border-radius: 50px;
        border: 6px solid var(--background-color);
        float: left;
        margin: 0 10px 0 0;
    }

    .portfolio-details .portfolio-description .testimonial-item h3 {
        font-size: 18px;
        font-weight: bold;
        margin: 15px 0 5px 0;
        padding-top: 20px;
    }

    .portfolio-details .portfolio-description .testimonial-item h4 {
        font-size: 14px;
        color: #6c757d;
        margin: 0;
    }

    .portfolio-details .portfolio-description .testimonial-item .quote-icon-left,
    .portfolio-details .portfolio-description .testimonial-item .quote-icon-right {
        color: color-mix(in srgb, var(--accent-color), transparent 50%);
        font-size: 26px;
        line-height: 0;
    }

    .portfolio-details .portfolio-description .testimonial-item .quote-icon-left {
        display: inline-block;
        left: -5px;
        position: relative;
    }

    .portfolio-details .portfolio-description .testimonial-item .quote-icon-right {
        display: inline-block;
        right: -5px;
        position: relative;
        top: 10px;
        transform: scale(-1, -1);
    }

    .portfolio-details .portfolio-description .testimonial-item p {
        font-style: italic;
        margin: 0 0 15px 0 0 0;
        padding: 0;
    }

/*--------------------------------------------------------------
# Service Details Section
--------------------------------------------------------------*/
.service-details .services-list {
    background-color: var(--surface-color);
    padding: 10px 30px;
    border: 1px solid color-mix(in srgb, var(--default-color), transparent 90%);
    margin-bottom: 20px;
}

    .service-details .services-list a {
        display: block;
        line-height: 1;
        padding: 8px 0 8px 15px;
        border-left: 3px solid color-mix(in srgb, var(--default-color), transparent 70%);
        margin: 20px 0;
        color: color-mix(in srgb, var(--default-color), transparent 20%);
        transition: 0.3s;
    }

        .service-details .services-list a.active {
            color: var(--heading-color);
            font-weight: 700;
            border-color: var(--accent-color);
        }

        .service-details .services-list a:hover {
            border-color: var(--accent-color);
        }

.service-details .services-img {
    margin-bottom: 20px;
}

.service-details h3 {
    font-size: 26px;
    font-weight: 700;
}

.service-details h4 {
    font-size: 20px;
    font-weight: 700;
}

.service-details p {
    font-size: 15px;
}

.service-details ul {
    list-style: none;
    padding: 0;
    font-size: 15px;
}

    .service-details ul li {
        padding: 5px 0;
        display: flex;
        align-items: center;
    }

    .service-details ul i {
        font-size: 20px;
        margin-right: 8px;
        color: var(--accent-color);
    }

/*--------------------------------------------------------------
# Arham CSS
--------------------------------------------------------------*/


/*-------- 5.1 Ribbons css --------*/
/* -------- Ribbon RTL ONLY -------- */
.ribbon_3 {
    position: absolute;
    right: 10px;
    top: -5px;
    z-index: 2;
    overflow: hidden;
    width: 75px;
    height: 75px;
}

    .ribbon_3 span {
        position: absolute;
        top: 19px;
        right: -21px;
        width: 100px;
        line-height: 20px;
        font-size: 10px;
        font-weight: bold;
        color: #fff;
        text-align: center;
        white-space: nowrap;
        direction: rtl;
        background: linear-gradient(#9BC90D 0%, #79A70A 100%);
        box-shadow: 0 3px 10px -5px rgba(0,0,0,1);
        text-shadow: 1px 1px 2px rgba(0,0,0,.25);
        transform: rotate(45deg);
    }

        /* ribbon edges */
        .ribbon_3 span::before {
            content: "";
            position: absolute;
            right: 0;
            top: 100%;
            z-index: -1;
            border-right: 3px solid #638908;
            border-left: 3px solid transparent;
            border-top: 3px solid #638908;
            border-bottom: 3px solid transparent;
        }

        .ribbon_3 span::after {
            content: "";
            position: absolute;
            left: 0;
            top: 100%;
            z-index: -1;
            border-left: 3px solid #638908;
            border-right: 3px solid transparent;
            border-top: 3px solid #638908;
            border-bottom: 3px solid transparent;
        }

    /* -------- State: died -------- */
    .ribbon_3.died span {
        background: #555;
        color: #f8f8f8;
    }

        .ribbon_3.died span::before,
        .ribbon_3.died span::after {
            border-top-color: #555;
            border-right-color: #555;
            border-left-color: #555;
        }

/* ===============================
   Arham Card (Match Screenshot)
   =============================== */
.arham-card {
    text-align: center;
    margin: auto; /* centers card inside column */
    width: 100%;
    max-width: 320px; /* optional: keeps cards uniform */
    position: relative;
    overflow: hidden;
}
/* ===============================
   ARHAMI CARD – BRAND WATERMARK
=============================== */

.arham-card {
    position: relative;
    overflow: hidden;
    background: #fff;
    border-radius: 18px;
}

    /* Brand watermark (logo in full color) */
    .arham-card::before {
        content: "";
        position: absolute;
        inset: -25%;
        background: url("/assets/img/arhami-logo/icon-1.png") center center no-repeat;
        background-size: 80%;
        opacity: 0.1; /* قوة ظهور الشعار */
        pointer-events: none;
        z-index: 1;
    }

    /* Keep all real content above watermark */
    .arham-card > * {
        position: relative;
        z-index: 2;
    }

    .arham-card .member-info {
        padding: 14px 12px 16px;
        text-align: center;
    }

/* Name */
.member-name {
    font-size: 16px;
    font-weight: 700;
    margin-bottom: 8px;
}

.member-actions {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 10px;
    margin-top: 18px;
    direction: rtl;
}

    .member-actions a {
        background: #dde3e1;
        color: #2F5F4E;
        padding: 10px 18px;
        border-radius: 14px;
        font-size: 15px;
        font-weight: 600;
        text-decoration: none;
        min-width: 90px;
        text-align: center;
        transition: all .2s ease;
    }

        .member-actions a:hover {
            background: #2F5F4E;
            color: #fff;
        }


.edit-link {
    background: #fff1dc;
    color: #b45309;
    border: 1px dashed #f59e0b;
    padding: 5px 5px 5px 5px;
}

@media (max-width: 768px) {
    .arham-card {
        max-width: 360px;
    }

    .team-member img {
        max-height: 120px;
        object-fit: contain;
    }
}

/* ===============================
   Clear Number Badge
   =============================== */
.children-count {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 14px;
    font-size: 18px;
    font-weight: 600;
}

    /* Male / Female blocks */
    .children-count .child {
        display: inline-flex;
        align-items: center;
    }

    /* Icons */
    .children-count i {
        /*font-size: 16px;*/
        line-height: 1;
    }

    /* Separator */
    .children-count .separator {
        color: #c3cbd6;
        font-weight: 400;
        gap: 6px;
    }


.number {
    font-family: Arial, sans-serif;
    font-variant-numeric: tabular-nums;
    letter-spacing: 0.5px;
}

/* Mobile */
@media (max-width: 576px) {
    .member-actions {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* ===============================
   jQuery UI Autocomplete – Arham
   =============================== */

.ui-autocomplete {
    direction: rtl;
    text-align: right;
    font-family: var(--default-font) !important;
    font-size: 15px;
    background: #ffffff;
    border-radius: 10px;
    border: 1px solid #e6eef6;
    box-shadow: 0 10px 30px rgba(0,0,0,.12);
    padding: 6px;
    z-index: 9999 !important;
}

/* Each item */
.ui-menu-item {
    margin: 0;
}

/* Item content */
.ui-menu-item-wrapper {
    padding: 10px 14px;
    cursor: pointer;
    border-radius: 6px;
    transition: background .2s ease;
    color: var(--default-color);
}

    /* Hover / active */
    .ui-menu-item-wrapper.ui-state-active {
        background: var(--accent-color);
        color: #fff;
    }

/* Remove default jQuery UI styles */
.ui-widget,
.ui-widget-content {
    border: none;
}

/* Scroll for large results */
.ui-autocomplete {
    max-height: 260px;
    overflow-y: auto;
    overflow-x: hidden;
}
/* ==========================
   Header Auth CSS
   ========================== */

.header .btn-getstarted {
    color: var(--contrast-color);
    background: var(--accent-color);
    font-size: 14px;
    padding: 8px 25px;
    border-radius: 4px;
    transition: background .3s ease;
    text-decoration: none;
}

    /* Hover & focus */
    .header .btn-getstarted:hover,
    .header .btn-getstarted:focus {
        color: var(--contrast-color);
        background: color-mix(in srgb, var(--accent-color), transparent 15%);
        outline: none;
    }

/* Remove default spacing conflicts */
.header .btn-getstarted {
    margin: 0;
}

/* profile */


.person-card {
    display: block;
    padding: 12px;
    border-radius: 10px;
    background: #fff;
    box-shadow: 0 1px 6px rgba(0,0,0,.05);
    text-decoration: none;
}


.person-link {
    display: block;
    padding: 6px 0;
    text-decoration: none;
}

.person-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 6px 0;
}

.person-link {
    font-weight: 500;
    text-decoration: none;
}

    .person-link.male {
        color: #1e6fff;
    }

    .person-link.female {
        color: #e83e8c;
    }

.relation-icons {
    display: flex;
    gap: 6px;
    font-size: 16px;
    white-space: nowrap;
}


.badge {
    font-size: 11px;
    padding: 2px 8px;
    border-radius: 12px;
}

.badge-sibling {
    background: #fff6d8;
    color: #9a7b00;
}

.badge-father {
    background: #e8f1ff;
    color: #1e6fff;
}

.badge-mother {
    background: #ffecec;
    color: #e55353;
}

.count-pill {
    margin-inline-start: 6px;
    padding: 2px 8px;
    border-radius: 12px;
    font-size: 12px;
}

    .count-pill.male {
        background: #e8f1ff;
        color: #1e6fff;
    }

    .count-pill.father {
        background: #eef3ff;
        color: #4c6ef5;
    }

    .count-pill.mother {
        background: #ffecec;
        color: #e55353;
    }

.card.mb-3 {
    border-left: 4px solid var(--accent-color);
}

.text-danger .card {
    border-left-color: #e55353;
}

/* Accordions */
.accordion-item {
    background: #ffffff;
    border-radius: 12px;
    border: 1px solid #e9edf3;
    overflow: hidden;
}

.accordion-button {
    /*background: #f8fafc;*/
    font-weight: 600;
}

    .accordion-button:not(.collapsed) {
        /*background: #eef4ff;*/
        color: var(--accent-color);
    }

.recordedby-card {
    background: #f8fbfa;
    border: 1px solid #e2ece7;
    border-radius: 14px;
    padding: 12px 16px;
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 14px;
    color: #2f3e39;
}

    .recordedby-card i {
        font-size: 18px;
        color: var(--accent-color);
    }

.recordedby-name {
    font-weight: 700;
    color: var(--accent-color);
    text-decoration: none;
}

    .recordedby-name:hover {
        text-decoration: underline;
    }

/* All Cards */
.card,
.person-card,
.stat-card {
    background: white;
    border-radius: 16px;
    padding: 18px 10px;
    font-weight: 700;
    font-size: 22px;
    box-shadow: 0 8px 24px rgba(0,0,0,.04);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

    .stat-card span {
        font-size: 13px;
        font-weight: 600;
        opacity: .7;
        margin-top: 6px;
    }


    .card:hover,
    .person-card:hover {
        transform: translateY(-2px);
        box-shadow: 0 10px 26px rgba(0,0,0,.08);
    }

/* ===== PROFILE META ===== */
.profile-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 14px;
    padding: 10px 14px;
    background: #f8fbfa;
    border-radius: 14px;
    font-size: 16px;
    gap: 12px;
}

.meta-item {
    display: flex;
    align-items: center;
    gap: 6px;
    color: #6c7f78;
    font-weight: 600;
}

    .meta-item i {
        color: var(--accent-color);
        font-size: 14px;
    }

.meta-actions {
    display: flex;
    gap: 10px;
}

.meta-btn {
    display: flex;
    align-items: center;
    gap: 6px;
    background: #ffffff;
    border: 1px solid #e2ece7;
    border-radius: 10px;
    padding: 6px 12px;
    font-size: 16px;
    font-weight: 700;
    color: #2f3e39;
    transition: .2s;
}

    .meta-btn i {
        color: var(--accent-color);
    }

    .meta-btn:hover {
        background: var(--accent-color);
        color: white;
    }

        .meta-btn:hover i {
            color: white;
        }

/* ===== SIBLING CARD (TEXT ONLY) ===== */
.sibling-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    background: #ffffff;
    border-radius: 14px;
    padding: 14px 12px 10px;
    text-decoration: none;
    box-shadow: 0 6px 18px rgba(0,0,0,.04);
    transition: .2s;
    min-width: 120px;
}

    .sibling-card:hover {
        transform: translateY(-3px);
        box-shadow: 0 10px 26px rgba(0,0,0,.08);
    }

/* Name */
.sibling-name {
    font-size: 14px;
    font-weight: 700;
    color: #2F3E39;
    text-align: center;
    margin-bottom: 6px;
}

/* Locked badge under name */
.sibling-type {
    font-size: 11px;
    font-weight: 700;
    padding: 4px 10px;
    border-radius: 999px;
    background: #f3f5f4;
    color: #6c7f78;
}

    /* Type colors */
    .sibling-type.full {
        background: rgba(47,95,78,.12);
        color: var(--accent-color);
    }

    .sibling-type.father {
        background: rgba(110,159,211,.15);
        color: #3b6ea8;
    }

    .sibling-type.mother {
        background: rgba(227,160,181,.15);
        color: #b5526f;
    }

/* Gender border */
.sibling-card.male {
    border-top: 4px solid #6E9FD3;
}

.sibling-card.female {
    border-top: 4px solid #E3A0B5;
}

/* ===== ARHAMI LANDING ===== */

.arhami-intro {
    background: #f9f7f4;
}

/* FAMILY LIST */
.landing-families {
    padding: 20px 0 10px;
}

.families-mobile-list {
    display: flex;
    flex-direction: column;
    gap: 14px;
    align-items: center; /* center cards */
}

.family-mobile-row {
    display: flex;
    align-items: center;
    width: 100%;
    max-width: 420px;
    background: white;
    border-radius: 18px;
    padding: 14px 18px;
    text-decoration: none;
    color: inherit;
    box-shadow: 0 6px 20px rgba(0,0,0,.04);
    transition: all .25s ease;
}

    .family-mobile-row:hover {
        box-shadow: 0 12px 30px rgba(0,0,0,.08);
        transform: translateY(-2px);
    }

.family-mobile-left {
    width: 44px;
    height: 44px;
    border-radius: 12px;
    background: rgba(0,0,0,.04);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
    color: var(--accent-color);
    margin-left: 14px;
}

.family-mobile-body {
    flex: 1;
    text-align: right;
}

.family-mobile-name {
    font-weight: 700;
    font-size: 15px;
    color: #2f2f2f;
}

.family-mobile-arrow {
    font-size: 18px;
    color: #bbb;
}

/* Desktop grid */
@media (min-width: 992px) {
    .families-mobile-list {
        display: grid;
        grid-template-columns: repeat(3, minmax(220px, 1fr));
        justify-content: center;
        gap: 18px;
    }

    .family-mobile-row {
        max-width: none;
    }
}

.login-card {
    max-width: 420px;
    width: 100%;
    background: #fff;
}

.btn-google {
    background: #fff;
    border: 1px solid #ddd;
    color: #444;
    border-radius: 12px;
    transition: all .2s ease;
}

    .btn-google:hover {
        background: #f5f5f5;
        border-color: var(--accent-color);
        color: var(--accent-color);
        transform: translateY(-1px);
    }

.min-vh-75 {
    min-height: 75vh;
}
/* ===== Trees ===== */

.tree-area {
    position: relative;
    height: 100%;
}

.profile-view-tree {
    height: 100vh;
    display: flex;
    flex-direction: column;
}


.tree-container {
    flex: 1;
    display: flex;
    flex-direction: column;
    padding-inline: 20px;
}

/* header ثابت */
.profile-header {
    flex-shrink: 0;
    margin-bottom: 12px;
}

/* المنطقة التي تحتوي الشجرة */
.tree-area {
    flex: 1;
    position: relative;
    min-height: 0;
}

/* ===== Tree ===== */

#arhamTree {
    width: 100%;
    height: 100%;
    background: #f7f9fb;
    border-radius: 14px;
    box-shadow: 0 6px 20px rgba(0,0,0,.06);
}

    /* smooth canvas */
    #arhamTree canvas {
        outline: none;
    }

/* ===== Floating toolbar ===== */

.tree-toolbar {
    position: absolute;
    top: 14px;
    right: 14px;
    z-index: 10;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

    .tree-toolbar button {
        width: 40px;
        height: 40px;
        border: none;
        border-radius: 50%;
        background: var(--heading-color);
        color: #fff;
        font-size: 18px;
        cursor: pointer;
        box-shadow: 0 6px 14px rgba(0,0,0,.25);
        transition: .15s;
    }

        .tree-toolbar button:hover {
            transform: scale(1.08);
        }

        .tree-toolbar button:active {
            transform: scale(.92);
        }

/* ===== Mobile ===== */

@media(max-width:768px) {
    #arhamTree {
        border-radius: 0;
    }

    .tree-toolbar {
        right: 10px;
        top: 10px;
    }
}

#myDiagramDiv {
    background: #f8f9fa;
    border-radius: 12px;
    padding: 12px;
}

/* Base node card */
.person-card {
    border-radius: 10px;
    padding: 8px 10px;
    min-width: 120px;
    box-shadow: 0 2px 6px rgba(0,0,0,.08);
    font-family: 'Segoe UI', sans-serif;
    box-shadow: 0 2px 6px rgba(0,0,0,.08);
}

    /* Male / Female (استخدم الموجود عندك لو مختلف) */
    .person-card.male {
        background: var(--male-bg, #e3f2fd);
        border-right: 4px solid var(--male-border, #2196f3);
    }

    .person-card.female {
        background: var(--female-bg, #fce4ec);
        border-right: 4px solid var(--female-border, #e91e63);
    }

.person-name {
    font-weight: 600;
    font-size: 13px;
    text-align: center;
}

.person-status {
    font-size: 11px;
    text-align: center;
    color: #555;
}

.country-tile {
    background: var(--background-color);
    border-radius: 20px;
    overflow: hidden;
    box-shadow: 0 10px 30px rgba(0,0,0,.06);
    transition: .3s ease;
    height: 340px;
    display: flex;
    flex-direction: column;
}

    .country-tile:hover {
        transform: translateY(-6px);
        box-shadow: 0 20px 45px rgba(0,0,0,.12);
    }

/* FLAG AREA */
.country-flag-box {
    height: 150px;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    flex-shrink: 0;
    position: relative;
}

/* Soft overlay over flag */
.country-flag-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient( to bottom, rgba(0,0,0,.25), rgba(0,0,0,.05) );
}

/* BODY */
.country-body {
    flex: 1;
    padding: 18px 12px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    background: linear-gradient( to bottom, rgba(255,255,255,.92), rgba(245,248,247,.9) );
}

    .country-body .count {
        font-size: 38px;
        font-weight: 900;
        line-height: 1;
        margin-bottom: 6px;
    }

    .country-body .name {
        font-size: 18px;
        font-weight: 800;
        color: var(--accent-color);
        max-width: 90%;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
    }

/* =============================
   COUNTRY PAGE (Scoped)
============================= */

.country-page {
    max-width: 720px;
    margin: auto;
    padding: 10px;
}

    /* Header */
    .country-page .country-header {
        display: flex;
        justify-content: space-between;
        align-items: center;
        background: #fff;
        border-radius: 18px;
        padding: 18px 22px;
        margin-bottom: 18px;
        box-shadow: 0 8px 25px rgba(0,0,0,.05);
    }

    .country-page .country-title {
        font-size: 20px;
        font-weight: 800;
        color: var(--accent-color);
        display: flex;
        align-items: center;
        gap: 10px;
    }

        .country-page .country-title .fi {
            font-size: 26px;
        }

    /* List */
    .country-page .people-list {
        background: #fff;
        border-radius: 18px;
        box-shadow: 0 10px 30px rgba(0,0,0,.05);
        overflow: hidden;
    }

    /* Rows */
    .country-page .person-row {
        display: flex;
        justify-content: space-between;
        align-items: center;
        padding: 14px 20px;
        border-bottom: 1px solid #eef1f4;
        font-size: 15px;
        transition: .2s ease;
    }

        .country-page .person-row:hover {
            background: #f8fbfa;
        }

    .country-page .person-arrow {
        font-size: 18px;
        color: var(--accent-color);
        opacity: .6;
    }

/* Country person card */
.country-person-card {
    border-bottom: 1px solid #eef1f4;
}

    .country-person-card:last-child {
        border-bottom: none;
    }

/* 3 dots button */
.country-page .toggle-actions {
    background: transparent;
    border: none;
    font-size: 22px;
    cursor: pointer;
    color: var(--accent-color);
}

/* hide by default */
.country-page .country-actions {
    display: none;
    padding: 10px 14px 14px;
    background: #f8fbfa;
    border-top: 1px solid #e6ecea;
}

/* when open */
.country-person-card.active .country-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.country-search {
    position: relative;
    margin-bottom: 14px;
}

    .country-search input {
        width: 100%;
        border-radius: 14px;
        padding: 12px 44px 12px 16px;
        border: 1px solid #e2ece7;
        background: #fff;
        font-size: 15px;
        outline: none;
        box-shadow: 0 4px 18px rgba(0,0,0,.04);
    }

    .country-search i {
        position: absolute;
        right: 16px;
        top: 50%;
        transform: translateY(-50%);
        color: #9fb3ad;
        font-size: 18px;
    }

.country-person-card {
    border-bottom: 1px solid #eef1f4;
}

.person-main {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.toggle-btn {
    background: transparent;
    border: none;
    font-size: 20px;
    color: #9fb3ad;
    cursor: pointer;
}

.country-person-card .member-actions {
    display: none;
    padding: 12px 22px 18px;
    background: #f8fbfa;
}

.country-person-card.active .member-actions {
    display: flex;
}

.country-actions {
    gap: 10px;
    flex-wrap: wrap;
}

.country-header.enhanced {
    background: #fff;
    border-radius: 20px;
    padding: 28px 30px;
    margin-bottom: 22px;
    box-shadow: 0 12px 30px rgba(0,0,0,.06);
    display: flex;
    justify-content: center;
    align-items: center;
    text-align: center;
}

.country-title-wrap {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 6px;
}

.country-name {
    font-size: 20px;
    font-weight: 900;
    color: var(--accent-color);
    line-height: 1.2;
}

.country-count {
    font-size: 34px;
    font-weight: 700;
    color: #7a8b85;
}

.country-flag-box {
    width: 100%;
    height: 140px;
    border-radius: 18px 18px 0 0;
}

.country-breadcrumb {
    margin-bottom: 14px;
    font-size: 14px;
    color: #7a8b85;
}

    .country-breadcrumb a {
        color: var(--accent-color);
        font-weight: 600;
        text-decoration: none;
    }

    .country-breadcrumb span {
        margin: 0 6px;
        color: #b5c3be;
    }
    .flag-box {
    width: 100%;
    aspect-ratio: 3 / 2;
    background-size: cover;
    background-position: center;
    border-radius: 8px;
    position: relative;
}

.flag-fallback {
    background: linear-gradient(135deg, #e9f3ef, #f7faf9);
    display: flex;
    align-items: center;
    justify-content: center;
}

.flag-fallback::after {
    content: "🌍";
    font-size: 48px;
    opacity: .4;
}
