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

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    line-height: 1.6;
    color: #333;
    background-color: #f5f5f5;
}

.container {
    max-width: 1200px;
    margin: 2rem auto;
    display: flex;
    background-color: white;
    box-shadow: 0 0 20px rgba(0, 0, 0, 0.1);
    border-radius: 8px;
    overflow: hidden;
}

/* Left column styles */
.left-column {
    width: 300px;
    background-color: #2c3e50;
    color: white;
    padding: 2rem;
    position: relative;
    min-height: 100%;
}

.profile-picture {
    width: 180px;
    height: 180px;
    margin: 0 auto 2.5rem;
    border-radius: 50%;
    overflow: hidden;
    border: 2px solid #3498db;
}

.profile-picture img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.left-column h2 {
    color: #3498db;
    margin-bottom: 1.5rem;
    font-size: 1.2rem;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    font-weight: 600;
}

.left-column .contact-info,
.left-column .skills,
.left-column .languages {
    margin-bottom: 2.5rem;
}

.left-column p {
    margin-bottom: 0.8rem;
    color: #ecf0f1;
    font-size: 0.95rem;
}

.left-column i {
    margin-right: 0.8rem;
    color: #3498db;
    width: 16px;
    text-align: center;
}

.left-column a {
    color: #3498db;
    text-decoration: none;
    transition: color 0.2s;
}

.left-column a:hover {
    color: #2980b9;
}

.left-column .skill-category h3 {
    color: #ecf0f1;
    margin-bottom: 0.8rem;
    font-size: 1rem;
    font-weight: 500;
}

.left-column ul {
    list-style: none;
    margin-left: 0;
}

.left-column li {
    margin-bottom: 0.5rem;
    color: #ecf0f1;
    font-size: 0.95rem;
    padding-left: 0;
}

/* Right column styles */
.right-column {
    flex: 1;
    padding: 2.5rem 3rem;
    background-color: #fff;
}

header {
    margin-bottom: 2.5rem;
    padding-bottom: 1.5rem;
    border-bottom: 1px solid #eee;
}

.profile h1 {
    font-size: 2.5rem;
    color: #2c3e50;
    margin-bottom: 0.5rem;
    letter-spacing: -0.5px;
}

.title {
    font-size: 1.2rem;
    color: #3498db;
    font-weight: 400;
}

/* Section styles */
.section {
    margin-bottom: 2.5rem;
}

.section h2 {
    color: #2c3e50;
    margin-bottom: 1.5rem;
    padding-bottom: 0.8rem;
    border-bottom: 1px solid #eee;
    font-size: 1.5rem;
    letter-spacing: 0.5px;
}

.section p {
    color: #2c3e50;
    line-height: 1.6;
    margin-bottom: 1rem;
}

.section i {
    color: #3498db;
    width: 20px;
    text-align: center;
    margin-right: 0.5rem;
}

/* Timeline styles */
.timeline {
    position: relative;
    padding-left: 25px;
    margin-left: 0;
}

.timeline:before {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 1px;
    background-color: #3498db;
    opacity: 0.5;
}

.timeline-item {
    position: relative;
    margin-bottom: 2rem;
    padding-left: 35px;
}

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

.timeline-item:before {
    content: '';
    position: absolute;
    left: -4px;
    top: 5px;
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background-color: #fff;
    border: 1px solid #3498db;
    z-index: 1;
}

.timeline-date {
    color: #3498db;
    font-weight: 500;
    font-size: 0.95rem;
    margin-bottom: 0.3rem;
}

.timeline-content {
    position: relative;
}

.timeline-content h3 {
    color: #2c3e50;
    margin-bottom: 0.3rem;
    font-size: 1.1rem;
    font-weight: 600;
}

.company, .institution {
    color: #7f8c8d;
    font-style: italic;
    margin-bottom: 0.8rem;
    font-size: 0.9rem;
}

.timeline-content ul {
    list-style: none;
    margin-left: 0;
}

.timeline-content li {
    margin-bottom: 0.4rem;
    padding-left: 1rem;
    position: relative;
    line-height: 1.5;
    color: #2c3e50;
    font-size: 0.95rem;
}

.timeline-content li:before {
    content: "•";
    color: #3498db;
    position: absolute;
    left: 0;
}

