/**
 * AFM Pro - Simple Styles
 * Basic styling for the AFM FlexBox widget
 */

/* AFM FlexBox Base Styles */
.afm-flexbox {
    display: flex;
    align-items: center;
    gap: 24px;
    padding: 32px;
    background: #ffffff;
    border-radius: 12px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
    transition: all 0.3s ease;
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
    position: relative;
}

.afm-flexbox:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
}

/* Horizontal Layout (Default) */
.afm-horizontal {
    flex-direction: row;
}

.afm-horizontal .afm-image {
    flex: 0 0 40%;
}

.afm-horizontal .afm-content {
    flex: 1;
}

/* Vertical Layout */
.afm-vertical {
    flex-direction: column;
    text-align: center;
}

.afm-vertical .afm-image {
    width: 100%;
}

.afm-vertical .afm-content {
    width: 100%;
}

/* Image Styles */
.afm-image {
    overflow: hidden;
    border-radius: 8px;
}

.afm-image img {
    width: 100%;
    height: auto;
    display: block;
    transition: transform 0.3s ease;
}

.afm-image:hover img {
    transform: scale(1.05);
}

/* Content Styles */
.afm-content {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.afm-title {
    font-size: 24px;
    font-weight: 700;
    line-height: 1.2;
    color: #171a20;
    margin: 0;
}

.afm-description {
    font-size: 16px;
    line-height: 1.6;
    color: #5c5e62;
    margin: 0;
}

/* Button Styles */
.afm-button-wrapper {
    margin-top: 8px;
}

.afm-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 8px 20px;
    background-color: #3566f4;
    color: #ffffff;
    text-decoration: none;
    border-radius: 4px;
    font-size: 14px;
    font-weight: 500;
    transition: all 0.3s ease;
    border: none;
    cursor: pointer;
    min-height: 36px;
}

.afm-button:hover {
    background-color: #2b52cc;
    transform: translateY(-1px);
    box-shadow: 0 4px 8px rgba(53, 102, 244, 0.3);
    color: #ffffff;
    text-decoration: none;
}

.afm-button:active {
    transform: translateY(0);
}

/* Responsive Design */
@media (max-width: 768px) {
    .afm-flexbox {
        flex-direction: column;
        text-align: center;
        padding: 24px;
        gap: 20px;
    }
    
    .afm-horizontal .afm-image {
        flex: none;
        width: 100%;
    }
    
    .afm-horizontal .afm-content {
        flex: none;
        width: 100%;
    }
    
    .afm-title {
        font-size: 20px;
    }
    
    .afm-description {
        font-size: 14px;
    }
    
    .afm-button {
        width: 100%;
        padding: 12px 24px;
    }
}

@media (max-width: 480px) {
    .afm-flexbox {
        padding: 20px;
        gap: 16px;
    }
    
    .afm-title {
        font-size: 18px;
    }
}

/* Dark Mode Support */
@media (prefers-color-scheme: dark) {
    .afm-flexbox {
        background: #1a1a1a;
        color: #ffffff;
    }
    
    .afm-title {
        color: #ffffff;
    }
    
    .afm-description {
        color: #a3a3a3;
    }
}

/* Print Styles */
@media print {
    .afm-flexbox {
        box-shadow: none;
        border: 1px solid #e3e3e3;
    }
    
    .afm-button {
        display: none;
    }
}

/* Accessibility */
.afm-button:focus {
    outline: 2px solid #3566f4;
    outline-offset: 2px;
}

/* Reduced Motion */
@media (prefers-reduced-motion: reduce) {
    .afm-flexbox,
    .afm-button,
    .afm-image img {
        transition: none;
    }
    
    .afm-flexbox:hover {
        transform: none;
    }
    
    .afm-button:hover {
        transform: none;
    }
    
    .afm-image:hover img {
        transform: none;
    }
}

