/* =================================================================
   HOME.CSS — AGECS WordPress Theme  |  ZigZag-inspired layout
   ================================================================= */

/* ---- Base Reset ---- */
*,
*::before,
*::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html,
body {
    height: 100%;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Open Sans', sans-serif;
    font-size: 16px;
    color: #444;
    line-height: 1.6;
    overflow-x: hidden;
}

a {
    text-decoration: none;
    color: inherit;
    transition: color 0.2s ease;
}

ul {
    list-style: none;
}

/* ---- Page Wrapper ---- */
#tm-page {
    position: relative;
    width: 100%;
    overflow-x: hidden;
}

/* =================================================================
   HEADER
   ================================================================= */

#tm-header {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1000;
    overflow: visible;
}

.tm-header-inner {
    display: flex;
    align-items: stretch;
    justify-content: space-between;
    overflow: visible;
}

/* --- Logo (copiat exact din logo-preview.html) --- */
#tm-site-logo {
    display: flex;
    align-items: center;
    padding: 0 0 0 110px;
    text-decoration: none;
    white-space: nowrap;
}

.gear-icon {
    position: absolute;
    top: 18px;
    right: 12px;
    width: 20px;
    height: 20px;
    fill: rgba(33, 147, 176, 0.5);
}

.ui-frame-borderless {
    border: none;
    border-radius: 0;
    padding: 25px 35px;
    position: relative;
    background: transparent;
}

.logo-with-frame-tight {
    display: flex;
    flex-direction: column;
    align-items: center;
}

.logo-in-frame {
    display: flex;
    align-items: center;
    gap: 2px;
}

.logo-in-frame-text {
    font-size: 3rem;
    font-weight: 800;
    font-family: "Arial", sans-serif;
    line-height: 1;
}

.logo-montserrat {
    font-family: "Montserrat", sans-serif;
    font-weight: 800;
}

.bulb-in-frame {
    position: relative;
    width: 50px;
    height: 50px;
    margin: 0 3px;
}

.bulb-in-frame .bulb-center {
    position: absolute;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    top: 0;
    left: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 3px 12px rgba(102, 126, 234, 0.4);
}

.compact-bulb-icon {
    width: 22px;
    height: 22px;
}



/* --- Navigation bar (dark trapezoid on the right) --- */
#tm-nav {
    flex-shrink: 0;
    position: relative;
    display: flex;
    align-items: center;
    padding: 0 52px 0 100px;
    min-height: 96px;
    overflow: visible;
}

/* Fundalul trapezoid mutat pe ::before ca sa nu clipuiasca dropdownul */
#tm-nav::before {
    content: '';
    position: absolute;
    inset: 0;
    background-color: #1e2b38;
    clip-path: polygon(52px 0%, 100% 0%, 100% 100%, 0% 100%);
    z-index: 0;
    pointer-events: none;
}

#tm-nav > * {
    position: relative;
    z-index: 1;
}

#primary-menu {
    display: flex;
    align-items: center;
    gap: 46px;
    margin: 0;
    padding: 0;
}

#primary-menu li a {
    color: #ffffff;
    font-size: 13px;
    font-weight: 600;
    letter-spacing: 2px;
    text-transform: uppercase;
    text-decoration: none;
    transition: color 0.2s ease;
}

#primary-menu li a:hover,
#primary-menu li.current-menu-item > a {
    color: #4dc8c8;
}

/* ---- Dropdown submenu ---- */
#primary-menu li {
    position: relative;
}

#primary-menu li .sub-menu {
    display: block;
    visibility: hidden;
    opacity: 0;
    pointer-events: none;
    position: absolute;
    top: calc(100% + 12px);
    left: 50%;
    transform: translateX(-50%) translateY(-6px);
    min-width: 200px;
    background: #1a2e3b;
    border-top: 3px solid #2193b0;
    border-radius: 0 0 8px 8px;
    box-shadow: 0 12px 32px rgba(0,0,0,0.3);
    padding: 8px 0;
    margin: 0;
    list-style: none;
    z-index: 9999;
    transition: opacity 0.2s ease, transform 0.2s ease, visibility 0s linear 0.2s;
}

