/* ========================================
   KLIN360 HOME - Landing Page Styles
   Hero, Slider, Machines, Flip Cards, Blog, Social
   ======================================== */

/* HERO */
.hero {
    padding: 160px 2rem 140px;
    background:
        linear-gradient(135deg, rgba(0,0,0,0.8) 0%, rgba(0,0,0,0.65) 100%),
        url('https://klin360.com/wp-content/uploads/2025/09/local-moto.jpg');
    background-size: cover;
    background-position: center;
    position: relative; overflow: hidden;
}
.hero::after {
    content: ''; position: absolute; bottom: 0; left: 0; right: 0;
    height: 100px; background: linear-gradient(to bottom, transparent, var(--white));
}
.hero-container { max-width: 1200px; margin: 0 auto; position: relative; z-index: 1; }
.hero-content { max-width: 750px; margin: 0 auto; text-align: center; }
.hero-content h1 { color: var(--white); margin-bottom: 1.5rem; text-shadow: 0 2px 20px rgba(0,0,0,0.3); }
.hero-subtitle {
    font-size: clamp(20px, 3vw, 30px); color: var(--yellow);
    margin-bottom: 2.5rem; line-height: 1.5; font-weight: 600;
}
.hero-ctas { display: flex; gap: 1rem; flex-wrap: wrap; justify-content: center; }

@media (max-width: 768px) {
    .hero { padding: 140px 2rem 100px; }
    .hero-ctas { flex-direction: column; }
    .hero-ctas .btn { width: 100%; text-align: center; }
}

/* COMPARISON SLIDER */
.comparison-slider {
    position: relative; width: 100%; max-width: 800px; height: 500px;
    margin: 0 auto 60px; overflow: hidden; border-radius: 20px;
    box-shadow: 0 20px 40px rgba(0,0,0,0.2);
    cursor: ew-resize; -webkit-user-select: none; user-select: none;
}
.image-after, .image-before {
    position: absolute; top: 0; left: 0; width: 100%; height: 100%;
    background-size: cover; background-position: center;
}
.image-before { border-right: 2px solid white; width: 50%; z-index: 2; }
.slider-handle { position: absolute; top: 0; left: 50%; width: 4px; height: 100%; background: white; z-index: 3; transform: translateX(-50%); }
.handle-circle {
    position: absolute; top: 50%; left: 50%; transform: translate(-50%, -50%);
    width: 44px; height: 44px; background: var(--yellow); border-radius: 50%;
    display: flex; align-items: center; justify-content: center;
    color: black; box-shadow: 0 0 15px rgba(0,0,0,0.3);
}
.label-before, .label-after {
    position: absolute; bottom: 20px;
    padding: 8px 16px; background: rgba(0,0,0,0.7);
    color: white; font-size: 11px; font-weight: 700;
    border-radius: 4px; z-index: 4; letter-spacing: 0.05em;
}
.label-before { left: 20px; }
.label-after { right: 20px; }
@media (max-width: 768px) { .comparison-slider { height: 350px; } }

/* MACHINES */
.machine-grid {
    display: grid; grid-template-columns: 1fr 1fr; gap: 4rem; margin-top: 4rem;
}
.machine-card {
    background: var(--white); border: 2px solid var(--grey-300);
    border-radius: 20px; transition: all 0.4s; position: relative;
}
.machine-card:hover {
    border-color: var(--yellow); transform: translateY(-8px);
    box-shadow: 0 20px 50px rgba(0,0,0,0.12);
}
.machine-image {
    width: 100%; height: 400px; background: var(--white);
    display: flex; align-items: center; justify-content: center;
    padding: 2rem; position: relative;
    border-bottom: 2px solid var(--grey-300);
    border-radius: 18px 18px 0 0; overflow: hidden;
}
.machine-image img { max-width: 100%; max-height: 100%; object-fit: contain; display: block; }
.machine-badge {
    position: absolute; top: 1.5rem; right: 1.5rem;
    background: var(--yellow); color: var(--black);
    padding: 0.5rem 1.2rem; border-radius: 8px;
    font-size: 13px; font-weight: 700; letter-spacing: 0.05em; z-index: 10;
}
.machine-badge-new {
    position: absolute; top: 15px; left: 15px;
    background: #E60012; color: white;
    padding: 8px 16px; border-radius: 20px;
    font-size: 14px; font-weight: 800; text-transform: uppercase;
    letter-spacing: 1px; box-shadow: 0 4px 15px rgba(230,0,18,0.4);
    animation: pulse-new 2s infinite; z-index: 10;
}
@keyframes pulse-new {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.05); box-shadow: 0 6px 20px rgba(230,0,18,0.6); }
}