/* August Hero Section Styles */
.afm-august-hero {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    min-height: 100vh;
    background-size: cover;
    background-position: center center;
    background-repeat: no-repeat;
    overflow: hidden;
}

.afm-august-hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: rgba(0, 0, 0, 0.3);
    z-index: 1;
}

.afm-august-hero-content {
    position: relative;
    z-index: 2;
    text-align: center;
    max-width: 800px;
    padding: 0 20px;
}

.afm-august-hero-title {
    font-size: 48px;
    font-weight: 600;
    line-height: 1.2;
    color: #ffffff;
    margin: 0 0 16px 0;
    letter-spacing: -0.02em;
}

.afm-august-hero-subtitle {
    font-size: 20px;
    font-weight: 400;
    line-height: 1.4;
    color: #ffffff;
    margin: 0 0 32px 0;
    opacity: 0.9;
}

.afm-august-hero-buttons {
    display: flex;
    gap: 16px;
    justify-content: center;
    flex-wrap: wrap;
}

.afm-august-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 8px 24px;
    text-decoration: none;
    border-radius: 4px;
    font-size: 14px;
    font-weight: 500;
    transition: all 0.3s ease;
    border: none;
    cursor: pointer;
    min-width: 120px;
    min-height: 36px;
}

.afm-august-btn-primary {
    background-color: #3566f4;
    color: #ffffff;
}

.afm-august-btn-primary:hover {
    background-color: #2b52cc;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(53, 102, 244, 0.4);
    color: #ffffff;
    text-decoration: none;
}

.afm-august-btn-secondary {
    background-color: rgba(255, 255, 255, 0.1);
    color: #ffffff;
    border: 1px solid rgba(255, 255, 255, 0.3);
}

.afm-august-btn-secondary:hover {
    background-color: rgba(255, 255, 255, 0.2);
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(255, 255, 255, 0.2);
    color: #ffffff;
    text-decoration: none;
}

/* August Hero Responsive */
@media (max-width: 768px) {
    .afm-august-hero-title {
        font-size: 36px;
    }
    
    .afm-august-hero-subtitle {
        font-size: 18px;
        margin-bottom: 24px;
    }
    
    .afm-august-hero-buttons {
        flex-direction: column;
        align-items: center;
        gap: 12px;
    }
    
    .afm-august-btn {
        width: 100%;
        max-width: 280px;
    }
}

@media (max-width: 480px) {
    .afm-august-hero-title {
        font-size: 28px;
    }
    
    .afm-august-hero-subtitle {
        font-size: 16px;
    }
    
    .afm-august-hero-content {
        padding: 0 16px;
    }
}

/* August Hero Reduced Motion */
@media (prefers-reduced-motion: reduce) {
    .afm-august-btn {
        transition: none;
    }
    
    .afm-august-btn:hover {
        transform: none;
    }
}

/* August CTA Card Styles */
.afm-august-cta-card {
    position: relative;
    display: flex;
    width: 100%;
    height: 300px;
    background-color: #f8f9fa;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
    transition: all 0.3s ease;
}

.afm-august-cta-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.12);
}

/* Image positioning */
.afm-august-cta-image {
    position: absolute;
    top: 0;
    width: 50%;
    height: 100%;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    border-radius: 8px;
}

.afm-image-right .afm-august-cta-image {
    right: 0;
    border-radius: 0 12px 12px 0;
}

.afm-image-left .afm-august-cta-image {
    left: 0;
    border-radius: 12px 0 0 12px;
}

/* Content positioning */
.afm-august-cta-content {
    position: relative;
    display: flex;
    flex-direction: column;
    justify-content: center;
    width: 50%;
    padding: 32px;
    z-index: 2;
}

.afm-image-right .afm-august-cta-content {
    padding-right: 32px;
    padding-left: 32px;
}

.afm-image-left .afm-august-cta-content {
    margin-left: 50%;
    padding-left: 32px;
    padding-right: 32px;
}

