* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
}

.container {
    background: white;
    border-radius: 12px;
    padding: 2rem;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
    text-align: center;
    max-width: 1200px;
    width: 95%;
}

h1 {
    color: #333;
    margin-bottom: 2rem;
    font-size: 2rem;
    font-weight: 600;
}

.ip-display {
    margin-bottom: 2rem;
    background: #f8f9fa;
    border-radius: 8px;
    padding: 1rem;
    border: 1px solid #e9ecef;
}

.ip-section {
    padding: 0.5rem 0;
}

.ip-section:first-child {
    padding-top: 0;
    border-bottom: 1px solid #dee2e6;
    padding-bottom: 0.75rem;
    margin-bottom: 0.75rem;
}

.ip-section:last-child {
    padding-bottom: 0;
}

.ip-section h3 {
    color: #495057;
    font-size: 0.9rem;
    margin-bottom: 0.5rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    font-weight: 600;
}

.ip-address {
    font-size: 1.4rem;
    font-weight: bold;
    color: #667eea;
    word-break: break-all;
    min-height: 1.6rem;
}

.loading {
    color: #999;
    font-size: 1rem;
}

.content-layout {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
    margin-bottom: 2rem;
    text-align: left;
}

.info-section {
    background: #f8f9fa;
    border-radius: 8px;
    padding: 1.5rem;
    display: flex;
    flex-direction: column;
    gap: 1.25rem;
}

.info-item {
    display: flex;
    flex-direction: column;
    padding: 0.75rem;
    background: white;
    border-radius: 6px;
    border: 1px solid #e9ecef;
}

.info-item label {
    font-weight: 600;
    color: #495057;
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 0.25rem;
}

.info-item span {
    color: #333;
    font-size: 0.95rem;
    word-break: break-word;
}

.network-stats {
    margin-top: 0.25rem;
}

.network-stats small {
    color: #6c757d;
    font-style: italic;
}

/* Modal Styles */
.modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
}

.modal-content {
    background: white;
    border-radius: 8px;
    width: 90%;
    max-width: 500px;
    max-height: 90vh;
    overflow-y: auto;
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1.5rem 1.5rem 0 1.5rem;
    border-bottom: 1px solid #e9ecef;
    margin-bottom: 1rem;
}

.modal-header h3 {
    margin: 0;
    color: #333;
}

.close-btn {
    background: none;
    border: none;
    font-size: 1.5rem;
    cursor: pointer;
    color: #6c757d;
    padding: 0;
    width: 30px;
    height: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.close-btn:hover {
    color: #333;
}

.modal-body {
    padding: 0 1.5rem 1.5rem 1.5rem;
}

.network-info-display {
    background: #f8f9fa;
    padding: 1rem;
    border-radius: 6px;
    margin: 1rem 0;
    border: 1px solid #e9ecef;
}

.form-group {
    margin-bottom: 1rem;
}

.form-group label {
    display: block;
    font-weight: 600;
    color: #495057;
    font-size: 0.9rem;
    margin-bottom: 0.25rem;
}

.form-group input {
    width: 100%;
    padding: 0.75rem;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 0.95rem;
}

.form-group input:focus {
    outline: none;
    border-color: #667eea;
    box-shadow: 0 0 0 2px rgba(102, 126, 234, 0.1);
}

.modal-actions {
    display: flex;
    gap: 0.5rem;
    margin-top: 1.5rem;
}

.save-btn, .cancel-btn {
    padding: 0.75rem 1rem;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-size: 0.9rem;
    font-weight: 500;
    transition: background-color 0.2s;
}

.save-btn {
    background: #667eea;
    color: white;
    flex: 1;
}

.save-btn:hover {
    background: #5a6fd8;
}

.cancel-btn {
    background: #6c757d;
    color: white;
}

.cancel-btn:hover {
    background: #5a6268;
}

.error-message {
    color: #dc3545;
    font-size: 0.9rem;
    margin-top: 1rem;
    padding: 0.5rem;
    background: #f8d7da;
    border: 1px solid #f5c6cb;
    border-radius: 4px;
}

/* Floating Edit Icon */
.floating-edit-icon {
    position: fixed;
    bottom: 2rem;
    right: 2rem;
    color: #667eea;
    cursor: pointer;
    transition: all 0.3s ease;
    z-index: 999;
}

.floating-edit-icon:hover {
    color: #5a6fd8;
    transform: scale(1.1);
}

.floating-edit-icon svg {
    filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.1));
}

@media (max-width: 768px) {
    .floating-edit-icon {
        bottom: 1rem;
        right: 1rem;
    }
    
    .floating-edit-icon svg {
        width: 18px;
        height: 18px;
    }
}

.address-block {
    padding: 0.75rem;
    background: white;
    border-radius: 6px;
    border: 1px solid #e9ecef;
}

.address-block label {
    font-weight: 600;
    color: #495057;
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 0.5rem;
    display: block;
}

.address-content {
    color: #333;
    font-size: 0.95rem;
    line-height: 1.4;
}

.address-content div {
    margin-bottom: 0.1rem;
}

.address-content div:last-child {
    margin-bottom: 0;
}

.map-section h3 {
    color: #333;
    margin-bottom: 1rem;
    font-size: 1.25rem;
    text-align: center;
}

.map-container {
    height: 400px;
    border-radius: 8px;
    border: 2px solid #e9ecef;
    margin-bottom: 0.5rem;
}

.map-disclaimer {
    font-size: 0.8rem;
    color: #6c757d;
    text-align: center;
    font-style: italic;
}

@media (max-width: 768px) {
    .container {
        padding: 1.5rem;
        width: 98%;
    }
    
    h1 {
        font-size: 1.5rem;
    }
    
    .ip-address {
        font-size: 1.2rem;
    }
    
    .content-layout {
        grid-template-columns: 1fr;
        gap: 1.5rem;
        text-align: center;
    }
    
    .map-container {
        height: 300px;
    }
}

@media (max-width: 480px) {
    .container {
        padding: 1rem;
    }
    
    .ip-address {
        font-size: 1.1rem;
    }
    
    .map-container {
        height: 250px;
    }
}