/* ===================================
   Dane Gov Elementor Widgets Styles
   =================================== */

/* ===================================
   1. Property Field Widget
   =================================== */
.dg-field-value {
    display: inline-block;
}

.dg-field-value.dg-badge {
    padding: 5px 15px;
    border-radius: 3px;
    background: #0073aa;
    color: #fff;
}

/* ===================================
   2. Property Data Table Widget
   =================================== */
.dg-data-table {
    width: 100%;
    border-collapse: collapse;
}

.dg-data-table th,
.dg-data-table td {
    padding: 12px;
    text-align: left;
}

.dg-data-table.dg-table-striped tbody tr:nth-child(odd) {
    background: #f9f9f9;
}

.dg-data-table.dg-table-bordered th,
.dg-data-table.dg-table-bordered td {
    border: 1px solid #ddd;
}

.dg-data-table.dg-table-minimal th {
    border-bottom: 2px solid #333;
}

@media (max-width: 768px) {
    .dg-data-table thead {
        display: none;
    }
    
    .dg-data-table tr {
        display: block;
        margin-bottom: 15px;
        border: 1px solid #ddd;
    }
    
    .dg-data-table td {
        display: block;
        text-align: right;
        padding: 10px;
    }
    
    .dg-data-table td:before {
        content: attr(data-label);
        float: left;
        font-weight: bold;
    }
}

/* ===================================
   3. Property Price Display Widget
   =================================== */
.dg-price-display {
    padding: 20px;
}

.dg-price-display.dg-layout-horizontal {
    display: flex;
    gap: 30px;
}

.dg-price-display.dg-layout-vertical .dg-price-item {
    margin-bottom: 20px;
}

.dg-price-label {
    font-size: 14px;
    color: #666;
    margin-bottom: 5px;
}

.dg-price-value {
    font-size: 24px;
    font-weight: bold;
    color: #333;
}

.dg-price-badge {
    display: inline-block;
    padding: 5px 15px;
    background: #ff9900;
    color: #fff;
    border-radius: 3px;
    margin-bottom: 15px;
}

/* ===================================
   5. Property Location Map Widget
   =================================== */
.dg-location-map {
    width: 100%;
    background: #f0f0f0;
    position: relative;
}

/* ===================================
   6. Property Contact Form Widget
   =================================== */
.dg-contact-form-wrapper {
    max-width: 600px;
}

.dg-contact-form .dg-form-field {
    margin-bottom: 15px;
}

.dg-contact-form label {
    display: block;
    margin-bottom: 5px;
    font-weight: 600;
}

.dg-contact-form input[type="text"],
.dg-contact-form input[type="email"],
.dg-contact-form input[type="tel"],
.dg-contact-form textarea {
    width: 100%;
    padding: 10px;
    border: 1px solid #ddd;
    border-radius: 3px;
}

.dg-contact-form button {
    padding: 12px 30px;
    background: #0073aa;
    color: #fff;
    border: none;
    border-radius: 3px;
    cursor: pointer;
    font-size: 16px;
}

.dg-contact-form button:hover {
    background: #005a87;
}

.dg-form-message {
    margin-top: 15px;
    padding: 10px;
    border-radius: 3px;
}

.dg-form-message.success {
    background: #d4edda;
    color: #155724;
    border: 1px solid #c3e6cb;
}

.dg-form-message.error {
    background: #f8d7da;
    color: #721c24;
    border: 1px solid #f5c6cb;
}

/* ===================================
   7. Property Parts List Widget
   =================================== */
.dg-parts-list h4 {
    margin-bottom: 10px;
}

.dg-parts-list ul {
    list-style: none;
    padding: 0;
}

.dg-parts-list.dg-layout-list .dg-part-item {
    padding: 10px;
    border-bottom: 1px solid #eee;
}

.dg-parts-list.dg-layout-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 15px;
}

.dg-parts-list.dg-layout-cards .dg-part-item {
    padding: 15px;
    border: 1px solid #ddd;
    border-radius: 5px;
}

