

::-webkit-scrollbar-track { background: #f8f9fa; }
::-webkit-scrollbar { 
    width: 5px; 
    height: 5px;
}
  
::-webkit-scrollbar-thumb {
    background: var(--secondary);
    opacity: .7;
    border-radius: 1em;
}



.content {

    display: flex;
   
    justify-content: center;
  
}
#settings, .container-items {
    height: 450px;
}

#settings {
    display: flex;
    align-items: center;
    flex-direction: column;
    color: #333;
    padding-top: 20px;
    background: #fff;
    border: 1px solid #e3e7ed;
    border-radius: 8px 0px 0px 0px;
    border-bottom: none;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.05);
    
}
.input-row {
    justify-content: center;
}

#flexbox-container{
    width: 55%;
}
.input-row {
    display: flex;
    gap: 20px;
    flex-wrap: wrap;
}

.input-group {
    display: flex;
    flex-direction: column;
    width: 200px;
    margin: 0.5em;
    min-width: fit-content;
}
.input-element{
    font-size: 15px;
}

.input-group label {
    font-weight: 600;
    color: #333;
    margin-bottom: 0.5rem;
    font-size: 17px;
}

.input-group select,
.input-group textarea,
.input-group input {
    margin-top: 0.5rem;
    height: 35px;
    width: 200px;
    padding: 0.5rem;
    background-color: #fff;
    color: #333;
    font-weight: 500;
    border: 1px solid #e3e7ed;
    border-radius: 4px;
    transition: all 0.3s ease;
}

.input-group select:focus,
.input-group textarea:focus,
.input-group input:focus {
    outline: none;
    border-color: var(--maincolor);
    box-shadow: 0 0 0 2px rgba(0, 0, 255, 0.1);
}

.css-result,
.input-group textarea {
    height: 150px;
    width: 100%;
    max-width: 600px;

    resize: none;
    font-family: 'Roboto Mono', monospace;
    font-size: 0.9rem;
    line-height: 1.5;
}

.css-result, .html-result {
    flex: 1;
    min-width: 300px;
}

.container {
    width: 45%;
 
    
}

.outputcodes{
    border: 1px solid #e3e7ed;
    border-radius: 0px 0px 8px 8px;
    background-color: white;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.05);
}
.container-items {
  
    
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.05);
    display: flex;
    background-color: #fff;
    border: 1px solid ;
    border-color: #e3e7ed;
   
    border-bottom: none;
    border-radius: 0px 8px 0px 0px;

    overflow-y: scroll;
}

/* Improve scroll perf */
.container-items { will-change: transform; }

.item {
    min-height: 60px;
    max-height: 480px;
    min-width: 60px;
    max-width: 480px;
    padding: .5em;
    background: linear-gradient(135deg, var(--maincolor) 0%, var(--orange) 100%);
    border-style: solid;
    border-width: 2px;
    border-color: #e3e7ed;
    color: #fff;
    font-weight: 600;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 6px;
}

.button-group {
    flex-direction: row;
    gap: 1rem;
    margin-top: 1rem;
    width: 100%;
    justify-content: center;
}

.action-button {
    height: 35px;
    padding: 0 1rem;
    background-color: #fff;
    color: #333;
    border: 1px solid #000000;
    border-radius: 4px;
    cursor: pointer;
    font-weight: 600;
    transition: all 0.3s ease;
    min-width: 120px;
    font-size: 15px;
}

.action-button:hover {
    background: linear-gradient(135deg, var(--maincolor) 0%, var(--orange) 100%);
    color: #fff;
    transform: translateY(-2px);
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

#remove-item {
    background-color: #fff;
    color: #ea4335;
    border-color: #ea4335;
}

#remove-item:hover {
    background-color: #ea4335;
    color: #fff;
}

#reset-items {
    background-color: #fff;
    color: var(--maincolor);
    border-color: var(--maincolor);
}

#reset-items:hover {
    background-color: var(--maincolor);
    color: #fff;
}

#flexbox-container,    
.container { animation: fade 500ms; }

