/* ====== REFERENCE – hranatý moderní layout ====== */
:root{
    --rf-bg:#0f0f10;
    --rf-card:#151618;
    --rf-text:#e9edf1;
    --rf-sub:#9aa3ad;
    --rf-accent:#c6322c;
    --rf-border:#24262a;
    --rf-radius:14px;
    --rf-soft:#f6f7f9; /* jemné pozadí sekcí */
}

/* WRAPPER */
.rf-works{
    background:#fff;
    padding: clamp(32px, 4vw, 64px) 16px;
}
.rf-works__wrap{max-width:1200px;margin:0 auto;}
.rf-works__head{
    display:flex;justify-content:space-between;align-items:flex-end;gap:16px;
    margin-bottom:24px;border-bottom:1px solid var(--rf-border);padding-bottom:16px;
}

/* SEKCE CONTACTS */
.rf-contacts{ background: var(--rf-soft); padding: 28px 20px; border-top: 1px solid #eee; }
.rf-contacts__wrap{ max-width: 1200px; margin: 0 auto; }

/* Hlavička sekce */
.rf-contacts__head{ display:flex; gap:16px; align-items:flex-start; justify-content:space-between; margin-bottom:18px; }
.rf-contacts__title{
    margin:0; letter-spacing:.2px; font-size:32px; font-weight:700;
    font-family:"Audiowide",system-ui,-apple-system,Segoe UI,Roboto,Arial; color:#000;
}
.rf-contacts__subtitle{ margin:.25rem 0 0; color:#000; font:400 14px/1.35 system-ui,-apple-system,Segoe UI,Roboto,Arial; }
.rf-contacts__mail{ color:var(--rf-accent); text-decoration:none; font:600 14px/1 system-ui,-apple-system,Segoe UI,Roboto,Arial; }

/* GRID PRVKŮ */
.rf-works__grid{
    display:grid; grid-template-columns: repeat(12, 1fr); gap:24px;
}

/* KARTY / DLAŽDICE */
.rf-work{
    grid-column: span 4; /* default = 3 na řádek */
    display:flex; flex-direction:column;
    border:1px solid var(--rf-border);
    overflow:hidden;
    box-shadow: 0px 0px 10px 0px rgba(0, 0, 0, 0.17);
    transition: transform .18s ease, box-shadow .22s ease, border-color .2s ease;


    background-color: #ffffff;
    background-image: linear-gradient(#e9e9e9 1px, transparent 1px),
    linear-gradient(90deg, #e9e9e9 1px, transparent 1px);
    background-size: 20px 20px;
}
@media (max-width:1024px){ .rf-work{ grid-column: span 6; } }   /* 2 na řádek */
@media (max-width:600px){ .rf-work{ grid-column: span 12 !important; } } /* 1 na řádek */

.rf-work:hover{
    transform: translateY(-3px);
    border-color:#34383e;
    box-shadow:0 10px 28px rgba(0,0,0,.35);
}

/* MEDIA */
.rf-work__media{ cursor:pointer; position:relative; }
.rf-work__img{
    width:100%; padding-bottom:66%; /* 3:2 */
    background-size:cover; background-position:center;
}
.rf-work__zoom{
    position:absolute; right:10px; bottom:10px;
    background: rgba(15,15,16,.55);
    border:1px solid rgba(255,255,255,.14);
    color:#fff; font-size:14px; line-height:1;
    padding:8px 10px; backdrop-filter: blur(4px);
    transition: transform .15s ease, background .2s ease;
}
.rf-work__media:hover .rf-work__zoom{ transform: scale(1.06); }

/* BODY KARTY */
.rf-work__body{
    padding:12px 16px 16px; }

.rf-work__name {
    width: 100%;
    display: flex;
    justify-content: center;
    align-items: start;
}
.rf-work__name a{
    margin:0 0 0px 0;
    font:600 18px/1.35 "Montserrat",system-ui;
    color: var(--e-global-color-accent);

    display: inline-block;    /* nebo block */
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 100%;
}
.rf-work__meta{
    display: flex;
    flex-wrap: wrap;
    align-items: center;      /* zarovnání vertikálně */
    justify-content: center;  /* zarovnání horizontálně */gap:8px;
    color:var(--rf-sub);
    font:500 13px/1.3 "Open Sans",system-ui;
    margin-bottom:10px;
}
.rf-dot{ width:4px;height:4px;background:#3a3d42;display:inline-block; }
.rf-chip{
    position:absolute;top:10px;left:10px;
    display:inline-flex;align-items:center;gap:6px;
    padding:4px 8px; background:#191b1e;border:1px solid #272a2f;color:#c3c9d0;
    font:600 12px/1 "Montserrat",system-ui; letter-spacing:.2px;
}
.rf-work__desc{ text-align: center; margin:0; color:#000; font:400 14px/1.55 "Open Sans",system-ui; }

/* Elementor lightbox – tmavší */
.elementor-lightbox{ background: rgba(10,10,12,.96) !important; }
.elementor-lightbox .dialog-widget-content{ box-shadow: 0 20px 80px rgba(0,0,0,.65) !important; }

/* DVOU-SLOUPCOVÝ LAYOUT (sidebar + obsah) */
.rf-works__layout{
    display:grid; grid-template-columns: 280px minmax(0,1fr);
    gap:16px; align-items:start;
}

/* LEFT FILTER PANEL */
.rf-filter{
    border:1px solid #E5E7EB; background:#FFF; padding:16px 18px;
    box-shadow:0 1px 0 rgba(0,0,0,.04); border-radius:0;
}
.rf-filter--left{
    position:sticky; top:96px; width:250px; /* pod sticky headerem */
}

/* TITULEK + klikací plocha (celé H3 je klikací) */
.rf-filter__title{
    margin:0 0 8px; font-size:16px; font-weight:700; color:#0F172A;
}
.rf-filter__toggle-area{
    display:flex; align-items:center; justify-content:space-between;
    width:100%; cursor:pointer; user-select:none; padding:6px 0;
}
.rf-filter__chev{
    display:inline-block; width:8px; height:8px;
    border-right:2px solid #374151; border-bottom:2px solid #374151;
    transform:rotate(45deg); transition:.2s; /* default = chevron-down */
}

/* Skrytý checkbox */
.rf-filter__chk{
    position:absolute; opacity:0; pointer-events:none;
}

/* Obsah filtru */
.rf-filter__group{
    display:flex; flex-direction:column; gap:8px; margin:12px 0 16px;
}

.rf-filter__label{
    font-size:13px; font-weight:600; color:#334155;
    text-transform:uppercase; letter-spacing:.02em;
}

/* Hranaté „chip“ tlačítka */
.rf-chipbtn{
    appearance:none; border:1px solid #E5E7EB; background:#F8FAFC; color:#0F172A;
    font-size:14px; padding:10px 12px; line-height:1; text-align:left; border-radius:0;
    cursor:pointer;
    transition:transform .06s ease, border-color .12s ease, background .12s ease, color .12s ease;
}
.rf-chipbtn.active,
.rf-chipbtn:hover{
    transform:translateY(-1px);
    border-color: var(--rf-accent);
    background: var(--rf-accent);
    color:#fff;
}
.rf-chipbtn.is-active,
.rf-chipbtn[aria-pressed="true"]{
    background:var(--e-global-color-accent);
    color:#FFF; border-color:var(--e-global-color-accent);
}
.rf-chipbtn--clear{ background:#FFF; margin-top:8px; }

/* Kategorie chipy s šipkou vpravo */
.rf-chipbtn--chev{ position:relative; padding-right:30px; }
.rf-chipbtn--chev::after{
    content:""; position:absolute; right:10px; top:50%;
    width:8px; height:8px;
    border-right:2px solid currentColor; border-top:2px solid currentColor;
    transform: translateY(-50%) rotate(45deg); opacity:.6;
}
.rf-chipbtn.is-active::after,
.rf-chipbtn[aria-pressed="true"]::after{ opacity:1; }

/* PAGINATION */
.rf-pagination{
    display:flex; justify-content:center; align-items:center;
    gap:8px; margin:12px 0 96px; flex-wrap:wrap;
}
.rf-page{
    min-width:44px; height:44px; padding:0 10px;
    display:inline-flex; align-items:center; justify-content:center;
    text-decoration:none; user-select:none;
    font-weight:600; color:#0F172A; background:#FFF;
    border:1px solid #E5E7EB; border-radius:0;
    box-shadow:0 1px 0 rgba(0,0,0,.04);
    transition: transform .06s ease, border-color .12s ease, background .12s ease, color .12s ease;
}
.rf-page:hover{ transform:translateY(-1px); border-color:#0F172A; }
.rf-page.is-active{
    background:#0F172A; color:#FFF; border-color:#0F172A; box-shadow:none;
}
.rf-page.is-disabled, .rf-page[aria-disabled="true"]{ opacity:.45; pointer-events:none; }
.rf-page--ellipsis{ min-width:auto; padding:0 6px; border:none; background:transparent; box-shadow:none; }
.rf-page--prev, .rf-page--next{ font-weight:700; }

/* MOBILE TWEAKS – pagination menší */
@media (max-width:480px){
    .rf-page{ min-width:38px; height:38px; font-size:14px; }
}

/* RESPONSIVE: filtr nad gridem na mobilu/tabletu */
@media (max-width:1023px){
    .rf-works__layout{ grid-template-columns:1fr; }
    .rf-filter--left{ position:static; top:auto; width:auto; }
    .rf-filter{ order:-1; padding:12px 16px 8px 12px; }

    /* Collapse by default */
    .rf-filter__group{ display:none; }
    .rf-filter__chk:checked ~ .rf-filter__group{ display:flex; }

    /* Otevřeno → šipka nahoru */
    .rf-filter__chk:checked ~ .rf-filter__title .rf-filter__chev{
        transform:rotate(-135deg); }
}

/* DESKTOP: filtr vždy otevřený, bez šipky */
@media (min-width:1024px){
    .rf-filter__chev{ display:none; }
    .rf-filter__chk{ display:none; }
    .rf-filter__group{ display:flex !important; }
}
