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

body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    background-color: #f5f5f7;
    color: #1d1d1f;
    line-height: 1.8;
    display: flex;
    justify-content: center;
    align-items: flex-start;
    padding: 40px;
    min-height: 100vh;
}

/* Main Container */
.container {
    display: none;
    width: 100%;
    max-width: 1200px;
    background: #ffffff;
    border-radius: 20px;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.15);
    overflow: hidden;
    padding-bottom: 40px;
}

/* Header */
/* Header Section */
header {
    background-color: #00575f; /* Solid primary color */
    color: #ffffff;
    padding: 60px 60px;
    text-align: left;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
}

header h1 {
    font-size: 3rem;
    font-weight: 700;
}

header .subtitle {
    font-size: 1rem;
    font-weight: 200;
    max-width: 800px; /* Limit line length */
    opacity: 0.9;
    line-height: 1.6;
    font-style: italic;
}

header .button-group {
    margin-top: 20px;
    display: flex;
    gap: 20px;
}

header .button-group a {
    padding: 12px 30px;
    font-size: 1.1rem;
    font-weight: 500;
    color: #ffffff;
    background-color: #00424a;
    border-radius: 10px;
    text-decoration: none;
    transition: background-color 0.3s, transform 0.2s;
}

header .button-group a:hover {
    background-color: #003136;
    transform: translateY(-2px);
}

header .button-group a:active {
    transform: scale(0.98);
}


/* Section */
section {
    padding: 40px 60px 0px 60px;
}

section h2 {
    font-size: 2rem;
    font-weight: 500;
    color: #1d1d1f;
    margin-bottom: 20px;
    border-bottom: 2px solid #00575f;
    display: inline-block;
    padding-bottom: 5px;
}

/* Output Boxes */
.output-box {
    background: #f9f9f9;
    margin: 20px 0;
    padding: 20px 30px;
    border-radius: 12px;
    border: 1px solid #e0e0e0;
    font-family: "SF Mono", "Courier New", monospace;
    font-size: 1rem;
    color: #333;
    box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.05);
    white-space: pre-wrap;
}

/* Settings Section */
.settings-section {
    padding: 40px 60px;
    border-bottom: 2px solid rgba(0, 0, 0, 0.05);
}

fieldset {
    border: none;
    margin-bottom: 30px;
    padding: 0;
}

legend {
    font-size: 1.25rem;
    font-weight: 500;
    color: #333;
    margin-bottom: 10px;
    display: block;
}

.tooltip {
    font-size: 0.9rem;
    color: #555;
    margin-top: 8px;
    font-style: italic;
}

.form-group {
    margin-bottom: 30px;
}

.input-label {
    font-size: 1.25rem;
    font-weight: 500;
    color: #333;
    margin-bottom: 12px;
    display: block;
}

.radio-group {
    display: flex;
    gap: 20px;
    margin-top: 8px;
}

.radio-group label {
    font-size: 1.1rem;
    font-weight: 400;
    color: #1d1d1f;
    display: flex;
    align-items: center;
    gap: 10px;
    cursor: pointer;
    transition: color 0.2s;
}

radio-group label:hover {
    color: #00575f;
}

input[type="radio"] {
    cursor: pointer;
}

select {
    width: 100%;
    padding: 12px 15px;
    font-size: 1rem;
    border: 1px solid #d2d2d7;
    border-radius: 8px;
    background: #ffffff;
    color: #1d1d1f;
    transition: border-color 0.2s;
}

select:focus {
    border-color: #00575f;
    outline: none;
    box-shadow: 0 0 0 3px rgba(0, 87, 95, 0.3);
}

/* Save Button */
.save-button {
    display: inline-block;
    margin-top: 20px;
    padding: 15px 40px;
    font-size: 1.25rem;
    font-weight: 600;
    color: #ffffff;
    background: #00575f;
    border: none;
    border-radius: 12px;
    cursor: pointer;
    transition: background-color 0.3s, transform 0.2s;
    text-align: center;
}

.save-button:hover {
    background: #00424a;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
}

.save-button:active {
    transform: scale(0.98);
}

.save-button[disabled] {
    background: #e0e0e0;
    cursor: not-allowed;
    box-shadow: none;
    transform: none;
}



/* Animations */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.container {
    animation: fadeIn 1s ease-in-out;
}

/* Responsive Design */
@media (max-width: 1024px) {
    header h1 {
        font-size: 2.5rem;
    }

    section h2 {
        font-size: 1.75rem;
    }

    body {
        padding: 20px;
    }
}

/* Spinner styles */
.spinner {
    position: fixed;
    top: 50%;
    left: 50%;
    width: 50px;
    height: 50px;
    border: 5px solid #ccc;
    border-top: 5px solid #00575f;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    z-index: 9999;
    transform: translate(-50%, -50%);
}

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