/* Print styles */
@media print {
    @page:first {
        margin: 0;
        size: A4;
    }

    @page {
        margin: 1.5rem 0 0 0;
        size: A4;
    }

    body {
        margin: 0;
        padding: 0;
        background-color: #2c3e50 !important;
        -webkit-print-color-adjust: exact !important;
        print-color-adjust: exact !important;
    }

    .container {
        margin: 0;
        padding: 0;
        width: 210mm;
        min-height: 297mm;
        box-shadow: none;
        border-radius: 0;
        overflow: visible;
        background-color: #2c3e50 !important;
        display: flex;
    }

    .left-column {
        background-color: #2c3e50 !important;
        color: white !important;
        width: 300px;
        padding: 2rem;
        -webkit-print-color-adjust: exact !important;
        print-color-adjust: exact !important;
    }

    /* Skills section print layout */
    .left-column .skills {
        display: grid !important;
        grid-template-columns: repeat(2, 1fr) !important;
        gap: 1rem !important;
        margin-bottom: 1rem !important;
        margin-top: 6rem !important;
    }

    .left-column .skills h2 {
        position: absolute !important;
        margin-top: -3rem !important;
        color: #3498db !important;
        font-size: 1.2rem !important;
        text-transform: uppercase !important;
        letter-spacing: 1.5px !important;
    }

    .skill-category {
        break-inside: avoid;
        margin-bottom: 1rem !important;
    }

    .skill-category h3 {
        color: #ecf0f1 !important;
        margin-bottom: 0.5rem !important;
        font-size: 1rem !important;
        font-weight: 500 !important;
    }

    .skill-category ul {
        margin: 0 !important;
        padding: 0 !important;
    }

    .skill-category li {
        color: #ecf0f1 !important;
        margin-bottom: 0.3rem !important;
        font-size: 0.9rem !important;
        line-height: 1.3 !important;
    }

    /* Timeline print styles */
    .timeline {
        break-inside: auto;
        margin-bottom: 0;
        padding-left: 20px;
        margin-top: 2rem !important;
    }

    .timeline-item {
        break-inside: avoid !important;
        page-break-inside: avoid !important;
        margin-bottom: 2.5rem !important;
        padding-left: 25px;
        position: relative;
        padding-top: 0.1rem !important;
    }

    .timeline-item:first-child {
        margin-top: 0.5rem !important;
    }

    .timeline-item:last-child {
        margin-bottom: 3rem;
    }

    .timeline-date {
        color: #3498db !important;
        font-weight: 500;
        margin-bottom: 0.5rem !important;
        line-height: 1.2 !important;
        font-size: 0.95rem !important;
    }

    .timeline-content {
        break-inside: avoid !important;
        page-break-inside: avoid !important;
    }

    .timeline-content h3 {
        color: #2c3e50 !important;
        margin-bottom: 0.5rem !important;
        font-size: 1.1rem;
    }

    .company, .institution {
        margin-bottom: 1rem !important;
    }

    .timeline-content ul {
        break-inside: avoid !important;
        page-break-inside: avoid !important;
        margin-left: 0;
    }

    .timeline-content li {
        margin-bottom: 0.5rem !important;
        line-height: 1.4 !important;
    }

    /* Section styles for print */
    .section {
        break-before: auto;
        break-after: auto;
        break-inside: avoid !important;
        page-break-before: auto;
        page-break-after: auto;
        page-break-inside: avoid !important;
        margin-bottom: 3rem !important;
        margin-top: 1.5rem !important;
    }

    .section:first-child {
        margin-top: 0 !important;
    }

    .section h2 {
        break-after: avoid !important;
        page-break-after: avoid !important;
        margin-bottom: 2rem !important;
        padding-bottom: 1rem !important;
    }

    /* Ensure the timeline line prints correctly */
    .timeline:before {
        content: '';
        position: absolute;
        left: 0;
        top: 0;
        bottom: 0;
        width: 1px;
        background-color: #3498db !important;
        opacity: 0.5;
    }

    .timeline-item:before {
        content: '';
        position: absolute;
        left: -4px;
        top: 0.25rem !important;
        width: 10px !important;
        height: 10px !important;
        border-radius: 50%;
        background-color: white !important;
        border: 2px solid #3498db !important;
        z-index: 1;
    }

    .right-column {
        background-color: white !important;
        padding: 2rem 2.5rem 3rem !important;
        flex: 1;
    }

    /* First page specific styles */
    .container:first-of-type .right-column {
        padding-top: 0 !important;
    }

    /* Other pages specific styles */
    .container:not(:first-of-type) {
        margin-top: 2rem !important;
        page-break-before: always;
    }

    .container:not(:first-of-type) .right-column {
        padding-top: 3rem !important;
    }

    /* Ensure proper page breaks */
    .section {
        break-inside: avoid;
        page-break-inside: avoid;
    }

    .profile h1 {
        color: #2c3e50 !important;
        -webkit-print-color-adjust: exact;
        print-color-adjust: exact;
        color-adjust: exact;
    }

    .title {
        color: #3498db !important;
        -webkit-print-color-adjust: exact;
        print-color-adjust: exact;
        color-adjust: exact;
    }

    .section h2 {
        color: #2c3e50 !important;
        border-bottom: 1px solid #eee !important;
        -webkit-print-color-adjust: exact;
        print-color-adjust: exact;
        color-adjust: exact;
    }

    /* Hide shadow and adjust borders */
    * {
        text-shadow: none !important;
        box-shadow: none !important;
    }

    /* Ensure links don't show URLs */
    a[href]:after {
        content: none !important;
    }

    /* Override skills layout for print - custom grid layout */
    .skills {
        display: grid !important;
        grid-template-columns: repeat(2, 1fr) !important;
        gap: 2rem !important;
    }
    
    .skill-category {
        break-inside: avoid;
        margin-bottom: 2rem !important;
    }

    /* Reorder skill categories for print */
    .skill-category:nth-of-type(1) { /* Leadership & Management */
        grid-row: 1;
        grid-column: 1;
    }
    
    .skill-category:nth-of-type(2) { /* Development */
        grid-row: 1;
        grid-column: 2;
    }
    
    .skill-category:nth-of-type(3) { /* DevOps & Infrastructure */
        grid-row: 2;
        grid-column: 1;
    }
    
    .skill-category:nth-of-type(4) { /* Security */
        grid-row: 2;
        grid-column: 2;
    }
    
    .skill-category h3 {
        color: #ecf0f1 !important;
        margin-bottom: 1rem !important;
        font-size: 1rem !important;
        font-weight: 500 !important;
    }
    
    .skill-category li {
        color: #ecf0f1 !important;
        margin-bottom: 0.5rem !important;
        font-size: 0.9rem !important;
    }

    .timeline-item {
        orphans: 3;
        widows: 3;
    }

    .personal-info {
        margin-bottom: 1.5rem !important;
    }

    .personal-info h2 {
        color: #3498db !important;
        margin-bottom: 0.8rem !important;
        font-size: 1.1rem !important;
    }

    .personal-info p {
        color: #ecf0f1 !important;
        margin-bottom: 0.4rem !important;
    }

    .personal-info i {
        color: #3498db !important;
    }

    .section p {
        color: #2c3e50 !important;
        -webkit-print-color-adjust: exact !important;
        print-color-adjust: exact !important;
    }

    .section i {
        color: #3498db !important;
        -webkit-print-color-adjust: exact !important;
        print-color-adjust: exact !important;
    }

    .thesis {
        color: #2c3e50 !important;
        margin: 0.8rem 0 !important;
        -webkit-print-color-adjust: exact !important;
        print-color-adjust: exact !important;
    }

    .thesis strong {
        color: #3498db !important;
        -webkit-print-color-adjust: exact !important;
        print-color-adjust: exact !important;
    }

    .timeline-content a {
        color: #3498db !important;
        text-decoration: none !important;
        -webkit-print-color-adjust: exact !important;
        print-color-adjust: exact !important;
    }

    .timeline-content a i {
        font-size: 0.8rem;
    }
}

