/* Reset e Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    background: linear-gradient(135deg, #fefce8 0%, #fef7ed 100%);
    min-height: 100vh;
    color: #333;
    line-height: 1.6;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Header Styles */
.header {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    box-shadow: 0 2px 20px rgba(0, 0, 0, 0.1);
    position: sticky;
    top: 0;
    z-index: 100;
}

.header-content {
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 1rem 0;
    gap: 3rem;
}

.header-left {
    display: flex;
    align-items: center;
    gap: 2rem;
}

.header-center {
    text-align: center;
}

.header-right {
    display: flex;
    align-items: center;
}

.company-logo {
    display: flex;
    align-items: center;
}

.dogre-logo {
    height: 3rem;
    width: auto;
    filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.1));
}

.city-logo {
    display: flex;
    align-items: center;
    flex-direction: column;
    text-align: center;
}

.city-emblem {
    height: 3rem;
    width: auto;
    filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.1));
    margin-bottom: 0.2rem;
}

.city-name {
    font-size: 0.75rem;
    font-weight: 700;
    color: #2c3e50;
    text-transform: uppercase;
    letter-spacing: 1px;
    font-family: 'Times New Roman', 'serif';
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.1);
}

.logo {
    display: flex;
    align-items: center;
    gap: 12px;
}

.logo i {
    font-size: 2rem;
    color: #f59e0b;
}

