/* ==========================================================================
   ICHIMALL Presentation Portal - Light Theme CSS
   Inspired by the Live Ichimall.com Design System
   ========================================================================== */

/* Imports */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700&family=Outfit:wght@400;500;600;700;800&display=swap');

/* CSS Variables */
:root {
    --font-heading: 'Outfit', 'Yu Gothic Medium', 'Yu Gothic', '游ゴシック体', sans-serif;
    --font-body: 'Inter', 'Yu Gothic Medium', 'Yu Gothic', '游ゴシック体', sans-serif;
    
    /* Core Light Theme Palette */
    --bg-portal: #ffffff;
    --text-primary: #333333;
    --text-secondary: #666666;
    --text-muted: #888888;
    --border-color: #ddd;
    
    /* Live Ichimall Specifics */
    --bg-header-footer: #eee;
    --accent-link: rgb(6, 142, 89); /* Green links */
    --btn-gray: #9c9c9c;
    
    /* Brand Accent Colors */
    --accent-ichimall: #4f46e5; /* Indigo */
    --accent-enakuam: #d97706; /* Earthy Amber */
    --accent-lamaisonjaponaise: #dc2626; /* Crimson Red */
    --accent-xsrecord: #04368c; /* Dark Blue */
    
    /* System Tokens */
    --radius-sm: 8px;
    --radius-md: 15px; /* Replicating live 15px radius */
    --radius-lg: 20px;
    --shadow-sm: 0 2px 4px rgba(0, 0, 0, 0.05);
    --shadow-md: 0px 0px 20px lightgrey; /* Replicating live shadow */
    --shadow-lg: 0px 10px 30px rgba(0, 0, 0, 0.08);
    --transition-smooth: all 0.25s ease-out;
    
    --primary-color: var(--accent-ichimall);
}

/* Reset & Base Rules */
.ichimall-app-wrapper * {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body{
    background-color:#f2f2f2;
}

main {
    padding-left: 20px;
    padding-right: 20px;
}

.ksg_api_news_7_priority-badge{
    display:none !important;
}

.ichimall-app-wrapper {
    font-family: var(--font-body);
    background-color: var(--bg-portal);
    color: var(--text-primary);
    line-height: 1.6;
    min-height: 100vh;
    overflow-x: hidden;
    position: relative;
    padding: 30px 15px;
}

/* Scrollbar styling */
.ichimall-app-wrapper ::-webkit-scrollbar {
    width: 8px;
    height: 8px;
}
.ichimall-app-wrapper ::-webkit-scrollbar-track {
    background: transparent;
}
.ichimall-app-wrapper ::-webkit-scrollbar-thumb {
    background: #ccc;
    border-radius: 4px;
}
.ichimall-app-wrapper ::-webkit-scrollbar-thumb:hover {
    background: #999;
}

/* Typography elements */
.ichimall-app-wrapper h1, 
.ichimall-app-wrapper h2, 
.ichimall-app-wrapper h3, 
.ichimall-app-wrapper h4 {
    font-family: var(--font-heading);
    font-weight: 700;
    color: #111111;
    line-height: 1.25;
}

.ichimall-app-wrapper p {
    color: var(--text-secondary);
    font-size: 1rem;
    font-weight: 400;
}

/* Layout Utilities */
.ichimall-container {
    max-width: 1200px;
    margin: 0 auto;
    width: 100%;
}

.text-center { text-align: center; }
.mb-xs { margin-bottom: 8px; }
.mb-sm { margin-bottom: 16px; }
.mb-md { margin-bottom: 24px; }
.mb-lg { margin-bottom: 40px; }
.mb-xl { margin-bottom: 60px; }

/* SPA Route View Panels */
.ichimall-view {
    opacity: 1;
    transform: translateY(0);
    transition: opacity 0.3s ease, transform 0.3s ease-out;
    will-change: opacity, transform;
}

.ichimall-view.fade-out {
    opacity: 0;
    transform: translateY(10px);
}

.ichimall-view.fade-in {
    opacity: 0;
    transform: translateY(-10px);
    transition: none;
}

/* Banners (250px Height) styling */
.company-banner {
    height: 250px;
    width: 100%;
    border-radius: var(--radius-md);
    overflow: hidden;
    position: relative;
    border: 1px solid #dedede;
    background-color: #f6f6f6;
    margin-bottom: 15px;
}

.company-banner img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
    transition: var(--transition-smooth);
    will-change: transform;
}

.company-banner:hover img {
    transform: scale(1.02);
}

