* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    font-family: 'Poppins', sans-serif;
    font-weight: 300;
    background: #e8e8e8;
    color: #333;
    font-size: 15px;
}

.main.page {
    padding: 2rem 1rem;
    min-height: 100vh;
}

.content-holder {
    display: flex;
    max-width: 1600px;
    margin: 0 auto;
    background: #fff;
    box-shadow: 0 2px 20px rgba(0, 0, 0, 0.12);
    position: relative;
}

.content-holder::after {
    content: '';
    position: absolute;
    top: 0;
    left: 300px;
    width: 1px;
    height: 100%;
    background: #ebebeb;
    z-index: 5;
}

/* ── SIDEBAR ── */

.sidebar {
    width: 300px;
    min-width: 300px;
    background: #fff;
    padding: 2rem 2rem;
    flex-shrink: 0;
    position: relative;
}

.me {
    width: 150px;
    height: 150px;
    border-radius: 50%;
    overflow: hidden;
    margin: 0 auto 1.25rem;
    background: #f2f2f2;
    display: flex;
    align-items: center;
    justify-content: center;
}

.me img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.me i {
    font-size: 3.5rem;
    color: #ccc;
}

.profile-header {
    margin-bottom: 2.2rem;
    padding-bottom: 2rem;
    border-bottom: 1px solid #e8e8e8;
}

.profile-header h1 {
    font-size: 1.45rem;
    font-weight: 700;
    color: #222;
    margin-bottom: 0.3rem;
    line-height: 1.2;
}

.profile-header h2 {
    font-size: 0.85rem;
    font-weight: 400;
    color: #999;
    margin-bottom: 1.5rem;
    border: none;
    padding: 0;
}

.profile-header .button {
    display: inline-block;
    background: #dc143c;
    color: #fff !important;
    border-radius: 20px;
    padding: 0.5rem 1.4rem;
    font-size: 0.75rem;
    font-weight: 700;
    text-decoration: none;
    cursor: pointer;
    font-family: 'Poppins', sans-serif;
    transition: background 0.2s;
}

.profile-header .button:hover {
    background: #b91c32;
}

.info-cnt {
    margin-top: 0;
}

.general-info {
    margin-bottom: 0.8rem;
}

.gen-item {
    margin-bottom: 0.95rem;
}

.gen-item .label {
    font-size: 0.75rem;
    color: #555;
    margin-bottom: 0.2rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-weight: 500;
}

.gen-item .label i {
    width: 14px;
    color: #888;
    font-size: 0.8rem;
}

.gen-item .label span {
    color: #555;
}

.gen-item .value {
    font-size: 0.88rem;
    font-weight: 700;
    color: #222;
    padding-left: 0;
}

.gen-item .value a {
    color: #0066cc;
    text-decoration: none;
    font-weight: 700;
    transition: color 0.2s;
}

.gen-item .value a:hover {
    color: #0052a3;
}

.sidebar-sep {
    height: 1px;
    background: #e8e8e8;
    margin: 1.2rem 0;
}

/* ── MAIN CONTENT ── */

.content {
    flex: 1;
    padding: 2rem 3rem;
    min-width: 0;
}

.cv-section {
    margin-bottom: 2.2rem;
}

.cv-section > h2 {
    font-size: 0.95rem;
    font-weight: 700;
    color: #222;
    border-bottom: 2px solid #e0e0e0;
    padding-bottom: 0.6rem;
    margin-bottom: 1.3rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-family: 'Poppins', sans-serif;
}

.cv-section > h2 i {
    color: #666;
    font-size: 0.9rem;
}

.cv-section-body {
    margin-top: 0.5rem;
}

.cv-section-item {
    display: flex;
    gap: 1.8rem;
    margin-bottom: 1.8rem;
}

.cv-section-item.d-block {
    display: block;
}

.cv-item-left {
    min-width: 130px;
    max-width: 130px;
    flex-shrink: 0;
    text-align: right;
}

.cv-item-left .date {
    font-size: 0.75rem;
    color: #666;
    padding-top: 0.05rem;
    font-weight: 500;
}