.dg-part-icon {
    margin-right: 10px;
}

.dg-part-price {
    float: right;
    font-weight: bold;
    color: #0073aa;
}

/* ===================================
   8. Property Price History Widget
   =================================== */
.dg-price-history-table {
    width: 100%;
    border-collapse: collapse;
}

.dg-price-history-table th,
.dg-price-history-table td {
    padding: 10px;
    text-align: left;
    border-bottom: 1px solid #eee;
}

.dg-price-history-list {
    list-style: none;
    padding: 0;
}

.dg-price-history-item {
    padding: 15px;
    margin-bottom: 10px;
    border-left: 3px solid #0073aa;
    background: #f9f9f9;
}

.dg-change-increase {
    color: #ff0000;
}

.dg-change-decrease {
    color: #00aa00;
}

.dg-change-neutral {
    color: #999;
}

/* ===================================
   9. Property Card Widget
   =================================== */
.dg-property-card {
    border: 1px solid #ddd;
    border-radius: 5px;
    overflow: hidden;
    transition: box-shadow 0.3s;
}

.dg-property-card:hover {
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
}

.dg-property-card.dg-layout-horizontal {
    display: flex;
}

.dg-property-card.dg-layout-horizontal .dg-card-image {
    flex: 0 0 40%;
}

.dg-card-image img {
    width: 100%;
    height: auto;
    display: block;
}

.dg-card-content {
    padding: 20px;
}

.dg-card-title {
    margin: 0 0 15px 0;
}

.dg-card-fields {
    margin-bottom: 15px;
}

.dg-card-field {
    margin-bottom: 8px;
}

.dg-card-button {
    display: inline-block;
    padding: 10px 20px;
    background: #0073aa;
    color: #fff;
    text-decoration: none;
    border-radius: 3px;
    transition: background 0.3s;
}

.dg-card-button:hover {
    background: #005a87;
}

/* ===================================
   10. Properties Grid Widget
   =================================== */
.dg-properties-grid.dg-layout-grid {
    display: grid;
    gap: 30px;
}

.dg-properties-grid.dg-columns-1 {
    grid-template-columns: 1fr;
}

.dg-properties-grid.dg-columns-2 {
    grid-template-columns: repeat(2, 1fr);
}

.dg-properties-grid.dg-columns-3 {
    grid-template-columns: repeat(3, 1fr);
}

.dg-properties-grid.dg-columns-4 {
    grid-template-columns: repeat(4, 1fr);
}

