_footer.scss 9.22 KB
Newer Older
1
// Open edX: LMS footer
2
// ====================
3 4 5
@import '../base/grid-settings';
@import 'neat/neat'; // lib - Neat

6
.wrapper-footer {
7
  box-shadow: 0 -1px 5px 0 $shadow-l1;
8
  border-top: 1px solid tint($m-gray,50%);
9
  padding: 25px ($baseline/2) ($baseline*1.5) ($baseline/2);
10
  background: $footer-bg;
11
  clear: both;
12

13 14
  footer {
    @include clearfix();
15
    @include box-sizing(border-box);
16 17
    max-width: grid-width(12);
    min-width: 760px;
18
    width: flex-grid(12);
19 20 21 22
    margin: 0 auto;

    p, ol, ul {
      font-family: $sans-serif;
23 24 25 26 27

      // override needed for poorly scoped font-family styling on p a:link {}
      a {
        font-family: $sans-serif;
      }
28 29 30
    }

    a {
31
      @include transition(link-color 0.15s ease-in-out 0s, border 0.15s ease-in-out 0s);
32 33 34
      border-bottom: none;
      color: $link-color;
      text-decoration: none !important;
35

36
      &:hover, &:focus, &:active {
37
        border-bottom: 1px dotted $link-color;
38 39 40 41 42
      }
    }

    // colophon
    .colophon {
43
      @include margin-right(flex-gutter());
44
      width: flex-grid(8,12);
45
      @include float(left);
46

47 48
      .nav-colophon {
        @include clearfix();
49
        margin: $footer_margin;
50 51

        li {
52
          @include float(left);
53 54 55 56 57
          margin-right: ($baseline*0.75);

          a {
            color: tint($black, 20%);

58
            &:hover, &:focus, &:active {
59
              color: $link-color;
60
            }
61 62
          }

63 64
          &:last-child {
            margin-right: 0;
65 66 67 68
          }
        }
      }

69
      .colophon-about {
70
        @include clearfix();
71

72 73 74 75 76
        img {
          width: 68px;
          height: 34px;
          margin-right: 0;
          float: left;
77 78
        }

79 80
        p {
          float: left;
81
          width: flex-grid(6,8);
82 83 84 85
          margin-left: $baseline;
          padding-left: $baseline;
          font-size: em(13);
          background: transparent url(/static/images/bg-footer-divider.jpg) 0 0 no-repeat;
86 87
        }
      }
88
    }
89

90 91
    // references
    .references {
92
      margin: -10px 0 0 0;
93
      width: flex-grid(4,12);
94 95
      display: inline-block;
    }
96

97
    .wrapper-logo {
98
      margin: ($baseline*0.75) 0;
99

100 101
      a {
        display: inline-block;
102

103 104 105 106 107
        &:hover {
          border-bottom: 0;
        }
      }
    }
108

109 110 111 112
    .copyright {
      margin: -2px 0 8px 0;
      font-size: em(11);
      color: $gray-l2;
113
      @include text-align(left);
114
    }
115

116 117
    .nav-legal {
      @include clearfix();
118
      @include text-align(left);
119

120 121 122 123
      li {
        display: inline-block;
        font-size: em(11);

124 125
      }

126
      .nav-legal-02 a {
127

128 129
        &:before {
          margin-right: ($baseline/4);
130 131
          content: "-";
        }
132
      }
133
    }
134

135 136 137
    .nav-social {
      margin: 0;
      text-align: right;
138

139 140
      li {
        display: inline-block;
141

142 143
        &:last-child {
          margin-right: 0;
144 145
        }

146 147
        a {
          display: block;
148

149 150
          &:hover, &:focus, &:active {
            border: none;
151 152
          }
        }
153 154 155 156

        img {
          display: block;
        }
157 158
      }
    }
159

160
    // platform Open edX logo and link
161
    .footer-about-openedx {
162
      @include float(right);
163 164 165
      width: flex-grid(3,12);
      display: inline-block;
      vertical-align: bottom;
166
      @include text-align(right);
167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190

      a {
        display: inline-block;

        &:hover {
          border-bottom: none;
        }
      }
    }
  }

  // edx theme overrides
  &.edx-footer {

    footer {

      .copyright {
        text-align: right;
      }

      .nav-legal {
        text-align: right;
      }
    }
191
  }
192 193 194
}

