@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700&family=Playfair+Display:wght@400;500;600;700&display=swap');

:root {
    --rmt-primary: #4f46e5;
    --rmt-primary-dark: #4338ca;
    --rmt-primary-light: #818cf8;
    --rmt-secondary: #64748b;
    --rmt-success: #10b981;
    --rmt-danger: #ef4444;
    --rmt-warning: #f59e0b;
    --rmt-bg: #f8fafc;
    --rmt-surface: #ffffff;
    --rmt-border: #e2e8f0;
    --rmt-text: #1e293b;
    --rmt-text-light: #64748b;
    --rmt-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    --rmt-shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
    --rmt-radius: 8px;
    --rmt-radius-lg: 12px;
    --rmt-font: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    --rmt-font-serif: 'Playfair Display', Georgia, serif;
}

* {
    box-sizing: border-box;
}

.rmt-container {
    font-family: var(--rmt-font);
    background: var(--rmt-bg);
    min-height: 100vh;
    padding: 2rem;
    max-width: 1400px;
    margin: 0 auto;
}

.rmt-header {
    text-align: center;
    margin-bottom: 2rem;
}

.rmt-title {
    font-size: 2.5rem;
    font-weight: 700;
    color: var(--rmt-text);
    margin: 0 0 0.5rem;
    background: linear-gradient(135deg, var(--rmt-primary) 0%, var(--rmt-primary-light) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.rmt-subtitle {
    color: var(--rmt-text-light);
    font-size: 1.1rem;
    margin: 0;
}

.rmt-main-wrapper {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
    align-items: start;
}

@media (max-width: 1200px) {
    .rmt-main-wrapper {
        grid-template-columns: 1fr;
    }
}

.rmt-form-section {
    background: var(--rmt-surface);
    border-radius: var(--rmt-radius-lg);
    padding: 2rem;
    box-shadow: var(--rmt-shadow);
}

.rmt-toolbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-bottom: 1.5rem;
    border-bottom: 1px solid var(--rmt-border);
    margin-bottom: 1.5rem;
    flex-wrap: wrap;
    gap: 1rem;
}

.rmt-template-selector {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.rmt-template-selector label {
    font-weight: 500;
    color: var(--rmt-text);
}

.rmt-select {
    padding: 0.5rem 1rem;
    border: 1px solid var(--rmt-border);
    border-radius: var(--rmt-radius);
    background: var(--rmt-surface);
    font-size: 0.95rem;
    cursor: pointer;
    transition: border-color 0.2s, box-shadow 0.2s;
}

.rmt-select:focus {
    outline: none;
    border-color: var(--rmt-primary);
    box-shadow: 0 0 0 3px rgba(79, 70, 229, 0.1);
}

.rmt-checkbox-label {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    cursor: pointer;
    font-size: 0.9rem;
    color: var(--rmt-text-light);
}

.rmt-checkbox-label input[type="checkbox"] {
    width: 18px;
    height: 18px;
    cursor: pointer;
}

.rmt-form-section-title {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--rmt-text);
    margin: 2rem 0 1rem;
    padding-bottom: 0.75rem;
    border-bottom: 2px solid var(--rmt-primary);
}

.rmt-form-section-title i {
    color: var(--rmt-primary);
    font-size: 1.25rem;
}

.rmt-form-section-title .rmt-btn {
    margin-left: auto;
}

.rmt-form-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1rem;
}

@media (max-width: 600px) {
    .rmt-form-grid {
        grid-template-columns: 1fr;
    }
}

.rmt-form-group {
    display: flex;
    flex-direction: column;
}

.rmt-form-group.rmt-full-width {
    grid-column: 1 / -1;
}

.rmt-form-group label {
    font-weight: 500;
    color: var(--rmt-text);
    margin-bottom: 0.5rem;
    font-size: 0.9rem;
}

.rmt-input,
.rmt-textarea {
    padding: 0.75rem 1rem;
    border: 1px solid var(--rmt-border);
    border-radius: var(--rmt-radius);
    font-size: 0.95rem;
    font-family: var(--rmt-font);
    transition: border-color 0.2s, box-shadow 0.2s;
    background: var(--rmt-surface);
}