.machine-content { padding: 2.5rem; }
.machine-content h4 { margin-bottom: 0.5rem; }
.machine-subtitle { font-size: 14px; color: var(--grey-500); margin-bottom: 2rem; }

.dimensions { background: var(--grey-100); padding: 1.5rem; border-radius: 12px; margin-bottom: 2rem; }
.dimensions h5 { font-size: 14px; margin-bottom: 1rem; color: var(--grey-900); }
.dimensions-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1rem; }
.dimension-item { font-size: 14px; }
.dimension-label { font-weight: 600; color: var(--grey-900); margin-bottom: 0.2rem; }
.dimension-value { color: var(--grey-700); font-weight: 500; }

.spec-label { font-weight: 600; margin-bottom: 1rem; font-size: 16px; }
.spec-list { list-style: none; margin-bottom: 2rem; }
.spec-list li {
    padding: 0.6rem 0; font-size: 14px; color: var(--grey-700);
    padding-left: 1.8rem; position: relative; line-height: 1.6;
}
.spec-list li::before { content: "\2713"; position: absolute; left: 0; color: var(--yellow-dark); font-weight: 700; }

.machine-highlight {
    padding: 1.2rem;
    background: linear-gradient(135deg, rgba(255,193,7,0.1), rgba(255,160,0,0.1));
    border-radius: 12px; margin: 1.5rem 0; border-left: 3px solid var(--yellow);
}
.highlight-label { font-weight: 600; margin-bottom: 0.5rem; font-size: 14px; }
.highlight-text { font-size: 14px; color: var(--grey-700); line-height: 1.6; }

.machine-ideal { padding: 1.2rem; background: var(--grey-100); border-radius: 12px; margin-top: 1.5rem; }
.ideal-label { font-weight: 600; margin-bottom: 0.5rem; font-size: 14px; }
.ideal-text { font-size: 14px; color: var(--grey-700); }
.machine-cta { margin-top: 2rem; }
.machine-cta .btn { width: 100%; text-align: center; }

@media (max-width: 968px) { .machine-grid { grid-template-columns: 1fr; } }
@media (max-width: 640px) { .dimensions-grid { grid-template-columns: 1fr; } }

/* CTA SECTION */
.cta-section {
    padding: clamp(80px, 12vw, 100px) 2rem;
    background: linear-gradient(135deg, var(--grey-900), var(--black));
    color: var(--white); text-align: center;
}
.cta-section h2 { color: var(--white); margin-bottom: 1rem; }
.cta-section > .container > p {
    font-size: 16px; color: rgba(255,255,255,0.85);
    margin-bottom: 3rem; max-width: 700px;
    margin-left: auto; margin-right: auto; line-height: 1.7;
}

/* FLIP CARDS */
.flip-cards-container {
    display: grid; grid-template-columns: repeat(3, 1fr);
    gap: 2rem; max-width: 1000px; margin: 0 auto;
}
.flip-card { height: 320px; perspective: 1000px; cursor: pointer; }
.flip-card-inner {
    position: relative; width: 100%; height: 100%;
    transition: transform 0.8s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    transform-style: preserve-3d;
}
.flip-card:hover .flip-card-inner { transform: rotateY(180deg); }
.flip-card-front, .flip-card-back {
    position: absolute; width: 100%; height: 100%;
    backface-visibility: hidden; border-radius: 20px;
    display: flex; flex-direction: column; align-items: center;
    justify-content: center; padding: 2rem; overflow: hidden;
}

