﻿/* 
 * AIList.sk - Homepage Styles
 * Hero section and company directory for the homepage
 */

/* ===== Hero Section ===== */
.hero {
    padding: var(--spacing-xxl) 0;
    text-align: center;
    background: linear-gradient(135deg, #f0f7ff 0%, #e6f0ff 50%, #d9e8ff 100%);
    position: relative;
    overflow: hidden;
    min-height: 450px;
    display: flex;
    align-items: center;
}

.hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background:
        radial-gradient(circle at 20% 30%, rgba(0, 114, 255, 0.12) 0%, transparent 50%),
        radial-gradient(circle at 80% 20%, rgba(63, 147, 255, 0.12) 0%, transparent 60%);
    animation: pulseGradient 8s ease-in-out infinite alternate;
}

@keyframes pulseGradient {
    0% {
        opacity: 0.5;
        transform: scale(1);
    }

    100% {
        opacity: 0.8;
        transform: scale(1.1);
    }
}

.hero::after {
    content: '';
    position: absolute;
    bottom: -10px;
    left: 0;
    width: 100%;
    height: 70px;
    background: linear-gradient(to bottom, transparent, #ffffff);
    z-index: 1;
}

.hero__content {
    position: relative;
    z-index: 2;
    transition: transform 0.6s cubic-bezier(0.165, 0.84, 0.44, 1);
}

/* Hero interactive elements */
.hero-blob {
    position: absolute;
    width: 200px;
    height: 200px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(59, 130, 246, 0.15) 0%, rgba(37, 99, 235, 0.05) 50%, transparent 70%);
    transform: translate(50%, 50%);
    pointer-events: none;
    z-index: 0;
    transition: transform 0.8s cubic-bezier(0.22, 1, 0.36, 1);
    filter: blur(40px);
}

.hero-particle {
    position: absolute;
    background-color: rgba(255, 255, 255, 0.8);
    border-radius: 50%;
    pointer-events: none;
    z-index: 1;
    transition: transform 1s cubic-bezier(0.22, 1, 0.36, 1);
    animation: floatAnimation linear infinite alternate;
}

@keyframes floatAnimation {
    0% {
        transform: translate(0, 0) rotate(0deg);
    }

    100% {
        transform: translate(10px, 10px) rotate(360deg);
    }
}

.hero__title {
    margin-bottom: 10px;
    font-size: 3rem;
    font-weight: 800;
    background: linear-gradient(to right, #202430 0%, #364060 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    text-fill-color: transparent;
    position: relative;
    letter-spacing: -1px;
    transition: all var(--transition-medium);
}

.hero__title .text-primary {
    background: linear-gradient(to right, var(--color-primary) 0%, #3a8dff 50%, var(--color-primary-dark) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    text-fill-color: transparent;
    position: relative;
    display: inline-block;
}

.hero__title .text-primary::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 100%;
    height: 3px;
    background: linear-gradient(to right, var(--color-primary) 0%, #3a8dff 50%, var(--color-primary-dark) 100%);
    transform: scaleX(0);
    transform-origin: bottom right;
    transition: transform 0.5s ease;
    animation: underlineAnimation 1.2s ease forwards 0.5s;
    border-radius: 2px;
}

@keyframes underlineAnimation {
    to {
        transform: scaleX(1);
        transform-origin: bottom left;
    }
}

.hero__subtitle {
    max-width: 800px;
    margin: 0 auto 20px;
    font-size: 0.95rem;
    color: #4a5568;
    line-height: 1.6;
    opacity: 0;
    animation: fadeInUp 0.8s cubic-bezier(0.25, 0.46, 0.45, 0.94) forwards 0.7s;
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.hero__actions {
    display: flex;
    justify-content: center;
    gap: 10px;
    opacity: 0;
    animation: fadeInUp 0.8s cubic-bezier(0.25, 0.46, 0.45, 0.94) forwards 1s;
}

.hero__actions .btn {
    padding: 0.8rem 1.8rem;
    font-size: 1.1rem;
    box-shadow: var(--shadow-md);
    transition: all var(--transition-medium);
    position: relative;
    overflow: hidden;
}

.hero__actions .btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: rgba(255, 255, 255, 0.2);
    transition: all 0.4s ease;
}

.hero__actions .btn:hover::before {
    left: 100%;
}

.hero__actions .btn:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow-lg);
}

@media (max-width: 768px) {
    .hero {
        min-height: 400px;
    }

    .hero__title {
        font-size: 2.5rem;
    }
}

@media (max-width: 576px) {
    .hero {
        min-height: 350px;
    }

    .hero__title {
        font-size: 2rem;
    }

    .hero__subtitle {
        font-size: 1rem;
    }

    .hero__actions {
        flex-direction: column;
        align-items: center;
        gap: var(--spacing-md);
    }
}

