/* ============================================
   NAILED IT CONSTRUCTION - TOOLS STYLESHEET
   Shared CSS for all calculator and tool pages
   ============================================ */

/* Reset & Base */
* { margin: 0; padding: 0; box-sizing: border-box; }

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background: #f4f4f4;
    color: #333;
    line-height: 1.6;
}

/* Header Navigation */
.navbar {
    background: #1a3c5e;
    color: white;
    padding: 15px 20px;
    position: sticky;
    top: 0;
    z-index: 1000;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

.nav-container {
    max-width: 1200px;
    margin: auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    font-size: 1.5em;
    font-weight: bold;
    color: white;
    text-decoration: none;
}

.nav-links {
    display: flex;
    list-style: none;
    gap: 20px;
}

.nav-links a {
    color: white;
    text-decoration: none;
    padding: 8px 15px;
    border-radius: 4px;
    transition: background 0.3s;
}

.nav-links a:hover,
.nav-links a.active {
    background: #ff6b35;
}

.mobile-menu-btn {
    display: none;
    background: none;
    border: none;
    color: white;
    font-size: 24px;
    cursor: pointer;
}

/* Main Layout */
.container {
    max-width: 1200px;
    margin: auto;
    padding: 20px;
}

.page-header {
    background: linear-gradient(135deg, #1a3c5e, #2a5c8e);
    color: white;
    padding: 80px 20px;
    text-align: center;
    margin-bottom: 30px;
}

.page-header h1 {
    font-size: 2.5em;
    margin-bottom: 10px;
}

.page-header p {
    font-size: 1.1em;
    opacity: 0.9;
}

/* Tool Card Grid */
.tools-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 25px;
    margin: 40px 0;
}

.tool-card {
    background: white;
    border-radius: 10px;
    padding: 25px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.08);
    transition: transform 0.3s, box-shadow 0.3s;
    text-align: center;
}

.tool-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 25px rgba(0,0,0,0.12);
}

.tool-card i {
    font-size: 3em;
    color: #ff6b35;
    margin-bottom: 15px;
}

.tool-card h3 {
    color: #1a3c5e;
    margin-bottom: 10px;
    font-size: 1.3em;
}

.tool-card p {
    color: #666;
    margin-bottom: 20px;
}

.cta-btn {
    background: #ff6b35;
    color: white;
    padding: 12px 25px;
    text-decoration: none;
    border-radius: 5px;
    font-weight: 600;
    display: inline-block;
    transition: background 0.3s, transform 0.2s;
    border: none;
    cursor: pointer;
}

.cta-btn:hover {
    background: #e55a2b;
    transform: scale(1.05);
}

.cta-btn-secondary {
    background: #1a3c5e;
}

.cta-btn-secondary:hover {
    background: #2a5c8e;
}

/* Calculator Container */
.calculator {
    background: white;
    border-radius: 10px;
    padding: 30px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.08);
    margin: 20px 0;
}

.calculator h2 {
    color: #1a3c5e;
    margin-bottom: 20px;
    padding-bottom: 10px;
    border-bottom: 2px solid #eee;
}

.calc-description {
    background: #f8f9fa;
    padding: 15px;
    border-radius: 8px;
    margin-bottom: 20px;
    border-left: 4px solid #ff6b35;
}

/* Form Elements */
.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
    color: #444;
}

.form-row {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 15px;
}

.form-control {
    width: 100%;
    padding: 12px 15px;
    border: 1px solid #ddd;
    border-radius: 5px;
    font-size: 16px;
    transition: border-color 0.3s;
}

.form-control:focus {
    outline: none;
    border-color: #ff6b35;
}

.select-control {
    width: 100%;
    padding: 12px 15px;
    border: 1px solid #ddd;
    border-radius: 5px;
    font-size: 16px;
    background: white;
    cursor: pointer;
}

.range-container {
    margin: 20px 0;
}

.range-container label {
    display: block;
    margin-bottom: 10px;
    font-weight: 600;
}

.range-slider {
    width: 100%;
    height: 8px;
    border-radius: 4px;
    background: #ddd;
    outline: none;
    -webkit-appearance: none;
}

.range-slider::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: #ff6b35;
    cursor: pointer;
    transition: transform 0.2s;
}

.range-slider::-webkit-slider-thumb:hover {
    transform: scale(1.2);
}

.range-slider::-moz-range-thumb {
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: #ff6b35;
    cursor: pointer;
    border: none;
}

.range-value {
    text-align: center;
    font-weight: bold;
    color: #ff6b35;
    font-size: 1.2em;
    margin-top: 10px;
}