/* Form Container style - Replicating live login form box */
.form-card {
    background: linear-gradient(0deg, #eee 10%, #eaeaea 20%, #eaeaea 80%, #eee 100%);
    border-radius: var(--radius-md);
    padding: 40px;
    box-shadow: var(--shadow-md);
    max-width: 800px;
    margin: 0 auto;
    border: 1px solid #dedede;
}

/* Clean Info Cards for Home & sub-pages */
.info-card {
    background: #ffffff;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 30px;
    box-shadow: var(--shadow-sm);
    transition: var(--transition-smooth);
}

.info-card:hover {
    border-color: #bbb;
    box-shadow: var(--shadow-md);
}

/* Buttons System */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-family: var(--font-heading);
    font-weight: 600;
    font-size: 0.95rem;
    padding: 10px 24px;
    border-radius: var(--radius-md); /* 15px border radius */
    border: 1px solid var(--border-color);
    cursor: pointer;
    text-decoration: none;
    transition: var(--transition-smooth);
    gap: 8px;
}

/* Replicating live buttons styling */
.btn-primary {
    background: var(--btn-gray);
    color: #ffffff;
    border: none;
}

.btn-primary:hover {
    background: #808080;
    transform: translateY(-1px);
}

.btn-secondary {
    background: #ffffff;
    color: var(--text-primary);
    border: 1px solid var(--border-color);
}

.btn-secondary:hover {
    background: #f5f5f5;
    border-color: #bbb;
    transform: translateY(-1px);
}

.btn-brand-action {
    background: #ffffff;
    color: var(--accent-link);
    border: 1px solid var(--border-color);
}

.btn-brand-action:hover {
    background: #f9f9f9;
    border-color: var(--accent-link);
    transform: translateY(-1px);
}

.btn:active {
    transform: translateY(0);
}

/* Form Styles */
.form-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
}

.form-full {
    grid-column: span 2;
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.form-label {
    font-family: var(--font-heading);
    font-weight: 600;
    font-size: 0.9rem;
    color: var(--text-primary);
    margin-left: 2px;
}

.form-control {
    background: #ffffff;
    border: 1px solid #ccc;
    border-radius: 8px;
    padding: 12px 16px;
    color: var(--text-primary);
    font-family: var(--font-body);
    font-size: 0.95rem;
    transition: var(--transition-smooth);
    width: 100%;
}

.form-control:focus {
    border-color: #666;
    outline: none;
    box-shadow: 0 0 0 3px rgba(0, 0, 0, 0.05);
}

textarea.form-control {
    resize: vertical;
    min-height: 120px;
}

/* Portal Main Header Title (No site header/footer allowed) */
.portal-hero {
    text-align: center;
    padding: 30px 0;
    border-bottom: 2px solid #eee;
}

.portal-hero h1 {
    font-size: 2.8rem;
    font-weight: 800;
    color: #111;
    margin-bottom: 12px;
    letter-spacing: 0.05em;
}

.portal-hero p {
    font-size: 1.1rem;
    max-width: 750px;
    margin: 0 auto;
    color: var(--text-secondary);
}

/* Company grid items */
.companies-grid {
    display: flex;
    flex-direction: column;
    gap: 35px;
    margin-bottom: 50px;
    margin-top: 40px;
}

.company-card {
    display: grid;
    grid-template-columns: 340px 1fr;
    gap: 30px;
    align-items: center;
    background: #ffffff;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 25px;
    transition: var(--transition-smooth);
    box-shadow: var(--shadow-sm);
}

.company-card:hover {
    border-color: #bbb;
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
}

.company-info-panel {
    display: flex;
    flex-direction: column;
    justify-content: center;
    height: 100%;
}

.company-card-header {
    display: flex;
    align-items: center;
    gap: 20px;
    margin-bottom: 14px;
}

.company-card-logo {
    height: 45px;
    width: auto;
    object-fit: contain;
    max-width: 140px;
}

.company-card h3 {
    font-size: 1.5rem;
    font-weight: 700;
    color: #111;
}

.company-card p {
    font-size: 0.95rem;
    margin-bottom: 20px;
    color: var(--text-secondary);
}

.company-card-footer {
    display: flex;
    gap: 12px;
}

/* Custom pages styles (Enakuam, La Maison Japonaise, XS Record) */
.brand-page-container {
    padding: 10px 0;
}

.brand-header-section {
    display: flex;
    align-items: center;
    gap: 25px;
    margin-bottom: 30px;
    border-bottom: 1px solid var(--border-color);
    padding-bottom: 25px;
}

.brand-header-logo {
    height: 60px;
    width: auto;
    object-fit: contain;
    max-width: 200px;
}

.brand-header-text h1 {
    font-size: 2.2rem;
    margin-bottom: 4px;
}

.brand-header-text p {
    font-size: 1.05rem;
}

.brand-details-grid {
    display: grid;
    grid-template-columns: 2fr 1.2fr;
    gap: 30px;
    align-items: start;
    margin-bottom: 40px;
}

.brand-story-card {
    padding: 30px;
}

.brand-story-card h2 {
    font-size: 1.6rem;
    margin-bottom: 15px;
    position: relative;
    padding-bottom: 8px;
}

.brand-story-card h2::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 50px;
    height: 2px;
    background: var(--primary-color);
}