.cv-item-right {
    flex: 1;
    min-width: 0;
}

.cv-item-right h3 {
    font-size: 0.98rem;
    font-weight: 700;
    color: #222;
    margin-bottom: 0.25rem;
}

.cv-item-right .institution {
    font-size: 0.8rem;
    color: #555;
    margin-bottom: 0.6rem;
    display: flex;
    align-items: center;
    gap: 0.4rem;
    flex-wrap: wrap;
}

.cv-item-right .institution i {
    color: #888;
    font-size: 0.75rem;
}

.cv-item-right .institution a {
    color: #555;
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 0.3rem;
    transition: color 0.2s;
}

.cv-item-right .institution a:hover {
    color: #dc143c;
}

.cv-item-right .thesis {
    margin-top: 0.4rem;
}

.cv-item-right .thesis a {
    font-size: 0.8rem;
    color: #dc143c;
    text-decoration: none;
    transition: color 0.2s;
}

.cv-item-right .thesis a:hover {
    color: #b91c32;
}

.cv-item-right p {
    font-size: 0.82rem;
    line-height: 1.75;
    color: #444;
    margin-bottom: 0.6rem;
}

.cv-item-right p:last-child {
    margin-bottom: 0;
}

.cv-item-right li {
    font-size: 0.82rem;
    line-height: 1.75;
    color: #444;
    margin-bottom: 0.4rem;
}

.cv-ul-list {
    list-style: none;
    padding: 0;
    margin-top: 0.3rem;
}

.cv-section-item.d-block p {
    font-size: 0.83rem;
    line-height: 1.75;
    color: #444;
    margin-bottom: 0.6rem;
}

.last-edit {
    font-size: 0.75rem;
    color: #aaa;
    text-align: center;
}

/* ── PRINT ── */

@media print {
    @page {
        size: A4;
        margin: 0;
    }

    * {
        -webkit-print-color-adjust: exact !important;
        print-color-adjust: exact !important;
    }

    body {
        background: #fff !important;
        font-size: 10px !important;
        margin: 0 !important;
        padding: 0 !important;
    }

    .main.page {
        padding: 0 !important;
        min-height: 0 !important;
        background: #fff !important;
    }

    .content-holder {
        display: flex !important;
        flex-direction: row !important;
        align-items: flex-start !important;
        box-shadow: none !important;
        max-width: 100% !important;
        width: 100% !important;
        margin: 0 !important;
        background-image: none !important;
        position: relative;
    }

    .content-holder::after {
        content: '';
        position: absolute;
        top: 0;
        left: 180px;
        width: 1px;
        height: 100%;
        background: #ebebeb;
    }

    .sidebar {
        display: block !important;
        width: 180px !important;
        min-width: 180px !important;
        max-width: 180px !important;
        padding: 1rem 0.9rem !important;
        border-right: none !important;
        border-bottom: none !important;
        flex-shrink: 0 !important;
        align-self: flex-start !important;
        position: relative !important;
    }

    .sidebar::after {
        display: none !important;
        content: none !important;
    }

    .me {
        width: 80px !important;
        height: 80px !important;
        margin-bottom: 0.6rem !important;
    }

    .profile-header {
        margin-bottom: 1rem !important;
        padding-bottom: 1rem !important;
        border-bottom: 1px solid #e8e8e8 !important;
    }

    .profile-header h1 {
        font-size: 1.1rem !important;
        margin-bottom: 0.05rem !important;
    }

    .profile-header h2 {
        font-size: 0.8rem !important;
        margin-bottom: 0.4rem !important;
    }

    .profile-header .button {
        display: none !important;
    }

    .gen-item {
        margin-bottom: 0.4rem !important;
    }

    .gen-item .label {
        font-size: 0.7rem !important;
    }

    .gen-item .label i {
        font-size: 0.7rem !important;
    }

    .gen-item .value {
        font-size: 0.8rem !important;
    }

    .sidebar-sep {
        margin: 0.5rem 0 !important;
    }

    .content {
        flex: 1 !important;
        padding: 1rem 1.2rem !important;
        min-width: 0 !important;
    }

    .cv-section {
        margin-bottom: 0.8rem !important;
    }

    .cv-section > h2 {
        font-size: 0.9rem !important;
        padding-bottom: 0.25rem !important;
        margin-bottom: 0.6rem !important;
        border-bottom: 1px solid #e0e0e0 !important;
    }

    .cv-section-item {
        margin-bottom: 0.65rem !important;
        gap: 0.6rem !important;
    }

    .cv-item-left {
        min-width: 80px !important;
        max-width: 80px !important;
    }

    .cv-item-left .date {
        font-size: 0.55rem !important;
    }

    .cv-item-right h3 {
        font-size: 0.85rem !important;
        margin-bottom: 0.08rem !important;
    }

    .cv-item-right .institution {
        font-size: 0.7rem !important;
        margin-bottom: 0.25rem !important;
    }

    .cv-item-right p,
    .cv-item-right li {
        font-size: 0.75rem !important;
        line-height: 1.45 !important;
        margin-bottom: 0.15rem !important;
    }

    .cv-section-item.d-block p {
        font-size: 0.75rem !important;
        line-height: 1.45 !important;
        margin-bottom: 0.3rem !important;
    }
}

