/* ==========================================================================
   Startseite Projekte Kacheln Element (Design matching index.html)
   ========================================================================== */

.startseite-projekte-wrapper {
    width: 100%;
    margin: 0 auto;
    box-sizing: border-box;
    font-family: var(--body_typography-font-family, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen, Ubuntu, Cantarell, "Open Sans", "Helvetica Neue", sans-serif);
    color: #333333;
}

/* Grid */
.startseite-projekte-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 32px;
    width: 100%;
    box-sizing: border-box;
}

.startseite-projekte-grid.cols-1 {
    grid-template-columns: 1fr;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

.startseite-projekte-grid.cols-2 {
    grid-template-columns: repeat(2, 1fr);
}

.startseite-projekte-grid.cols-3 {
    grid-template-columns: repeat(3, 1fr);
}

.startseite-projekte-grid.cols-4 {
    grid-template-columns: repeat(4, 1fr);
}

/* Card */
.startseite-projekt-kachel {
    text-decoration: none !important;
    color: inherit !important;
    background: #ffffff;
    border: 1px solid #ece8e2;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 2px 16px rgba(0, 0, 0, 0.05);
    display: flex;
    flex-direction: column;
    transition: transform 0.24s cubic-bezier(0.34, 1.4, 0.64, 1), box-shadow 0.24s ease;
    box-sizing: border-box;
    cursor: pointer;
    will-change: transform, box-shadow;
}

.startseite-projekt-kachel:hover {
    transform: translateY(-5px);
    box-shadow: 0 14px 34px rgba(0, 0, 0, 0.12);
    text-decoration: none !important;
    color: inherit !important;
}

/* Image Wrap */
.kachel-image-wrap {
    position: relative;
    aspect-ratio: 3 / 2;
    background-color: #f4efe9;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #8a8378;
    font-size: 14px;
    letter-spacing: 0.04em;
    overflow: hidden;
}

.kachel-image-wrap img,
.kachel-image-wrap .kachel-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.3s ease;
}

.startseite-projekt-kachel:hover .kachel-image-wrap img {
    transform: scale(1.03);
}

.kachel-image-placeholder {
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, #ede6dd 0%, #ddd5ca 100%);
}

/* Badge */
.kachel-badge {
    position: absolute;
    top: 14px;
    left: 14px;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 12px;
    border-radius: 50px;
    font-size: 12px !important;
    font-weight: 700 !important;
    letter-spacing: 0.05em !important;
    font-family: var(--body_typography-font-family, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif) !important;
    line-height: 1;
    text-transform: uppercase;
    z-index: 2;
}

.kachel-badge svg {
    vertical-align: -0.15em;
}

.kachel-badge.badge-idee {
    background: #fbeec2;
    color: #9a7b1a;
}

.kachel-badge.badge-projekt {
    background: #d6f0dd;
    color: #2e7d46;
}

.kachel-badge.badge-erfolgsgeschichte,
.kachel-badge.badge-erfolg {
    background: #ece2f6;
    color: #6b46a8;
}

/* Content */
.kachel-content {
    padding: 28px 26px 32px;
    display: flex;
    flex-direction: column;
    flex: 1;
    box-sizing: border-box;
    background: #ffffff;
}

.kachel-title {
    margin: 0 0 12px !important;
    font-family: var(--h3_typography-font-family, var(--headings_typography-font-family, var(--h1_typography-font-family, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif))) !important;
    font-weight: 700 !important;
    font-size: 22px !important;
    line-height: 1.25 !important;
    color: #333333 !important;
    letter-spacing: -0.01em;
}

.kachel-text {
    margin: 0 0 22px !important;
    font-family: var(--body_typography-font-family, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif) !important;
    font-size: 15px !important;
    line-height: 1.65 !important;
    color: #666666 !important;
    flex: 1;
}

.kachel-action {
    align-self: flex-start;
    color: #e8641e !important;
    font-family: var(--body_typography-font-family, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif) !important;
    font-weight: 600 !important;
    font-size: 15px !important;
    text-decoration: none !important;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    transition: gap 0.2s ease;
    line-height: 1.4;
}

.kachel-action svg {
    vertical-align: -0.15em;
    transition: transform 0.2s ease;
}

.startseite-projekt-kachel:hover .kachel-action svg {
    transform: translateX(3px);
}

/* Bottom Button */
.startseite-projekte-footer {
    text-align: center;
    margin-top: 52px;
    width: 100%;
}

.startseite-projekte-all-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 14px 34px;
    background: #e8641e;
    border: 1px solid #e8641e;
    color: #ffffff !important;
    font-weight: 700 !important;
    font-size: 15px !important;
    text-decoration: none !important;
    border-radius: 50px;
    font-family: var(--body_typography-font-family, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif) !important;
    transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease, border-color 0.2s ease;
    box-sizing: border-box;
}

.startseite-projekte-all-btn svg {
    vertical-align: -0.15em;
    transition: transform 0.2s ease;
}

.startseite-projekte-all-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 18px rgba(232, 100, 30, 0.35);
    background: #d45515;
    border-color: #d45515;
    color: #ffffff !important;
    text-decoration: none !important;
}

.startseite-projekte-all-btn:hover svg {
    transform: translateX(3px);
}

/* Responsive */
@media (max-width: 1024px) {
    .startseite-projekte-grid.cols-3,
    .startseite-projekte-grid.cols-4 {
        grid-template-columns: repeat(2, 1fr);
        gap: 24px;
    }
    .kachel-content {
        padding: 24px 20px 28px;
    }
}

@media (max-width: 680px) {
    .startseite-projekte-grid,
    .startseite-projekte-grid.cols-2,
    .startseite-projekte-grid.cols-3,
    .startseite-projekte-grid.cols-4 {
        grid-template-columns: 1fr;
        gap: 20px;
    }
    .startseite-projekte-footer {
        margin-top: 36px;
    }
}
