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

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    background: #1c2938;
    min-height: 100vh;
    padding: 20px;
    position: relative;
    overflow-x: hidden;
}

body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: url('/background.jpeg') center/cover no-repeat fixed;
    z-index: -1;
}



.container {
    max-width: 1200px;
    margin: 0 auto;
    position: relative;
    z-index: 1;
}

header {
    text-align: center;
    color: white;
    margin-bottom: 30px;
}

header h1 {
    font-size: 2.5rem;
    margin-bottom: 10px;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

.subtitle {
    font-size: 1.1rem;
    color: rgba(255, 255, 255, 0.9);
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.2);
}

.content {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.card {
    background: white;
    border-radius: 12px;
    padding: 30px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
}

.card h2 {
    color: #333;
    margin-bottom: 20px;
    font-size: 1.5rem;
}

.form-group {
    margin-bottom: 20px;
    flex: 1;
}

.form-row {
    display: flex;
    gap: 20px;
}

label {
    display: block;
    margin-bottom: 8px;
    color: #555;
    font-weight: 500;
}

input, select, textarea {
    width: 100%;
    padding: 12px;
    border: 2px solid #e0e0e0;
    border-radius: 8px;
    font-size: 1rem;
    transition: border-color 0.3s;
}

#jira_search, #version_search, #repo_search, #current_search, #release_search {
    margin-bottom: 8px;
    border-color: #667eea;
    background: #f8f9ff;
}

#jira_component, #version, #gitlab_repo, #current_branch, #release_branch {
    margin-top: 0;
}

input:focus, select:focus, textarea:focus {
    outline: none;
    border-color: #667eea;
}

.button-group {
    display: flex;
    gap: 10px;
}

.btn-primary {
    flex: 1;
    padding: 15px;
    background: linear-gradient(135deg, #2a4a6a 0%, #1c2938 100%);
    color: white;
    border: none;
    border-radius: 8px;
    font-size: 1.1rem;
    font-weight: 600;
    cursor: pointer;
    transition: transform 0.2s, box-shadow 0.2s;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(42, 74, 106, 0.6);
}

.btn-primary:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none;
}

.btn-demo {
    padding: 15px 25px;
    background: #ff9800;
    color: white;
    border: none;
    border-radius: 8px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: transform 0.2s, background 0.3s;
}

.btn-demo:hover {
    background: #f57c00;
    transform: translateY(-2px);
}

.btn-copy {
    padding: 8px 16px;
    background: #4caf50;
    color: white;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    font-size: 0.9rem;
    transition: background 0.3s;
}

.btn-copy:hover {
    background: #45a049;
}

.loading-card {
    text-align: center;
    padding: 50px;
}

.loading-spinner {
    width: 50px;
    height: 50px;
    border: 5px solid #f3f3f3;
    border-top: 5px solid #667eea;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin: 0 auto 20px;
}

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

.spinner-inline {
    display: inline-block;
    width: 12px;
    height: 12px;
    border: 2px solid #f3f3f3;
    border-top: 2px solid #667eea;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    vertical-align: middle;
    margin-right: 5px;
}

select.loading {
    background: linear-gradient(90deg, #f8f9fa 0%, #e9ecef 50%, #f8f9fa 100%);
    background-size: 200% 100%;
    animation: shimmer 1.5s infinite;
}

@keyframes shimmer {
    0% { background-position: -200% 0; }
    100% { background-position: 200% 0; }
}

.loading-subtext {
    color: #888;
    margin-top: 10px;
}

.result-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    padding-bottom: 15px;
    border-bottom: 2px solid #f0f0f0;
}

.result-title {
    font-size: 1.1rem;
    color: #2a4a6a;
    font-weight: 600;
}

.html-preview {
    background: #f8f9fa;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    padding: 20px;
    max-height: 400px;
    overflow-y: auto;
    font-size: 0.9rem;
    line-height: 1.6;
}

.window-item {
    background: #f0f4ff;
    border-left: 4px solid #667eea;
    padding: 15px;
    margin-bottom: 10px;
    border-radius: 6px;
}

.window-time {
    font-weight: 600;
    color: #333;
    margin-bottom: 5px;
}

.window-reason {
    color: #666;
    font-size: 0.9rem;
}

.snow-section {
    margin-bottom: 15px;
    border: 2px solid #e0e0e0;
    border-radius: 8px;
    overflow: hidden;
}