/* pod invizibil care acopera gap-ul de 12px dintre link si dropdown */
#primary-menu li:has(> .sub-menu)::after {
    content: '';
    position: absolute;
    bottom: -12px;
    left: 0;
    width: 100%;
    height: 12px;
    background: transparent;
}

#primary-menu li:hover > .sub-menu,
#primary-menu li:focus-within > .sub-menu {
    visibility: visible;
    opacity: 1;
    pointer-events: auto;
    transform: translateX(-50%) translateY(0);
    transition: opacity 0.2s ease, transform 0.2s ease, visibility 0s linear 0s;
}

#primary-menu li .sub-menu li {
    width: 100%;
}

#primary-menu li .sub-menu li a {
    display: block;
    padding: 10px 20px;
    font-size: 12px;
    letter-spacing: 1.2px;
    color: rgba(255,255,255,0.85);
    text-transform: uppercase;
    white-space: nowrap;
    transition: background 0.15s ease, color 0.15s ease, padding-left 0.15s ease;
}

#primary-menu li .sub-menu li a:hover {
    color: #4dc8c8;
    background: rgba(33,147,176,0.15);
    padding-left: 28px;
}

/* arrow indicator on parent item */
#primary-menu li:has(> .sub-menu) > a::after {
    content: '';
    display: inline-block;
    width: 0;
    height: 0;
    border-left: 4px solid transparent;
    border-right: 4px solid transparent;
    border-top: 5px solid currentColor;
    margin-left: 6px;
    vertical-align: middle;
    opacity: 0.7;
    transition: transform 0.2s ease;
}

#primary-menu li:has(> .sub-menu):hover > a::after {
    transform: rotate(180deg);
}

/* =================================================================
   HERO SECTION  —  geometric diamond background
   ================================================================= */

#tm-hero {
    position: relative;
    width: 100%;
    height: 100vh;
    overflow: hidden;
    background:
        radial-gradient(ellipse 360px 360px at 9%  52%, rgba(255, 255, 255, 0.18) 0%, transparent 70%),
        radial-gradient(ellipse 200px 200px at 6%  25%, rgba(109, 213, 237, 0.2) 0%, transparent 62%),
        radial-gradient(ellipse 130px 130px at 22% 70%, rgba(255, 255, 255, 0.10) 0%, transparent 55%),
        linear-gradient(155deg, #2193b0 0%, #2da8c8 40%, #6dd5ed 100%);
}

/* All diamond shapes share these base rules */
/* --- Diamond keyframes --- */
@keyframes diamond-in-topleft {
    from { transform: rotate(45deg) translate(-120px, -120px); opacity: 0; }
    to   { transform: rotate(45deg) translate(0, 0);           opacity: 1; }
}
@keyframes diamond-in-top {
    from { transform: rotate(45deg) translateY(-140px); opacity: 0; }
    to   { transform: rotate(45deg) translateY(0);      opacity: 1; }
}
@keyframes diamond-in-right {
    from { transform: rotate(45deg) translateX(160px); opacity: 0; }
    to   { transform: rotate(45deg) translateX(0);     opacity: 1; }
}
@keyframes diamond-in-bottomright {
    from { transform: rotate(45deg) translate(120px, 120px); opacity: 0; }
    to   { transform: rotate(45deg) translate(0, 0);          opacity: 1; }
}
@keyframes diamond-in-bottomleft {
    from { transform: rotate(45deg) translate(-120px, 120px); opacity: 0; }
    to   { transform: rotate(45deg) translate(0, 0);           opacity: 1; }
}

.tm-diamond {
    position: absolute;
    transform: rotate(45deg);
    opacity: 0;
    animation-fill-mode: forwards;
    animation-timing-function: cubic-bezier(0.22, 1, 0.36, 1);
    animation-duration: 2.5s;
}

/* Diamond 1 — large, left side, teal mediu (#2193b0 mai închis) */
.tm-diamond-1 {
    width: 36vw;
    height: 36vw;
    background: #1a7a96;
    left: -10vw;
    top: -12vw;
    animation-name: diamond-in-topleft;
    animation-delay: 0s;
}