/* ── RESPONSIVE ── */

@media (max-width: 768px) {
    .content-holder {
        flex-direction: column;
    }

    .content-holder::after {
        display: none;
    }

    .sidebar {
        width: 100%;
        min-width: 0;
        border-right: none;
        border-bottom: 1px solid #ebebeb;
    }

    .content {
        padding: 1.5rem 1rem;
    }

    .cv-section-item {
        flex-direction: column;
        gap: 0.2rem;
    }

    .cv-item-left {
        text-align: left;
        min-width: 0;
        max-width: none;
    }
}



/* PROJECT SECTIONS STYLING */
.project-meta {
    margin-bottom: 12px;
    font-size: 0.95rem;
}

.project-meta a {
    color: inherit;
    text-decoration: underline;
}

.project-meta a:hover {
    opacity: 0.7;
}

.project-section {
    margin-top: 16px;
    margin-bottom: 12px;
}

.project-section h4 {
    font-weight: 700;
    font-size: 0.95rem;
    margin-bottom: 8px;
    margin-top: 8px;
}

.cv-ol-list {
    list-style-position: outside;
    padding-left: 20px;
    margin-bottom: 8px;
}

.cv-ol-list li {
    margin-bottom: 6px;
    font-size: 0.9rem;
    line-height: 1.5;
}


