@import url("https://netdna.bootstrapcdn.com/font-awesome/4.1.0/css/font-awesome.css");

/* =========================================
   AP Simulation – all styles scoped to
   .ap-simulation to avoid site conflicts
   ========================================= */

.ap-simulation {
    font-family: 'Rubik', sans-serif;
    font-size: 1.1rem;
    color: #2c3e50;
    margin: 30px 0;
}

/* ---- Tabs ---- */
.ap-simulation input[type="radio"] {
    display: none;
}

.ap-simulation .tab {
    display: inline-block;
    margin: 0 0 -1px;
    padding: 15px 25px;
    font-weight: 600;
    text-align: center;
    color: #bbb;
    border: 1px solid transparent;
    cursor: pointer;
    font-size: 1.1rem;
}

.ap-simulation .tab:hover {
    color: #888;
}

.ap-simulation input[type="radio"]:checked + .tab {
    color: #555;
    border: 1px solid #ddd;
    border-top: 2px solid var(--primary-color, #f53d54);
    border-bottom: 1px solid #fff;
}

.ap-simulation .tab:before {
    font-family: fontawesome;
    font-weight: normal;
    margin-right: 8px;
}

.ap-simulation label[for*='1']:before { content: '\f0e7'; } /* fa-bolt */
.ap-simulation label[for*='2']:before { content: '\f013'; } /* fa-cog */
.ap-simulation label[for*='3']:before { content: '\f16b'; }
.ap-simulation label[for*='4']:before { content: '\f05a'; }

/* ---- Content sections ---- */
.ap-simulation section {
    display: none;
    padding: 20px 0 0;
    border-top: 1px solid #ddd;
}

#tab1:checked ~ #content1,
#tab2:checked ~ #content2,
#tab3:checked ~ #content3,
#tab4:checked ~ #content4 {
    display: block;
}

/* ---- Chart ---- */
.ap-simulation .chart-container {
    position: relative;
    width: 100%;
    margin-bottom: 20px;
}

/* ---- Select dropdown ---- */
.ap-simulation .selectdiv {
    margin-bottom: 15px;
}

.ap-simulation .selectdiv label {
    position: relative;
    display: inline-block;
    padding: 0 4px;
}

.ap-simulation .selectdiv label:before {
    content: "";
    height: 31px;
    position: absolute;
    right: 7px;
    top: 3px;
    width: 22px;
    background: #fff;
    border-top-right-radius: 3px;
    border-bottom-right-radius: 3px;
    pointer-events: none;
    display: block;
    font-family: inherit;
}

.ap-simulation .selectdiv label:after {
    content: " ";
    position: absolute;
    right: 15px;
    top: 46%;
    margin-top: -3px;
    z-index: 2;
    pointer-events: none;
    width: 0;
    height: 0;
    border-style: solid;
    border-width: 6.9px 4px 0 4px;
    border-color: #aaa transparent transparent transparent;
}

.ap-simulation .selectdiv select {
    -webkit-appearance: none;
    -moz-appearance: none;
    appearance: none;
    padding: 0 30px 0 10px;
    border: 1px solid #e0e0e0;
    border-radius: 3px;
    line-height: 36px;
    height: 36px;
    background: #fff;
    margin: 0 5px 5px 0;
    font-family: inherit;
    font-size: 1.1rem;
}

/* ---- Quantity number input ---- */
.ap-simulation .quantity {
    position: relative;
    display: inline-block;
    margin: 0 10px -17px;
}

.ap-simulation .quantity input[type="number"] {
    display: inline;
    width: 65px;
    height: 42px;
    line-height: 1.65;
    float: left;
    padding: 0 0 0 15px;
    margin: 0;
    border: 1px solid #eee;
    font-family: inherit;
    font-size: 1.1rem;
}

.ap-simulation .quantity input[type="number"].wide {
    width: 80px;
}

.ap-simulation .quantity input[type="number"]:focus {
    outline: 0;
}

.ap-simulation input[type="number"]::-webkit-inner-spin-button,
.ap-simulation input[type="number"]::-webkit-outer-spin-button {
    -webkit-appearance: none;
    margin: 0;
}

.ap-simulation input[type="number"] {
    -moz-appearance: textfield;
}

/* ---- Quantity nav (+/- buttons injected by jQuery) ---- */
.ap-simulation .quantity-nav {
    float: left;
    position: relative;
    height: 42px;
}

.ap-simulation .quantity-button {
    position: relative;
    cursor: pointer;
    border-left: 1px solid #eee;
    width: 20px;
    text-align: center;
    color: #333;
    font-size: 13px;
    line-height: 1.7;
    transform: translateX(-100%);
    user-select: none;
    display: block;
}

.ap-simulation .quantity-button.quantity-up {
    position: absolute;
    height: 50%;
    top: 0;
    border-bottom: 1px solid #eee;
}

.ap-simulation .quantity-button.quantity-down {
    position: absolute;
    bottom: -1px;
    height: 50%;
}

/* ---- Buttons ---- */
.ap-simulation .button-7 {
    background-color: var(--primary-color, #f53d54);
    border: none;
    border-radius: 4px;
    color: #fff;
    cursor: pointer;
    display: inline-block;
    font-family: 'Rubik', sans-serif;
    font-size: 13px;
    font-weight: 500;
    line-height: 1;
    margin: 0;
    outline: none;
    padding: 9px 16px;
    text-align: center;
    text-decoration: none;
    user-select: none;
    touch-action: manipulation;
    vertical-align: baseline;
    white-space: nowrap;
    transition: background-color 0.2s;
}

.ap-simulation .button-7:hover,
.ap-simulation .button-7:focus {
    background-color: #d4293f;
}

.ap-simulation .button-7:active {
    background-color: #b82234;
}

/* ---- Subsection & stats ---- */
.ap-simulation .subsection {
    margin: 0 0 20px;
    line-height: 2;
}

.ap-simulation .stats {
    font-size: 10px;
    line-height: 1;
}

/* ---- Responsive ---- */
@media screen and (max-width: 650px) {
    .ap-simulation .tab {
        font-size: 0;
        padding: 15px;
    }
    .ap-simulation .tab:before {
        margin: 0;
        font-size: 18px;
    }
}