.hero__logo-wrapper {
    display: flex;
    justify-content: center;
    align-items: center;
    width: 100%;
    margin-bottom: 20px;
}

.hero__logo {
    height: 100px;
    display: block;
    margin: 0 auto;
}

/* ===== Directory Section ===== */
.directory {
    padding: 5rem 0;
    background-color: var(--color-white);
}

.section-header {
    text-align: center;
    margin-bottom: var(--spacing-xl);
}

.section-title {
    margin-bottom: var(--spacing-sm);
}

.section-subtitle {
    color: var(--color-secondary);
}

/* Discovery Component - groups filters and search */
.discovery-component {
    background-color: rgba(var(--color-primary-rgb), 0.03);
    border-radius: 16px;
    padding: var(--spacing-lg);
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.04);
    margin-bottom: var(--spacing-xl);
}

.discovery-component .filter-tags {
    margin-bottom: var(--spacing-md);
}

.discovery-component .search-bar {
    margin-bottom: 0;
}

.filter-tags {
    display: flex;
    flex-wrap: wrap;
    gap: var(--spacing-sm);
    margin-bottom: var(--spacing-lg);
    justify-content: center;
}

.tag {
    background-color: var(--color-gray-light);
    color: var(--color-gray-dark);
    padding: 0.5rem 0.85rem;
    min-height: 44px;
    /* Ensure touch target is at least 44px */
    border-radius: var(--radius-md);
    font-size: 0.875rem;
    cursor: pointer;
    transition: all var(--transition-medium);
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-weight: 500;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
    border: 1px solid rgba(0, 0, 0, 0.05);
    position: relative;
    overflow: hidden;
}

/* Mobile: Increase padding for better touch and make tags horizontally scrollable */
@media (max-width: 768px) {
    .tag {
        padding: 0.65rem 1rem;
        font-size: 0.9rem;
        flex-shrink: 0;
    }

    .filter-tags {
        gap: 0.65rem;
        flex-wrap: nowrap;
        overflow-x: auto;
        justify-content: flex-start;
        padding-bottom: 0.5rem;
        -webkit-overflow-scrolling: touch;
        scrollbar-width: none;
        /* Firefox */
        position: relative;
        z-index: 1;
    }

    .filter-tags::-webkit-scrollbar {
        display: none;
        /* Chrome, Safari and Opera */
    }

    .filter-scroll-indicator {
        display: flex;
        position: absolute;
        right: -10px;
        top: 0;
        bottom: 0.5rem;
        width: 60px;
        align-items: center;
        justify-content: flex-end;
        padding-right: 15px;
        background: linear-gradient(to right, rgba(255, 255, 255, 0) 0%, rgba(250, 251, 253, 0.9) 50%, rgba(250, 251, 253, 1) 100%);
        pointer-events: none;
        color: var(--color-primary);
        font-size: 1.2rem;
        z-index: 2;
        border-radius: 0 16px 16px 0;
    }

    .filter-scroll-indicator i {
        animation: slideRight 1.5s ease-in-out infinite;
    }

    @keyframes slideRight {

        0%,
        100% {
            transform: translateX(0);
            opacity: 0.5;
        }

        50% {
            transform: translateX(5px);
            opacity: 1;
        }
    }
}

/* Hide indicator on desktop */
@media (min-width: 769px) {
    .filter-scroll-indicator {
        display: none;
    }
}

.tag::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(120deg, transparent 0%, rgba(255, 255, 255, 0.6) 50%, transparent 100%);
    transform: translateX(-100%);
    transition: transform 0.6s ease;
}

.tag:hover::before {
    transform: translateX(100%);
}

.tag:hover,
.tag.active {
    background-color: var(--color-primary);
    color: var(--color-white);
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
}

.search-bar {
    position: relative;
    margin-bottom: var(--spacing-xl);
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
    transition: all var(--transition-medium);
}

.search-bar i {
    position: absolute;
    left: var(--spacing-md);
    top: 50%;
    transform: translateY(-50%);
    color: var(--color-secondary);
    transition: color var(--transition-fast);
}

.search-bar input {
    width: 100%;
    padding: var(--spacing-md) var(--spacing-md) var(--spacing-md) calc(var(--spacing-md) * 2.5);
    border: 1px solid var(--color-gray);
    border-radius: var(--radius-md);
    font-size: 1rem;
    transition: all var(--transition-medium);
    box-shadow: var(--shadow-sm);
}

.search-bar:focus-within {
    transform: translateY(-2px);
}

.search-bar:focus-within i {
    color: var(--color-primary);
}

