/* ========================================
   Navy Corporate Executive Resume Template CSS
   Professional Navy Blue & Gold Design
   ======================================== */

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Segoe UI', 'Arial', 'Helvetica Neue', sans-serif;
    background: #f0f2f5;
    min-height: 100vh;
    padding: 20px;
    margin: 0;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* ========================================
   Main Container
   ======================================== */
.resume-builder-container {
    max-width: 1400px;
    width: 95vw;
    height: 92vh;
    margin: 0 auto;
    display: flex;
    flex-direction: row;
    gap: 0;
    background: white;
    border-radius: 16px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.1);
    overflow: hidden;
}

/* ========================================
   Form Section (Left Panel)
   ======================================== */
.form-section {
    width: 450px;
    background: linear-gradient(180deg, #ffffff 0%, #f9fafb 100%);
    padding: 32px 28px;
    overflow-y: auto;
    border-right: 2px solid #e2e8f0;
    display: flex;
    flex-direction: column;
}

.form-section h2 {
    font-size: 26px;
    font-weight: 700;
    color: #1e293b;
    margin-bottom: 24px;
    text-align: center;
}

.form-section-title {
    font-size: 15px;
    font-weight: 700;
    color: #475569;
    margin-top: 28px;
    margin-bottom: 16px;
    padding-bottom: 8px;
    border-bottom: 2px solid #e2e8f0;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* ========================================
   Form Groups & Inputs
   ======================================== */
.form-group {
    margin-bottom: 18px;
}

.form-group label {
    display: block;
    font-size: 13px;
    font-weight: 600;
    color: #334155;
    margin-bottom: 7px;
}

.form-group input,
.form-group textarea,
.form-group select {
    width: 100%;
    padding: 11px 14px;
    font-size: 14px;
    border: 2px solid #e2e8f0;
    border-radius: 8px;
    transition: all 0.2s;
    font-family: inherit;
    background: white;
}

.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus {
    outline: none;
    border-color: #1e3a8a;
    box-shadow: 0 0 0 3px rgba(30, 58, 138, 0.1);
}

.form-group textarea {
    resize: vertical;
    min-height: 80px;
}

.form-group small {
    display: block;
    margin-top: 6px;
    font-size: 12px;
    color: #64748b;
}

.form-row {
    display: flex;
    gap: 12px;
}

.form-row .form-group {
    flex: 1;
}

/* ========================================
   Color Theme Picker
   ======================================== */
.theme-color-section {
    background: linear-gradient(135deg, #f8fafc 0%, #e0e7ff 100%);
    padding: 18px;
    border-radius: 12px;
    border: 2px solid #cbd5e1;
    margin-bottom: 24px;
}

.color-picker-wrapper {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-top: 10px;
}

.color-input {
    width: 60px;
    height: 40px;
    border: 3px solid #cbd5e1;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.2s;
}

.color-input:hover {
    border-color: #1e3a8a;
    transform: scale(1.05);
}

.color-label {
    flex: 1;
    font-size: 13px;
    color: #475569;
    font-weight: 500;
}

.reset-color-btn {
    padding: 8px 16px;
    background: #1e3a8a;
    color: white;
    border: none;
    border-radius: 6px;
    font-size: 12px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
}

.reset-color-btn:hover {
    background: #1e40af;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(30, 58, 138, 0.3);
}

/* ========================================
   Photo Upload Section
   ======================================== */
.photo-upload-section input[type="file"] {
    padding: 10px;
    font-size: 13px;
    cursor: pointer;
}

.photo-upload-section input[type="file"]::file-selector-button {
    padding: 8px 16px;
    background: #1e3a8a;
    color: white;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    font-weight: 600;
    margin-right: 10px;
    transition: all 0.2s;
}

.photo-upload-section input[type="file"]::file-selector-button:hover {
    background: #1e40af;
    transform: translateY(-1px);
}

/* ========================================
   Dynamic Item Sections (Experience, Education, Skills)
   ======================================== */
.experience-item,
.education-item,
.skill-item {
    background: #f8fafc;
    padding: 18px;
    border-radius: 10px;
    border: 2px solid #e2e8f0;
    margin-bottom: 16px;
    position: relative;
    transition: all 0.2s;
}

.experience-item:hover,
.education-item:hover,
.skill-item:hover {
    border-color: #cbd5e1;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
}

.remove-btn {
    position: absolute;
    top: 12px;
    right: 12px;
    background: #dc2626;
    color: white;
    border: none;
    padding: 6px 12px;
    border-radius: 6px;
    cursor: pointer;
    font-size: 12px;
    font-weight: 600;
    transition: all 0.2s;
}

.remove-btn:hover {
    background: #b91c1c;
    transform: scale(1.05);
}

/* ========================================
   Add & Action Buttons
   ======================================== */
.add-btn {
    width: 100%;
    padding: 12px;
    background: linear-gradient(135deg, #1e3a8a 0%, #1e40af 100%);
    color: white;
    border: none;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    margin-bottom: 12px;
    transition: all 0.3s;
    box-shadow: 0 4px 12px rgba(30, 58, 138, 0.2);
}

.add-btn:hover {
    background: linear-gradient(135deg, #1e40af 0%, #2563eb 100%);
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(30, 58, 138, 0.3);
}

.action-buttons {
    margin-top: 24px;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.sample-data-btn {
    width: 100%;
    padding: 14px;
    background: linear-gradient(135deg, #d97706 0%, #f59e0b 100%);
    color: white;
    border: none;
    border-radius: 8px;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s;
    box-shadow: 0 4px 12px rgba(217, 119, 6, 0.3);
}

.sample-data-btn:hover {
    background: linear-gradient(135deg, #f59e0b 0%, #fbbf24 100%);
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(217, 119, 6, 0.4);
}

/* ========================================
   Scrollbar Styling
   ======================================== */
.form-section::-webkit-scrollbar {
    width: 8px;
}

.form-section::-webkit-scrollbar-track {
    background: #f1f5f9;
    border-radius: 10px;
}

.form-section::-webkit-scrollbar-thumb {
    background: #cbd5e1;
    border-radius: 10px;
    transition: background 0.2s;
}

.form-section::-webkit-scrollbar-thumb:hover {
    background: #94a3b8;
}

/* ========================================
   Preview Section (Right Panel)
   ======================================== */
.preview-section {
    flex: 1;
    display: flex;
    flex-direction: column;
    background: #f8fafc;
    overflow: hidden;
}

.preview-header {
    background: linear-gradient(135deg, #1e3a8a 0%, #1e40af 100%);
    color: white;
    padding: 20px 28px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    box-shadow: 0 4px 12px rgba(30, 58, 138, 0.2);
}

.preview-header h2 {
    font-size: 22px;
    font-weight: 700;
    margin: 0;
}

.preview-actions {
    display: flex;
    gap: 12px;
}

.btn-header-secondary,
.btn-header-success {
    padding: 10px 18px;
    border: none;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
    white-space: nowrap;
}

.btn-header-secondary {
    background: rgba(255, 255, 255, 0.2);
    color: white;
    border: 2px solid rgba(255, 255, 255, 0.4);
}

.btn-header-secondary:hover {
    background: rgba(255, 255, 255, 0.3);
    transform: translateY(-2px);
}

.btn-header-success {
    background: #d97706;
    color: white;
    box-shadow: 0 4px 12px rgba(217, 119, 6, 0.3);
}

.btn-header-success:hover {
    background: #f59e0b;
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(217, 119, 6, 0.4);
}

/* ========================================
   Preview Container
   ======================================== */
.preview-container {
    flex: 1;
    overflow-y: auto;
    padding: 32px;
    display: flex;
    justify-content: center;
    align-items: flex-start;
}

.preview-container::-webkit-scrollbar {
    width: 10px;
}

.preview-container::-webkit-scrollbar-track {
    background: #e2e8f0;
}

.preview-container::-webkit-scrollbar-thumb {
    background: #cbd5e1;
    border-radius: 10px;
}

.preview-container::-webkit-scrollbar-thumb:hover {
    background: #94a3b8;
}

/* ========================================
   Resume Preview Area (A4 Paper Simulation)
   ======================================== */
.resume-preview {
    width: 595px;
    min-height: 842px;
    background: white;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.12);
    border-radius: 8px;
    overflow: hidden;
    position: relative;
}

/* ========================================
   RESUME HEADER - Navy Blue with Gold Accent
   ======================================== */
.resume-header {
    background: linear-gradient(135deg, #1e3a8a 0%, #1e40af 100%);
    padding: 40px 45px 35px 45px;
    color: white;
    position: relative;
    border-bottom: 4px solid #d97706;
}

.resume-header::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 0;
    width: 100%;
    height: 4px;
    background: linear-gradient(90deg, #d97706 0%, #f59e0b 100%);
}

.header-content {
    display: flex;
    align-items: center;
    gap: 30px;
}

/* Profile Photo - Circular with Gold Border */
.profile-photo-container {
    flex-shrink: 0;
}

.profile-photo {
    width: 120px;
    height: 120px;
    border-radius: 50%;
    overflow: hidden;
    border: 4px solid #d97706;
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.3);
    background: rgba(255, 255, 255, 0.1);
    display: flex;
    align-items: center;
    justify-content: center;
}

.profile-photo img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.photo-placeholder {
    font-size: 48px;
    opacity: 0.6;
}

/* Header Text - Name and Title */
.header-text {
    flex: 1;
}

.header-name {
    font-size: 42px;
    font-weight: 800;
    line-height: 1.15;
    margin: 0 0 8px 0;
    color: white;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.header-title {
    font-size: 20px;
    font-weight: 500;
    color: #fbbf24;
    margin: 0;
    text-transform: uppercase;
    letter-spacing: 2px;
}

/* ========================================
   RESUME BODY - Two Column Layout
   ======================================== */
.resume-body {
    display: flex;
    min-height: 700px;
}

/* ========================================
   LEFT SIDEBAR - Light Navy Background
   ======================================== */
.resume-sidebar {
    width: 240px;
    background: linear-gradient(180deg, #dbeafe 0%, #e0e7ff 100%);
    padding: 35px 28px;
    border-right: 3px solid #1e3a8a;
}

.sidebar-section {
    margin-bottom: 32px;
}

.sidebar-title {
    font-size: 16px;
    font-weight: 700;
    color: #1e3a8a;
    margin-bottom: 14px;
    text-transform: uppercase;
    letter-spacing: 1px;
    padding-bottom: 8px;
    border-bottom: 3px solid #d97706;
}

.sidebar-text {
    font-size: 13px;
    line-height: 1.6;
    color: #1e293b;
    margin: 0;
}

/* Experience List in Sidebar */
.experience-list {
    display: flex;
    flex-direction: column;
    gap: 22px;
}

.experience-entry {
    position: relative;
    padding-left: 0;
}

.exp-company {
    font-size: 14px;
    font-weight: 700;
    color: #1e3a8a;
    margin: 0 0 4px 0;
}

.exp-dates {
    font-size: 11px;
    color: #d97706;
    font-weight: 600;
    margin: 0 0 8px 0;
}

.exp-roles {
    list-style: none;
    padding: 0;
    margin: 0;
}

.exp-roles li {
    font-size: 12px;
    color: #334155;
    margin-bottom: 4px;
    padding-left: 14px;
    position: relative;
    line-height: 1.5;
}

.exp-roles li::before {
    content: '▸';
    position: absolute;
    left: 0;
    color: #d97706;
    font-weight: bold;
}

/* ========================================
   RIGHT MAIN CONTENT - White Background
   ======================================== */
.resume-main {
    flex: 1;
    background: white;
    padding: 35px 40px;
}

.main-section {
    margin-bottom: 32px;
}

.main-title {
    font-size: 18px;
    font-weight: 700;
    color: #1e3a8a;
    margin-bottom: 16px;
    text-transform: uppercase;
    letter-spacing: 1px;
    padding-bottom: 10px;
    border-bottom: 3px solid #d97706;
    position: relative;
}

.main-title::after {
    content: '';
    position: absolute;
    bottom: -3px;
    left: 0;
    width: 60px;
    height: 3px;
    background: #1e3a8a;
}

/* Education List */
.education-list {
    display: flex;
    flex-direction: column;
    gap: 18px;
}

.education-entry {
    position: relative;
    padding-left: 0;
}

.edu-institution {
    font-size: 15px;
    font-weight: 700;
    color: #1e293b;
    margin: 0 0 4px 0;
}

.edu-dates {
    font-size: 12px;
    color: #d97706;
    font-weight: 600;
    margin: 0 0 6px 0;
}

.edu-degree {
    font-size: 13px;
    color: #475569;
    margin: 0;
    line-height: 1.5;
}

/* Skills List */
.skills-list {
    list-style: none;
    padding: 0;
    margin: 0;
    display: grid;
    grid-template-columns: 1fr;
    gap: 10px;
}

.skills-list li {
    font-size: 13px;
    color: #1e293b;
    padding: 10px 16px;
    background: linear-gradient(135deg, #dbeafe 0%, #e0e7ff 100%);
    border-left: 4px solid #1e3a8a;
    border-radius: 4px;
    font-weight: 500;
    transition: all 0.2s;
}

.skills-list li:hover {
    transform: translateX(5px);
    box-shadow: 0 2px 8px rgba(30, 58, 138, 0.2);
}

/* Contact List */
.contact-list {
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.contact-item {
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 13px;
    color: #1e293b;
}

.contact-icon {
    font-size: 18px;
    color: #1e3a8a;
    width: 24px;
    text-align: center;
}

.contact-text {
    font-weight: 500;
}

/* ========================================
   MOBILE RESPONSIVE DESIGN
   ======================================== */

@media screen and (max-width: 1200px) {
    .resume-builder-container {
        width: 98vw;
        height: 95vh;
    }
    
    .form-section {
        width: 400px;
    }
}

@media screen and (max-width: 992px) {
    body {
        padding: 10px;
    }
    
    .resume-builder-container {
        flex-direction: column;
        height: auto;
        max-height: none;
        width: 100%;
    }
    
    .form-section {
        width: 100%;
        max-height: 500px;
        border-right: none;
        border-bottom: 2px solid #e2e8f0;
    }
    
    .preview-section {
        min-height: 600px;
    }
    
    .preview-header {
        flex-direction: column;
        gap: 16px;
        align-items: stretch;
    }
    
    .preview-actions {
        justify-content: space-between;
    }
}

@media screen and (max-width: 768px) {
    body {
        overflow: visible !important;
        overflow-y: auto !important;
        height: auto !important;
        min-height: 100vh;
    }

    .resume-builder-container {
        height: auto !important;
        max-height: none !important;
        min-height: auto;
    }

    .form-section {
        max-height: none !important;
        height: auto !important;
        overflow-y: visible;
    }

    .preview-section {
        max-height: none !important;
        height: auto !important;
        overflow-y: visible;
    }

    .resume-preview {
        width: 100%;
        max-width: 500px;
    }
    
    .resume-header {
        padding: 30px 25px;
    }
    
    .header-content {
        flex-direction: column;
        text-align: center;
        gap: 20px;
    }
    
    .header-name {
        font-size: 32px;
    }
    
    .header-title {
        font-size: 16px;
    }
    
    .profile-photo {
        width: 100px;
        height: 100px;
    }
    
    .resume-body {
        flex-direction: column;
    }
    
    .resume-sidebar {
        width: 100%;
        border-right: none;
        border-bottom: 3px solid #1e3a8a;
    }
    
    .resume-main {
        padding: 25px 25px;
    }
    
    .skills-list {
        grid-template-columns: 1fr;
    }
}

@media screen and (max-width: 576px) {
    body {
        padding: 5px;
    }
    
    .preview-container {
        padding: 16px;
    }
    
    .resume-preview {
        border-radius: 4px;
    }
    
    .resume-header {
        padding: 20px 18px;
    }
    
    .header-name {
        font-size: 26px;
    }
    
    .header-title {
        font-size: 14px;
        letter-spacing: 1px;
    }
    
    .profile-photo {
        width: 80px;
        height: 80px;
        border: 3px solid #d97706;
    }
    
    .photo-placeholder {
        font-size: 36px;
    }
    
    .resume-sidebar,
    .resume-main {
        padding: 20px 18px;
    }
    
    .sidebar-title,
    .main-title {
        font-size: 14px;
    }
    
    .form-section h2 {
        font-size: 22px;
    }
    
    .form-section-title {
        font-size: 13px;
    }
    
    .preview-header h2 {
        font-size: 18px;
    }
    
    .btn-header-secondary,
    .btn-header-success {
        padding: 8px 14px;
        font-size: 12px;
    }
}

/* ========================================
   Print Styles
   ======================================== */
@media print {
    body {
        background: white;
        padding: 0;
    }
    
    .resume-builder-container {
        box-shadow: none;
        border-radius: 0;
        height: auto;
    }
    
    .form-section,
    .preview-header {
        display: none !important;
    }
    
    .preview-section {
        background: white;
    }
    
    .preview-container {
        padding: 0;
    }
    
    .resume-preview {
        width: 100%;
        box-shadow: none;
        border-radius: 0;
        page-break-after: always;
    }
}