.rmt-input:focus,
.rmt-textarea:focus {
    outline: none;
    border-color: var(--rmt-primary);
    box-shadow: 0 0 0 3px rgba(79, 70, 229, 0.1);
}

.rmt-input.rmt-input-error,
.rmt-textarea.rmt-input-error {
    border-color: var(--rmt-danger);
}

.rmt-input.rmt-input-error:focus,
.rmt-textarea.rmt-input-error:focus {
    box-shadow: 0 0 0 3px rgba(239, 68, 68, 0.1);
}

.rmt-error-message {
    color: var(--rmt-danger);
    font-size: 0.8rem;
    margin-top: 0.25rem;
    min-height: 1.2rem;
}

.rmt-textarea {
    resize: vertical;
    min-height: 100px;
}

.rmt-upload-wrapper {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.rmt-upload-preview {
    width: 100px;
    height: 100px;
    border: 2px dashed var(--rmt-border);
    border-radius: var(--rmt-radius);
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--rmt-bg);
    overflow: hidden;
}

.rmt-upload-preview img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.rmt-upload-preview i {
    font-size: 2.5rem;
    color: var(--rmt-secondary);
}

.rmt-tags-input {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    padding: 0.75rem;
    border: 1px solid var(--rmt-border);
    border-radius: var(--rmt-radius);
    background: var(--rmt-surface);
    min-height: 50px;
}

.rmt-tags-list {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.rmt-tag {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.35rem 0.75rem;
    background: var(--rmt-primary);
    color: white;
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: 500;
}

.rmt-tag-remove {
    background: none;
    border: none;
    color: white;
    cursor: pointer;
    padding: 0;
    font-size: 1.1rem;
    line-height: 1;
    opacity: 0.8;
    transition: opacity 0.2s;
}

.rmt-tag-remove:hover {
    opacity: 1;
}

.rmt-tag-input {
    flex: 1;
    min-width: 150px;
    border: none;
    outline: none;
    padding: 0.25rem;
    font-size: 0.95rem;
    font-family: var(--rmt-font);
    background: transparent;
}

.rmt-repeatable-list {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.rmt-repeatable-item {
    background: var(--rmt-bg);
    border: 1px solid var(--rmt-border);
    border-radius: var(--rmt-radius);
    padding: 1.25rem;
}

.rmt-repeatable-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
}

.rmt-repeatable-title {
    font-weight: 600;
    color: var(--rmt-text);
}

.rmt-empty-message {
    text-align: center;
    padding: 2rem;
    color: var(--rmt-text-light);
    background: var(--rmt-bg);
    border: 2px dashed var(--rmt-border);
    border-radius: var(--rmt-radius);
}

.rmt-empty-message i {
    font-size: 2rem;
    margin-bottom: 0.5rem;
    display: block;
}

.rmt-empty-message p {
    margin: 0;
}

.rmt-form-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    margin-top: 2rem;
    padding-top: 1.5rem;
    border-top: 1px solid var(--rmt-border);
}

.rmt-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.75rem 1.5rem;
    border: none;
    border-radius: var(--rmt-radius);
    font-size: 0.95rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s;
    font-family: var(--rmt-font);
}

.rmt-btn-primary {
    background: var(--rmt-primary);
    color: white;
}

.rmt-btn-primary:hover {
    background: var(--rmt-primary-dark);
    transform: translateY(-1px);
}

.rmt-btn-success {
    background: var(--rmt-success);
    color: white;
}

.rmt-btn-success:hover {
    background: #059669;
    transform: translateY(-1px);
}

.rmt-btn-secondary {
    background: var(--rmt-secondary);
    color: white;
}

.rmt-btn-secondary:hover {
    background: #475569;
    transform: translateY(-1px);
}

.rmt-btn-danger {
    background: var(--rmt-danger);
    color: white;
}

.rmt-btn-danger:hover {
    background: #dc2626;
}

.rmt-btn-add {
    background: var(--rmt-primary-light);
    color: white;
    padding: 0.4rem 0.75rem;
    font-size: 0.85rem;
}

.rmt-btn-add:hover {
    background: var(--rmt-primary);
}

.rmt-btn-small {
    padding: 0.4rem 0.75rem;
    font-size: 0.85rem;
}

