body {
    font-family: Arial, sans-serif;
    background-color: #1a1a2e; /* Dark blue background */
    color: #e0e0e0; /* Light gray text */
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
    margin: 0;
    padding: 20px; /* Added padding to ensure card doesn't touch edges on small screens */
    box-sizing: border-box; /* Include padding in element's total width and height */
}

.container {
    width: 100%;
    max-width: 800px; /* Increased max-width for better layout */
}

.card {
    background-color: #24243e; /* Slightly lighter dark blue */
    border-radius: 10px;
    padding: 30px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3); /* Stronger shadow */
    text-align: center;
}

.card-title {
    font-size: 2.5em; /* Larger title */
    margin-bottom: 15px;
    color: #94d82d; /* Green accent color */
}

.card-description {
    font-size: 1.1em;
    margin-bottom: 30px;
    color: #cccccc;
}

.ip-section, .client-network-section {
    display: flex;
    justify-content: space-around;
    margin-bottom: 30px;
    flex-wrap: wrap; /* Allow wrapping on smaller screens */
    gap: 20px; /* Space between flex items */
}

.ip-card, .client-network-section { /* Apply card styling to client-network-section directly */
    background-color: #1f1f3a; /* Even lighter dark blue */
    border-radius: 8px;
    padding: 20px;
    flex: 1; /* Allow cards to grow and shrink */
    min-width: 280px; /* Minimum width for IP cards */
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15); /* Slightly stronger shadow for inner cards */
    display: flex; /* For centering content within these cards */
    flex-direction: column;
    justify-content: center;
    align-items: center;
}

.ip-card h2, .client-network-section h2, .traceroute-section h2 {
    font-size: 1.4em; /* Slightly larger headings */
    color: #70a1ff; /* Light blue accent color */
    margin-top: 0;
    margin-bottom: 15px;
}

.ip-card p, .client-network-section p {
    font-size: 1.6em; /* Larger IP text */
    font-weight: bold;
    color: #ffffff;
    word-break: break-all; /* Ensure long IPs wrap */
}

.traceroute-section {
    background-color: #1f1f3a;
    border-radius: 8px;
    padding: 25px; /* Slightly more padding */
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
}

.traceroute-input-group {
    display: flex;
    gap: 10px;
    margin-bottom: 20px;
    justify-content: center;
    flex-wrap: wrap;
}

.traceroute-input-group input[type="text"],
.traceroute-input-group select {
    padding: 12px; /* More padding for inputs */
    border: 1px solid #3a3a5a;
    border-radius: 5px;
    background-color: #2e2e4a;
    color: #e0e0e0;
    font-size: 1.1em; /* Larger font size */
    flex-grow: 1; /* Allow input to take available space */
    min-width: 150px; /* Min width for input fields */
}

.traceroute-input-group input[type="text"]::placeholder {
    color: #aaaaaa;
}

.traceroute-input-group button {
    padding: 12px 25px; /* More padding for button */
    background-color: #94d82d;
    color: #1a1a2e;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    font-size: 1.1em;
    font-weight: bold;
    transition: background-color 0.3s ease, transform 0.2s ease; /* Smooth hover effects */
}

.traceroute-input-group button:hover {
    background-color: #7ec427;
    transform: translateY(-2px); /* Slight lift on hover */
}

#traceroute-output {
    background-color: #141426;
    border-radius: 5px;
    padding: 15px;
    text-align: left;
    white-space: pre-wrap; /* Preserve whitespace and wrap text */
    word-break: break-all; /* Break long words */
    max-height: 350px; /* Slightly taller output area */
    overflow-y: auto; /* Enable scrolling for long outputs */
    font-family: 'Courier New', Courier, monospace;
    font-size: 0.95em; /* Slightly larger font */
    color: #cccccc;
    border: 1px solid #3a3a5a;
    line-height: 1.4; /* Better readability */
}

/* Responsive adjustments */
@media (max-width: 600px) {
    .ip-section, .client-network-section, .traceroute-input-group {
        flex-direction: column;
        align-items: stretch; /* Stretch items to full width */
    }

    .ip-card, .client-network-section,
    .traceroute-input-group input[type="text"],
    .traceroute-input-group select,
    .traceroute-input-group button {
        min-width: unset; /* Remove min-width to allow full stretching */
        width: 100%; /* Make them take full width */
    }

    .card {
        padding: 20px;
    }

    .card-title {
        font-size: 2em;
    }

    .ip-card h2, .client-network-section h2, .traceroute-section h2 {
        font-size: 1.2em;
    }

    .ip-card p, .client-network-section p {
        font-size: 1.3em;
    }
}