:root { 
    --bg: #fdfbf9; 
    --card-bg: #ffffff;
    --text-main: #1a1a1a; 
    --text-muted: #666; 
    --border: #eceae6; 
    --accent: #222; 
    --hover: #000;
    --transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}
body { font-family: 'Inter', sans-serif; background: var(--bg); color: var(--text-main); margin: 0; padding: 0; display: flex; flex-direction: column; min-height: 100vh; -webkit-font-smoothing: antialiased; }
a { text-decoration: none; color: inherit; }
.container { max-width: 1240px; margin: 0 auto; padding: 0 24px; width: 100%; box-sizing: border-box; }

/* HEADER */
.top-header { background: #fff; border-bottom: 1px solid var(--border); padding: 20px 0; }
.top-header .container { display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 15px; }
.logo { font-size: 24px; font-weight: 700; letter-spacing: -0.5px; color: var(--text-main); display: flex; align-items: center; gap: 12px; }
.logo svg { width: 20px; height: 20px; opacity: 0.8; }
.top-links { display: flex; gap: 24px; font-size: 13px; font-weight: 600; color: var(--text-muted); text-transform: uppercase; letter-spacing: 0.5px; }
.top-links a { position: relative; padding-bottom: 2px; }
.top-links a::after { content: ''; position: absolute; left: 0; bottom: 0; width: 0; height: 2px; background: var(--text-main); transition: var(--transition); }
.top-links a:hover { color: var(--text-main); }
.top-links a:hover::after { width: 100%; }

/* NAVIGATION */
.main-nav { background: #fff; box-shadow: 0 4px 20px rgba(0,0,0,0.015); position: sticky; top: 0; z-index: 100; border-bottom: 1px solid var(--border); }
.nav-scroll { display: flex; overflow-x: auto; scrollbar-width: none; }
.nav-scroll::-webkit-scrollbar { display: none; }
.nav-scroll a { padding: 18px 20px; font-size: 12px; font-weight: 600; color: var(--text-muted); white-space: nowrap; text-transform: uppercase; letter-spacing: 1px; border-bottom: 2px solid transparent; transition: var(--transition); }
.nav-scroll a:hover { color: var(--text-main); background: #faf9f7; }
.nav-scroll a.active { color: var(--text-main); border-bottom-color: var(--accent); }

/* FOOTER */
.site-footer { background: #fff; border-top: 1px solid var(--border); padding: 40px 0; text-align: center; font-size: 13px; color: var(--text-muted); margin-top: auto; }
.footer-links { margin-bottom: 20px; font-weight: 500; }
.footer-links a { margin: 0 12px; color: var(--text-main); }
.footer-copy { display: block; margin-top: 10px; font-size: 11px; opacity: 0.6; }

/* UTILITIES */
.btn-logout { background: #f0f0f0; color: #333; padding: 6px 12px; border-radius:4px; font-size:12px; font-weight:600; }
.btn-red { color: #d32f2f; font-weight:600; font-size:12px; }

/* HOME TOOLBAR & GRID */
.toolbar { display: flex; justify-content: space-between; align-items: center; padding: 40px 0 30px; flex-wrap: wrap; gap: 20px; }
.date-display { font-size: 18px; font-weight: 600; color: var(--text-main); display: flex; align-items: center; gap: 10px; letter-spacing: -0.5px; }
.date-display svg { color: var(--text-muted); opacity: 0.7; }
.filters-group { display: flex; gap: 12px; }
.select-wrap { position: relative; }
.select-wrap svg { position: absolute; left: 14px; top: 50%; transform: translateY(-50%); color: var(--text-muted); pointer-events: none; width: 16px; height: 16px; }
select, .search-input, .form-input, .form-textarea { padding: 12px 20px; border: 1px solid var(--border); border-radius: 8px; font-family: 'Inter', sans-serif; font-size: 14px; background: #fff; outline: none; transition: var(--transition); box-shadow: 0 2px 10px rgba(0,0,0,0.01); width: 100%; box-sizing: border-box; }
select { appearance: none; padding-left: 40px; cursor: pointer; color: var(--text-main); font-weight: 500; }
select:focus, .search-input:focus, .form-input:focus, .form-textarea:focus, select:hover, .search-input:hover { border-color: var(--accent); box-shadow: 0 4px 15px rgba(0,0,0,0.03); }

.grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 24px; padding-bottom: 60px; }
.card { background: var(--card-bg); border: 1px solid var(--border); border-radius: 12px; text-align: center; padding: 0 0 24px; transition: var(--transition); display: flex; flex-direction: column; position: relative; overflow: hidden; box-shadow: 0 4px 20px rgba(0,0,0,0.015); }
.card::before { content: ''; position: absolute; top: 0; left: 0; right: 0; height: 3px; background: var(--accent); transform: scaleX(0); transform-origin: center; transition: var(--transition); }
.card:hover { box-shadow: 0 15px 35px rgba(0,0,0,0.06); transform: translateY(-4px); border-color: #ddd; }
.card:hover::before { transform: scaleX(1); }
.card-badge { background: var(--accent); color: #fff; display: inline-block; padding: 7px 20px; font-size: 11px; font-weight: 700; border-bottom-left-radius: 8px; border-bottom-right-radius: 8px; margin: 0 auto 25px; letter-spacing: 1px; }
.card-photo-wrap { padding: 8px; background: #fff; display: inline-block; border-radius: 4px; box-shadow: 0 5px 15px rgba(0,0,0,0.04); margin-bottom: 20px; border: 1px solid #f8f9fa; align-self: center; }
.card-photo { width: 120px; height: 155px; object-fit: cover; display: block; border-radius: 2px; }
.card-photo-placeholder { width: 120px; height: 155px; background: #faf9f7; display: flex; align-items: center; justify-content: center; color: #ddd; }
.card-name { font-size: 20px; font-weight: 700; color: var(--text-main); margin: 0 20px 6px; line-height: 1.3; letter-spacing: -0.3px; }
.card-years { font-size: 14px; color: var(--text-muted); margin-bottom: 18px; font-weight: 500; }
.card-text { font-size: 14px; color: #555; padding: 0 24px; line-height: 1.6; flex: 1; display: -webkit-box; -webkit-line-clamp: 4; -webkit-box-orient: vertical; overflow: hidden; }
.empty { text-align: center; padding: 80px 20px; color: var(--text-muted); width: 100%; grid-column: 1 / -1; background: #fff; border: 1px dashed #ccc; border-radius: 12px; font-size: 16px; font-weight: 500; }

/* SINGLE RE-DESIGN */
.single-main { padding: 40px 15px; flex: 1; display: flex; justify-content: center; }
.single-card { background: #fff; width: 100%; max-width: 900px; margin: 0 auto; border: 1px solid #e0e0e0; padding: 60px 40px 30px; text-align: center; position: relative; box-shadow: 0 4px 15px rgba(0,0,0,0.02); display: flex; flex-direction: column; min-height: 800px; }
.single-top-badge { position: absolute; top: -14px; left: 50%; transform: translateX(-50%); background: #fff; border: 1px solid #d0d0d0; border-radius: 20px; padding: 4px 30px; font-size: 13px; font-weight: 700; color: #555; text-transform: uppercase; letter-spacing: 1px; }
.single-photo { width: 120px; height: 160px; object-fit: cover; border: 1px solid #000; padding: 0; background: #fff; margin: 0 auto 20px auto; display: block; }
.single-name { font-size: 32px; font-weight: 700; color: #555; margin: 0 0 15px; letter-spacing: -0.5px; }
.single-cross { margin: 15px auto 20px; display: flex; justify-content: center; }
.single-cross img, .single-cross svg { max-height: 105px; width: auto; }
.single-years { font-size: 18px; color: #555; margin-bottom: 25px; font-weight: 500; }
.single-text-container { padding: 20px 0; margin-bottom: 30px; }
.single-text { font-size: 16px; color: #555; line-height: 1.6; padding: 0 30px; text-align: center; width: 100%; }
.single-text strong { font-weight: 700; color: #555; font-size: 16px; }
.single-actions { display: flex; justify-content: space-between; align-items: center; padding-top: 30px; margin-top: auto; flex-wrap: wrap; gap: 20px; width: 100%; border-top: 1px solid #eee; }
.action-btn { display: flex; flex-direction: column; align-items: center; gap: 10px; cursor: pointer; color: #777; font-size: 13px; font-weight: 600; transition: var(--transition); text-transform: uppercase; }
.action-btn:hover { color: #222; }
.action-btn svg { width: 40px; height: 40px; opacity: 0.8; }
.candle-btn { flex-direction: row; align-items: center; gap: 12px; font-size: 14px; font-weight: 700; color: #555; }
.candle-circle { width: 46px; height: 46px; background: #000; border-radius: 50%; display: flex; justify-content: center; align-items: center; font-size: 24px; box-shadow: 0 0 10px rgba(0,0,0,0.4); transition: all 0.3s; position: relative; overflow: hidden; }
.candle-btn:hover .candle-circle { box-shadow: 0 0 25px #ff9800; transform: scale(1.1); }

/* MULTI-STEP FORM */
.step-form-container { max-width: 600px; margin: 40px auto; background: #fff; border-radius: 8px; box-shadow: 0 10px 40px rgba(0,0,0,0.08); padding: 40px; }
.step { display: none; animation: fadeIn 0.4s ease; }
.step.active { display: block; }
@keyframes fadeIn { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: translateY(0); } }
.step-title { text-align: center; font-size: 22px; font-weight: 700; color: #26547c; margin-bottom: 30px; }
.step-hr { border: none; border-bottom: 1px dotted #ccc; margin: 30px 0; }
.radio-group { display: grid; grid-template-columns: 1fr 1fr; gap: 15px; margin-bottom: 20px; }
.radio-label { display: flex; align-items: center; gap: 10px; font-size: 15px; cursor: pointer; color: #444; }
.radio-label input { width: 18px; height: 18px; accent-color: #d32f2f; }
.form-group { margin-bottom: 25px; text-align: center; }
.form-group label { display: block; font-size: 16px; font-weight: 600; color: #26547c; margin-bottom: 10px; }
.step-input { width: 100%; padding: 12px 15px; border: 1px solid #ddd; background: #faf9f7; border-radius: 4px; font-size: 14px; text-align: center; box-sizing: border-box; }
.step-input:focus { outline: none; border-color: #26547c; background: #fff; }
.btn-blue { background: #26547c; color: #fff; padding: 12px 30px; border: none; border-radius: 4px; font-size: 16px; font-weight: 600; cursor: pointer; transition: 0.3s; }
.btn-blue:hover { background: #1a3c5a; }
.step-buttons { display: flex; justify-content: center; gap: 15px; }

/* CJENIK */
.cjenik-wrap { padding: 60px 20px; flex: 1; }
.pricing-header { text-align: center; margin-bottom: 50px; }
.pricing-header h1 { font-size: 32px; font-weight: 700; color: var(--text-main); margin: 0 0 15px; letter-spacing: -0.5px; }
.pricing-header p { color: var(--text-muted); font-size: 16px; max-width: 600px; margin: 0 auto; line-height: 1.6; }
.pricing-table { background: #fff; border: 1px solid var(--border); border-radius: 12px; overflow: hidden; box-shadow: 0 10px 40px rgba(0,0,0,0.03); max-width: 1000px; margin: 0 auto; }
.p-row { display: flex; align-items: center; padding: 24px; border-bottom: 1px solid var(--border); transition: var(--transition); }
.p-row:last-child { border-bottom: none; }
.p-row:hover:not(.p-head) { background: #faf9f7; }
.p-head { background: var(--accent); color: #fff; font-weight: 600; font-size: 13px; text-transform: uppercase; letter-spacing: 0.5px; }
.p-col { flex: 1; }
.p-col.flex-2 { flex: 2; padding-right: 20px; }
.p-col.text-center { text-align: center; }
.p-col.text-right { text-align: right; }
.p-name { font-weight: 700; color: var(--text-main); font-size: 16px; }
.p-days { font-weight: 600; color: var(--text-muted); }
.p-desc { font-size: 14px; color: #555; line-height: 1.5; }
.p-price { font-weight: 700; color: #d32f2f; font-size: 16px; }

/* KONTAKT & ADMIN LOGIN BOX */
.box-main { padding: 80px 20px; flex: 1; display: flex; justify-content: center; align-items: flex-start; }
.box { background: #fff; width: 100%; max-width: 500px; padding: 50px; border-radius: 12px; border: 1px solid var(--border); box-shadow: 0 10px 40px rgba(0,0,0,0.03); }
.box h1 { margin: 0 0 15px; font-size: 26px; color: var(--text-main); font-weight: 700; letter-spacing: -0.5px; }
.box p { color: var(--text-muted); margin-bottom: 30px; line-height: 1.6; font-size: 15px; }
.btn-primary { background: var(--accent); color: #fff; width: 100%; padding: 16px; border: none; border-radius: 6px; cursor: pointer; font-size: 15px; font-weight: 600; transition: var(--transition); letter-spacing: 0.5px; }
.btn-primary:hover { background: var(--hover); transform: translateY(-2px); box-shadow: 0 4px 12px rgba(0,0,0,0.1); }
.alert-error { background: #fff0f0; color: #d32f2f; padding: 12px; border-radius: 6px; margin-bottom: 20px; font-size: 14px; font-weight: 500; }

/* ADMIN PANEL */
.admin-main { padding: 40px 0; flex: 1; }
.panel { background: #fff; padding: 40px; border-radius: 12px; border: 1px solid var(--border); margin-bottom: 40px; box-shadow: 0 4px 20px rgba(0,0,0,0.02); }
.panel h2 { margin: 0 0 25px; font-size: 20px; border-bottom: 1px solid var(--border); padding-bottom: 15px; display:flex; justify-content:space-between; align-items:center; }
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; }
.form-grid .full { grid-column: 1 / -1; }
.form-grid label { display: block; font-size: 13px; color: var(--text-muted); margin-bottom: 8px; font-weight: 600; text-transform: uppercase; letter-spacing: 0.5px; }
.admin-table { width: 100%; border-collapse: separate; border-spacing: 0; background: #fff; border: 1px solid var(--border); border-radius: 12px; overflow: hidden; box-shadow: 0 4px 20px rgba(0,0,0,0.02); }
.admin-table th, .admin-table td { padding: 16px 20px; border-bottom: 1px solid var(--border); text-align: left; font-size: 14px; }
.admin-table th { background: #faf9f7; font-weight: 600; color: var(--text-muted); text-transform: uppercase; font-size: 12px; letter-spacing: 0.5px; }
.admin-table tr:last-child td { border-bottom: none; }
.badge-tip { background: #f0f0f0; padding: 4px 8px; border-radius: 4px; font-size: 11px; font-weight: 600; color: #333; }

/* RESPONSIVE */
@media(max-width: 1024px) { 
    .grid { grid-template-columns: repeat(3, 1fr); } 
}
@media(max-width: 768px) { 
    .grid { grid-template-columns: repeat(2, 1fr); }
    .form-grid { grid-template-columns: 1fr; }
    .single-actions { flex-direction: column; gap: 30px; }
}
@media(max-width: 600px) { 
    .grid { grid-template-columns: 1fr; } 
    .toolbar { flex-direction: column; align-items: stretch; padding: 25px 0; } 
    .filters-group { flex-direction: column; width: 100%; } 
    .single-card { padding: 40px 20px; }
    .single-name { font-size: 28px; } 
    .radio-group { grid-template-columns: 1fr; }
    .step-form-container { padding: 30px 20px; }
    .p-row { flex-direction: column; align-items: flex-start; gap: 10px; }
    .p-head { display: none; }
    .p-col { width: 100%; text-align: left !important; }
}

/* PRINT STYLES */
@media print {
    @page { margin: 10mm; }
    body * { visibility: hidden; }
    .single-card, .single-card * { visibility: visible; }
    .single-card { 
        position: absolute;
        left: 0;
        top: 0;
        width: 100%;
        border: 12px solid #000 !important; 
        box-shadow: none !important; 
        max-width: none !important; 
        margin: 0 !important; 
        padding: 50px 30px 20px !important; 
        box-sizing: border-box;
    }
    .single-top-badge {
        position: absolute !important;
        top: -16px !important;
        left: 50% !important;
        transform: translateX(-50%) !important;
        background: #fff !important;
        border: 2px solid #000 !important;
        color: #000 !important;
        padding: 5px 30px !important;
        border-radius: 15px !important;
        font-size: 14px !important;
        font-weight: bold !important;
        z-index: 10;
    }
    .single-actions, .single-actions * { display: none !important; visibility: hidden !important; }
    .single-name { font-size: 28px !important; color: #000 !important; margin-bottom: 10px !important; }
    .single-years { font-size: 16px !important; color: #000 !important; margin-bottom: 15px !important; }
    .single-text { color: #000 !important; font-size: 14px !important; line-height: 1.5 !important; padding: 0 !important; }
    .single-cross { margin: 10px auto 15px !important; }
    .single-cross svg { max-height: 80px !important; }
    .single-photo { width: 100px !important; height: 130px !important; margin-bottom: 15px !important; }
    * { -webkit-print-color-adjust: exact !important; print-color-adjust: exact !important; }
}