/* Results Section */
.results {
    background: #f8f9fa;
    padding: 25px;
    border-radius: 10px;
    margin-top: 30px;
    border-left: 5px solid #ff6b35;
}

.results h3 {
    color: #1a3c5e;
    margin-bottom: 15px;
}

.result-item {
    display: flex;
    justify-content: space-between;
    padding: 10px 0;
    border-bottom: 1px solid #eee;
}

.result-item:last-child {
    border-bottom: none;
}

.result-label {
    font-weight: 600;
    color: #555;
}

.result-value {
    font-weight: bold;
    color: #1a3c5e;
    font-size: 1.1em;
}

.total-result {
    background: #1a3c5e;
    color: white;
    padding: 20px;
    border-radius: 10px;
    text-align: center;
    margin-top: 20px;
    font-size: 1.3em;
    font-weight: bold;
}

/* Gallery Styles */
.gallery-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 20px;
    margin: 30px 0;
}

.gallery-item {
    background: white;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 5px 15px rgba(0,0,0,0.08);
    transition: transform 0.3s;
    position: relative;
}

.gallery-item:hover {
    transform: scale(1.03);
}

.gallery-img {
    width: 100%;
    height: 200px;
    object-fit: cover;
    display: block;
}

.gallery-info {
    padding: 15px;
}

.gallery-info h3 {
    color: #1a3c5e;
    font-size: 1.1em;
    margin-bottom: 5px;
}

.gallery-info p {
    color: #666;
    font-size: 0.9em;
}

.gallery-tag {
    display: inline-block;
    background: #ff6b35;
    color: white;
    padding: 4px 10px;
    border-radius: 12px;
    font-size: 0.8em;
    margin-top: 8px;
}

/* Comparison Table */
.comparison-table {
    width: 100%;
    border-collapse: collapse;
    margin: 20px 0;
    background: white;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 5px 15px rgba(0,0,0,0.08);
}

.comparison-table th {
    background: #1a3c5e;
    color: white;
    padding: 15px;
    text-align: left;
}

.comparison-table td {
    padding: 12px 15px;
    border-bottom: 1px solid #eee;
}

.comparison-table tr:hover {
    background: #f8f9fa;
}

.comparison-table .highlight {
    background: #fff3e6;
    font-weight: bold;
}

/* Testimonials */
.testimonials {
    background: #e9ecef;
    padding: 50px 20px;
    text-align: center;
}

.testimonials h2 {
    color: #1a3c5e;
    margin-bottom: 30px;
}

.testimonial-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 20px;
    max-width: 1000px;
    margin: auto;
}

.testimonial-card {
    background: white;
    padding: 25px;
    border-radius: 10px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.08);
    text-align: left;
}

.testimonial-card p {
    font-style: italic;
    color: #555;
    margin-bottom: 15px;
}

.testimonial-author {
    font-weight: bold;
    color: #1a3c5e;
}

/* Footer */
.footer {
    background: #1a3c5e;
    color: white;
    padding: 40px 20px 20px;
    text-align: center;
    margin-top: 50px;
}

.footer-links {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 30px;
    max-width: 800px;
    margin: auto;
}

.footer-column h4 {
    margin-bottom: 15px;
    font-size: 1.1em;
}

.footer-column ul {
    list-style: none;
}

.footer-column ul li {
    margin: 8px 0;
}

.footer-column ul li a {
    color: #ccc;
    text-decoration: none;
    transition: color 0.3s;
}

.footer-column ul li a:hover {
    color: #ff6b35;
}

.footer-bottom {
    margin-top: 30px;
    padding-top: 20px;
    border-top: 1px solid #2a5c8e;
    font-size: 0.9em;
    color: #ccc;
}

/* Responsive */
@media (max-width: 768px) {
    .nav-links {
        display: none;
    }
    
    .mobile-menu-btn {
        display: block;
    }
    
    .page-header h1 {
        font-size: 2em;
    }
    
    .form-row {
        grid-template-columns: 1fr;
    }
    
    .gallery-grid {
        grid-template-columns: 1fr;
    }
}

/* Utility Classes */
.hidden {
    display: none;
}

.text-center {
    text-align: center;
}

.mt-20 { margin-top: 20px; }
.mt-30 { margin-top: 30px; }
.mb-20 { margin-bottom: 20px; }
.mb-30 { margin-bottom: 30px; }

/* Print Styles */
@media print {
    .navbar, .footer, .no-print {
        display: none !important;
    }
    
    .calculator, .results {
        box-shadow: none;
        border: 1px solid #ccc;
    }
}