// marketing site design syncing
195
.view-register, .view-login, .view-passwordreset {
196 197 198 199 200 201 202 203

  .wrapper-footer footer {
    width: 960px;

    .colophon-about img {
      margin-top: ($baseline*1.5);
    }
  }
204
}
205 206 207 208 209


// edX theme: LMS Footer
// ====================
$edx-footer-spacing: ($baseline*0.75);
210
$edx-footer-link-color: $link-color;
211
$edx-footer-bg-color: rgb(252,252,252);
212 213 214 215 216 217

%edx-footer-reset {
  @include box-sizing(border-box);
}

%edx-footer-section {
Chris Rodriguez committed
218
  @include float(left);
219
  min-height: ($baseline*17.5);
Chris Rodriguez committed
220 221 222
  @include margin-right(flex-gutter());
  @include border-right(1px solid rgb(230, 230, 230));
  @include padding-right($baseline*1.5);
223 224 225

  // CASE: last child
  &:last-child {
Chris Rodriguez committed
226
    @include margin-right(0);
227
    border: none;
Chris Rodriguez committed
228
    @include padding-right(0);
229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289
  }
}

%edx-footer-title {
  // TODO: refactor _typography.scss to extend this set of styling
  @extend %t-title;
  @extend %t-weight4;
  @include font-size(15);
  @include line-height(15);
  text-transform: none;
  letter-spacing: inherit;
  color: rgb(61, 62, 63);
}

%edx-footer-link {
  @extend %t-copy-sub1;
  @include transition(color $tmg-f2 ease-in-out 0);
  display: block;
  margin-bottom: ($baseline/2);

  // NOTE: resetting poor link styles
  border: none;
  padding: 0;
  color: $edx-footer-link-color;

  .copy {
    @include transition(border-color $tmg-f2 ease-in-out 0);
    display: inline-block;
    border-bottom: 1px solid transparent;
    padding: 0 0 ($baseline/20) 0;
    color: $edx-footer-link-color;
  }

  // STATE: hover + focused
  &:hover, &:focus {
    color: saturate($edx-footer-link-color, 25%);

    // NOTE: resetting poor link styles
    border: none;

    .copy {
      border-bottom-color: saturate($edx-footer-link-color, 25%);
    }
  }

  // CASE: last child
  &:last-child {
    margin-bottom: 0;
  }

  // CASE: has visual emphasis
  &.has-emphasis {
    @extend %t-weight4;

    .copy {
      @extend %t-weight4;
    }
  }
}

