/**
 * Haken Property Features - Main Styles
 * 
 * @package Haken_Property_Features
 */

/* Container */
.haken-features-container {
    width: 100%;
    margin: 0 auto;
    font-family: inherit, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}

/* Grid Layout */
.haken-features-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
    width: 100%;
}

/* Category Box */
.haken-feature-category {
    background-color: #ffffff!important;
    /* border: 1px solid #e9ecef; */
    border-radius: 8px;
    padding: 0px;
    transition: all 0.3s ease;
    height: 100%;
}

/*
.haken-feature-category:hover {
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.1);
    transform: translateY(-2px);
}
*/

/* Category Title */
.haken-category-title {
    font-size: 14px; /* Slightly larger for better hierarchy */
    font-weight: 600;
    margin: 0 0 12px 0;
    color: #1a1a2e; /* Darker color for better contrast */
    padding-bottom: 10px;
    border-bottom: 1px solid #e9ecef;
    letter-spacing: 0px; /* Tighter letter spacing for headings */
}

/* Feature List */
.haken-feature-list {
    list-style: none;
    margin: 0;
    padding: 0;
    flex: 1; /* Allow list to grow and fill available space */
}

/* Feature Item */
.haken-feature-item {
    display: flex;
    align-items: flex-start;
    margin-bottom: 14px;
    padding: 0;
    font-size: 14px; /* Increased from 14px to match body text */
    line-height: 26px; /* Slightly increased for better readability */
    color: #394048;
    font-weight: 400;
}

.haken-feature-item:last-child {
    margin-bottom: 0;
}

/* Icon Styling */
.haken-feature-item i {
    color: #7e8b99;
    font-size: 14px; /* Slightly larger icon */
    margin-right: 12px; /* More spacing between icon and text */
    flex-shrink: 0;
    margin-top: 3px; /* Better vertical alignment with larger text */
}

.haken-feature-item span {
    flex: 1;
    word-wrap: break-word; /* Allow long words to break */
    overflow-wrap: break-word; /* Modern property for word breaking */
    hyphens: auto; /* Enable automatic hyphenation */
}

/* Column Variations */
.haken-columns-1 .haken-features-grid {
    grid-template-columns: 1fr;
}

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

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

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

/* Responsive Design - Tablet */
@media (max-width: 991px) {
    .haken-features-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 20px;
    }
    
    .haken-feature-category {
        padding: 20px;
    }
    
    .haken-category-title {
        font-size: 16px;
        margin-bottom: 15px;
    }
    
    .haken-feature-item {
        font-size: 14px;
    }
    
    /* Tablet column overrides */
    .haken-tablet-columns-1 .haken-features-grid {
        grid-template-columns: 1fr;
    }
    
    .haken-tablet-columns-2 .haken-features-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .haken-tablet-columns-3 .haken-features-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

/* Responsive Design - Mobile */
@media (max-width: 575px) {
    .haken-features-grid {
        grid-template-columns: 1fr;
        gap: 15px;
    }
    
    .haken-feature-category {
        padding: 15px;
    }
    
    .haken-category-title {
        font-size: 16px;
        margin-bottom: 12px;
    }
    
    .haken-feature-item {
        font-size: 14px;
        margin-bottom: 10px;
    }
    
    /* Mobile column overrides */
    .haken-mobile-columns-1 .haken-features-grid {
        grid-template-columns: 1fr;
    }
    
    .haken-mobile-columns-2 .haken-features-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* Empty State */
.haken-features-empty {
    text-align: center;
    padding: 60px 20px;
    background-color: #f8f9fa;
    border-radius: 8px;
}

.haken-empty-message {
    color: #6c757d;
    font-size: 16px;
    margin: 0;
}

/* Loading State */
.haken-features-loading {
    text-align: center;
    padding: 60px 20px;
}

.haken-loading-spinner {
    display: inline-block;
    width: 40px;
    height: 40px;
    border: 3px solid #f3f3f3;
    border-top: 3px solid #27ae60;
    border-radius: 50%;
    animation: haken-spin 1s linear infinite;
    margin-bottom: 20px;
}

@keyframes haken-spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

.haken-loading-message {
    color: #6c757d;
    font-size: 16px;
    margin: 0;
}

/* Error State */
.haken-features-error {
    text-align: center;
    padding: 60px 20px;
    background-color: #f8d7da;
    border: 1px solid #f5c6cb;
    border-radius: 8px;
}

.haken-error-message {
    color: #721c24;
    font-size: 16px;
    margin: 0;
}

/* Color Scheme Variations */
.haken-scheme-light .haken-feature-category {
    background-color: #fff;
    border-color: #dee2e6;
}

.haken-scheme-dark .haken-feature-category {
    background-color: #2c3e50;
    border-color: #34495e;
    color: #ecf0f1;
}

.haken-scheme-dark .haken-category-title {
    color: #ecf0f1;
    border-color: #34495e;
}

.haken-scheme-dark .haken-feature-item {
    color: #bdc3c7;
}

/* Integration with Houzez theme */
.property-detail .haken-features-container {
    margin-top: 30px;
    margin-bottom: 30px;
}

/* Print Styles */
@media print {
    .haken-feature-category {
        break-inside: avoid;
        page-break-inside: avoid;
    }
    
    .haken-features-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}