.search-bar input:focus {
    outline: none;
    border-color: var(--color-primary);
    box-shadow: 0 4px 12px rgba(37, 99, 235, 0.1);
}

.company-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: var(--spacing-lg);
}

/* Responsive grid improvements */
@media (max-width: 640px) {
    .company-grid {
        grid-template-columns: 1fr;
        /* Single column on mobile */
        gap: var(--spacing-md);
    }
}

@media (min-width: 641px) and (max-width: 900px) {
    .company-grid {
        grid-template-columns: repeat(2, 1fr);
        /* 2 columns on tablet */
    }
}

@media (min-width: 901px) {
    .company-grid {
        grid-template-columns: repeat(3, 1fr);
        /* 3 columns on desktop */
    }
}

.company-card {
    display: flex;
    flex-direction: column;
    height: 100%;
    transition: all 0.3s ease;
    border: 1px solid rgba(0, 0, 0, 0.05);
    border-radius: 12px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.05);
    overflow: hidden;
    position: relative;
    background-color: #fff;
    z-index: 1;
}

.company-card::before {
    content: "";
    position: absolute;
    top: 0;
    right: 0;
    width: 150px;
    height: 150px;
    background: linear-gradient(135deg, transparent 50%, rgba(var(--color-primary-rgb), 0.05) 50%);
    border-radius: 0 0 0 100%;
    transition: all 0.3s ease;
    z-index: 0;
}

.company-card:hover {
    transform: translateY(-6px) scale(1.01);
    box-shadow: var(--shadow-xl);
    border-color: rgba(var(--color-primary-rgb), 0.15);
}

.company-card:hover::before {
    background: linear-gradient(135deg, transparent 50%, rgba(var(--color-primary-rgb), 0.1) 50%);
}

.company-card:active {
    transform: translateY(-2px);
    transition: transform 0.1s;
}

/* Ripple effect for cards */
.company-card .ripple {
    position: absolute;
    border-radius: 50%;
    transform: scale(0);
    animation: ripple-animation 0.6s linear;
    background-color: rgba(255, 255, 255, 0.7);
    z-index: 0;
}

@keyframes ripple-animation {
    to {
        transform: scale(4);
        opacity: 0;
    }
}

.company-card__header {
    display: flex;
    align-items: center;
    padding: 15px;
    border-bottom: 1px solid rgba(0, 0, 0, 0.05);
}

.company-card__logo {
    width: 60px;
    height: 60px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-right: 15px;
    background: #f5f5f5;
    border-radius: 10px;
    overflow: hidden;
}

.company-card__logo img {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
}

.company-card__info {
    flex-grow: 1;
    overflow: hidden;
}

.company-card__name {
    margin: 0 0 5px 0;
    font-size: 1rem;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    color: var(--color-primary);
    transition: color 0.2s ease;
}

.company-card:hover .company-card__name {
    color: var(--color-primary-dark, var(--color-primary));
}

.company-card__location {
    margin: 0;
    color: var(--color-secondary);
    font-size: 0.8rem;
}

.company-card__description {
    flex-grow: 1;
    padding: 0 15px;
    margin: 10px 0;
    display: flex;
    align-items: center;
    min-height: 60px;
    color: var(--color-gray-dark);
    line-height: 1.5;
    position: relative;
    z-index: 2;
}

.company-card__tags {
    display: flex;
    flex-wrap: wrap;
    gap: 5px;
    padding: 0 15px 15px;
    margin-top: auto;
}

.card-tag {
    font-size: 0.7rem;
    padding: 3px 6px;
    border-radius: 12px;
    background-color: rgba(0, 0, 0, 0.05);
    color: rgba(0, 0, 0, 0.7);
    white-space: nowrap;
    transition: all 0.3s ease;
}

.company-card:hover .card-tag {
    background-color: rgba(var(--color-primary-rgb), 0.1);
    transform: translateY(-1px);
}

/* Badge for new companies */
.new-badge {
    position: absolute;
    top: 10px;
    right: 10px;
    background: linear-gradient(135deg, #0072ff, #00c6ff);
    color: white;
    padding: 4px 8px;
    font-size: 0.7rem;
    font-weight: 600;
    border-radius: 4px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    z-index: 2;
    letter-spacing: 0.5px;
    text-transform: uppercase;
    animation: badgePulse 2s infinite alternate;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.2);
}

@keyframes badgePulse {
    0% {
        box-shadow: 0 2px 4px rgba(0, 114, 255, 0.3);
    }

    100% {
        box-shadow: 0 2px 10px rgba(0, 114, 255, 0.7);
    }
}

/* ===== Upcoming Badge ===== */
.hero__upcoming-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    background: rgba(255, 255, 255, 0.4);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.4);
    padding: 0.5rem 1.2rem;
    border-radius: 999px;
    text-decoration: none;
    margin-bottom: 1.5rem;
    transition: all 0.3s ease;
    max-width: 100%;
    box-sizing: border-box;
}