.logo h1 {
    font-size: 1.8rem;
    font-weight: 700;
    background: linear-gradient(135deg, #fbbf24, #f97316);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.nav-links {
    margin-top: 0.5rem;
}

.guide-link {
    display: inline-block;
    background: #f59e0b;
    color: white;
    padding: 0.5rem 1rem;
    border-radius: 8px;
    text-decoration: none;
    font-size: 0.9rem;
    font-weight: 500;
    transition: all 0.3s ease;
}

.guide-link:hover {
    background: #d97706;
    transform: translateY(-1px);
    box-shadow: 0 2px 8px rgba(245, 158, 11, 0.3);
}

.guide-link i {
    margin-right: 0.5rem;
}

.nav {
    display: flex;
    gap: 2rem;
}

.nav-link {
    text-decoration: none;
    color: #64748b;
    font-weight: 500;
    padding: 0.5rem 1rem;
    border-radius: 8px;
    transition: all 0.3s ease;
}

.nav-link:hover,
.nav-link.active {
    color: #f59e0b;
    background: rgba(251, 191, 36, 0.1);
}

/* Main Content */
.main {
    padding: 2rem 0;
}

/* Calculator Card */
.calculator-card {
    background: white;
    border-radius: 20px;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
    overflow: hidden;
    margin-bottom: 2rem;
}

.card-header {
    background: linear-gradient(135deg, #fef3c7, #fed7aa);
    color: #92400e;
    padding: 2rem;
    text-align: center;
}

.card-header h2 {
    font-size: 2rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
}

.card-header i {
    margin-right: 0.5rem;
}

.card-header p {
    opacity: 0.9;
    font-size: 1.1rem;
}

.card-body {
    padding: 2rem;
}

/* Form Sections */
.form-section {
    margin-bottom: 2.5rem;
    padding-bottom: 2rem;
    border-bottom: 1px solid #e2e8f0;
}

.form-section:last-child {
    border-bottom: none;
    margin-bottom: 0;
}

.form-section h3 {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 1.5rem;
    font-size: 1.3rem;
    font-weight: 600;
    color: #1e293b;
}

.step-number {
    background: linear-gradient(135deg, #fef3c7, #fed7aa);
    color: #92400e;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.9rem;
    font-weight: 600;
}

/* Radio Groups */
.radio-group {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1rem;
}

.radio-card {
    position: relative;
    cursor: pointer;
    display: block;
}

.radio-card input[type="radio"] {
    position: absolute;
    opacity: 0;
    pointer-events: none;
}

.radio-content {
    background: #f8fafc;
    border: 2px solid #e2e8f0;
    border-radius: 12px;
    padding: 1.5rem;
    text-align: center;
    transition: all 0.3s ease;
}

.radio-content i {
    font-size: 2rem;
    color: #64748b;
    margin-bottom: 0.5rem;
    display: block;
}

.radio-content span {
    display: block;
    font-weight: 600;
    color: #1e293b;
    margin-bottom: 0.25rem;
}

.radio-content small {
    color: #64748b;
    font-size: 0.85rem;
}

.radio-card input[type="radio"]:checked + .radio-content {
    background: linear-gradient(135deg, rgba(254, 243, 199, 0.5), rgba(254, 215, 170, 0.5));
    border-color: #fbbf24;
    transform: translateY(-2px);
    box-shadow: 0 10px 25px rgba(251, 191, 36, 0.15);
}

.radio-card input[type="radio"]:checked + .radio-content i {
    color: #f59e0b;
}

/* Select Groups */
.select-group {
    position: relative;
}

.select-group select {
    width: 100%;
    padding: 1rem 3rem 1rem 1rem;
    border: 2px solid #e2e8f0;
    border-radius: 12px;
    font-size: 1rem;
    background: white;
    cursor: pointer;
    transition: all 0.3s ease;
    appearance: none;
}

.select-group select:focus {
    outline: none;
    border-color: #fbbf24;
    box-shadow: 0 0 0 3px rgba(251, 191, 36, 0.1);
}

.select-icon {
    position: absolute;
    right: 1rem;
    top: 50%;
    transform: translateY(-50%);
    color: #64748b;
    pointer-events: none;
}

/* Input Groups */
.input-group {
    margin-bottom: 1rem;
}

.input-group label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 500;
    color: #1e293b;
}

.input-group input {
    width: 100%;
    padding: 1rem;
    border: 2px solid #e2e8f0;
    border-radius: 12px;
    font-size: 1rem;
    transition: all 0.3s ease;
}

.input-group input:focus {
    outline: none;
    border-color: #fbbf24;
    box-shadow: 0 0 0 3px rgba(251, 191, 36, 0.1);
}

/* Search Select Group */
.search-select-group {
    position: relative;
}

.search-select-group input[type="text"] {
    width: 100%;
    padding: 1rem;
    border: 2px solid #e2e8f0;
    border-radius: 12px;
    font-size: 1rem;
    transition: all 0.3s ease;
}

.search-select-group input[type="text"]:focus {
    outline: none;
    border-color: #fbbf24;
    box-shadow: 0 0 0 3px rgba(251, 191, 36, 0.1);
}

.via-dropdown {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: white;
    border: 2px solid #e2e8f0;
    border-top: none;
    border-radius: 0 0 12px 12px;
    max-height: 200px;
    overflow-y: auto;
    z-index: 1000;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

.via-option {
    padding: 0.75rem 1rem;
    cursor: pointer;
    border-bottom: 1px solid #f1f5f9;
    transition: background-color 0.2s ease;
}

.via-option:hover,
.via-option.highlighted {
    background-color: #fef7ed;
    color: #f59e0b;
}

.via-option:last-child {
    border-bottom: none;
}

.via-option.no-results {
    color: #64748b;
    font-style: italic;
    cursor: default;
}

.via-option.no-results:hover {
    background-color: white;
    color: #64748b;
}

.via-option.more-results {
    color: #64748b;
    font-size: 0.9rem;
    cursor: default;
    background-color: #f8fafc;
}

.via-option.more-results:hover {
    background-color: #f8fafc;
    color: #64748b;
}

.via-option strong {
    color: #f59e0b;
    background-color: rgba(251, 191, 36, 0.1);
    padding: 1px 2px;
    border-radius: 2px;
}

/* Dimension Groups */
.dimension-group {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
    margin-bottom: 1rem;
}

.surface-display {
    background: #f8fafc;
    border-radius: 12px;
    padding: 1rem;
    border: 1px solid #e2e8f0;
}

.surface-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.5rem 0;
}

.surface-item:not(:last-child) {
    border-bottom: 1px solid #e2e8f0;
    margin-bottom: 0.5rem;
}

.surface-item strong {
    color: #f59e0b;
    font-weight: 600;
}

/* Date Groups */
.date-group {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
    margin-bottom: 1rem;
}

.days-display {
    background: #f8fafc;
    border-radius: 12px;
    padding: 1rem;
    text-align: center;
    border: 1px solid #e2e8f0;
}

.days-display strong {
    color: #f59e0b;
    font-weight: 600;
}

/* Calculate Button */
.btn-calculate {
    width: 100%;
    background: linear-gradient(135deg, #fef3c7, #fed7aa);
    color: #92400e;
    border: none;
    padding: 1.25rem 2rem;
    font-size: 1.1rem;
    font-weight: 600;
    border-radius: 12px;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
}

.btn-calculate:hover:not(:disabled) {
    transform: translateY(-2px);
    box-shadow: 0 10px 25px rgba(251, 191, 36, 0.2);
}

.btn-calculate:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    transform: none;
}

/* Result Actions */
.result-actions {
    margin-top: 1.5rem;
    padding-top: 1.5rem;
    border-top: 2px solid #fef7ed;
    text-align: center;
}

/* Save Quote Button */
.btn-save-quote {
    background: linear-gradient(135deg, #dc2626, #b91c1c);
    color: white;
    border: none;
    padding: 1rem 2rem;
    font-size: 1rem;
    font-weight: 600;
    border-radius: 12px;
    cursor: pointer;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    box-shadow: 0 4px 14px rgba(220, 38, 38, 0.2);
}

.btn-save-quote:hover {
    background: linear-gradient(135deg, #b91c1c, #991b1b);
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(220, 38, 38, 0.3);
}

.btn-save-quote i {
    font-size: 1.1rem;
}

/* Result Disclaimer */
.result-disclaimer {
    margin-top: 1.5rem;
    padding: 1.25rem;
    background: linear-gradient(135deg, #fef3c7, #fde68a);
    border-left: 4px solid #f59e0b;
    border-radius: 8px;
    font-size: 0.9rem;
}

.disclaimer-content {
    display: flex;
    align-items: flex-start;
    gap: 0.75rem;
}

.disclaimer-content i {
    color: #d97706;
    font-size: 1.1rem;
    margin-top: 0.1rem;
    flex-shrink: 0;
}

.disclaimer-text {
    line-height: 1.5;
    color: #92400e;
}

.disclaimer-text strong {
    color: #78350f;
    font-weight: 600;
}

/* Payment Section */
.payment-section {
    margin-top: 1.5rem;
    padding: 1.25rem;
    background: linear-gradient(135deg, #dbeafe, #bfdbfe);
    border-left: 4px solid #3b82f6;
    border-radius: 8px;
    font-size: 0.9rem;
}

.payment-content h4 {
    color: #1e40af;
    margin-bottom: 0.75rem;
    font-size: 1.1rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.payment-content h4 i {
    color: #2563eb;
}

.payment-content p {
    color: #1e40af;
    margin-bottom: 1rem;
    line-height: 1.5;
}

.btn-payment {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    background: linear-gradient(135deg, #3b82f6, #2563eb);
    color: white;
    padding: 0.75rem 1.5rem;
    border-radius: 8px;
    text-decoration: none;
    font-weight: 600;
    font-size: 0.9rem;
    transition: all 0.3s ease;
    box-shadow: 0 4px 6px rgba(59, 130, 246, 0.3);
}

.btn-payment:hover {
    background: linear-gradient(135deg, #2563eb, #1d4ed8);
    transform: translateY(-1px);
    box-shadow: 0 6px 12px rgba(59, 130, 246, 0.4);
    color: white;
    text-decoration: none;
}

.btn-payment i {
    font-size: 0.85rem;
}

/* Results Section */
.results-section {
    margin-top: 2rem;
    padding-top: 2rem;
    border-top: 2px solid #e2e8f0;
}

.results-section h3 {
    color: #1e293b;
    margin-bottom: 1.5rem;
    font-size: 1.3rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.result-card {
    background: linear-gradient(135deg, #fef3c7, #fed7aa);
    border-radius: 16px;
    overflow: hidden;
    color: #92400e;
    box-shadow: 0 20px 40px rgba(251, 191, 36, 0.15);
}

.result-header {
    padding: 1.5rem;
    text-align: center;
    background: rgba(255, 255, 255, 0.1);
}

.result-header h4 {
    font-size: 1.2rem;
    font-weight: 600;
}

.result-body {
    padding: 2rem;
}

.result-amount {
    text-align: center;
    margin-bottom: 1.5rem;
    display: flex;
    align-items: baseline;
    justify-content: center;
    gap: 0.3rem;
}

.currency {
    font-size: 2.5rem;
    font-weight: 600;
    opacity: 0.9;
}

.amount {
    font-size: 3rem;
    font-weight: 700;
}

.result-details {
    background: rgba(255, 255, 255, 0.2);
    border-radius: 12px;
    padding: 1.2rem;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0.8rem;
    font-size: 0.9rem;
}

.result-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.4rem 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.2);
}

.result-item:last-child {
    border-bottom: none;
}

.result-item.full-width {
    grid-column: 1 / -1;
    font-weight: 600;
    font-size: 1rem;
    border-top: 2px solid rgba(255, 255, 255, 0.3);
    margin-top: 0.5rem;
    padding-top: 0.8rem;
}

.detail-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.5rem 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.detail-row:last-child {
    border-bottom: none;
    font-weight: 600;
    font-size: 1.1rem;
}

/* Modal Styles */
.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(5px);
    z-index: 1000;
}

.modal-content {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: white;
    border-radius: 16px;
    width: 90%;
    max-width: 400px;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.2);
}

.modal-header {
    padding: 1.5rem;
    border-bottom: 1px solid #e2e8f0;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.modal-header h3 {
    font-size: 1.2rem;
    font-weight: 600;
    color: #1e293b;
}

.close {
    font-size: 1.5rem;
    cursor: pointer;
    color: #64748b;
    transition: color 0.3s ease;
}

.close:hover {
    color: #1e293b;
}

.modal-body {
    padding: 1.5rem;
}

.btn-primary {
    width: 100%;
    background: linear-gradient(135deg, #fef3c7, #fed7aa);
    color: #92400e;
    border: none;
    padding: 1rem;
    font-size: 1rem;
    font-weight: 600;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.btn-primary:hover {
    transform: translateY(-1px);
    box-shadow: 0 5px 15px rgba(251, 191, 36, 0.2);
}

/* Loading Overlay */
.loading-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(255, 255, 255, 0.9);
    backdrop-filter: blur(5px);
    z-index: 2000;
    justify-content: center;
    align-items: center;
    flex-direction: column;
}

.spinner {
    width: 40px;
    height: 40px;
    border: 4px solid #e2e8f0;
    border-top: 4px solid #fbbf24;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin-bottom: 1rem;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* System Messages */
.system-message {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: white;
    border-radius: 16px;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.2);
    z-index: 3000;
    max-width: 90%;
    width: 500px;
    animation: messageSlideIn 0.3s ease;
}

.system-message.info {
    border-left: 5px solid #fbbf24;
}

.system-message.warning {
    border-left: 5px solid #f59e0b;
}

.system-message.error {
    border-left: 5px solid #dc2626;
}

.message-content {
    padding: 2rem;
    position: relative;
}

.message-close {
    position: absolute;
    top: 1rem;
    right: 1rem;
    background: none;
    border: none;
    font-size: 1.5rem;
    cursor: pointer;
    color: #64748b;
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: all 0.3s ease;
}

.message-close:hover {
    background: rgba(100, 116, 139, 0.1);
    color: #1e293b;
}

@keyframes messageSlideIn {
    from {
        opacity: 0;
        transform: translate(-50%, -60%);
    }
    to {
        opacity: 1;
        transform: translate(-50%, -50%);
    }
}

/* Admin Panel Styles */
.admin-panel {
    display: none;
    background: white;
    border-radius: 16px;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
    overflow: hidden;
    margin-top: 2rem;
}

.admin-header {
    background: linear-gradient(135deg, #fef3c7, #fed7aa);
    color: #92400e;
    padding: 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.admin-header h2 {
    font-size: 1.5rem;
    font-weight: 600;
}

.btn-logout {
    background: rgba(255, 255, 255, 0.2);
    color: white;
    border: none;
    padding: 0.5rem 1rem;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.btn-logout:hover {
    background: rgba(255, 255, 255, 0.3);
}

.admin-tabs {
    display: flex;
    border-bottom: 1px solid #e2e8f0;
}

.admin-tab {
    flex: 1;
    padding: 1rem;
    background: none;
    border: none;
    cursor: pointer;
    font-weight: 500;
    color: #64748b;
    transition: all 0.3s ease;
}

.admin-tab.active {
    color: #f59e0b;
    border-bottom: 2px solid #f59e0b;
}

.admin-content {
    padding: 2rem;
}

.table-container {
    overflow-x: auto;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
}

.data-table {
    width: 100%;
    border-collapse: collapse;
}

.data-table th,
.data-table td {
    padding: 0.75rem;
    text-align: left;
    border-bottom: 1px solid #e2e8f0;
}

.data-table th {
    background: #f8fafc;
    font-weight: 600;
    color: #1e293b;
}

.data-table tr:hover {
    background: #f8fafc;
}

/* Responsive Design */
@media (max-width: 768px) {
    .header-content {
        flex-direction: column;
        gap: 1rem;
    }

    .header-left {
        flex-direction: column;
        gap: 1rem;
        text-align: center;
    }

    .city-emblem {
        height: 2.5rem;
    }

    .city-name {
        font-size: 0.7rem;
        font-family: 'Times New Roman', 'serif';
    }

    .dogre-logo {
        height: 2.5rem;
    }

    .nav {
        gap: 1rem;
    }

    .radio-group {
        grid-template-columns: 1fr;
    }

    .dimension-group,
    .date-group {
        grid-template-columns: 1fr;
    }

    .logo h1 {
        font-size: 1.5rem;
    }

    .card-header h2 {
        font-size: 1.5rem;
    }

    .amount {
        font-size: 2rem;
    }

    .currency {
        font-size: 1.8rem;
    }

    .result-details {
        grid-template-columns: 1fr;
        font-size: 0.85rem;
    }

    .modal-content {
        width: 95%;
    }
}

@media (max-width: 480px) {
    .container {
        padding: 0 15px;
    }

    .card-body {
        padding: 1rem;
    }

    .form-section h3 {
        font-size: 1.1rem;
    }

    .step-number {
        width: 28px;
        height: 28px;
        font-size: 0.8rem;
    }
}

/* Footer */
.footer {
    background: rgba(255, 255, 255, 0.8);
    backdrop-filter: blur(10px);
    border-top: 1px solid rgba(251, 191, 36, 0.2);
    margin-top: 3rem;
    padding: 2rem 0;
}

.footer-content {
    text-align: center;
    color: #6b7280;
}

.copyright {
    font-size: 0.9rem;
    margin-bottom: 0.5rem;
    font-weight: 500;
}

.powered-by {
    font-size: 0.8rem;
    color: #9ca3af;
}

.powered-by strong {
    color: #f59e0b;
    font-weight: 600;
}