/* Diamond 2 — centre-left, teal logo */
.tm-diamond-2 {
    width: 29vw;
    height: 29vw;
    background: #d4f3fa;
    left: 5vw;
    top: -6vw;
    animation-name: diamond-in-top;
    animation-delay: 0.15s;
}

/* Diamond 3 — centre, teal intermediar */
.tm-diamond-3 {
    width: 26vw;
    height: 26vw;
    background: #a8e8f5;
    left: 13vw;
    top: 12vw;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    animation-name: diamond-in-top;
    animation-delay: 0.28s;
}

.tm-diamond-img {
    width: 150%;
    height: 150%;
    object-fit: cover;
    transform: rotate(-45deg);
    pointer-events: none;
}

/* Diamond 4 — large, right side, teal deschis (#6dd5ed) */
.tm-diamond-4 {
    width: 39vw;
    height: 39vw;
    background: #a8e8f5;
    right: -7vw;
    top: -12vw;
    animation-name: diamond-in-right;
    animation-delay: 0.1s;
}

/* Diamond 5 — navy din logo (#2c3e50) */
.tm-diamond-5 {
    width: 15vw;
    height: 15vw;
    background: #2c3e50;
    right: -2vw;
    bottom: -6vw;
    animation-name: diamond-in-bottomright;
    animation-delay: 0.4s;
}

/* Diamond 6 — teal închis, stânga-jos */
.tm-diamond-6 {
    width: 20vw;
    height: 20vw;
    background: #2c3e50;
    left: -10vw;
    bottom: -8vw;
    animation-name: diamond-in-bottomleft;
    animation-delay: 0.5s;
}

/* =================================================================
   HERO CONTENT
   ================================================================= */

.tm-hero-content {
    position: absolute;
    inset: 0;
    z-index: 10;
    display: flex;
    align-items: center;
    padding: 40vh 8vw 0 30vw;
}

.tm-hero-text {
    width: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.tm-hero-title {
    font-family: 'Montserrat', sans-serif;
    font-weight: 800;
    font-size: clamp(1rem, 2.6vw, 3.2rem);
    color: #2c3e50;
    line-height: 1.2;
    text-align: center;
    white-space: nowrap;
    text-shadow: 0 2px 20px rgba(255,255,255,0.5);
    animation: hero-title-in 1.2s cubic-bezier(0.22, 1, 0.36, 1) 0.6s both;
}

@keyframes hero-title-in {
    from { opacity: 0; transform: translateY(30px); }
    to   { opacity: 1; transform: translateY(0); }
}

.tm-hero-btn {
    display: inline-block;
    margin-top: 28px;
    padding: 16px 42px;
    background: #2c3e50;
    color: #ffffff;
    font-family: 'Montserrat', sans-serif;
    font-weight: 700;
    font-size: 0.95rem;
    letter-spacing: 2px;
    text-transform: uppercase;
    text-decoration: none;
    clip-path: polygon(6% 0%, 100% 0%, 94% 100%, 0% 100%);
    transition: background 0.25s ease, transform 0.25s ease;
    animation: hero-title-in 1.2s cubic-bezier(0.22, 1, 0.36, 1) 0.85s both;
}

.tm-hero-btn:hover {
    background: #2193b0;
    transform: translateY(-2px);
}

@keyframes hero-image-in {
    from { opacity: 0; transform: translateX(50px); }
    to   { opacity: 1; transform: translateX(0); }
}

/* =================================================================
   VIDEO SECTION
   ================================================================= */

.tm-container {
    max-width: 1280px;
    margin: 0 auto;
    padding: 0 40px;
}

#tm-video-section {
    padding: 80px 0;
    background: #f0fafd;
    position: relative;
    overflow: hidden;
}

#tm-video-section::before {
    content: '';
    position: absolute;
    width: 28vw;
    height: 28vw;
    background: rgba(33,147,176,0.06);
    transform: rotate(45deg);
    left: -10vw;
    top: -10vw;
    pointer-events: none;
}

#tm-video-section::after {
    content: '';
    position: absolute;
    width: 18vw;
    height: 18vw;
    background: rgba(44,62,80,0.05);
    transform: rotate(45deg);
    right: -6vw;
    bottom: -6vw;
    pointer-events: none;
}