.edx-footer-new {
290
  background: $edx-footer-bg-color;
291

292 293 294 295
  @media print {
    @include padding(10px, 10px, 0, 10px);
  }

296 297 298 299 300 301 302 303 304 305 306
  // NOTE: resetting older footer styles - can be removed once not needed
  box-shadow: none;
  border-top: none;
  padding: ($baseline*2) $baseline;

  // about
  // --------------------
  .footer-about {
    @extend %edx-footer-reset;
    @extend %edx-footer-section;
    width: flex-grid(6,12);
307 308 309 310 311 312 313 314

    @media print {
      @include margin-right(0);
      @include padding-right(0);
      width: flex-grid(12,12);
      border: none;
      min-height: 0;
    }
315 316 317 318
  }

  .footer-about-title {
    @extend %edx-footer-title;
319
    @extend %ui-print-excluded;
320 321
  }

322
  .footer-about-logo, .footer-about-openedx {
323
    margin-bottom: $edx-footer-spacing;
324 325 326 327 328 329 330 331 332 333 334 335 336 337 338

    img {
      height: 47px;
    }

    a {
      display: block;

      &:hover {
        border-bottom: 0;
      }
    }
  }

  .footer-about-logo {
339
    @include float(left);
340
    @extend %ui-print-excluded;
341 342 343
  }

  .footer-about-openedx-logo {
344
    @include float(right);
345 346 347
    @media print {
      @include float(left);
    }
348 349 350 351
  }

  .footer-about-copy {
    @extend %t-copy-sub1;
352
    @extend %ui-print-excluded;
353 354
    margin-bottom: $edx-footer-spacing;
    color: rgb(61, 62, 63);
355
    clear: both;
356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371

    p {
      // NOTE: needed for poor LMS span styling
      color: inherit;
    }
  }

  .footer-about-copyright {
    @extend %t-copy-sub1;
    margin-bottom: $edx-footer-spacing;
    color: rgb(138, 140, 143);

    p {
      // NOTE: needed for poor LMS span styling
      color: inherit;
    }
372 373 374 375 376 377

    a {
      @extend %edx-footer-link;
      display: inline-block;
      margin-bottom: ($edx-footer-spacing/2);
    }
378 379 380 381

    @media print {
      margin-bottom: 0;
    }
382 383 384
  }

  .footer-about-links {
385
    @extend %ui-print-excluded;
386 387 388 389 390 391 392 393 394 395 396 397 398 399 400 401

    a {
      @extend %edx-footer-link;
      margin-bottom: ($edx-footer-spacing/2);
    }

    .note {
      color: rgb(138, 140, 143);
    }
  }

  // nav (learn more links)
  // --------------------
  .footer-nav {
    @extend %edx-footer-reset;
    @extend %edx-footer-section;
402
    @extend %ui-print-excluded;
403 404 405 406 407
    width: flex-grid(3,12);
  }

  .footer-nav-title {
    @extend %edx-footer-title;
408
    margin-top: $baseline;
409 410 411 412 413 414 415 416 417 418 419 420 421 422 423
  }

  .footer-nav-links {
    margin-bottom: ($edx-footer-spacing*2.25);

    a {
      @extend %edx-footer-link;
    }
  }

  // follow (social media)
  // --------------------
  .footer-follow {
    @extend %edx-footer-reset;
    @extend %edx-footer-section;
424
    @extend %ui-print-excluded;
425 426 427 428 429
    width: flex-grid(3,12);
  }

  .footer-follow-title {
    @extend %edx-footer-title;
430
    margin-top: $baseline;
431 432 433 434 435 436
  }

  .footer-follow-links {

    a {
      @extend %edx-footer-link;
437
      margin-top: $baseline;
438 439 440 441 442 443 444 445 446 447 448 449 450 451 452 453 454 455 456

      .icon, .copy {
        display: inline-block;
        vertical-align: middle;
      }

      .icon {
        @extend %t-icon3;
        margin-right: ($baseline/4);
        text-align: center;
        min-width: ($baseline*1.5);
      }

      .copy {
        // NOTE: needed for poor LMS span styling
        color: inherit;
      }
    }
  }
457 458 459 460 461 462 463 464 465 466 467 468

  &.rwd {
    @include box-sizing(border-box);
    @include outer-container;

    &.wrapper-footer footer {
      min-width: 0;
    }

    .footer-about,
    .footer-nav,
    .footer-follow {
469
      @include span-columns(12);
470 471
    }

472
    @include media( $edx-bp-medium ) {
473 474
    }

475
    @include media( $edx-bp-large ) {
476 477 478 479 480 481 482 483 484 485
      .footer-about {
        @include span-columns(6);
      }

      .footer-nav,
      .footer-follow {
        @include span-columns(3);
      }
    }
  }
486 487 488 489 490 491 492 493 494 495 496 497 498 499 500 501 502 503 504 505 506 507 508 509 510 511 512 513

  // App links
  // --------------------
  .footer-mobile-apps {
    padding-top: 20px;

    .mobile-app-wrapper {
      margin: 0 0 10px 0;
    }

    a {
      display: inline-block;

      &:hover {
        border: none;
      }
    }

    .app-store {
      height: auto;
      width: 129px;
    }

    .google-play {
      height: auto;
      width: 129px;
    }
  }
514
}