.brand-story-card p {
    margin-bottom: 16px;
    line-height: 1.7;
}

.brand-features-list {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.brand-feature-item {
    display: flex;
    gap: 15px;
    align-items: flex-start;
}

.brand-feature-icon {
    font-size: 1.2rem;
    background: #f5f5f5;
    border: 1px solid var(--border-color);
    width: 42px;
    height: 42px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    color: var(--primary-color);
    flex-shrink: 0;
}

.brand-feature-content h4 {
    font-size: 1rem;
    margin-bottom: 4px;
    color: #111;
}

.brand-feature-content p {
    font-size: 0.9rem;
    color: var(--text-secondary);
}

/* Floating Navigation helper for SPA (Since no native header/footer) */
.page-navigation-controls {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 25px;
}

/* Alert styles for clipboard copy feedback */
.clipboard-toast {
    position: fixed;
    bottom: 30px;
    right: 30px;
    background: rgb(6, 142, 89); /* green */
    color: white;
    padding: 12px 20px;
    border-radius: var(--radius-sm);
    box-shadow: var(--shadow-lg);
    display: flex;
    align-items: center;
    gap: 10px;
    font-family: var(--font-heading);
    font-weight: 600;
    z-index: 1000;
    transform: translateY(100px);
    opacity: 0;
    transition: transform 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275), opacity 0.4s ease;
}

.clipboard-toast.show {
    transform: translateY(0);
    opacity: 1;
}

/* Custom Palette theme injectors per Route */
.route-enakuam {
    --primary-color: var(--accent-enakuam);
}
.route-lamaisonjaponaise {
    --primary-color: var(--accent-lamaisonjaponaise);
}
.route-xsrecord {
    --primary-color: var(--accent-xsrecord);
}

/* Responsive Rules */
@media (max-width: 900px) {
    .company-card {
        grid-template-columns: 1fr;
        gap: 20px;
    }
    .brand-details-grid {
        grid-template-columns: 1fr;
        gap: 25px;
    }
    .portal-hero h1 {
        font-size: 2.3rem;
    }
}

@media (max-width: 640px) {
    .form-grid {
        grid-template-columns: 1fr;
    }
    .form-full {
        grid-column: span 1;
    }
    .portal-hero h1 {
        font-size: 1.8rem;
    }
    .company-banner {
        height: 180px;
    }
    .btn {
        width: 100%;
    }
    .company-card-footer {
        flex-direction: column;
        gap: 10px;
    }
    .form-card {
        padding: 25px 15px;
    }
}

/* Floating Language Switcher */
.lang-switcher {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 1000;
    display: flex;
    gap: 8px;
    background: rgba(255, 255, 255, 0.7);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid rgba(0, 0, 0, 0.1);
    padding: 6px 12px;
    border-radius: 30px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.05);
    transition: var(--transition-smooth);
}

.lang-switcher:hover {
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.1);
    background: rgba(255, 255, 255, 0.9);
}

.lang-btn {
    text-decoration: none;
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--text-secondary);
    padding: 4px 10px;
    border-radius: 15px;
    transition: var(--transition-smooth);
}

.lang-btn:hover {
    color: var(--text-primary);
}

.lang-btn.active {
    background: var(--primary-color);
    color: #ffffff;
}

/* Adjust layout on small screens to avoid overlap */
@media (max-width: 640px) {
    .lang-switcher {
        top: 10px;
        right: 10px;
        padding: 4px 8px;
    }
    .lang-btn {
        font-size: 0.75rem;
        padding: 3px 8px;
    }
    .ichimall-app-wrapper {
        padding-top: 60px; /* Leave space for the floating bar */
    }
}