.tm-section-header {
    text-align: center;
    margin-bottom: 40px;
    position: relative;
    z-index: 1;
}

.tm-section-title {
    font-family: 'Montserrat', sans-serif;
    font-weight: 800;
    font-size: clamp(1.6rem, 2.8vw, 2.6rem);
    color: #2c3e50;
    margin: 0 0 14px;
}

.tm-section-title-accent {
    display: inline-block;
    position: relative;
}

.tm-section-title-accent::after {
    content: '';
    position: absolute;
    bottom: -6px;
    left: 0;
    width: 100%;
    height: 3px;
    background: linear-gradient(90deg, #2193b0, #6dd5ed);
    border-radius: 2px;
}

.tm-section-subtitle {
    font-family: 'Open Sans', sans-serif;
    font-size: 1rem;
    color: #5a6a7a;
    max-width: 600px;
    margin: 0 auto;
    line-height: 1.7;
}

.tm-video-wrapper {
    border-radius: 14px;
    overflow: hidden;
    box-shadow: 0 20px 64px rgba(33, 147, 176, 0.22);
    position: relative;
    z-index: 1;
    border: 3px solid rgba(33,147,176,0.15);
    max-width: 720px;
    margin: 0 auto;
}

.tm-video-wrapper video {
    display: block;
    width: 100%;
    height: auto;
    background: #000;
}

/* =================================================================
   HOMEPAGE — Ce oferim
   ================================================================= */

#tm-ce-oferim {
    padding: 80px 0;
    background: #fff;
    position: relative;
    overflow: hidden;
}

#tm-ce-oferim::before {
    content: '';
    position: absolute;
    width: 22vw;
    height: 22vw;
    background: rgba(33,147,176,0.05);
    transform: rotate(45deg);
    right: -8vw;
    top: -8vw;
    pointer-events: none;
}

#tm-ce-oferim::after {
    content: '';
    position: absolute;
    width: 15vw;
    height: 15vw;
    background: rgba(44,62,80,0.04);
    transform: rotate(45deg);
    left: -5vw;
    bottom: -5vw;
    pointer-events: none;
}

#tm-ce-oferim .tm-section-title::after {
    content: '';
    display: block;
    width: 60px;
    height: 3px;
    background: linear-gradient(90deg, #2193b0, #6dd5ed);
    border-radius: 2px;
    margin: 14px auto 0;
}

.tm-ce-oferim-split {
    display: flex;
    align-items: stretch;
    gap: 64px;
}

.tm-ce-oferim-content {
    flex: 1 1 0;
    min-width: 0;
}

.tm-ce-oferim-image {
    flex: 0 0 32%;
    max-width: 32%;
    position: relative;
    overflow: hidden;
    border-radius: 18px;
    box-shadow: 0 24px 64px rgba(33,147,176,0.18);
}

.tm-ce-oferim-image img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.tm-ce-oferim-intro {
    text-align: center;
    margin-bottom: 40px;
}

.tm-ce-oferim-intro .tm-section-title {
    margin-bottom: 14px;
}

#tm-ce-oferim .tm-section-title::after {
    margin: 14px auto 0;
}

.tm-ce-oferim-grid {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.tm-oferim-card {
    display: flex;
    align-items: flex-start;
    gap: 20px;
    padding: 24px 28px;
    border-radius: 12px;
    border: 1px solid #e4eff5;
    transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.tm-oferim-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 36px rgba(33,147,176,0.13);
}

.tm-oferim-icon {
    flex-shrink: 0;
    width: 52px;
    height: 52px;
    background: linear-gradient(135deg, #2193b0 0%, #6dd5ed 100%);
    border-radius: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.3rem;
    color: #fff;
}

.tm-oferim-body {
    flex: 1;
    min-width: 0;
}

.tm-oferim-title {
    font-family: 'Montserrat', sans-serif;
    font-weight: 800;
    font-size: 1.0rem;
    color: #2c3e50;
    margin: 0 0 6px;
}

.tm-oferim-text {
    font-family: 'Open Sans', sans-serif;
    font-size: 0.87rem;
    color: #6a8090;
    line-height: 1.7;
    margin: 0;
}

/* =================================================================
   HOMEPAGE — Aplicații
   ================================================================= */

#tm-aplicatii {
    padding: 80px 0;
    background: #f0fafd;
    position: relative;
    overflow: hidden;
}

#tm-aplicatii::before {
    content: '';
    position: absolute;
    width: 35vw;
    height: 35vw;
    background: rgba(33,147,176,0.05);
    transform: rotate(45deg);
    right: -12vw;
    top: -12vw;
    pointer-events: none;
}