/* Typography */
.afm-august-cta-title {
    font-size: 24px;
    font-weight: 600;
    line-height: 1.3;
    color: #171a20;
    margin: 0 0 24px 0;
    letter-spacing: -0.01em;
}

/* Button - Tesla-style simple text link */
.afm-august-cta-button {
    display: inline-flex;
    align-items: center;
    justify-content: flex-start;
    padding: 0;
    background-color: transparent;
    color: #5c5e62;
    text-decoration: underline;
    font-size: 14px;
    font-weight: 500;
    border: none;
    border-radius: 0;
    transition: all 0.3s ease;
    cursor: pointer;
    width: fit-content;
    min-width: auto;
}

.afm-august-cta-button:hover {
    background-color: transparent;
    color: #171a20;
    text-decoration: underline;
    transform: none;
    box-shadow: none;
}

/* Responsive Design */
@media (max-width: 768px) {
    .afm-august-cta-card {
        flex-direction: column;
        height: auto;
        min-height: 400px;
    }
    
    .afm-august-cta-image {
        position: relative;
        width: 100%;
        height: 200px;
        border-radius: 12px 12px 0 0;
    }
    
    .afm-image-right .afm-august-cta-image,
    .afm-image-left .afm-august-cta-image {
        border-radius: 12px 12px 0 0;
    }
    
    .afm-august-cta-content {
        width: 100%;
        margin-left: 0;
        padding: 24px;
    }
    
    .afm-image-left .afm-august-cta-content {
        margin-left: 0;
    }
    
    .afm-august-cta-title {
        font-size: 20px;
        margin-bottom: 16px;
    }
}

@media (max-width: 480px) {
    .afm-august-cta-card {
        min-height: 350px;
    }
    
    .afm-august-cta-image {
        height: 160px;
    }
    
    .afm-august-cta-content {
        padding: 20px;
    }
    
    .afm-august-cta-title {
        font-size: 18px;
    }
}

/* CTA Card Reduced Motion */
@media (prefers-reduced-motion: reduce) {
    .afm-august-cta-card,
    .afm-august-cta-button {
        transition: none;
    }
    
    .afm-august-cta-card:hover {
        transform: none;
    }
    
    .afm-august-cta-button:hover {
        transform: none;
    }
}

/* August Offset Slider Styles */
.afm-august-offset-slider {
    position: relative;
    width: 100%;
    overflow: hidden;
    padding: 0;
}

.afm-august-offset-slider .swiper-container {
    width: 100%;
    height: 100%;
    overflow: visible;
    padding: 0 20px;
}

.afm-august-offset-slider .swiper-wrapper {
    align-items: center;
}

.afm-august-offset-slider .swiper-slide {
    width: 60%;
    height: auto;
    flex-shrink: 0;
}

/* Slide Styles */
.afm-offset-slide {
    position: relative;
    width: 100%;
    height: 600px;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    border-radius: 12px;
    overflow: hidden;
    display: flex;
    align-items: flex-end;
    padding: 60px;
    box-sizing: border-box;
}

.afm-offset-slide::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: rgba(0, 0, 0, 0.3);
    z-index: 1;
}

.afm-slide-content {
    position: relative;
    z-index: 2;
    color: #ffffff;
    max-width: 600px;
}

/* Overlay Label - Tesla-style simple text in upper left */
.afm-slide-overlay-label {
    position: absolute;
    top: 32px;
    left: 32px;
    background-color: transparent;
    color: #ffffff;
    padding: 0;
    border-radius: 0;
    font-size: 14px;
    font-weight: 400;
    backdrop-filter: none;
    z-index: 3;
    text-shadow: 0 1px 3px rgba(0, 0, 0, 0.3);
}

/* Typography */
.afm-slide-title {
    font-size: 48px;
    font-weight: 600;
    line-height: 1.2;
    color: #ffffff;
    margin: 0 0 16px 0;
    letter-spacing: -0.02em;
}