/* Skills styles */
.skills {
    display: block;
    margin-top: 0;
}

.skill-category {
    margin-bottom: 1.5rem;
}

.skill-category h3 {
    color: #ecf0f1;
    margin-bottom: 0.5rem;
    font-size: 0.95rem;
    font-weight: 500;
}

.skill-category ul {
    list-style: none;
    margin: 0;
}

.skill-category li {
    margin-bottom: 0.4rem;
    padding-left: 0;
    position: relative;
    color: #ecf0f1;
    font-size: 0.9rem;
}

.skill-category li:before {
    display: none;
}

/* Languages styles */
.languages p {
    margin-bottom: 0.5rem;
}

/* Responsive design */
@media (max-width: 1024px) {
    .timeline-date {
        margin-bottom: 0.3rem;
    }

    .timeline {
        padding-left: 20px;
    }

    .timeline-item {
        padding-left: 25px;
    }
}

@media (max-width: 768px) {
    .container {
        flex-direction: column;
        margin: 0;
        border-radius: 0;
    }

    .left-column {
        width: 100%;
        padding: 2rem;
    }

    .profile-picture {
        width: 150px;
        height: 150px;
    }

    .right-column {
        padding: 2rem;
    }
}

.personal-info {
    margin-bottom: 2rem;
}

.personal-info h2 {
    color: #3498db;
    margin-bottom: 1rem;
    font-size: 1.2rem;
    text-transform: uppercase;
    letter-spacing: 1.5px;
}

.personal-info p {
    color: #ecf0f1;
    margin-bottom: 0.5rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.personal-info i {
    color: #3498db;
    width: 20px;
    text-align: center;
}

.thesis {
    color: #2c3e50;
    margin: 0.8rem 0;
    font-size: 0.95rem;
}

.thesis strong {
    color: #3498db;
}

.timeline-content a {
    color: #3498db;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    transition: color 0.2s;
}

.timeline-content a:hover {
    color: #2980b9;
}

.timeline-content a i {
    font-size: 0.8rem;
} 