.tm-aplicatii-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
    margin-top: 48px;
}

.tm-app-card {
    background: #fff;
    border-radius: 14px;
    overflow: hidden;
    box-shadow: 0 4px 24px rgba(33,147,176,0.09);
    transition: transform 0.25s ease, box-shadow 0.25s ease;
    display: flex;
    flex-direction: column;
}

.tm-app-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 20px 56px rgba(33,147,176,0.18);
}

.tm-app-card-header {
    padding: 32px 28px 24px;
    background: linear-gradient(135deg, #2193b0 0%, #6dd5ed 100%);
    position: relative;
    overflow: hidden;
}

.tm-app-card-header::after {
    content: '';
    position: absolute;
    width: 80px;
    height: 80px;
    background: rgba(255,255,255,0.08);
    transform: rotate(45deg);
    right: -20px;
    top: -20px;
}

.tm-app-card-icon {
    font-size: 2rem;
    color: rgba(255,255,255,0.9);
    margin-bottom: 12px;
    display: block;
}

.tm-app-card-title {
    font-family: 'Montserrat', sans-serif;
    font-weight: 800;
    font-size: 1.15rem;
    color: #fff;
    margin: 0 0 6px;
}

.tm-app-card-badge {
    font-family: 'Open Sans', sans-serif;
    font-size: 0.72rem;
    color: rgba(255,255,255,0.78);
    letter-spacing: 1.5px;
    text-transform: uppercase;
    margin: 0;
}

.tm-app-card-body {
    padding: 24px 28px;
    flex: 1;
    display: flex;
    flex-direction: column;
}

.tm-app-card-desc {
    font-family: 'Open Sans', sans-serif;
    font-size: 0.88rem;
    color: #6a8090;
    line-height: 1.7;
    margin: 0 0 20px;
}

.tm-app-features {
    list-style: none;
    padding: 0;
    margin: 0 0 28px;
    flex: 1;
}

.tm-app-features li {
    font-family: 'Open Sans', sans-serif;
    font-size: 0.83rem;
    color: #4a6070;
    padding: 6px 0;
    border-bottom: 1px solid #f0f6fa;
    display: flex;
    align-items: center;
    gap: 8px;
}

.tm-app-features li::before {
    content: '';
    width: 6px;
    height: 6px;
    background: #2193b0;
    border-radius: 50%;
    flex-shrink: 0;
}

.tm-app-card-link {
    display: inline-block;
    font-family: 'Montserrat', sans-serif;
    font-weight: 700;
    font-size: 0.8rem;
    letter-spacing: 1.5px;
    text-transform: uppercase;
    color: #2193b0;
    text-decoration: none;
    border: 2px solid #2193b0;
    padding: 10px 24px;
    border-radius: 4px;
    transition: background 0.2s ease, color 0.2s ease;
    text-align: center;
}

.tm-app-card-link:hover {
    background: #2193b0;
    color: #fff;
}

/* -- Alte servicii (mini-cards) -- */

.tm-servicii-grid {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 16px;
    margin-top: 32px;
    padding-top: 32px;
    border-top: 1px solid rgba(33,147,176,0.15);
}

.tm-serviciu-card {
    background: #fff;
    border: 1px solid #e4eff5;
    border-radius: 12px;
    padding: 20px 18px;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 12px;
    transition: transform 0.22s ease, box-shadow 0.22s ease;
}

.tm-serviciu-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 10px 32px rgba(33,147,176,0.12);
}

