/* =====================================================================
   ANA SƏHİFƏ "KOMPLEKSLƏR" KARTI — project_view.php-dəki zəngin dizayn
   sisteminin ana səhifə üçün uyğunlaşdırılmış versiyası (karusel yoxdur,
   çünki ana səhifə sorğusu hər layihə üçün yalnız 1 şəkil gətirir).
   DİQQƏT: bu, ÖZ-ÖZLÜYÜNDƏ tam kart dizaynıdır (".card" ilə paylaşılan
   heç nə yoxdur) — adi elan kartlarına təsir etmir.
===================================================================== */
.home-project-card {
    --hp-paper:       #F8F9Fa;
    --hp-surface:     #FFFFFF;
    --hp-ink:         #182530;
    --hp-ink-soft:    #64707C;
    --hp-brass:       #A9814C;
    --hp-brass-deep:  #8A6A3D;
    --hp-ready:       #2F6F5E;
    --hp-line:        #E2DFD6;
    --hp-line-strong: #CFCABC;

    position: relative;
    display: flex;
    flex-direction: column;
    width: 100%;
    height: 370px;
    background: var(--hp-surface);
    border: 1px solid var(--hp-line);
    border-radius: 3px;
    overflow: hidden;
    text-decoration: none;
    transition: transform 0.35s cubic-bezier(.2,.8,.2,1), box-shadow 0.35s ease, border-color 0.35s ease;
    will-change: transform;
}

.home-project-card:hover,
.home-project-card:focus-within {
    transform: translateY(-6px);
    border-color: var(--hp-line-strong);
    box-shadow: 0 22px 34px -18px rgba(24,37,48,0.35);
}

.home-project-card .corner-mark {
    position: absolute;
    width: 18px;
    height: 18px;
    border: 2px solid rgba(255,255,255,0.85);
    opacity: 0.75;
    transition: width 0.35s ease, height 0.35s ease, opacity 0.35s ease;
    z-index: 2;
    pointer-events: none;
}

.home-project-card .corner-mark.tl { top: 12px; left: 12px; border-right: none; border-bottom: none; }
.home-project-card .corner-mark.br { bottom: 12px; right: 12px; border-left: none; border-top: none; }

.home-project-card:hover .corner-mark,
.home-project-card:focus-within .corner-mark {
    width: 26px;
    height: 26px;
    opacity: 1;
}

.home-project-card .media-frame {
    position: relative;
    height: 190px;
    flex-shrink: 0;
    overflow: hidden;
    background: var(--hp-ink);
}

.home-project-card .media-frame::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg, rgba(0,0,0,0.28) 0%, rgba(0,0,0,0) 30%, rgba(0,0,0,0) 65%, rgba(0,0,0,0.35) 100%);
    pointer-events: none;
    z-index: 1;
}

.home-project-card .media-frame img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.6s cubic-bezier(.2,.8,.2,1);
}

.home-project-card:hover .media-frame img,
.home-project-card:focus-within .media-frame img {
    transform: scale(1.06);
}

.home-project-card .delivery-stamp {
    position: absolute;
    top: 14px;
    left: 14px;
    z-index: 2;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: rgba(255,255,255,0.94);
    color: var(--hp-ready);
    font-weight: 600;
    font-size: 0.72rem;
    letter-spacing: 0.02em;
    padding: 5px 10px 5px 8px;
    border-radius: 2px;
    box-shadow: 0 4px 10px rgba(0,0,0,0.18);
}

.home-project-card .delivery-stamp i {
    font-size: 0.85rem;
}

.home-project-card .card-body {
    padding: 14px 16px 0 16px;
    flex: 1 1 auto;
    min-height: 0;
}

.home-project-card .card-title {
    font-weight: 600;
    font-size: 1.05rem;
    line-height: 1.25;
    margin: 0 0 6px;
    color: var(--hp-ink);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.home-project-card .address {
    font-size: 0.8rem;
    color: var(--hp-ink-soft);
    margin: 0;
    display: flex;
    align-items: baseline;
    gap: 5px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.home-project-card .address i {
    color: var(--hp-brass);
    flex-shrink: 0;
}

.home-project-card .stat-strip {
    display: flex;
    align-items: stretch;
    flex-shrink: 0;
    margin: 10px 16px 0 16px;
    border-top: 1px solid var(--hp-line);
}

.home-project-card .stat-strip > div {
    flex: 1;
    padding: 8px 0;
    min-width: 0;
}

.home-project-card .stat-strip > div:first-child {
    border-right: 1px solid var(--hp-line);
    padding-right: 10px;
}

.home-project-card .stat-strip > div:last-child {
    padding-left: 10px;
}

.home-project-card .stat-label {
    display: block;
    font-size: 0.62rem;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: var(--hp-ink-soft);
    margin-bottom: 2px;
}

.home-project-card .stat-value {
    font-size: 0.88rem;
    font-weight: 500;
    color: var(--hp-ink);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.home-project-card .stat-value.price {
    color: var(--hp-brass-deep);
}

.home-project-card .card-footer-row {
    z-index: 2;
    flex-shrink: 0;
    padding: 8px 10px 12px 16px;
    display: flex;
    align-items: center;
}

.home-project-card .view-link {
    position: relative;
    z-index: 2;
    font-size: 0.78rem;
    font-weight: 600;
    color: var(--hp-ink);
    display: inline-flex;
    align-items: center;
    gap: 6px;
    text-decoration: none;
}

.home-project-card .view-link i {
    transition: transform 0.25s ease;
    color: var(--hp-brass-deep);
}

.home-project-card:hover .view-link i,
.home-project-card:focus-within .view-link i {
    transform: translateX(4px);
}

/* "Stretched link" — bütün kart klikə bilən olsun */
.home-project-card .stretched-link::after {
    content: "";
    position: absolute;
    inset: 0;
    z-index: 1;
}

@media (prefers-reduced-motion: reduce) {
    .home-project-card,
    .home-project-card .media-frame img,
    .home-project-card .corner-mark,
    .home-project-card .view-link i {
        transition: none !important;
    }
}