/* Basic styles for Dynamic Homepage Blocks */
/* Palette:
   #3f4144 (primary text / dark)
   #FFFFFF (white)
   #f7f5f3 (soft background)
   #A3A19D (accent)
*/

.dhb-block {
    box-sizing: border-box;
    margin: 1.5rem 0;
    padding: 1.5rem;
    border-radius: var(--dhb-radius, 0px);
    background: var(--dhb-bg, #ffffff);
    color: var(--dhb-text, #3f4144);
    box-shadow: 0 8px 18px rgba(0,0,0,0.05);
}

/* Links inside blocks: no underlines in boxes */
.dhb-block a,
.dhb-block a:hover,
.dhb-block a:focus {
    text-decoration: none;
}

/* Buttons */
.dhb-btn {
    display: inline-block;
    margin-top: 0.75rem;
    padding: 0.7rem 1.6rem;
    border-radius: 0;
    text-decoration: none;
    background: #3f4144;
    color: #ffffff;
    font-weight: 600;
    font-family: 'Archivo', system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    text-transform: uppercase;
    letter-spacing: 0.03em;
    font-size: 0.9rem;
    transition: transform 0.15s ease, box-shadow 0.15s ease, background 0.15s ease;
}
.dhb-btn:hover {
    background: #A3A19D;
    box-shadow: 0 6px 14px rgba(0,0,0,0.15);
    transform: translateY(-1px);
}

/* Event block */
.dhb-event-block {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
}
.dhb-event-image {
    flex: 1 1 260px;
    min-height: 180px;
    border-radius: var(--dhb-radius, 0px);
    background-size: cover;
    background-position: center;
}
.dhb-event-content {
    flex: 2 1 300px;
}
.dhb-event-title {
    margin-top: 0;
    margin-bottom: 0.4rem;
}
.dhb-event-location {
    font-weight: 600;
    margin-bottom: 0.5rem;
    color: #A3A19D;
}

/* CTA block */
.dhb-cta-block {
    text-align: left;
}
.dhb-cta-title {
    margin-top: 0;
}
.dhb-cta-subtitle p:last-child {
    margin-bottom: 0;
}

/* Hero block */
.dhb-hero-block {
    position: relative;
    padding: 3.5rem 1.5rem;
    overflow: hidden;
    color: #3f4144;
    background: #f7f5f3;
}
.dhb-hero-bg {
    position: absolute;
    inset: 0;
    background-size: cover;
    background-position: center;
    z-index: 1;
}
.dhb-hero-overlay {
    position: absolute;
    inset: 0;
    z-index: 2;
}
.dhb-hero-content {
    position: relative;
    z-index: 3;
    max-width: 800px;
}
.dhb-hero-title {
    margin-top: 0;
    font-size: 2.3rem;
}
.dhb-hero-subheadline {
    font-size: 1.1rem;
    max-width: 36rem;
}

/* Countdown */
.dhb-countdown-block {
    text-align: center;
}
.dhb-countdown-bar {
    text-align: left;
}
.dhb-countdown-label {
    font-weight: 600;
    margin-bottom: 0.5rem;
}
.dhb-countdown-timer {
    font-family: monospace;
    font-size: 1.1rem;
}

/* Case studies grid (layout A: 3-column, mobile friendly) */
.dhb-case-grid-block {
    box-shadow: none;
    padding: 0;
    background: transparent;
}
.dhb-case-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 22px;
}
.dhb-case-card {
    background: #ffffff;
    border: 1px solid rgba(0,0,0,0.06);
    box-shadow: 0 2px 6px rgba(0,0,0,0.06);
    display: flex;
    flex-direction: column;
}
.dhb-case-image {
    width: 100%;
    height: 200px;
    overflow: hidden;
}
.dhb-case-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}
.dhb-case-title {
    font-size: 1rem;
    padding: 0.85rem 1rem 1rem;
    margin: 0;
}

/* Prevent boxes changing colour on hover (no background change on cards) */
.dhb-case-card:hover {
    background: #ffffff;
}

/* Responsive tweaks */
@media (max-width: 1024px) {
    .dhb-event-block {
        flex-direction: column;
    }

    .dhb-hero-block {
        padding: 2.5rem 1.25rem;
    }

    .dhb-case-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 640px) {
    .dhb-case-grid {
        grid-template-columns: 1fr;
    }
}