.afm-slide-subtitle {
    font-size: 18px;
    font-weight: 400;
    line-height: 1.4;
    color: #ffffff;
    margin: 0 0 32px 0;
    opacity: 0.9;
}

/* Buttons - Tesla-style slim buttons */
.afm-slide-buttons {
    display: flex;
    gap: 16px;
    flex-wrap: wrap;
}

.afm-slide-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 8px 24px;
    text-decoration: none;
    border-radius: 4px;
    font-size: 14px;
    font-weight: 500;
    transition: all 0.3s ease;
    border: none;
    cursor: pointer;
    min-width: 120px;
    min-height: 36px;
}

.afm-slide-btn-primary {
    background-color: #3566f4;
    color: #ffffff;
}

.afm-slide-btn-primary:hover {
    background-color: #2b52cc;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(53, 102, 244, 0.4);
    color: #ffffff;
    text-decoration: none;
}

.afm-slide-btn-secondary {
    background-color: rgba(255, 255, 255, 0.1);
    color: #ffffff;
    border: 1px solid rgba(255, 255, 255, 0.3);
}

.afm-slide-btn-secondary:hover {
    background-color: rgba(255, 255, 255, 0.2);
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(255, 255, 255, 0.2);
    color: #ffffff;
    text-decoration: none;
}

/* Pagination Dots */
.afm-august-offset-slider .swiper-pagination {
    position: relative;
    margin-top: 30px;
    text-align: center;
}

.afm-august-offset-slider .swiper-pagination-bullet {
    width: 8px;
    height: 8px;
    background-color: rgba(255, 255, 255, 0.5);
    border-radius: 50%;
    margin: 0 4px;
    cursor: pointer;
    transition: all 0.3s ease;
    opacity: 1;
}

.afm-august-offset-slider .swiper-pagination-bullet-active {
    background-color: #ffffff;
    transform: scale(1.2);
}

/* Responsive Design */
@media (min-width: 1200px) {
    .afm-august-offset-slider .swiper-slide {
        width: 55%;
    }
}

@media (max-width: 1024px) {
    .afm-august-offset-slider {
        padding: 0 15px;
    }
    
    .afm-august-offset-slider .swiper-slide {
        width: 65%;
    }
    
    .afm-offset-slide {
        padding: 40px;
    }
    
    .afm-slide-title {
        font-size: 36px;
    }
    
    .afm-slide-subtitle {
        font-size: 16px;
        margin-bottom: 24px;
    }
}

@media (max-width: 768px) {
    .afm-august-offset-slider {
        padding: 0 10px;
    }
    
    .afm-august-offset-slider .swiper-slide {
        width: 85%;
    }
    
    .afm-offset-slide {
        padding: 30px;
        height: 500px;
    }
    
    .afm-slide-overlay-label {
        top: 30px;
        left: 30px;
        font-size: 12px;
    }
    
    .afm-slide-title {
        font-size: 28px;
    }
    
    .afm-slide-subtitle {
        font-size: 14px;
    }
    
    .afm-slide-buttons {
        flex-direction: column;
        gap: 12px;
    }
    
    .afm-slide-btn {
        width: 100%;
        max-width: 280px;
    }
}

@media (max-width: 480px) {
    .afm-offset-slide {
        padding: 20px;
        height: 400px;
    }
    
    .afm-slide-overlay-label {
        top: 20px;
        left: 20px;
    }
    
    .afm-slide-title {
        font-size: 24px;
    }
}

/* Offset Slider Reduced Motion */
@media (prefers-reduced-motion: reduce) {
    .afm-slide-btn,
    .afm-august-offset-slider .swiper-pagination-bullet {
        transition: none;
    }
    
    .afm-slide-btn:hover {
        transform: none;
    }
    
    .afm-august-offset-slider .swiper-pagination-bullet-active {
        transform: none;
    }
}