.rmt-btn-icon {
    width: 40px;
    height: 40px;
    padding: 0;
    border-radius: 50%;
    background: var(--rmt-bg);
    color: var(--rmt-secondary);
}

.rmt-btn-icon:hover {
    background: var(--rmt-primary);
    color: white;
}

.rmt-preview-section {
    background: var(--rmt-surface);
    border-radius: var(--rmt-radius-lg);
    padding: 1.5rem;
    box-shadow: var(--rmt-shadow);
    position: sticky;
    top: 2rem;
}

.rmt-preview-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid var(--rmt-border);
}

.rmt-preview-header h2 {
    margin: 0;
    font-size: 1.25rem;
    color: var(--rmt-text);
}

.rmt-preview-wrapper {
    background: #e5e7eb;
    border-radius: var(--rmt-radius);
    padding: 1rem;
    min-height: 600px;
    overflow: auto;
}

.rmt-preview {
    background: white;
    box-shadow: var(--rmt-shadow-lg);
    border-radius: 4px;
    overflow: hidden;
}

.rmt-preview-placeholder {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-height: 500px;
    color: var(--rmt-secondary);
    text-align: center;
    padding: 2rem;
}

.rmt-preview-placeholder i {
    font-size: 4rem;
    margin-bottom: 1rem;
    opacity: 0.3;
}

.rmt-loading-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    z-index: 9999;
}

.rmt-loading-overlay p {
    color: white;
    font-size: 1.1rem;
    margin-top: 1rem;
}