.hero__upcoming-badge-text {
    font-size: 0.85rem;
    font-weight: 500;
    color: var(--color-heading, #111);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.pulsing-dot {
    width: 8px;
    height: 8px;
    background: var(--color-primary, #0072ff);
    border-radius: 50%;
    display: inline-block;
    box-shadow: 0 0 0 0 rgba(0, 114, 255, 0.4);
    animation: pulse-blue 2s infinite;
}

@keyframes pulse-blue {
    0% {
        transform: scale(0.95);
        box-shadow: 0 0 0 0 rgba(0, 114, 255, 0.4);
    }

    70% {
        transform: scale(1);
        box-shadow: 0 0 0 6px rgba(0, 114, 255, 0);
    }

    100% {
        transform: scale(0.95);
        box-shadow: 0 0 0 0 rgba(0, 114, 255, 0);
    }
}

.hero__upcoming-badge:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.1);
    background: rgba(255, 255, 255, 0.6);
}

@media (max-width: 768px) {
    .hero__upcoming-badge {
        width: 90%;
        border-radius: 8px;
        background: rgba(255, 255, 255, 0.7);
        backdrop-filter: blur(10px);
        -webkit-backdrop-filter: blur(10px);
        border: 1px solid rgba(255, 255, 255, 0.3);
        padding: 0.6rem 1rem;
    }

    .hero__upcoming-badge-text {
        font-size: 13px;
    }
}

/* ===== Latest Blog Section ===== */
.latest-blog-section {
    padding: 90px 0;
    background-color: #f0f7ff;
    margin-bottom: 0;
}

.blog-container-inner {
    background: transparent;
    border: none;
    border-radius: 0;
    padding: 0;
    box-shadow: none;
    margin: 0 auto;
}

.blog-header-wrapper {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2.5rem;
    border-bottom: none;
    padding-bottom: 0;
}

.blog-header-title {
    margin: 0;
    font-weight: 600;
    text-transform: uppercase;
    font-size: 0.85rem;
    letter-spacing: 0.15em;
    color: var(--color-gray-dark, #666);
}

.blog-header-link {
    color: var(--color-heading, #111);
    font-size: 0.85rem;
    text-decoration: none;
    font-weight: 500;
    transition: all 0.2s ease;
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    border-bottom: 1px solid transparent;
    padding-bottom: 2px;
}

.blog-header-link:hover {
    color: var(--color-primary, #0056b3);
    border-bottom-color: var(--color-primary, #0056b3);
}

.minimal-blog-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 1.5rem 0;
    text-decoration: none;
    color: inherit;
    border-bottom: 1px solid rgba(0, 0, 0, 0.04);
    transition: all 0.2s ease;
}

.minimal-blog-item:first-child {
    border-top: 1px solid rgba(0, 0, 0, 0.04);
}

.minimal-blog-item:last-child {
    border-bottom: 1px solid rgba(0, 0, 0, 0.04);
}

.minimal-blog-item:hover {
    opacity: 0.75;
}

.minimal-blog-content {
    display: flex;
    align-items: center;
    gap: 2rem;
    flex: 1;
    min-width: 0;
}

.minimal-blog-date {
    font-size: 0.8rem;
    color: var(--color-text-light, #888);
    min-width: 100px;
    flex-shrink: 0;
    font-variant-numeric: tabular-nums;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin: 0;
}

.minimal-blog-title {
    margin: 0;
    font-size: 1.05rem;
    font-weight: 500;
    color: var(--color-heading, #111);
    transition: color 0.2s ease;
    line-height: 1.4;
}

.minimal-blog-item:hover .minimal-blog-title {
    color: var(--color-primary, #0056b3);
}

.minimal-blog-chevron {
    color: var(--color-gray-light, #ccc);
    font-size: 0.85rem;
    opacity: 0;
    transform: translateX(-5px);
    transition: all 0.2s ease;
    flex-shrink: 0;
    margin-left: 1rem;
}

.minimal-blog-item:hover .minimal-blog-chevron {
    opacity: 1;
    transform: translateX(0);
    color: var(--color-primary, #0056b3);
}

@media (max-width: 768px) {
    .minimal-blog-content {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.5rem;
    }

    .minimal-blog-date {
        min-width: auto;
    }
}

@media (max-width: 576px) {
    .blog-container-inner {
        padding: 0 1rem;
    }

    .blog-header-wrapper {
        margin-bottom: 2rem;
    }

    .minimal-blog-item {
        padding: 1.25rem 0;
    }

    .minimal-blog-chevron {
        display: none;
    }
}