/* Import Poppins font from Google Fonts */
@import url('https://fonts.googleapis.com/css2?family=Poppins:wght@300;400;500;600;700&display=swap');

/* Reset and base styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Poppins', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, 'Open Sans', 'Helvetica Neue', sans-serif;
    background-color: #f9fafc;
    color: #2d2e2f;
    line-height: 1.6;
    overflow-x: hidden;
}

/* App Container Layout */
.app-container {
    display: flex;
    min-height: 100vh;
}

/* Sidebar Styles */
.sidebar {
    width: 250px;
    background-color: #2d2e2f;
    color: #fff;
    transition: all 0.3s ease;
    position: relative;
    z-index: 100;
    box-shadow: 2px 0 10px rgba(0, 0, 0, 0.1);
}

.sidebar.collapsed {
    width: 70px;
}

.sidebar-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 20px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.logo {
    display: flex;
    align-items: center;
}

.logo-text {
    font-size: 1.5rem;
    font-weight: 700;
    color: #fff;
    transition: opacity 0.3s;
}

.sidebar.collapsed .logo-text {
    opacity: 0;
    width: 0;
    overflow: hidden;
}

.toggle-btn {
    background: transparent;
    border: none;
    color: #fff;
    cursor: pointer;
    font-size: 1rem;
    transition: transform 0.3s;
}

.sidebar.collapsed .toggle-btn {
    transform: rotate(180deg);
}

.sidebar-menu {
    padding: 20px 0;
}

.sidebar-menu ul {
    list-style: none;
}

.sidebar-menu li {
    margin-bottom: 5px;
    transition: background-color 0.3s;
}

.sidebar-menu li.active {
    background-color: rgba(255, 255, 255, 0.1);
}

.sidebar-menu li:hover {
    background-color: rgba(255, 255, 255, 0.05);
}

.sidebar-menu a {
    display: flex;
    align-items: center;
    padding: 12px 20px;
    color: #fff;
    text-decoration: none;
    transition: all 0.3s;
}

.sidebar-menu i {
    font-size: 1.2rem;
    margin-right: 15px;
    min-width: 20px;
    text-align: center;
}

.sidebar-menu .menu-text {
    transition: opacity 0.3s;
    white-space: nowrap;
}

.sidebar.collapsed .menu-text {
    opacity: 0;
    width: 0;
    overflow: hidden;
}

/* Main Content Wrapper */
.main-wrapper {
    flex: 1;
    padding: 20px;
    transition: all 0.3s ease;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
}

header {
    margin-bottom: 30px;
    padding-bottom: 20px;
    border-bottom: 1px solid #e5e5e5;
}

h1 {
    color: #3c3f41;
    font-size: 28px;
    font-weight: 600;
}

h2 {
    font-size: 20px;
    margin-bottom: 15px;
    color: #3c3f41;
    font-weight: 500;
}

.main-content {
    display: grid;
    grid-template-columns: 1fr 2fr;
    gap: 30px;
}

.input-section, .output-section {
    background-color: #ffffff;
    border-radius: 8px;
    padding: 20px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}

textarea {
    width: 100%;
    height: 200px;
    padding: 12px;
    border: 1px solid #e0e0e0;
    border-radius: 4px;
    margin-bottom: 15px;
    font-size: 14px;
    resize: vertical;
}

button {
    background-color: #FF4A00;
    color: white;
    border: none;
    padding: 10px 16px;
    border-radius: 3px;
    cursor: pointer;
    font-size: 14px;
    font-weight: 500;
    margin-right: 10px;
    transition: background-color 0.2s, transform 0.2s;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05);
}

button:hover {
    background-color: #E5430F;
    transform: translateY(-2px);
}

#clear-input-btn, #clear-all-btn {
    background-color: #F44336;
}

#clear-input-btn:hover, #clear-all-btn:hover {
    background-color: #D32F2F;
}

#export-btn, .export-format-btn, #copy-all-btn {
    background-color: #3F51B5;
}

#export-btn:hover, .export-format-btn:hover, #copy-all-btn:hover {
    background-color: #303F9F;
}

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

.output-controls {
    display: flex;
    align-items: center;
}

#search-input {
    padding: 8px 12px;
    border: 1px solid #e0e0e0;
    border-radius: 4px;
    margin-right: 10px;
    font-size: 14px;
    width: 200px;
}

.export-dropdown {
    position: relative;
    display: inline-block;
}

.export-dropdown-content {
    display: none;
    position: absolute;
    background-color: #fff;
    min-width: 120px;
    box-shadow: 0 8px 16px rgba(0,0,0,0.1);
    z-index: 1;
    border-radius: 3px;
    top: 100%;
    left: 0;
}

.export-dropdown:hover .export-dropdown-content {
    display: flex;
    flex-direction: column;
}

.export-format-btn {
    padding: 8px 12px;
    text-align: left;
    background: none;
    color: #253858;
    box-shadow: none;
    border-radius: 0;
    margin: 0;
}

.export-format-btn:hover {
    background-color: #f5f8fa;
}

.file-upload-container {
    margin-bottom: 15px;
    display: flex;
    align-items: center;
    flex-wrap: wrap;
}

.file-upload-label {
    background-color: #FF4A00;
    color: white;
    padding: 8px 12px;
    border-radius: 3px;
    cursor: pointer;
    font-size: 14px;
    margin-right: 10px;
    display: inline-block;
}

#file-upload {
    display: none;
}

#file-name {
    font-size: 14px;
    color: #6b7280;
}

.credentials-list {
    max-height: 500px;
    overflow-y: auto;
}

.credential-item {
    padding: 12px;
    border-bottom: 1px solid #f0f0f0;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.credential-item:hover {
    background-color: #f5f7fa;
}

.credential-text {
    font-family: monospace;
    font-size: 14px;
}

.credential-actions {
    display: flex;
    gap: 8px;
}

.copy-btn, .delete-btn {
    background-color: transparent;
    color: #6b7280;
    padding: 4px 8px;
    font-size: 12px;
    border: 1px solid #e5e5e5;
}

.copy-btn:hover {
    color: #2563eb;
    border-color: #2563eb;
}

.delete-btn:hover {
    color: #ef4444;
    border-color: #ef4444;
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .main-content {
        grid-template-columns: 1fr;
    }
    
    .output-header {
        flex-direction: column;
        align-items: flex-start;
    }
    
    .output-controls {
        margin-top: 10px;
        width: 100%;
    }
    
    #search-input {
        width: 100%;
        margin-bottom: 10px;
    }
    
    .sidebar {
        width: 70px;
    }
    
    .logo-text, 
    .sidebar-menu .menu-text {
        opacity: 0;
        width: 0;
        overflow: hidden;
    }
    
    .sidebar.expanded {
        width: 250px;
        position: absolute;
        height: 100vh;
        z-index: 1000;
    }
    
    .sidebar.expanded .logo-text,
    .sidebar.expanded .menu-text {
        opacity: 1;
        width: auto;
    }
    
    .domain-stats {
        flex-direction: column;
        gap: 10px;
    }
    
    .file-upload-container {
        flex-direction: column;
        align-items: flex-start;
    }
    
    .file-upload-label {
        width: 100%;
        text-align: center;
    }
    
    #file-name {
        margin-left: 0;
        margin-top: 5px;
    }
}