.tm-serviciu-icon {
    width: 44px;
    height: 44px;
    background: linear-gradient(135deg, #2193b0 0%, #6dd5ed 100%);
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.1rem;
    color: #fff;
    flex-shrink: 0;
}

.tm-serviciu-title {
    font-family: 'Montserrat', sans-serif;
    font-weight: 700;
    font-size: 0.85rem;
    color: #2c3e50;
    margin: 0 0 6px;
    line-height: 1.4;
}

.tm-serviciu-text {
    font-family: 'Open Sans', sans-serif;
    font-size: 0.8rem;
    color: #6a8090;
    line-height: 1.6;
    margin: 0;
}

/* =================================================================
   HOMEPAGE — Avantaje cheie
   ================================================================= */

#tm-avantaje {
    padding: 80px 0;
    background: #2c3e50;
    position: relative;
    overflow: hidden;
}

#tm-avantaje::before {
    content: '';
    position: absolute;
    width: 40vw;
    height: 40vw;
    background: rgba(33,147,176,0.06);
    transform: rotate(45deg);
    left: -14vw;
    bottom: -14vw;
    pointer-events: none;
}

.tm-avantaje-title {
    font-family: 'Montserrat', sans-serif;
    font-weight: 800;
    font-size: clamp(1.4rem, 2.4vw, 2rem);
    color: #fff;
    text-align: center;
    margin: 0 0 52px;
    position: relative;
    z-index: 1;
}

.tm-avantaje-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
    position: relative;
    z-index: 1;
}

.tm-avantaj-item {
    text-align: center;
    padding: 32px 18px;
    border-radius: 12px;
    border: 1px solid rgba(255,255,255,0.07);
    background: rgba(255,255,255,0.03);
    opacity: 0;
    transform: translateY(24px);
    transition: opacity 0.5s ease, transform 0.5s ease, background 0.25s ease;
}

.tm-avantaj-item.tm-visible {
    opacity: 1;
    transform: translateY(0);
}

.tm-avantaj-item.tm-visible:hover {
    background: rgba(33,147,176,0.15);
    transform: translateY(-5px);
}

.tm-avantaj-item .fa {
    font-size: 2rem;
    color: #6dd5ed;
    margin-bottom: 16px;
    display: block;
}

.tm-avantaj-item h3 {
    font-family: 'Montserrat', sans-serif;
    font-weight: 700;
    font-size: 0.9rem;
    color: #fff;
    margin: 0 0 10px;
}

.tm-avantaj-item p {
    font-family: 'Open Sans', sans-serif;
    font-size: 0.82rem;
    color: rgba(255,255,255,0.58);
    line-height: 1.6;
    margin: 0;
}

/* =================================================================
   HOMEPAGE — CTA final
   ================================================================= */

#tm-hpcta {
    padding: 48px 40px;
    background: linear-gradient(135deg, #1a7a96 0%, #2193b0 50%, #6dd5ed 100%);
    position: relative;
    overflow: hidden;
}

#tm-hpcta::before {
    content: '';
    position: absolute;
    inset: 0;
    background: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%23ffffff' fill-opacity='0.04'%3E%3Cpath d='M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zm0-30V0h-2v4h-4v2h4v4h2V6h4V4h-4zM6 34v-4H4v4H0v2h4v4h2v-4h4v-2H6zM6 4V0H4v4H0v2h4v4h2V6h4V4H6z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
    pointer-events: none;
}

#tm-hpcta::after {
    content: '';
    position: absolute;
    width: 24vw;
    height: 24vw;
    background: rgba(255,255,255,0.06);
    transform: rotate(45deg);
    right: -8vw;
    top: -8vw;
    pointer-events: none;
}

.tm-hpcta-inner {
    max-width: 1280px;
    margin: 0 auto;
    padding: 0 40px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 40px;
    position: relative;
    z-index: 1;
}

.tm-hpcta-text {
    flex: 1;
}

#tm-hpcta h2 {
    font-family: 'Montserrat', sans-serif;
    font-weight: 800;
    font-size: clamp(1.3rem, 2.2vw, 1.9rem);
    color: #fff;
    margin: 0 0 8px;
}

#tm-hpcta p {
    font-family: 'Open Sans', sans-serif;
    font-size: 0.95rem;
    color: rgba(255,255,255,0.85);
    margin: 0;
}