.snow-section-header {
    padding: 15px;
    background: linear-gradient(135deg, #2a4a6a 0%, #1c2938 100%);
    color: white;
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
    transition: background 0.3s;
}

.snow-section-header:hover {
    background: linear-gradient(135deg, #1c2938 0%, #0f1a24 100%);
}

.snow-section-title {
    font-weight: 600;
    font-size: 1.1rem;
}

.snow-section-count {
    font-size: 0.9rem;
    opacity: 0.9;
}

.snow-section-content {
    padding: 15px;
    background: white;
}

.snow-field {
    margin-bottom: 15px;
    padding: 15px;
    background: #f8f9fa;
    border-radius: 8px;
}

.snow-field:last-child {
    margin-bottom: 0;
}

.snow-field-value p {
    margin: 8px 0;
}

.snow-field-value ul {
    margin: 8px 0;
    padding-left: 20px;
}

.snow-field-value li {
    margin: 4px 0;
}

.snow-field-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 10px;
}

.snow-field-label {
    font-weight: 600;
    color: #2a4a6a;
    flex: 1;
}

.snow-field-value {
    color: #333;
    white-space: pre-wrap;
    line-height: 1.8;
    padding: 10px;
    background: white;
    border: 1px solid #e0e0e0;
    border-radius: 4px;
}

.btn-copy-small {
    padding: 6px 12px;
    background: #4caf50;
    color: white;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-size: 0.85rem;
    transition: background 0.3s;
}

.btn-copy-small:hover {
    background: #45a049;
}

.success-message {
    background: #d4edda;
    color: #155724;
    padding: 12px;
    border-radius: 6px;
    margin-top: 10px;
    text-align: center;
}

.auth-note {
    margin-top: 15px;
    padding: 10px;
    background: #f0f4ff;
    border-radius: 6px;
    font-size: 0.9rem;
    color: #555;
    text-align: center;
}

.auth-note a {
    color: #667eea;
    text-decoration: none;
    font-weight: 600;
}

.auth-note a:hover {
    text-decoration: underline;
}

/* Multi-repo card styles */
.repos-section {
    margin: 20px 0;
}

.section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 15px;
}

.section-header h3 {
    color: #333;
    font-size: 1.2rem;
}

.btn-add {
    padding: 10px 20px;
    background: #2a4a6a;
    color: white;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    font-size: 0.95rem;
    font-weight: 600;
    transition: background 0.3s, transform 0.2s;
}

.btn-add:hover {
    background: #1c2938;
    transform: translateY(-1px);
}

.repo-card {
    background: #f8f9fa;
    border: 2px solid #e0e0e0;
    border-radius: 8px;
    padding: 20px;
    margin-bottom: 15px;
    position: relative;
    transition: border-color 0.3s;
}

.repo-card:hover {
    border-color: #2a4a6a;
}

.repo-card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 15px;
}

.repo-card-title {
    font-weight: 600;
    color: #2a4a6a;
    font-size: 1rem;
}

.btn-remove {
    padding: 6px 12px;
    background: #f44336;
    color: white;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-size: 0.85rem;
    transition: background 0.3s;
}

.btn-remove:hover {
    background: #d32f2f;
}

.repo-card .form-group {
    margin-bottom: 15px;
}

.repo-card label {
    font-size: 0.9rem;
}

.repo-card input,
.repo-card select {
    font-size: 0.95rem;
    padding: 10px;
}

.tooltip-icon {
    cursor: pointer;
    user-select: none;
    margin-left: 4px;
}

.tooltip-popup {
    position: fixed;
    background: #333;
    color: white;
    padding: 8px 12px;
    border-radius: 6px;
    font-size: 0.9rem;
    z-index: 1000;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
    max-width: 250px;
    animation: fadeIn 0.2s;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(-5px); }
    to { opacity: 1; transform: translateY(0); }
}

@media (max-width: 768px) {
    .form-row {
        flex-direction: column;
    }
    
    .button-group {
        flex-direction: column;
    }
    
    header h1 {
        font-size: 2rem;
    }
    
    .result-header {
        flex-direction: column;
        gap: 10px;
        align-items: flex-start;
    }
    
    .section-header {
        flex-direction: column;
        gap: 10px;
        align-items: stretch;
    }
}