.input-group { animation: move-to-right 600ms backwards; animation-timing-function: cubic-bezier(0.075, 0.82, 0,165, 1);}
.input-row:nth-child(1) .input-group:nth-child(1) { animation-delay: 250ms; }
.input-row:nth-child(1) .input-group:nth-child(4) { animation-delay: 50ms; }
.input-row:nth-child(1) .input-group:nth-child(3) { animation-delay: 300ms; }
.input-row:nth-child(1) .input-group:nth-child(6) { animation-delay: 100ms; }
.input-row:nth-child(1) .input-group:nth-child(5) { animation-delay: 350ms; }
.container { 
    animation: move-to-left 700ms 350ms backwards; 
    animation-timing-function: ease-in-out;
}

@keyframes fade {
    from {
        opacity: 0;
        transform: scale(0.8);
    } to {
        opacity: 1;
        transform: scale(1);
    }
}

@keyframes move-to-right {
    from {
        opacity: 0;
        transform: translateX(-100vh);
    } to {
        opacity: 1;
        transform: translateX(0%);
    }
}

@keyframes move-to-left {
    from {
        opacity: 0;
        transform: translateX(200vh);
    } to {
        opacity: 1;
        transform: translateX(0%);
    }
}

.css-copy-container, .html-copy-container {
    position: relative;
    margin-top: 5px;
}

#container-css, #container-html {
    width: 100%;
    min-height: 170px;
    padding: 10px;
    border: 1px solid #ccc;
    border-radius: 4px;
    font-family: monospace;
    resize: vertical;
    color: darkmagenta;
}

.copy-button {
    position: absolute;
    top: 0px;
    right: 0px;
    padding: 5px 10px;
    background: #f0f0f0;
    border: 1px solid #ccc;
    border-radius: 4px;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 5px;
    color: blue;
}

.copy-button:hover {
    background: #e0e0e0;
}

/* Responsive Styles */
@media screen and (max-width: 1200px) {
    .content {
        flex-direction: column;
        height: auto;
       
    }

    .container {
        width: 100%;
        
    }

    #flexbox-container {
        width: 100%;
    }
    #settings, .container-items {
        height: 400px;
    }
}

@media screen and (max-width: 768px) {
    .input-row {
        flex-direction: column;
        align-items: center;
    }

    .input-group {
        width: 100%;
        max-width: 400px;
        margin: 0.5rem 0;
    }

    .input-group select,
    .input-group textarea,
    .input-group input {
        width: 100%;
    }

    .css-result,
    .input-group textarea {
        width: 100%;
        max-width: 400px;
    }

 

    .action-button {
        width: 100%;
        max-width: 200px;
    }
    #settings {
        height: 770px;
    }
    .container-items{
        height: 400px;
    }
   
}

@media screen and (max-width: 480px) {
    #settings {
        padding: 1rem;
    }

    .input-group {
        max-width: 100%;
    }

    .css-result,
    .input-group textarea {
        max-width: 100%;
        padding: 4px;
    }

    .container-items {
        height: 300px;
    }

    .item {
        min-width: 40px;
        min-height: 40px;
    }

    .button-group {
        gap: 0.5rem;
    }

    .action-button {
        padding: 0.1rem;
        font-size: 0.8rem;
    }
    .action-button {
        min-height: 33px;
    }

}

@media screen and (max-width: 400px) {

.input-group select, .input-group textarea, .input-group input {
    width: 95vw;
}
.button-group{
    flex-direction: column;
}
#container-css, #container-html{
    width: 95vw;
}
#settings {
	height: 820px;
}
.action-button {
	
	max-width: none;
}
.copy-button {
	position: absolute;
	top: 7px;
	right: 20px;
	padding: 2px 4px;
font-size: small;
}
}
/* Fix for very small screens */
@media screen and (max-width: 320px) {
    .input-group label {
        font-size: 0.9rem;
    }

    .input-group select,
    .input-group textarea,
    .input-group input {
        font-size: 0.9rem;
    }

    .container-items {
        height: 250px;
    }
}


/* Fix for container items overflow */
.container-items {
    overflow-x: auto;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
}

/* Improve touch targets on mobile */
@media (hover: none) {
    .action-button,
    .input-group select,
    .input-group input {
        min-height: 44px; /* Minimum touch target size */
    }
}