.tm-hpcta-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    flex-shrink: 0;
    font-family: 'Montserrat', sans-serif;
    font-weight: 700;
    font-size: 0.9rem;
    letter-spacing: 0.5px;
    color: #1a7a96;
    background: #fff;
    padding: 14px 32px;
    border-radius: 50px;
    text-decoration: none;
    box-shadow: 0 8px 32px rgba(0,0,0,0.15);
    transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
    white-space: nowrap;
}

.tm-hpcta-btn:hover {
    background: #f0fafd;
    transform: translateY(-2px);
    box-shadow: 0 14px 40px rgba(0,0,0,0.2);
}

@media (max-width: 640px) {
    .tm-hpcta-inner {
        flex-direction: column;
        text-align: center;
    }
}

/* responsive homepage sections */
@media (max-width: 1024px) {
    .tm-avantaje-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 1024px) {
    .tm-ce-oferim-split {
        gap: 40px;
    }
    .tm-ce-oferim-image {
        flex: 0 0 38%;
        max-width: 38%;
    }
    .tm-servicii-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (max-width: 768px) {
    .tm-ce-oferim-split {
        flex-direction: column;
        gap: 32px;
    }
    .tm-ce-oferim-image {
        flex: none;
        max-width: 100%;
        width: 100%;
    }
    .tm-aplicatii-grid {
        grid-template-columns: 1fr;
    }
    .tm-servicii-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    .tm-avantaje-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 480px) {
    .tm-avantaje-grid {
        grid-template-columns: 1fr;
    }
    .tm-servicii-grid {
        grid-template-columns: 1fr;
    }
}

/* =================================================================
   FOOTER
   ================================================================= */

#tm-footer {
    background: #1e2b38;
    color: #ffffff;
    text-align: center;
    padding: 22px 20px;
}

#tm-footer p {
    font-size: 14px;
    margin: 0;
}

/* =================================================================
   RESPONSIVE — ajustări per breakpoint
   ================================================================= */

@media (max-width: 1280px) {
    .tm-hero-content {
        padding: 0 6vw 0 42vw;
    }

    #tm-nav {
        padding: 0 36px 0 72px;
    }

    #primary-menu {
        gap: 32px;
    }
}

@media (max-width: 1024px) {
    .tm-hero-content {
        padding: 0 4vw 0 44vw;
    }

    #tm-site-logo {
        padding: 0 0 0 40px;
    }

    #tm-nav {
        padding: 0 28px 0 56px;
    }

    #primary-menu {
        gap: 20px;
    }

    /* submeniu pe ecrane medii — poziționat normal, fără centrat */
    #primary-menu li .sub-menu {
        left: 0;
        transform: translateX(0) translateY(-6px);
    }
    #primary-menu li:hover > .sub-menu,
    #primary-menu li:focus-within > .sub-menu {
        transform: translateX(0) translateY(0);
    }
}

/* =================================================================
   SCROLL PROGRESS BAR
   ================================================================= */

#tm-progress-bar {
    position: fixed;
    top: 0;
    left: 0;
    width: 0%;
    height: 4px;
    background: linear-gradient(90deg, #2193b0, #6dd5ed);
    z-index: 9999;
    transition: width 0.08s linear;
    pointer-events: none;
}

/* =================================================================
   SCROLL TO TOP BUTTON
   ================================================================= */

#tm-scroll-top {
    position: fixed;
    bottom: 32px;
    right: 32px;
    width: 48px;
    height: 48px;
    background: linear-gradient(135deg, #2193b0, #6dd5ed);
    color: #fff;
    border: none;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.1rem;
    box-shadow: 0 4px 20px rgba(33,147,176,0.4);
    opacity: 0;
    visibility: hidden;
    transform: translateY(16px);
    transition: opacity 0.3s ease, visibility 0.3s ease, transform 0.3s ease, box-shadow 0.2s ease;
    z-index: 9998;
}

#tm-scroll-top.tm-stt-visible {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

#tm-scroll-top:hover {
    box-shadow: 0 8px 28px rgba(33,147,176,0.6);
    transform: translateY(-3px);
}

#tm-scroll-top:focus {
    outline: 2px solid #2193b0;
    outline-offset: 3px;
}