.rmt-spinner {
    width: 50px;
    height: 50px;
    border: 4px solid rgba(255, 255, 255, 0.3);
    border-top-color: white;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

@media (max-width: 768px) {
    .rmt-container {
        padding: 1rem;
    }
    
    .rmt-title {
        font-size: 1.75rem;
    }
    
    .rmt-form-section {
        padding: 1.25rem;
    }
    
    .rmt-form-actions {
        flex-direction: column;
    }
    
    .rmt-btn {
        width: 100%;
    }
}

.resume-simple {
    padding: 2rem;
    font-family: var(--rmt-font);
    font-size: 11pt;
    line-height: 1.6;
    color: #333;
    max-width: 210mm;
    margin: 0 auto;
    background: white;
}

.resume-simple-photo {
    width: 100px;
    height: 100px;
    border-radius: 50%;
    overflow: hidden;
    margin: 0 auto 1.5rem;
    border: 3px solid var(--rmt-primary);
}

.resume-simple-photo img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.resume-simple-header {
    text-align: center;
    margin-bottom: 1.5rem;
    padding-bottom: 1rem;
    border-bottom: 2px solid var(--rmt-primary);
}

.resume-simple-header h1 {
    font-size: 24pt;
    font-weight: 700;
    color: #1e293b;
    margin: 0 0 0.75rem;
}

.resume-simple-contact {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 1rem;
    font-size: 10pt;
    color: #64748b;
}

.resume-simple-contact span {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
}

.resume-simple-section {
    margin-bottom: 1.5rem;
}

.resume-simple-section h2 {
    font-size: 14pt;
    font-weight: 600;
    color: var(--rmt-primary);
    margin: 0 0 0.75rem;
    padding-bottom: 0.35rem;
    border-bottom: 1px solid #e2e8f0;
}

.resume-simple-skills {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.skill-tag {
    background: #f1f5f9;
    color: #475569;
    padding: 0.25rem 0.75rem;
    border-radius: 20px;
    font-size: 9pt;
    font-weight: 500;
}

.resume-simple-item {
    margin-bottom: 1rem;
}

.resume-simple-item:last-child {
    margin-bottom: 0;
}

.resume-simple-item-header {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    margin-bottom: 0.25rem;
}

.resume-simple-item-header h3 {
    font-size: 12pt;
    font-weight: 600;
    color: #1e293b;
    margin: 0;
}

.resume-simple-item-date {
    font-size: 9pt;
    color: #64748b;
}

.resume-simple-item h4 {
    font-size: 11pt;
    font-weight: 500;
    color: #475569;
    margin: 0 0 0.35rem;
}

.resume-simple-item p {
    margin: 0;
    font-size: 10pt;
    color: #64748b;
}

.resume-modern {
    display: grid;
    grid-template-columns: 280px 1fr;
    min-height: 297mm;
    font-family: var(--rmt-font);
    max-width: 210mm;
    margin: 0 auto;
    background: white;
}

.resume-modern-sidebar {
    background: linear-gradient(135deg, #1e293b 0%, #334155 100%);
    color: white;
    padding: 2rem 1.5rem;
}

.resume-modern-photo {
    width: 120px;
    height: 120px;
    border-radius: 50%;
    overflow: hidden;
    margin: 0 auto 1.5rem;
    border: 4px solid rgba(255, 255, 255, 0.2);
}

.resume-modern-photo img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.resume-modern-contact h3,
.resume-modern-skills h3 {
    font-size: 12pt;
    font-weight: 600;
    margin: 0 0 1rem;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: var(--rmt-primary-light);
}

.resume-modern-contact p {
    font-size: 10pt;
    margin: 0 0 0.75rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    word-break: break-word;
}

.resume-modern-contact i {
    width: 16px;
    color: var(--rmt-primary-light);
}

.resume-modern-skills {
    margin-top: 2rem;
}

.resume-modern-skills .skill-tag {
    background: rgba(255, 255, 255, 0.1);
    color: white;
    margin-bottom: 0.5rem;
    display: block;
}

.resume-modern-main {
    padding: 2rem;
}

.resume-modern-main > h1 {
    font-size: 28pt;
    font-weight: 700;
    color: #1e293b;
    margin: 0 0 1.5rem;
}

.resume-modern-section {
    margin-bottom: 1.75rem;
}

.resume-modern-section h2 {
    font-size: 14pt;
    font-weight: 600;
    color: var(--rmt-primary);
    margin: 0 0 1rem;
    padding-bottom: 0.5rem;
    border-bottom: 2px solid var(--rmt-primary);
}

.resume-modern-section > p {
    font-size: 10pt;
    line-height: 1.7;
    color: #475569;
    margin: 0;
}

.resume-modern-item {
    margin-bottom: 1.25rem;
}

.resume-modern-item:last-child {
    margin-bottom: 0;
}

.resume-modern-item-header {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    margin-bottom: 0.25rem;
}

.resume-modern-item-header h3 {
    font-size: 12pt;
    font-weight: 600;
    color: #1e293b;
    margin: 0;
}

.resume-modern-item-header span {
    font-size: 9pt;
    color: var(--rmt-primary);
    font-weight: 500;
}

.resume-modern-item h4 {
    font-size: 11pt;
    font-weight: 500;
    color: #475569;
    margin: 0 0 0.35rem;
}

.resume-modern-item p {
    font-size: 10pt;
    color: #64748b;
    margin: 0;
    line-height: 1.6;
}

@media (max-width: 768px) {
    .resume-modern {
        grid-template-columns: 1fr;
    }
    
    .resume-modern-sidebar {
        padding: 1.5rem;
    }
}

.resume-creative {
    font-family: var(--rmt-font);
    max-width: 210mm;
    margin: 0 auto;
    background: linear-gradient(180deg, #f8fafc 0%, #ffffff 100%);
}

.resume-creative-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 2.5rem;
    background: linear-gradient(135deg, #4f46e5 0%, #7c3aed 50%, #db2777 100%);
    color: white;
}

.resume-creative-left h1 {
    font-size: 28pt;
    font-weight: 700;
    margin: 0 0 1rem;
}

.resume-creative-contact {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
    font-size: 10pt;
}

.resume-creative-contact span {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    background: rgba(255, 255, 255, 0.15);
    padding: 0.35rem 0.75rem;
    border-radius: 20px;
}

.resume-creative-photo {
    width: 120px;
    height: 120px;
    border-radius: 50%;
    overflow: hidden;
    border: 4px solid rgba(255, 255, 255, 0.3);
}

.resume-creative-photo img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.resume-creative-section {
    padding: 1.5rem 2.5rem;
}

.resume-creative-section h2 {
    font-size: 14pt;
    font-weight: 600;
    color: #1e293b;
    margin: 0 0 1rem;
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.resume-creative-section h2 i {
    color: var(--rmt-primary);
    font-size: 1.1rem;
}

.resume-creative-summary p {
    font-size: 11pt;
    line-height: 1.7;
    color: #475569;
    margin: 0;
    padding: 1rem;
    background: white;
    border-left: 4px solid var(--rmt-primary);
    border-radius: 0 8px 8px 0;
}

.resume-creative-skills {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 0.75rem;
}

.skill-bar {
    background: white;
    padding: 0.75rem 1rem;
    border-radius: 8px;
    display: flex;
    flex-direction: column;
    gap: 0.35rem;
}

.skill-name {
    font-size: 9pt;
    font-weight: 600;
    color: #1e293b;
}

.skill-progress {
    height: 6px;
    background: #e2e8f0;
    border-radius: 3px;
    overflow: hidden;
}

.skill-progress-bar {
    height: 100%;
    background: linear-gradient(90deg, var(--rmt-primary) 0%, var(--rmt-primary-light) 100%);
    border-radius: 3px;
    transition: width 0.5s ease;
}

.resume-creative-item {
    display: flex;
    gap: 1.5rem;
    margin-bottom: 1.25rem;
    animation: fadeIn 0.5s ease forwards;
    animation-delay: var(--delay, 0s);
    opacity: 0;
}

@keyframes fadeIn {
    to { opacity: 1; }
}

.resume-creative-timeline {
    display: flex;
    flex-direction: column;
    align-items: center;
    width: 20px;
}

.timeline-dot {
    width: 12px;
    height: 12px;
    background: var(--rmt-primary);
    border-radius: 50%;
    border: 3px solid white;
    box-shadow: 0 0 0 2px var(--rmt-primary);
}

.timeline-line {
    flex: 1;
    width: 2px;
    background: linear-gradient(180deg, var(--rmt-primary) 0%, #e2e8f0 100%);
    margin-top: 0.5rem;
}

.resume-creative-item:last-child .timeline-line {
    display: none;
}

.resume-creative-item-content {
    flex: 1;
    background: white;
    padding: 1rem 1.25rem;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
}

.resume-creative-date {
    font-size: 9pt;
    color: var(--rmt-primary);
    font-weight: 600;
}

.resume-creative-item-content h3 {
    font-size: 12pt;
    font-weight: 600;
    color: #1e293b;
    margin: 0.25rem 0;
}

.resume-creative-item-content h4 {
    font-size: 10pt;
    font-weight: 500;
    color: #64748b;
    margin: 0 0 0.5rem;
}

.resume-creative-item-content p {
    font-size: 10pt;
    color: #475569;
    margin: 0;
    line-height: 1.6;
}

.resume-creative-projects {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1rem;
}

.resume-creative-project {
    background: white;
    padding: 1.25rem;
    border-radius: 8px;
    border-left: 4px solid var(--rmt-primary);
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
}

.resume-creative-project h3 {
    font-size: 11pt;
    font-weight: 600;
    color: #1e293b;
    margin: 0 0 0.5rem;
}

.resume-creative-project p {
    font-size: 10pt;
    color: #64748b;
    margin: 0;
    line-height: 1.5;
}

@media (max-width: 768px) {
    .resume-creative-header {
        flex-direction: column-reverse;
        text-align: center;
        padding: 1.5rem;
    }
    
    .resume-creative-left h1 {
        font-size: 22pt;
    }
    
    .resume-creative-contact {
        justify-content: center;
    }
    
    .resume-creative-section {
        padding: 1.25rem;
    }
    
    .resume-creative-skills,
    .resume-creative-projects {
        grid-template-columns: 1fr;
    }
}

@media print {
    .rmt-container {
        padding: 0;
        background: white;
    }
    
    .rmt-form-section,
    .rmt-toolbar,
    .rmt-form-actions,
    .rmt-preview-header,
    .rmt-loading-overlay {
        display: none !important;
    }
    
    .rmt-main-wrapper {
        display: block;
    }
    
    .rmt-preview-section {
        box-shadow: none;
        padding: 0;
    }
    
    .rmt-preview-wrapper {
        background: white;
        padding: 0;
    }
    
    .resume-modern-sidebar {
        -webkit-print-color-adjust: exact;
        print-color-adjust: exact;
    }
    
    .resume-creative-header {
        -webkit-print-color-adjust: exact;
        print-color-adjust: exact;
    }
    
    .skill-progress-bar {
        -webkit-print-color-adjust: exact;
        print-color-adjust: exact;
    }
}