/* ── PAGE BREAKS FOR PRINT ── */
@media print {
    @page {
        size: A4;
        margin: 0;
    }

    * {
        -webkit-print-color-adjust: exact !important;
        print-color-adjust: exact !important;
    }

    body {
        background: #fff !important;
        font-size: 10px !important;
        margin: 0 !important;
        padding: 0 !important;
    }

    .main.page {
        padding: 0 !important;
        min-height: 0 !important;
        background: #fff !important;
    }

    .content-holder {
        display: flex !important;
        flex-direction: row !important;
        align-items: flex-start !important;
        box-shadow: none !important;
        max-width: 100% !important;
        width: 100% !important;
        margin: 0 !important;
        background-image: none !important;
        position: relative;
    }

    .content-holder::after {
        content: '' !important;
        position: absolute !important;
        top: 1rem !important;
        left: 180px !important;
        width: 1px !important;
        height: calc(100% - 2rem) !important;
        background: #e8e8e8 !important;
        z-index: 5 !important;
        display: block !important;
    }

    .sidebar {
        display: block !important;
        width: 180px !important;
        min-width: 180px !important;
        max-width: 180px !important;
        padding: 1rem 0.9rem !important;
        border-right: none !important;
        border-bottom: none !important;
        flex-shrink: 0 !important;
        align-self: flex-start !important;
        position: relative !important;
    }

    .sidebar::after {
        display: none !important;
        content: none !important;
    }

    .me {
        width: 80px !important;
        height: 80px !important;
        margin-bottom: 0.6rem !important;
    }

    .profile-header {
        margin-bottom: 1rem !important;
        padding-bottom: 1rem !important;
        border-bottom: 1px solid #e8e8e8 !important;
    }

    .profile-header h1 {
        font-size: 1.1rem !important;
        margin-bottom: 0.05rem !important;
    }

    .profile-header h2 {
        font-size: 0.8rem !important;
        margin-bottom: 0.4rem !important;
    }

    .profile-header .button {
        display: none !important;
    }

    /* ─── CONTACT INFO (mali font) ─── */
    /* ─── CONTACT INFO (vrlo mali font) ─── */
    .contact-info {
        margin-bottom: 0.2rem !important;
    }

    .contact-info .gen-item {
        margin-bottom: 0.15rem !important;
    }

    .contact-info .gen-item .label {
        font-size: 0.55rem !important;
        margin-bottom: 0.02rem !important;
    }

    .contact-info .gen-item .value {
        font-size: 0.6rem !important;
        padding-left: 0 !important;
        word-break: break-word !important;
    }

    .contact-info .gen-item .value a {
        font-size: 0.55rem !important;
        white-space: nowrap !important;
        display: inline-block !important;
    }

    /* ─── TECH INFO (veći font) ─── */
    .tech-info {
        margin-bottom: 0 !important;
    }

    /* ─── TECH INFO (jos veci font) ─── */
    .tech-info .gen-item {
        margin-bottom: 0.55rem !important;
    }

    .tech-info .gen-item .label {
        font-size: 0.8rem !important;
        margin-bottom: 0.08rem !important;
        font-weight: 600 !important;
    }

    .tech-info .gen-item .label i {
        font-size: 0.8rem !important;
    }

    .tech-info .gen-item .value {
        font-size: 0.9rem !important;
        font-weight: 700 !important;
    }

    .sidebar-sep {
        margin: 0.5rem 0 !important;
    }

    .content {
        flex: 1 !important;
        padding: 1rem 1.2rem !important;
        min-width: 0 !important;
    }

    .cv-section {
        margin-bottom: 0.8rem !important;
    }

    .cv-section > h2 {
        font-size: 0.9rem !important;
        padding-bottom: 0.25rem !important;
        margin-bottom: 0.6rem !important;
        border-bottom: 1px solid #e0e0e0 !important;
    }

    .cv-section-item {
        flex-direction: column !important;
        margin-bottom: 0.65rem !important;
        gap: 0.1rem !important;
    }

    .cv-item-left {
        min-width: auto !important;
        max-width: none !important;
        text-align: left !important;
        order: 1 !important;
        margin-bottom: 0.05rem !important;
    }

    .cv-item-right {
        order: 2 !important;
    }

    .cv-item-left .date {
        font-size: 0.55rem !important;
        color: #999 !important;
        font-weight: 400 !important;
        white-space: nowrap !important;
    }

    .cv-item-right h3 {
        font-size: 0.85rem !important;
        margin-bottom: 0.08rem !important;
        margin-top: 0 !important;
    }

    .cv-item-right .institution {
        font-size: 0.7rem !important;
        margin-bottom: 0.25rem !important;
    }

    .cv-item-right p,
    .cv-item-right li {
        font-size: 0.75rem !important;
        line-height: 1.45 !important;
        margin-bottom: 0.15rem !important;
    }

    .cv-section-item.d-block p {
        font-size: 0.75rem !important;
        line-height: 1.45 !important;
        margin-bottom: 0.3rem !important;
    }

    /* ─── PAGE BREAKS ─── */
    .skills-section {
        page-break-before: always;
        margin-top: 2rem !important;
    }

    .projects-section {
        page-break-before: always;
        margin-top: 2rem !important;
    }

    .cv-section {
        page-break-inside: avoid;
    }

    .cv-section-item {
        page-break-inside: avoid;
    }
}