/* Front styles */
.flip-card-front {
    background: linear-gradient(145deg, #ffffff 0%, #f0f0f0 100%);
    border: 2px solid rgba(200,200,200,0.5);
    box-shadow: 0 15px 35px rgba(0,0,0,0.15), 0 0 0 1px rgba(255,255,255,0.8) inset;
    transition: all 0.4s ease;
}
.flip-card:hover .flip-card-front {
    box-shadow: 0 25px 50px rgba(0,0,0,0.2), 0 0 0 1px rgba(255,255,255,1) inset;
}
.flip-card-front.featured {
    background: linear-gradient(145deg, #FFD54F 0%, var(--yellow) 50%, #e6ac00 100%);
    background-size: 200% 200%; animation: goldenShift 4s ease infinite;
    border: 2px solid rgba(255,220,100,0.8);
    box-shadow: 0 15px 40px rgba(255,193,7,0.4), 0 0 60px rgba(255,193,7,0.2);
}
@keyframes goldenShift { 0%, 100% { background-position: 0% 50%; } 50% { background-position: 100% 50%; } }

/* Floating circles */
.flip-card-front::before {
    content: ''; position: absolute; width: 150px; height: 150px;
    background: rgba(0,0,0,0.06); border-radius: 50%;
    top: -30px; right: -30px; animation: floatCircle1 8s ease-in-out infinite;
}
.flip-card-front.featured::before { background: rgba(255,255,255,0.15); }
.flip-card-front .circle-3, .flip-card-front .circle-4 {
    position: absolute; border-radius: 50%; pointer-events: none;
}
.flip-card-front .circle-3 {
    width: 60px; height: 60px; background: rgba(0,0,0,0.05);
    top: 50%; left: 20%; animation: floatCircle3 6s ease-in-out infinite;
}
.flip-card-front .circle-4 {
    width: 80px; height: 80px; background: rgba(0,0,0,0.03);
    bottom: 30%; right: 10%; animation: floatCircle4 12s ease-in-out infinite;
}
.flip-card-front.featured .circle-3 { background: rgba(255,255,255,0.12); }
.flip-card-front.featured .circle-4 { background: rgba(255,255,255,0.08); }

@keyframes floatCircle1 {
    0%, 100% { transform: translate(0,0) scale(1); }
    50% { transform: translate(-10px, 50px) scale(0.9); }
}
@keyframes floatCircle3 {
    0%, 100% { transform: translate(0,0); opacity: 0.5; }
    50% { transform: translate(40px, -30px) scale(1.2); opacity: 0.8; }
}
@keyframes floatCircle4 {
    0%, 100% { transform: translate(0,0) rotate(0deg); }
    50% { transform: translate(-30px, 10px) rotate(180deg); }
}

.flip-card-code {
    font-size: 56px; font-weight: 900; color: var(--black);
    margin-bottom: 0.5rem; letter-spacing: -2px;
    text-shadow: 2px 2px 0 rgba(255,255,255,0.5);
    position: relative; z-index: 2; animation: float 3s ease-in-out infinite;
}
@keyframes float { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-8px); } }

.flip-card-label {
    font-size: 16px; font-weight: 700; color: var(--grey-700);
    text-transform: uppercase; letter-spacing: 2px; position: relative;
}
.flip-card-front.featured .flip-card-label { color: var(--black); }