@media (max-width: 1024px) {
    .dg-properties-grid.dg-columns-4,
    .dg-properties-grid.dg-columns-3 {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .dg-properties-grid.dg-layout-grid {
        grid-template-columns: 1fr;
    }
}

.dg-property-item {
    border: 1px solid #ddd;
    border-radius: 5px;
    overflow: hidden;
}

.dg-property-image {
    position: relative;
}

.dg-property-image img {
    width: 100%;
    height: auto;
}

.dg-property-no-image {
    position: relative;
    background: #f5f5f5;
    padding: 60px 20px;
    text-align: center;
    min-height: 200px;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Badge statusu w siatce nieruchomości */
.dg-property-status-badge {
    position: absolute;
    top: 10px;
    right: 10px;
    padding: 6px 12px;
    border-radius: 3px;
    font-size: 12px;
    font-weight: 600;
    text-transform: uppercase;
    z-index: 10;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

.dg-property-status-badge.dg-status-available {
    background-color: #28a745;
    color: #fff;
}

.dg-property-status-badge.dg-status-reserved {
    background-color: #ffc107;
    color: #333;
}

.dg-property-status-badge.dg-status-sold {
    background-color: #dc3545;
    color: #fff;
}

.dg-property-content {
    padding: 15px;
}

.dg-property-type {
    font-size: 14px;
    color: #666;
    margin-bottom: 8px;
}

.dg-property-area,
.dg-property-price-m2,
.dg-property-price-total {
    font-size: 14px;
    margin-bottom: 8px;
    line-height: 1.6;
}

.dg-property-area strong,
.dg-property-price-m2 strong,
.dg-property-price-total strong {
    font-weight: 600;
    color: #333;
}

.dg-property-price-total {
    font-size: 16px;
    color: #0073aa;
    font-weight: bold;
    margin-top: 10px;
}

.dg-property-link {
    display: inline-block;
    margin-top: 10px;
    color: #0073aa;
    text-decoration: none;
}

.dg-pagination {
    margin-top: 30px;
    text-align: center;
}

.dg-pagination .page-numbers {
    display: inline-block;
    padding: 8px 12px;
    margin: 0 5px;
    background: #f0f0f0;
    text-decoration: none;
    color: #333;
    border-radius: 3px;
}

.dg-pagination .page-numbers.current {
    background: #0073aa;
    color: #fff;
}

/* ===================================
   11. Property Comparison Widget
   =================================== */
.dg-comparison-wrapper {
    overflow-x: auto;
}

.dg-comparison-table {
    width: 100%;
    border-collapse: collapse;
    min-width: 600px;
}

.dg-comparison-table th,
.dg-comparison-table td {
    padding: 12px;
    border: 1px solid #ddd;
    text-align: left;
}

.dg-comparison-table thead th {
    background: #f0f0f0;
    font-weight: bold;
}

.dg-comparison-table tbody tr:nth-child(odd) {
    background: #f9f9f9;
}

.dg-comparison-table .dg-has-difference {
    background: #fff3cd;
}

/* ===================================
   12. Property Status Badge Widget
   =================================== */
.dg-status-badge {
    display: inline-block;
    padding: 8px 16px;
    border-radius: 3px;
    font-weight: 600;
}

.dg-status-badge.dg-badge-filled {
    /* Kolory ustawiane inline */
}

.dg-status-badge.dg-badge-outlined {
    background: transparent;
}

.dg-status-badge.dg-badge-subtle {
    /* Kolory ustawiane inline z przezroczystością */
}

.dg-status-badge.dg-position-absolute {
    position: absolute;
    top: 10px;
    right: 10px;
    z-index: 10;
}

/* ===================================
   13. Property Investment Info Widget
   =================================== */
.dg-investment-info.dg-layout-horizontal {
    display: flex;
    gap: 30px;
}

.dg-investment-info.dg-layout-cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
}

.dg-investment-section {
    margin-bottom: 20px;
}

.dg-investment-section h4 {
    margin-bottom: 10px;
    color: #333;
}

.dg-investment-section p {
    margin-bottom: 8px;
}

/* ===================================
   14. Property Prospekt Download Widget
   =================================== */
.dg-prospekt-button {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 12px 24px;
    background: #0073aa;
    color: #fff;
    text-decoration: none;
    border-radius: 3px;
    transition: background 0.3s;
}

.dg-prospekt-button:hover {
    background: #005a87;
}

.dg-prospekt-button.dg-icon-right {
    flex-direction: row-reverse;
}

/* ===================================
   15. Property Developer Info Widget
   =================================== */
.dg-developer-info.dg-layout-horizontal {
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
}

.dg-developer-info.dg-layout-horizontal p {
    flex: 1 1 45%;
}

.dg-developer-info.dg-layout-card {
    padding: 20px;
    border: 1px solid #ddd;
    border-radius: 5px;
    background: #f9f9f9;
}

.dg-developer-info p {
    margin-bottom: 10px;
}

.dg-developer-info a {
    color: #0073aa;
    text-decoration: none;
}

.dg-developer-info a:hover {
    text-decoration: underline;
}

/* ===================================
   Responsive Adjustments
   =================================== */
@media (max-width: 768px) {
    .dg-price-display.dg-layout-horizontal,
    .dg-investment-info.dg-layout-horizontal,
    .dg-developer-info.dg-layout-horizontal {
        flex-direction: column;
    }
    
    .dg-property-card.dg-layout-horizontal {
        flex-direction: column;
    }
    
    .dg-property-card.dg-layout-horizontal .dg-card-image {
        flex: 0 0 100%;
    }
}

