/* ===============================
   Page: Property Details
   Scope: .page-details
   =============================== */

.page-details {
    --bg: #f5f6fa;
    --card: #ffffff;
    --primary: #3498db;
    --primary-hover: #2980b9;
    --accent: #27ae60;
    --accent-hover: #1e8449;
    --muted: #7f8c8d;

    background: linear-gradient(135deg, #f8f9fb, #edf1f5);
    color: #2c3e50;
    font-family: 'Inter', sans-serif;
    min-height: 100vh;
    padding: 0;
}

/* Global-ish but scoped */
.page-details * {
    box-sizing: border-box;
}

.page-details a {
    text-decoration: none;
    transition: .25s;
    color: inherit;
}

/* ===============================
   Layout
   =============================== */

.page-details .super-container {
    max-width: 1240px;
    margin: 0 auto;
    padding: 0 16px;
}

.page-details .container {
    display: flex;
    align-items: flex-start;
    gap: 24px;
}

@media (max-width:900px) {
    .page-details .container {
        flex-direction: column;
    }
}

.page-details .left-column,
.page-details .right-column {
    flex: 1 1 350px;
    display: flex;
    flex-direction: column;
    gap: 0;
}

/* ===============================
   House Card
   =============================== */

.page-details .house-wrapper {
    background: var(--card);
    border-radius: 16px;
    overflow: hidden;
    background: transparent;
}

.page-details .house-card {
    width: 100%;
    height: 640px;
    padding: 0;
}

.page-details .house-card img {
    width: 100%;
    height: 420px;
    object-fit: cover;
    display: block;
    margin: 0;
}

.page-details .card-content {
    padding: 16px 16px 20px;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.page-details .price-row {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
}

.page-details .price {
    font-size: 1.6rem;
    font-weight: 800;
}

.page-details .price-per-m2 {
    font-size: 0.9rem;
    color: var(--muted);
}

.page-details .address {
    font-weight: 600;
}

.page-details .meta {
    font-size: .95rem;
    color: var(--muted);
    line-height: 1.45;
}

.page-details .lifecycle-label {
    margin: 0;
}

/* ===============================
   Buttons
   =============================== */

.page-details .buttons-row {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

.page-details .view-link {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 10px;
    background: var(--primary);
    color: #fff;
    border-radius: 6px;
    font-size: 0.9rem;
    font-weight: 600;
}

.page-details .view-link:hover {
    background: var(--primary-hover);
}


/* ===============================
   Timeline
   =============================== */

.page-details .timeline {
    background: var(--card);
    border-radius: 16px;
    box-shadow: 0 10px 25px rgba(0, 0, 0, .12);
    padding: 20px;
    height: 640px;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.page-details .timeline-wrapper {
    max-height: 500px;
    display: flex;
    flex-direction: column;
    overflow-y: auto;
    scroll-behavior: smooth;
    scrollbar-width: thin;      /* Firefox */
    scrollbar-color: #888 #f1f1f1; /* thumb color, track color */
}

/* Chrome, Edge, Safari */
.page-details .timeline-wrapper::-webkit-scrollbar {
    width: 8px;                 /* width of scrollbar */
}

.page-details .timeline-wrapper::-webkit-scrollbar-track {
    background: #f1f1f1;        /* track color */
    border-radius: 8px;
}

.page-details .timeline-wrapper::-webkit-scrollbar-thumb {
    background-color: #888;     /* thumb color */
    border-radius: 8px;
    border: 2px solid #f1f1f1; /* space around thumb */
}

.page-details .timeline-item {
    position: relative;
    padding-left: 30px;
    margin-bottom: 20px;
}

.page-details .timeline-item::before {
    content: "";
    position: absolute;
    left: 15px;
    top: 8px;
    bottom: -40px;
    width: 2px;
    background: #e0e0e0;
}

.page-details .timeline-item:last-child::before {
    display: none;
}

.page-details .timeline-dot {
    position: absolute;
    left: 10px;
    top: 5px;
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: #4CAF50;
    border: 2px solid #fff;

}

.page-details .timeline-date {
    font-size: 0.85rem;
    color: #6b7280;
    margin-bottom: 4px;
}

.page-details .timeline-content {
    background: #f9fafb;
    padding: 0.75rem 1rem;
    border-radius: 8px;
}

.page-details .timeline-action {
    font-weight: 600;
}

.page-details .timeline-value {
    display: inline-block;
    margin-top: 4px;
    background: #e0f2fe;
    padding: 2px 6px;
    border-radius: 4px;
    font-size: 0.85rem;
}

.page-details .timeline-item.hidden {
    display: none;
}

.page-details .timeline-toggle {
    margin-top: 10px;
    background: none;
    border: 1px solid #ccc;
    padding: 6px 12px;
    border-radius: 6px;
    cursor: pointer;
}

/* ===============================
   Nearby Properties
   =============================== */

.page-details .nearby {
    margin-top: 3rem;
}

.page-details .nearby-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 16px;
    max-width: 600px;
}

.page-details .nearby-card {
    background: #fff;
    border-radius: 8px;
    padding: 8px;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.1);
    display: flex;
    gap: 8px;
    align-items: center;
    transition: box-shadow 0.25s;
}

.page-details .nearby-card:hover {
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
}

.page-details .nearby-thumb img {
    width: 60px;
    height: 45px;
    object-fit: cover;
    border-radius: 4px;
}

.page-details .nearby-info {
    font-size: 0.9rem;
}

.page-details .nearby-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 4px;
}

.page-details .meta-item {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    background: #f5f5f5;
    border-radius: 12px;
    padding: 3px 8px;
    font-size: 0.8rem;
}

/* Responsive tweaks */
@media (max-width:900px) {
    .page-details .container {
        flex-direction: column;
    }

    .page-details .nearby-grid {
        grid-template-columns: 1fr;
    }
}

.timeline-note {
    display: inline-block;
    padding: 3px 8px;
    /* slightly more padding */
    background-color: #eaf1fb;
    /* soft light-blue background */
    color: #1a73e8;
    /* matching text color */
    border: 1px solid #c5d7f2;
    /* subtle border for badge */
    border-radius: 12px;
    /* pill shape */
    font-size: 0.85em;
    font-style: normal;
    /* remove italics for badge */
    font-weight: 500;
}