/* Back styles */
.flip-card-back {
    background: linear-gradient(145deg, var(--yellow) 0%, #e6ac00 100%);
    transform: rotateY(180deg); box-shadow: 0 15px 50px rgba(255,193,7,0.4);
}
.flip-card-back.investor {
    background: linear-gradient(145deg, #2d2d2d 0%, #1a1a1a 50%, #0a0a0a 100%);
    color: var(--white); box-shadow: 0 15px 50px rgba(0,0,0,0.5);
}
.flip-card-back img {
    max-width: 85%; max-height: 180px; object-fit: contain;
    margin-bottom: 1rem; filter: drop-shadow(0 10px 20px rgba(0,0,0,0.2));
}
.flip-card-back .btn-cadastre {
    display: inline-block;
    background: linear-gradient(145deg, #1a1a1a 0%, #000 100%);
    color: var(--white); padding: 14px 32px; border-radius: 50px;
    font-weight: 700; font-size: 14px; text-decoration: none;
    text-transform: uppercase; letter-spacing: 1px;
    transition: all 0.3s; box-shadow: 0 5px 20px rgba(0,0,0,0.3);
}
.flip-card-back .btn-cadastre:hover { transform: scale(1.08) translateY(-2px); }
.flip-card-back.investor .btn-cadastre {
    background: linear-gradient(145deg, var(--yellow) 0%, #e6ac00 100%);
    color: var(--black); box-shadow: 0 5px 20px rgba(255,193,7,0.4);
}
.flip-card-back .investor-text {
    font-size: 16px; line-height: 1.7; text-align: center;
    margin-bottom: 1.5rem; color: rgba(255,255,255,0.9);
}

@media (max-width: 768px) {
    .flip-cards-container { grid-template-columns: 1fr; max-width: 300px; margin: 0 auto; }
    .flip-card { height: 380px; }
    .flip-card-back img { max-height: 220px; }
}

/* BLOG */
.blog-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 2.5rem; margin-top: 3rem; }
.blog-card {
    background: var(--white); border: 1px solid var(--grey-300);
    border-radius: 16px; overflow: hidden; transition: all 0.3s;
}
.blog-card:hover { transform: translateY(-8px); box-shadow: 0 20px 40px rgba(0,0,0,0.1); border-color: var(--yellow); }
.blog-image { width: 100%; height: 240px; background: var(--grey-100); overflow: hidden; }
.blog-image img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.3s; }
.blog-card:hover .blog-image img { transform: scale(1.05); }
.blog-content { padding: 2rem; }
.blog-meta { font-size: 13px; color: var(--grey-500); margin-bottom: 1rem; }
.blog-content h5 { margin-bottom: 1rem; line-height: 1.4; }
.blog-content p { font-size: 14px; color: var(--grey-700); line-height: 1.7; margin-bottom: 1.5rem; }
.blog-link {
    color: var(--yellow-dark); font-weight: 600; font-size: 14px;
    text-decoration: none; display: inline-flex; align-items: center; gap: 0.5rem;
}
.blog-link:hover { gap: 0.8rem; }

@media (max-width: 968px) { .blog-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 640px) { .blog-grid { grid-template-columns: 1fr; } }

/* SOCIAL MEDIA */
.social-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 4rem; margin-top: 4rem; }
.social-embed {
    background: var(--white); border: 2px solid var(--grey-300);
    border-radius: 20px; padding: 2rem;
}
.social-embed h4 { margin-bottom: 1.5rem; display: flex; align-items: center; gap: 0.8rem; }
.social-embed h4 i { color: var(--yellow-dark); font-size: 24px; }
.social-posts-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1rem; margin-top: 1rem; }
.social-post-card {
    aspect-ratio: 1; background: var(--grey-100); border-radius: 12px;
    overflow: hidden; position: relative; transition: all 0.3s; cursor: pointer;
}
.social-post-card:hover { transform: scale(1.05); box-shadow: 0 8px 20px rgba(0,0,0,0.15); }
.social-post-card img { width: 100%; height: 100%; object-fit: cover; }
.social-post-overlay {
    position: absolute; top: 0; left: 0; width: 100%; height: 100%;
    background: rgba(0,0,0,0.5); display: flex; align-items: center;
    justify-content: center; opacity: 0; transition: opacity 0.3s;
}
.social-post-card:hover .social-post-overlay { opacity: 1; }
.social-post-overlay i { color: white; font-size: 32px; }
.social-cta { margin-top: 1.5rem; text-align: center; }
.social-cta a {
    display: inline-flex; align-items: center; gap: 0.5rem;
    padding: 0.8rem 1.5rem; background: var(--yellow); color: var(--black);
    text-decoration: none; border-radius: 8px; font-weight: 600;
    font-size: 14px; transition: all 0.3s;
}
.social-cta a:hover { background: var(--yellow-dark); transform: translateY(-2px); }

@media (max-width: 968px) { .social-grid { grid-template-columns: 1fr; } }
@media (max-width: 640px) {
    .social-posts-grid { grid-template-columns: repeat(2, 1fr); }
    .social-post-card:nth-child(3) { display: none; }
}